Skip to content
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

Hibernate Reactive extension ignores quarkus.hibernate-orm.datasource #39049

Open
yrodiere opened this issue Feb 28, 2024 · 5 comments
Open

Hibernate Reactive extension ignores quarkus.hibernate-orm.datasource #39049

yrodiere opened this issue Feb 28, 2024 · 5 comments
Labels
area/hibernate-reactive Hibernate Reactive kind/bug Something isn't working

Comments

@yrodiere
Copy link
Member

Describe the bug

The fact that the extension doesn't support named persistence units is documented, but nowhere in the documentation does it say we can't have the default PU point to a named datasource.

Expected behavior

No response

Actual behavior

No response

How to Reproduce?

No response

Output of uname -a or ver

No response

Output of java -version

No response

Quarkus version or git rev

No response

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

No response

Additional information

We should either document this limitation and improve feedback (error on picking a named datasource), or add support for named datasources in the Hibernate Reactive extension. I think we may as well do the latter as it's simpler.

While we're at it, we could improve build-time errors when the datasource Hibernate Reactive is supposed to use isn't configured: https://github.com/quarkusio/quarkus/pull/39005/files#r1503049286
And we could even have a more precise message when the datasource isn't reactive...

@yrodiere yrodiere added the kind/bug Something isn't working label Feb 28, 2024
@quarkus-bot quarkus-bot bot added area/hibernate-reactive Hibernate Reactive area/persistence OBSOLETE, DO NOT USE labels Feb 28, 2024
Copy link

quarkus-bot bot commented Feb 28, 2024

/cc @DavideD (hibernate-reactive), @gavinking (hibernate-reactive)

@mkouba
Copy link
Contributor

mkouba commented Feb 28, 2024

The fact that the extension doesn't support named persistence units is documented, but nowhere in the documentation does it say we can't have the default PU point to a named datasource.

We do mention this in the limitations but the configuration section contains unsupported properties (for example quarkus.hibernate-orm.datasource) which is IMO quite confusing...

@yrodiere
Copy link
Member Author

We do mention this in the limitations

Are you sure? Maybe I'm dumb but I don't see anything. Note a named persistence unit is not a named datasource.

but the configuration section contains unsupported properties (for example quarkus.hibernate-orm.datasource) which is IMO quite confusing...

Yeah that can't be helped until we work on #13425 to properly separate Hibernate ORM from Hibernate Reactive. There were some shortcuts taken when initially integrating HR and they resulted in a massive technical debt.

@mkouba
Copy link
Contributor

mkouba commented Feb 28, 2024

We do mention this in the limitations

Are you sure? Maybe I'm dumb but I don't see anything. Note a named persistence unit is not a named datasource.

Yes, I was talking about the PU, i.e. this part: "it’s not possible to configure multiple persistence units, or even a single named persistence unit"... My point is that some of the config properties in the doc are useless, including https://quarkus.io/guides/hibernate-reactive#quarkus-hibernate-orm_quarkus-hibernate-orm-persistence-units-additional-named-persistence-units...

@yrodiere
Copy link
Member Author

Ok so that's what I thought: the limitation is not documented.

And yes the list of configuration properties is confusing. It changes on 3.9, but I'm not sure it's less confusing :/ https://quarkus.io/version/main/guides/hibernate-reactive#hr-configuration-properties

@yrodiere yrodiere removed the area/persistence OBSOLETE, DO NOT USE label Aug 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/hibernate-reactive Hibernate Reactive kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants