JBoss Community

Error when open SessionFacoty in Eclipse's Hibernate Perspective

created by spring liao in JBoss Tools - View the full discussion

Hi,

Following is my application/development enviroment:

1.Eclipse 3.7.2/Indigo SR2

2.jboss tools 3.3.1.Final

3.hibernate-orm 4.1.7.Final

4.Joda Time 2.1

5.usertype 3.0.0.CR3

 

My domain class use joda time LocalDateTime type and UserType annotation:

 

@Column(name = "START")

@Type(type = "org.jadira.usertype.dateandtime.joda.PersistentLocalDateTime")

private org.joda.time.LocalDateTime start;

 

Both my application and development enviroment work properly except the only one issue:

When I open Hibernate Perspective in Eclipse then click SessionFactory to open it

, the following exception raised and failed to open.

I am not sure it is jboss tools or usertype problem ?

--------------------------------begin error log--------------------------------

!ENTRY org.hibernate.eclipse.console 4 4 2012-09-24 15:06:26.609

!MESSAGE Problems while creating sessionfactory

!SUBENTRY 1 org.hibernate.eclipse.console 4 150 2012-09-24 15:06:26.609

!MESSAGE java.lang.VerifyError: (class: org/jadira/usertype/spi/shared/AbstractTimestampColumnMapper, method: getHibernateType signature: ()Lorg/hibernate/type/AbstractStandardBasicType;) Wrong return type in function

!STACK 0

java.lang.VerifyError: (class: org/jadira/usertype/spi/shared/AbstractTimestampColumnMapper, method: getHibernateType signature: ()Lorg/hibernate/type/AbstractStandardBasicType;) Wrong return type in function

at java.lang.Class.getDeclaredConstructors0(Native Method)

at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)

at java.lang.Class.getConstructor0(Class.java:2699)

at java.lang.Class.newInstance0(Class.java:326)

at java.lang.Class.newInstance(Class.java:308)

at org.jadira.usertype.spi.shared.AbstractSingleColumnUserType.<init>(AbstractSingleColumnUserType.java:41)

at org.jadira.usertype.dateandtime.joda.PersistentLocalDateTime.<init>(PersistentLocalDateTime.java:31)

at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)

at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)

at java.lang.reflect.Constructor.newInstance(Constructor.java:513)

at java.lang.Class.newInstance0(Class.java:355)

at java.lang.Class.newInstance(Class.java:308)

at org.hibernate.type.CustomType.<init>(CustomType.java:75)

at org.hibernate.type.TypeFactory.heuristicType(TypeFactory.java:301)

at org.hibernate.mapping.SimpleValue.getType(SimpleValue.java:282)

at org.hibernate.tuple.PropertyFactory.buildStandardProperty(PropertyFactory.java:143)

at org.hibernate.tuple.component.ComponentMetamodel.<init>(ComponentMetamodel.java:68)

at org.hibernate.mapping.Component.buildType(Component.java:183)

at org.hibernate.mapping.Component.getType(Component.java:176)

at org.hibernate.mapping.SimpleValue.isValid(SimpleValue.java:275)

at org.hibernate.mapping.Collection.validate(Collection.java:301)

at org.hibernate.mapping.Set.validate(Set.java:42)

at org.hibernate.cfg.Configuration.validate(Configuration.java:1197)

at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1378)

at org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:954)

at org.hibernate.console.ConsoleConfiguration$5.execute(ConsoleConfiguration.java:278)

at org.hibernate.console.execution.DefaultExecutionContext.execute(DefaultExecutionContext.java:63)

at org.hibernate.console.ConsoleConfiguration.execute(ConsoleConfiguration.java:107)

at org.hibernate.console.ConsoleConfiguration.buildSessionFactory(ConsoleConfiguration.java:273)

at org.hibernate.eclipse.console.workbench.LazySessionFactoryAdapter.getChildren(LazySessionFactoryAdapter.java:43)

at org.hibernate.eclipse.console.workbench.BasicWorkbenchAdapter.getChildren(BasicWorkbenchAdapter.java:100)

at org.hibernate.eclipse.console.workbench.BasicWorkbenchAdapter.fetchDeferredChildren(BasicWorkbenchAdapter.java:106)

at org.eclipse.ui.progress.DeferredTreeContentManager$1.run(DeferredTreeContentManager.java:235)

at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

!SUBENTRY 2 org.hibernate.eclipse.console 4 150 2012-09-24 15:06:26.625

!MESSAGE java.lang.VerifyError: (class: org/jadira/usertype/spi/shared/AbstractTimestampColumnMapper, method: getHibernateType signature: ()Lorg/hibernate/type/AbstractStandardBasicType;) Wrong return type in function

!STACK 0

java.lang.VerifyError: (class: org/jadira/usertype/spi/shared/AbstractTimestampColumnMapper, method: getHibernateType signature: ()Lorg/hibernate/type/AbstractStandardBasicType;) Wrong return type in function

at java.lang.Class.getDeclaredConstructors0(Native Method)

at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)

at java.lang.Class.getConstructor0(Class.java:2699)

at java.lang.Class.newInstance0(Class.java:326)

at java.lang.Class.newInstance(Class.java:308)

at org.jadira.usertype.spi.shared.AbstractSingleColumnUserType.<init>(AbstractSingleColumnUserType.java:41)

at org.jadira.usertype.dateandtime.joda.PersistentLocalDateTime.<init>(PersistentLocalDateTime.java:31)

at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)

at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)

at java.lang.reflect.Constructor.newInstance(Constructor.java:513)

at java.lang.Class.newInstance0(Class.java:355)

at java.lang.Class.newInstance(Class.java:308)

at org.hibernate.type.CustomType.<init>(CustomType.java:75)

at org.hibernate.type.TypeFactory.heuristicType(TypeFactory.java:301)

at org.hibernate.mapping.SimpleValue.getType(SimpleValue.java:282)

at org.hibernate.tuple.PropertyFactory.buildStandardProperty(PropertyFactory.java:143)

at org.hibernate.tuple.component.ComponentMetamodel.<init>(ComponentMetamodel.java:68)

at org.hibernate.mapping.Component.buildType(Component.java:183)

at org.hibernate.mapping.Component.getType(Component.java:176)

at org.hibernate.mapping.SimpleValue.isValid(SimpleValue.java:275)

at org.hibernate.mapping.Collection.validate(Collection.java:301)

at org.hibernate.mapping.Set.validate(Set.java:42)

at org.hibernate.cfg.Configuration.validate(Configuration.java:1197)

at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1378)

at org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:954)

at org.hibernate.console.ConsoleConfiguration$5.execute(ConsoleConfiguration.java:278)

at org.hibernate.console.execution.DefaultExecutionContext.execute(DefaultExecutionContext.java:63)

at org.hibernate.console.ConsoleConfiguration.execute(ConsoleConfiguration.java:107)

at org.hibernate.console.ConsoleConfiguration.buildSessionFactory(ConsoleConfiguration.java:273)

at org.hibernate.eclipse.console.workbench.LazySessionFactoryAdapter.getChildren(LazySessionFactoryAdapter.java:43)

at org.hibernate.eclipse.console.workbench.BasicWorkbenchAdapter.getChildren(BasicWorkbenchAdapter.java:100)

at org.hibernate.eclipse.console.workbench.BasicWorkbenchAdapter.fetchDeferredChildren(BasicWorkbenchAdapter.java:106)

at org.eclipse.ui.progress.DeferredTreeContentManager$1.run(DeferredTreeContentManager.java:235)

at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

---------------------------------end error log---------------------------------

Reply to this message by going to Community

Start a new discussion in JBoss Tools at Community