hibernate学习笔记1(javax.persistence.Cacheable)

Exception in thread "main" java.lang.NoClassDefFoundError: javax/persistence/Cacheable

Caused by: java.lang.ClassNotFoundException: javax.persistence.Cacheable

错误原因,javax.persistence.Cacheable 是 JPA 2.0 规范中的东西!

需要加入hibernate-distribution-3.5.0-Final/lib/jpa目录下的hibernate-jpa-2.0-api-1.0.0.Final.jar

你可能感兴趣的:(thread,exception,Hibernate,jpa)