`

com.opensymphony.xwork2.config.ConfigurationException: Cannot locate the

    博客分类:
  • ssh
阅读更多
com.opensymphony.xwork2.config.ConfigurationException: Cannot locate the
chosen ObjectFactory implementation: spring
at org.apache.struts2.config.BeanSelectionProvider.alias(BeanSelectionProvider.java:287)
at org.apache.struts2.config.BeanSelectionProvider.alias(BeanSelectionProvider.java:258)
看了网上很多帖子,说是缺少struts2和spring整合包struts2-spring-plugin-XXX.jar,但是我工程里面已经有了这个包,后来看到说在struts.properties里把struts.objectFactory=spring改成struts.objectFactory=com.opensymphony.xwork2.ObjectFactory,果真就可以了,如下,在struts.xml中把
<constant name="struts.objectFactory" value="spring" /> 改为:
<constant name="struts.objectFactory" value="com.opensymphony.xwork2.ObjectFactory" />
不知道这样会不会有影响?请知道的朋友指导一下!
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics