-
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
Hibernate ORM 6.2 - NullPointerException in TupleMappingModelExpressible #36363
Comments
Thanks for reporting. This looks more like a bug (potentially in Hibernate ORM itself) than something missing from the migration guide. That being said, I think the reproducer would be slightly more useful if it included the query that triggers the failure :] What's the code of |
It would help immensely if you could put together a self contained reproducer. Thanks! |
cc/ @beikov |
@gsmet I was finally able to get together a self-contained reproducer, but I'm not get the error. So it's definitely something with my company's baseline/configuration. But I'm not sure where to go from here to track down the issue, since the error is deep in the guts of Hibernate. |
@mikethecalamity In my experience the only way to proceed in these cases is to build the reproducer by basically copy-pasting your whole project to a new one, then stripping it down little by little, regularly checking whether the bug is still there. It's ready when you can't remove anything without eliminating the bug. In particular, make sure to use Quarkus in your reproducer, at least at first, because Quarkus does customize Hibernate ORM significantly and this can lead ORM to behave differently than with its default settings, including different bugs. |
I am experiencing the same bug in Spring Boot 3.1.4. |
Thanks for letting us know @ingalemart! Did you report this to the ORM project already? Do you have a link? |
Yes, here is the ticket: https://hibernate.atlassian.net/browse/HHH-17332 |
Thanks! I updated the labels. |
@ingalemart is there any workaround that you've found? |
@mikethecalamity Unfortunately I couldn't find a proper workaround, but I guess you could revert to Hibernate ORM 6.2.4 or earlier, or you could try to rewrite your query so that it does not need an anonoymous tuple. Maybe you could split it into two separate queries or use a self join |
Thanks @ingalemart, that works for now, I added to my configurations.all {
resolutionStrategy {
force 'org.hibernate.orm:hibernate-core:6.2.4.Final'
}
} |
@ingalemart any word on whether the Hibernate folks fixed this issue? And if so what version has the fix |
As @ingalemart wrote, this was reported as https://hibernate.atlassian.net/browse/HHH-17332, which is fixed in several versions, as you can see by following the link. |
Has anyone still seen this in Hibernate 6.4? I've been working on upgrading our services to Quarkus 3.9.3 (which uses the latest Hibernate 6.4.4) and I still see this issue. But the reproducer linked in the hibernate issue does now pass with 6.4.4. So I am at a loss as to why this issue would still be happening and cannot get it to reproduce in a vacuum. |
@mikethecalamity can you please try to write a reproducer based on this code, which provides a closer environment to quarkus? https://github.com/hibernate/hibernate-test-case-templates/blob/main/orm/hibernate-orm-6/src/test/java/org/hibernate/bugs/QuarkusLikeORMUnitTestCase.java If you manage to reproduce, please open a new issue with a link to this one . |
Describe the bug
I am attempting to migrate from Quarkus 2.16.8 to 3.3.3 and I receive a NPE when running a query using the new version. Everything worked before and I thought I made all the necessary updates in the migration guide.
I'm assuming something is missing from my migration or configuration, but I can't determine what.
Expected behavior
Actual behavior
No failure
How to Reproduce?
Build Gradle:
Code:
Config:
Output of
uname -a
orver
No response
Output of
java -version
Temurin 17.0.8
GraalVM version (if different from Java)
No response
Quarkus version or git rev
3.3.3
Build tool (ie. output of
mvnw --version
orgradlew --version
)Gradle 8.3
Additional information
No response
The text was updated successfully, but these errors were encountered: