-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Named datasource not found on DevServices #21387
Comments
/cc @stuartwdouglas |
geoand
added a commit
to geoand/quarkus
that referenced
this issue
Dec 1, 2021
Because of how the Quarkus Runtime Config objects are populated for map fields (like the named datasources), it so happened that when a user configured a jdbc property for a named datasource, the DevServices provided URL for that datasource was not ending up in DataSourceJdbcRuntimeConfig. Fixes: quarkusio#21387
geoand
added a commit
to geoand/quarkus
that referenced
this issue
Dec 1, 2021
Because of how the Quarkus Runtime Config objects are populated for map fields (like the named datasources), it so happened that when a user configured a jdbc property for a named datasource, the DevServices provided URL for that datasource was not ending up in DataSourceJdbcRuntimeConfig. Fixes: quarkusio#21387
geoand
added a commit
to geoand/quarkus
that referenced
this issue
Dec 1, 2021
Because of how the Quarkus Runtime Config objects are populated for map fields (like the named datasources), it so happened that when a user configured a jdbc property for a named datasource, the DevServices provided URL for that datasource was not ending up in DataSourceJdbcRuntimeConfig. Fixes: quarkusio#21387
stuartwdouglas
added a commit
that referenced
this issue
Dec 1, 2021
Fix named datasource handling for dev-services
gsmet
pushed a commit
to gsmet/quarkus
that referenced
this issue
Dec 9, 2021
Because of how the Quarkus Runtime Config objects are populated for map fields (like the named datasources), it so happened that when a user configured a jdbc property for a named datasource, the DevServices provided URL for that datasource was not ending up in DataSourceJdbcRuntimeConfig. Fixes: quarkusio#21387 (cherry picked from commit 5494549)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
While using Dev Services and hibernate, a named datasource that includes a jdbc configuration (e.g. quarkus.datasource."datasource-name".jdbc.min-size) while cause the following error when starting Quarkus.
Caused by: java.lang.RuntimeException: io.quarkus.runtime.configuration.ConfigurationException: Model classes are defined for the default persistence unit nameds but configured datasource nameds not found: the default EntityManagerFactory will not be created. To solve this, configure the default datasource. Refer to https://quarkus.io/guides/datasource for guidance.
Removing the configuration or declaring it with the %prod profile, does not cause the problem.
Also, this does not seem to happen with the default datasource.
Expected behavior
Configurations such as quarkus.datasource."datasource-name".jdbc.min-size did not cause the mentioned issue.
Actual behavior
How to Reproduce?
Configuring Quarkus project using a named datasource with the following example configuration, and running it in dev-mode.
Output of
uname -a
orver
No response
Output of
java -version
11
GraalVM version (if different from Java)
No response
Quarkus version or git rev
2.4.1.Final
Build tool (ie. output of
mvnw --version
orgradlew --version
)No response
Additional information
No response
The text was updated successfully, but these errors were encountered: