aused by: java.lang.IllegalArgumentException: More than one fragment with the name [spring_web] was

今天在搭建springweb應用環境的時候啓動tomcat報錯More than one fragment with the name [spring_web] was found. This is not legal ...

部分錯誤:

 Caused by: java.lang.IllegalArgumentException: More than one fragment with the name [spring_web] was found. This is not legal with relative ordering.
 See section 8.2.2 2c of the Servlet specification for details. Consider using absolute ordering.
                at org.apache.tomcat.util.descriptor.web.WebXml.orderWebFragments(WebXml.java:2257)
                at org.apache.tomcat.util.descriptor.web.WebXml.orderWebFragments(WebXml.java:2215)
                at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1134)
                at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:775)
                at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:301)
                at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123)
                at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5048)
                at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
                ... 26 more

解決辦法就是:

在web.xml加一個標籤:<absolute-ordering />

參考:http://www.bubuko.com/infodetail-3090661.html

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章