问答详情
源自:3-1 创建项目引入jar包-SSH环境搭建

Error creating bean with name 'sessionFactory' defined in class path resource [applicationContext.xml]: Invocation of init method failed; nested exception is java.lang.NoClassDefFoundError: javax/persistence/Entity

这个怎么啦:

Error creating bean with name 'sessionFactory' defined in class path resource [applicationContext.xml]: Invocation of init method failed; nested exception is java.lang.NoClassDefFoundError: javax/persistence/Entity 

提问者:change_224235553 2016-11-22 10:15

个回答

  • 醉清风tomorrow
    2016-11-22 10:16:36
    已采纳

    有可能少了jpa的jar包

  • 慕尼黑8761269
    2016-11-30 02:29:32

    看你的applicationContext.xml文件的配置,setter注入时是不是用的接口,dao实现类有没有继承applicationsupp什么那个类