注意:从14开始的错误都是JDK版本不同引起的,14楼上面几楼的错误jdk1.6的,跟14楼下面的是不相同,14楼以下几楼因为我是重新安装了OS使用的是jdk1.5所以出现java.lang.UnsupportedClassVersionError: Bad version number in .class file的错误,这是我另外找到的一个意外错误,错误解释请看:http://xling.blueidea.com/archives/2007/4283.shtml
所以现在的问题要解决本页上面的错误了!!!!
我在fedora 7 tomcat 6 ant 1.7 jdk 1.6环境下
使用ant -f build.xml
部署不成功,下面是tomcat log
[Copy to clipboard] [
- ]CODE:2007-9-27 16:34:17 org.apache.catalina.core.StandardContext listenerStart
严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'softWareCategoryDao' defined in ServletContext resource [/WEB-INF/spotmau-config/purchase/purchase-spring.xml]: Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/spotmau-config/global-spring.xml]: Invocation of init method failed; nested exception is org.hibernate.DuplicateMappingException: Duplicate class/entity mapping com.spotmau.myaccount.pojo.FileExtention
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/spotmau-config/global-spring.xml]: Invocation of init method failed; nested exception is org.hibernate.DuplicateMappingException: Duplicate class/entity mapping com.spotmau.myaccount.pojo.FileExtention
Caused by: org.hibernate.DuplicateMappingException: Duplicate class/entity mapping com.spotmau.myaccount.pojo.FileExtention
at org.hibernate.cfg.Mappings.addClass(Mappings.java:118)
at org.hibernate.cfg.HbmBinder.bindRoot(HbmBinder.java:145)
at org.hibernate.cfg.Configuration.add(Configuration.java:669)
at org.hibernate.cfg.Configuration.addInputStream(Configuration.java:504)
at org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(LocalSessionFactoryBean.java:656)
at org.springframework.orm.hibernate3.AbstractSessionFactoryBean.afterPropertiesSet(AbstractSessionFactoryBean.java:134)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1175)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1145)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:427)
发表评论