Skip to content

HHH-17002 enable use of query plan cache for Jakarta Data Orders and Restrictions #10021

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

Closed
wants to merge 1 commit into from

Conversation

gavinking
Copy link
Member

@gavinking gavinking commented Apr 14, 2025

@beikov something's wrong here, since the tests broke. Is there something special I need to do, or perhaps there's a bug?

[Please describe here what your change is about]


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license
and can be relicensed under the terms of the LGPL v2.1 license in the future at the maintainers' discretion.
For more information on licensing, please check here.


https://hibernate.atlassian.net/browse/HHH-17002

@beikov
Copy link
Member

beikov commented Apr 15, 2025

So right now, caching of criteria queries depends on a session level setting QuerySettings.CRITERIA_PLAN_CACHE_ENABLED/Session#setCriteriaPlanCacheEnabled(). I wasn't sure if we wanted to cache all criteria queries by default, but assumed it might not be appropriate. Also, there is a sort of tension between caching based on HQL representation and the object identity of the criteria query if criteria tree copying is disabled.

Maybe we can discuss this a bit on Wednesday?

@gavinking
Copy link
Member Author

OK, sure 👍

@hibernate-github-bot
Copy link

hibernate-github-bot bot commented Apr 18, 2025

Thanks for your pull request!

This pull request appears to follow the contribution rules.

› This message was automatically generated.

…Restrictions

shows that something's wrong, since the tests broke
@gavinking
Copy link
Member Author

Closing, since the query plan cache is still based on object identity for criteria queries.

@gavinking gavinking closed this Apr 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants