升级到Hibernate 3.5.0后,使用Web应用程序启动Tomcat实例时,出现以下异常:

org.hibernate.annotations.common.AssertionFailure: Fail to process type argument in a generic declaration. Type: class sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl
 at org.hibernate.ejb.metamodel.AttributeFactory$PluralAttributeMetadataImpl.getClassFromGenericArgument(AttributeFactory.java:836)
 at org.hibernate.ejb.metamodel.AttributeFactory$PluralAttributeMetadataImpl.getClassFromGenericArgument(AttributeFactory.java:833)
 at org.hibernate.ejb.metamodel.AttributeFactory$PluralAttributeMetadataImpl.<init>(AttributeFactory.java:748)
 at org.hibernate.ejb.metamodel.AttributeFactory$PluralAttributeMetadataImpl.<init>(AttributeFactory.java:723)
 at org.hibernate.ejb.metamodel.AttributeFactory.determineAttributeMetadata(AttributeFactory.java:518)
 at org.hibernate.ejb.metamodel.AttributeFactory.buildAttribute(AttributeFactory.java:93)


由于这是在Tomcat启动时发生的,因此我不知道在代码中查找的位置以防止这种情况:-(

最佳答案

将错误消息发送给Google,可能会向您显示许多解释,包括此JIRA问题:

http://opensource.atlassian.com/projects/hibernate/browse/HHH-5098

09-26 17:17