quarkusio / quarkus

Quarkus: Supersonic Subatomic Java.
https://quarkus.io
Apache License 2.0
13.73k stars 2.67k forks source link

Devservices derby doesn't start because of missing resource bundle #21639

Closed JiriOndrusek closed 2 years ago

JiriOndrusek commented 2 years ago

Describe the bug

According to the documentation, zero config setup for Apache derby should work. But if it is used, there is an error preventing db to start:

java.util.MissingResourceException: Can't find bundle for base name org.apache.derby.loc.drda.messages, locale en
    at java.base/java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:2055)
    at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1689)
    at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1593)
    at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1556)
    at java.base/java.util.ResourceBundle.getBundle(ResourceBundle.java:932)
    at org.apache.derby.iapi.tools.i18n.LocalizedResource.setResource(Unknown Source)

Expected behavior

Derby dev service should start.

Actual behavior

No response

How to Reproduce?

Issue could be reproduced with quarkus-quickstart spring-data-jpa-quickstart

  1. Clone https://github.com/quarkusio/quarkus-quickstarts/
  2. Modify https://github.com/quarkusio/quarkus-quickstarts/blob/main/spring-data-jpa-quickstart/pom.xml#L40 to 'quarkus-jdbc-derby'
  3. From the quarkus-quickstarts/spring-data-jpa-quickstart run the test (i.e. mvn package)
  4. Test fails with
    Caused by: java.util.MissingResourceException: Can't find bundle for base name org.apache.derby.loc.drda.messages, locale en
    at java.base/java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:2055)
    at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1689)
    at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1593)
    at java.base/java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1556)
    at java.base/java.util.ResourceBundle.getBundle(ResourceBundle.java:932)
    at org.apache.derby.iapi.tools.i18n.LocalizedResource.setResource(Unknown Source)
    at org.apache.derby.iapi.tools.i18n.LocalizedResource.getTextMessage(Unknown Source)
    at org.apache.derby.impl.drda.NetworkServerControlImpl.localizeMessage(Unknown Source)
    at org.apache.derby.impl.drda.NetworkServerControlImpl.consolePropertyMessageWork(Unknown Source)
    at org.apache.derby.impl.drda.NetworkServerControlImpl.consolePropertyMessage(Unknown Source)
    at org.apache.derby.impl.drda.NetworkServerControlImpl.setUpSocket(Unknown Source)
    at org.apache.derby.impl.drda.NetworkServerControlImpl.ping(Unknown Source)
    at org.apache.derby.drda.NetworkServerControl.ping(Unknown Source)
    at io.quarkus.devservices.derby.deployment.DerbyDevServicesProcessor$1.startDatabase(DerbyDevServicesProcessor.java:42)

Output of uname -a or ver

No response

Output of java -version

No response

GraalVM version (if different from Java)

No response

Quarkus version or git rev

No response

Build tool (ie. output of mvnw --version or gradlew --version)

No response

Additional information

Workaround

Resource could be added manually into the app. Add following dependency into the https://github.com/quarkusio/quarkus-quickstarts/blob/main/spring-data-jpa-quickstart/pom.xml

        <dependency>
            <groupId>org.apache.derby</groupId>
            <artifactId>derbynet</artifactId>
            <scope>test</scope>
        </dependency>

and test is successful.

quarkus-bot[bot] commented 2 years ago

/cc @stuartwdouglas

geoand commented 2 years ago

What version of Quarkus does this failure occur with?

JiriOndrusek commented 2 years ago

@geoand I forgot to menioon it: 2.5.0.Final (tested with camel-quarkus test) and also 2.4.2.Final (tested with quarkus-quickstart)