struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nils-Helge Garli Hegvik <nil...@gmail.com>
Subject Re: Getting Servlets and Struts 2.1.6 to work together?
Date Tue, 03 Mar 2009 18:59:16 GMT
You probably want to edit the url pattern of the struts 2 filter mapping.

Nils-H

On Tue, Mar 3, 2009 at 7:50 PM, Greg Lindholm <glindholm@yahoo.com> wrote:
> I'm trying to upgrade from Struts 2.0.11 to 2.1.6 and having a problem, struts isn't
passing requests thru to my servlets.
>
> I have a servlet named 'status' and defined in web.xml like this.
>
>     <servlet-mapping>
>         <servlet-name>StatusServlet</servlet-name>
>         <url-pattern>/status</url-pattern>
>     </servlet-mapping>
>
> After upgrading to 2.1.6 I now get the following exception when I try to go the the status
servlet.  I'm not (intentionally) using conventions or any other zero config-ish plugin.
It's looking for an action named 'status' which I don't have. I use a '.action' suffix for
all my action URL requests.
>
> 2009-03-03 13:41:05,692 WARN  org.apache.struts2.dispatcher.Dispatcher:49 - Could not
find action or result
> There is no Action mapped for namespace / and action name status. - [unknown location]
>     at com.opensymphony.xwork2.DefaultActionProxy.prepare(DefaultActionProxy.java:177)
>     at org.apache.struts2.impl.StrutsActionProxy.prepare(StrutsActionProxy.java:61)
>     at org.apache.struts2.impl.StrutsActionProxyFactory.createActionProxy(StrutsActionProxyFactory.java:39)
>     at com.opensymphony.xwork2.DefaultActionProxyFactory.createActionProxy(DefaultActionProxyFactory.java:47)
>     at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:458)
>     at org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:395)
>     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
>     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
>     at com.google.inject.servlet.GuiceFilter.doFilter(GuiceFilter.java:46)
>     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
>     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
>     at com.allmanint.common.servlet.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:61)
>     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
>     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
>     at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>     at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
>     at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
>     at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>     at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
>     at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
>     at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
>     at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:874)
>     at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
>     at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
>     at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
>     at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
>     at java.lang.Thread.run(Thread.java:619)
>
> So how do I get it to behave like 2.0.11 and pass any requests that don't have .action
suffix thru to the servlets?
>
>
>
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message