原文地址:https://developer.jboss.org/wiki/HibernateFAQ-CommonProblems
I've enabled the second-level cache and my queries are not being cached!
The Hibernate second-level cache is different to the Hibernate query cache. The second level cache applies when objects are retrieved using get(), load() or navigation of associations. It does not apply to query result sets. You must use the query cache to cache HQL, SQL, or criteria query result sets.