The JPA specification is like a Java interface, However, when it comes to performance, implementation details matter a lot. That’s why, even if you use the JPA standard, you still need to know how the underlying provider implements the standard specification.
For instance, if we take this tweet from Gareth Western:
We can clearly see that there is an issue in the way literals might be handled by Hibernate when executing a Criteria API query.
Therefore, in this article, we are going to see how literals are handled by Hibernate and explain what we have changed in Hibernate 5.2.12.