Hello,
I saw that there was no plan to enable @Filter for entity retrieval by ID: https://hibernate.atlassian.net/browse/HHH-11485
But unfortunately, our confidentiality mechanisms are based on the data filter.
WHERE CONFIDENTIALITE=ENTREPRISE_NAME
Suddenly that would prohibit using session.get () or load () or getId () otherwise we risk recovering data that should not be visible.
It’s still very restrictive …
The solution to still not pass a Query does not satisfy me either: java - How can I get an Entity by ID whilst applying a Hibernate @Filter? - Stack Overflow -filter
Difficult to form an opinion of how to do it, an idea?
Thank you
Vincent