项目部署Tomcat启动报错 求大神解答!
本帖最后由 百事PepsiCola丶 于 2014-5-2 17:03 编辑开发环境: MyEclipse 2014 / MySQL / Tomcat 7.x / JDK 1.8.0 / Maven 3.1.1
代码来源: http://git.oschina.net/jeecg/jeecg.git
错误信息: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'templetContext': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'freemarker' defined in URL : Initialization of bean failed; nested exception is org.springframework.beans.FatalBeanException: Failed to obtain BeanInfo for class ; nested exception is java.beans.IntrospectionException: type mismatch between read and write methods
目前猜测错误起因是因为重复注入. spring-mvc-cgform.xml
<!-- FreeMarker -->
<bean id="freemarker" class="freemarker.template.Configuration">
<property name="templateLoader" ref="templetLoader" />
<property name="defaultEncoding" value="UTF-8"></property>
<property name="numberFormat" value="0"></property>
</bean>
<!-- Template Context -->
<bean id="templetContext" class="org.jeecgframework.web.cgform.engine.TempletContext">
<property name="tags">
<map>
<entry key="DictData" value-ref="dictDataTag" />
</map>
</property>
</bean> spring-mvc-hibernate.xml
<context:component-scan base-package="org.jeecgframework.web.*">
<context:exclude-filter type="annotation" expression="org.springframework.stereotype.Controller" />
</context:component-scan> spring-mvc.xml
<context:component-scan base-package="org.jeecgframework.web.*">
<context:exclude-filter type="annotation" expression="org.springframework.stereotype.Service" />
</context:component-scan>
项目目录结构:
求各位大神帮忙,已经卡在这一天了!:dizzy:
先自己顶顶, 免得沉了!:( 好吧. 自己搞定了.
JDK 1.8 版本过高, 换成JDK 1.6 搞定.
:( 个人猜测应该是JDK 1.8 验证逻辑更加严谨. 遇到同样问题的童鞋们, 可以借鉴一下这个帖子!:victory: 可以支持JDK1.8,但是需要更新一下pom.xml 中的spring版本:<spring.version>3.2.9.RELEASE</spring.version>
产生这个问题的根源应该是spring在JDK1.8的问题,官方已经有修复版本,具体可以看spring的更新历史
页:
[1]