Caused by: java.lang.IllegalArgumentException: El mapeo de filtro especifica un nombre desconocido de filtro struts2
at org.apache.catalina.core.StandardContext.validateFilterMap(StandardContext.java:3040)
at org.apache.catalina.core.StandardContext.addFilterMap(StandardContext.java:3005)
at org.apache.catalina.deploy.WebXml.configureContext(WebXml.java:1271)
at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1346)
at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:878)
at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:376)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5322)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 7 more
有什么问题吗?我使用Apache Tomcat 7,使用以下3个jar: -bootstrap.jar, - Tomcat - julia .jar和-JRE系统库[jre7]。另一个JAR丢失了吗?问题在哪里?
本地化日志:NEVER是个好选择。
由:java.lang.IllegalArgumentException: El mapeo de filter to particular unnombre desconocido de filter to structs2
又名
原因:java.lang.IllegalArgumentException: Filter mapping指定了一个未知的Filter name struts2
是告诉你,问题是在你的Struts过滤器配置在web.xml
,最有可能的是你的<filter>
指定的<filter-name>
与<filter-mapping>
指定的<filter-name>
不同。
<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>