测试积点老人 发表于 2018-11-27 11:14:45

hibernate异常

请问这个是什么异常,该怎么解决?
org.hibernate.HibernateException: Unable to instantiate default tuplizer

at org.hibernate.tuple.entity.EntityTuplizerFactory.constructTuplizer(EntityTuplizerFactory.java:108)

at org.hibernate.tuple.entity.EntityTuplizerFactory.constructDefaultTuplizer(EntityTuplizerFactory.java:133)

at org.hibernate.tuple.entity.EntityEntityModeToTuplizerMapping.<init>(EntityEntityModeToTuplizerMapping.java:80)

at org.hibernate.tuple.entity.EntityMetamodel.<init>(EntityMetamodel.java:322)

at org.hibernate.persister.entity.AbstractEntityPersister.<init>(AbstractEntityPersister.java:485)

at org.hibernate.persister.entity.SingleTableEntityPersister.<init>(SingleTableEntityPersister.java:133)

at org.hibernate.persister.PersisterFactory.createClassPersister(PersisterFactory.java:84)

at org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:286)

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

at com.itheima.onetomany.onetomanytest.test1(onetomanytest.java:12)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

at java.lang.reflect.Method.invoke(Unknown Source)

at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)

at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)

at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)

at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)

at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)

at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)

at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)

at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)

at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)

at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)

at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)

at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)

at org.junit.runners.ParentRunner.run(ParentRunner.java:363)

at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:89)

at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:41)

at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:541)

at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:763)

at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:463)

at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:209)

Caused by: java.lang.reflect.InvocationTargetException

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

at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)

at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)

at java.lang.reflect.Constructor.newInstance(Unknown Source)

at org.hibernate.tuple.entity.EntityTuplizerFactory.constructTuplizer(EntityTuplizerFactory.java:105)

... 32 more

Caused by: org.hibernate.PropertyNotFoundException: Could not find a getter for Students in class com.itheima.onetomany.Grade

at org.hibernate.property.BasicPropertyAccessor.createGetter(BasicPropertyAccessor.java:326)

at org.hibernate.property.BasicPropertyAccessor.getGetter(BasicPropertyAccessor.java:320)

at org.hibernate.mapping.Property.getGetter(Property.java:330)

at org.hibernate.tuple.entity.PojoEntityTuplizer.buildPropertyGetter(PojoEntityTuplizer.java:297)

at org.hibernate.tuple.entity.AbstractEntityTuplizer.<init>(AbstractEntityTuplizer.java:155)

at org.hibernate.tuple.entity.PojoEntityTuplizer.<init>(PojoEntityTuplizer.java:77)

... 37 more

abcsell 发表于 2018-11-28 10:01:26

组件获取失败了

jingzizx 发表于 2018-11-28 11:07:05

缺少方法

qqq911 发表于 2018-11-28 11:21:52

重装下

海海豚 发表于 2018-11-28 13:22:56

https://www.cnblogs.com/e206842/p/6550605.html
页: [1]
查看完整版本: hibernate异常