WARN [deprecation] HHH90000022: Hibernate's legacy org.hibernate.Criteria API is deprecated; use the JPA javax.persistence.criteria.CriteriaQuery instead #558
The old hibernate Criteria query has been deprecated and is removed in hibernate 6.0 the next version. We need to update all of the places that we are using the old Criteria query to use the new JPA style query.
The old hibernate Criteria query has been deprecated and is removed in hibernate 6.0 the next version. We need to update all of the places that we are using the old Criteria query to use the new JPA style query.
Old Example:
Fixed Code: