Default schema for an additional persistence unit cannot be set during runtime #36838
Labels
area/hibernate-orm
Hibernate ORM
kind/bug
Something isn't working
triage/needs-feedback
We are waiting for feedback.
Describe the bug
When setting a default schema for an additional persistence unit (quarkus.hibernate-orm."persistence-unit-name".database.default-schema) it will be ignored, when not set during build time.
Expected behavior
If a schema is given via the property quarkus.hibernate-orm."persistence-unit-name".database.default-schema in an .env file, the schema should be used by hibernate when accessing the database.
Actual behavior
The default schema is only used, when the property quarkus.hibernate-orm."persistence-unit-name".database.default-schema is present in the application.properties, during build time.
How to Reproduce?
No response
Output of
uname -a
orver
Linux import-service-pnet-6bf995bd8-frw49 5.15.0-1049-azure #56-Ubuntu SMP Wed Sep 20 12:34:34 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
Output of
java -version
openjdk version "17.0.6" 2023-01-17 OpenJDK Runtime Environment Temurin-17.0.6+10 (build 17.0.6+10) OpenJDK 64-Bit Server VM Temurin-17.0.6+10 (build 17.0.6+10, mixed mode, sharing)
Quarkus version or git rev
3.5.0
Build tool (ie. output of
mvnw --version
orgradlew --version
)Apache Maven 3.8.6
Additional information
The database used is an AzureSQL database which has the restriction, that a default schema cannot be set for a connection. But as hibernate should build SQL statements, referencing the default schema, this should not be an issue.
The text was updated successfully, but these errors were encountered: