Re: Doubt on Struts 2 Architechture
suppose, i'm not using timer interceptor and suppose i'm using timer interceptor then in such a case that interceptor only triggered but it's executing all interceptor in reverse order once again in post processing. why? -- View this message in context: http://struts.1045723.n5.nabble.com/Doubt-on-Struts-2-Architechture-tp4601232p4629574.html Sent from the Struts - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org
Re: Doubt on Struts 2 Architechture
On Mon, Jul 25, 2011 at 9:58 AM, mohan rao [via Struts] ml-node+4629574-1865382249-219...@n5.nabble.com wrote: suppose, i'm not using timer interceptor and suppose i'm using timer interceptor then in such a case that interceptor only triggered but it's executing all interceptor in reverse order once again in post processing. why? -- If you reply to this email, your message will be added to the discussion below: http://struts.1045723.n5.nabble.com/Doubt-on-Struts-2-Architechture-tp4601232p4629574.html To unsubscribe from Doubt on Struts 2 Architechture, click herehttp://struts.1045723.n5.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_codenode=4601232code=bW9oYW5hcmFvc3ZAZ21haWwuY29tfDQ2MDEyMzJ8NTQ5NjkzNDYy. -- View this message in context: http://struts.1045723.n5.nabble.com/Doubt-on-Struts-2-Architechture-tp4601232p4629652.html Sent from the Struts - User mailing list archive at Nabble.com.
Re: Doubt on Struts 2 Architechture
Actually, no, it's not executing them again, it's finishing the original execution. The interceptor does whatever it's supposed to do before the execution of the action, it then turns over control to Struts which decides whether there is another interceptor in the chain, or whether it's time to execute the action. When the action is done, the call returns control back to each interceptor in (as you said) reverse order where it can finish it's work. It's the simplest and most effective way of assuring the interceptors can do both pre-processing and post-processing. (*Chris*) On Sun, Jul 24, 2011 at 9:28 PM, mohan rao mohanara...@gmail.com wrote: suppose, i'm not using timer interceptor and suppose i'm using timer interceptor then in such a case that interceptor only triggered but it's executing all interceptor in reverse order once again in post processing. why? -- View this message in context: http://struts.1045723.n5.nabble.com/Doubt-on-Struts-2-Architechture-tp4601232p4629574.html Sent from the Struts - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org
SEVERE: Servlet.service() for servlet default threw exception, java.lang.IllegalStateException
Hello, I always get the following exception, does someone know why? web.xml filter filter-namestruts/filter-name filter-classorg.apache.struts2.dispatcher.FilterDispatcher/filter-class init-param param-nameactionPackages/param-name param-valueaction/param-value /init-param /filter filter-mapping filter-namestruts/filter-name url-pattern/*/url-pattern dispatcherREQUEST/dispatcher dispatcherINCLUDE/dispatcher /filter-mapping Thanks a lot! Emi -- SEVERE: Servlet.service() for servlet default threw exception java.lang.IllegalStateException at org.apache.catalina.connector.ResponseFacade.sendError(ResponseFacade.java:407) at org.apache.struts2.dispatcher.Dispatcher.sendError(Dispatcher.java:819) at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:519) at org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:434) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.displaytag.filter.ResponseOverrideFilter.doFilter(ResponseOverrideFilter.java:125) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:859) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489) at java.lang.Thread.run(Thread.java:662) - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org
Re: SEVERE: Servlet.service() for servlet default threw exception, java.lang.IllegalStateException
Hello, I tried dispatcher.ng.filter.StrutsPrepareAndExecuteFilter as well, but still got the following error. Could someone help? Thank you, Emi filter filter-namestruts2/filter-name filter-classorg.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter/filter-class init-param param-nameactionPackages/param-name param-valueaction/param-value /init-param /filter filter-mapping filter-namestruts2/filter-name url-pattern/*/url-pattern dispatcherREQUEST/dispatcher dispatcherINCLUDE/dispatcher /filter-mapping ---Exception --- org.apache.catalina.core.StandardWrapperValve invoke SEVERE: Servlet.service() for servlet default threw exception java.lang.IllegalStateException at org.apache.catalina.connector.ResponseFacade.sendError(ResponseFacade.java:407) at org.apache.struts2.dispatcher.Dispatcher.sendError(Dispatcher.java:819) at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:519) at org.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:77) at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:91) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:859) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489) at java.lang.Thread.run(Thread.java:662) On 07/25/2011 04:15 PM, Emi Lu wrote: Hello, I always get the following exception, does someone know why? web.xml filter filter-namestruts/filter-name filter-classorg.apache.struts2.dispatcher.FilterDispatcher/filter-class init-param param-nameactionPackages/param-name param-valueaction/param-value /init-param /filter filter-mapping filter-namestruts/filter-name url-pattern/*/url-pattern dispatcherREQUEST/dispatcher dispatcherINCLUDE/dispatcher /filter-mapping Thanks a lot! Emi -- SEVERE: Servlet.service() for servlet default threw exception java.lang.IllegalStateException at org.apache.catalina.connector.ResponseFacade.sendError(ResponseFacade.java:407) at org.apache.struts2.dispatcher.Dispatcher.sendError(Dispatcher.java:819) at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:519) at org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:434) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.displaytag.filter.ResponseOverrideFilter.doFilter(ResponseOverrideFilter.java:125) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:859) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489) at java.lang.Thread.run(Thread.java:662) - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org -- Emi Lu, ENCS, Concordia University, Montreal H3G 1M8 em...@encs.concordia.ca+1 514 848-2424 x5884 - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org
excludeMethods parameter question
Hello list! I'm making a research about Struts2 and there are several things that I don't understand (haha), I have studied really hard and I think I'm in the righ way now, but there's a thing that i don't understand about this examples i found about interceptors, i'm talking about the parameter excludeMethods. I have seen that most of the times it has input,back,cancel but I don't really know what does it mean. Can u help me guys please? -- Manolo Pájaro Santander Ingeniero de Sistemas VIII Semestre (Actual) Promoviendo el Software Libre CUSOL-UAC Linux Registered User # 522026
Re: excludeMethods parameter question
There are some interceptors, like validator one, which are not triggered in case of the name of the invoked method matches one of the list element (there is no reason to validate an input action, you don't yet obtain the user input, so you have anything to validate). Hope this help. Maurizio Cucchiara Il giorno 25/lug/2011 23.11, Mano Pájaro mano0...@gmail.com ha scritto: Hello list! I'm making a research about Struts2 and there are several things that I don't understand (haha), I have studied really hard and I think I'm in the righ way now, but there's a thing that i don't understand about this examples i found about interceptors, i'm talking about the parameter excludeMethods. I have seen that most of the times it has input,back,cancel but I don't really know what does it mean. Can u help me guys please? -- Manolo Pájaro Santander Ingeniero de Sistemas VIII Semestre (Actual) Promoviendo el Software Libre CUSOL-UAC Linux Registered User # 522026
Re: excludeMethods parameter question
Thanks Maurizio, let me see if i got it straight. You mean that, for example: interceptor-ref name=validation param name=excludeMethodsinput,back,cancel/param/interceptor-ref won't be executed by results whose name is input, back or cancel? 2011/7/25 Maurizio Cucchiara maurizio.cucchi...@gmail.com There are some interceptors, like validator one, which are not triggered in case of the name of the invoked method matches one of the list element (there is no reason to validate an input action, you don't yet obtain the user input, so you have anything to validate). Hope this help. Maurizio Cucchiara -- Manolo Pájaro Santander Ingeniero de Sistemas VIII Semestre (Actual) Promoviendo el Software Libre CUSOL-UAC Linux Registered User # 522026
Re: excludeMethods parameter question
Not exactly. It would not execute for actions whose method name is input, back or cancel. It's on the action side, not the result side. (*Chris*) On Mon, Jul 25, 2011 at 2:59 PM, Mano Pájaro mano0...@gmail.com wrote: Thanks Maurizio, let me see if i got it straight. You mean that, for example: interceptor-ref name=validation param name=excludeMethodsinput,back,cancel/param/interceptor-ref won't be executed by results whose name is input, back or cancel? 2011/7/25 Maurizio Cucchiara maurizio.cucchi...@gmail.com There are some interceptors, like validator one, which are not triggered in case of the name of the invoked method matches one of the list element (there is no reason to validate an input action, you don't yet obtain the user input, so you have anything to validate). Hope this help. Maurizio Cucchiara -- Manolo Pájaro Santander Ingeniero de Sistemas VIII Semestre (Actual) Promoviendo el Software Libre CUSOL-UAC Linux Registered User # 522026
Re: excludeMethods parameter question
I see mm so, it only acts on the action which method attribute is diferent from in the list, that's it? :D 2011/7/25 Chris Pratt thechrispr...@gmail.com Not exactly. It would not execute for actions whose method name is input, back or cancel. It's on the action side, not the result side. (*Chris*) -- Manolo Pájaro Santander Ingeniero de Sistemas VIII Semestre (Actual) Promoviendo el Software Libre CUSOL-UAC Linux Registered User # 522026
Re: excludeMethods parameter question
Exactly, so the default (execute) would run the validation, but not the ones that are listed. (*Chris*) On Mon, Jul 25, 2011 at 4:53 PM, Mano Pájaro mano0...@gmail.com wrote: I see mm so, it only acts on the action which method attribute is diferent from in the list, that's it? :D 2011/7/25 Chris Pratt thechrispr...@gmail.com Not exactly. It would not execute for actions whose method name is input, back or cancel. It's on the action side, not the result side. (*Chris*) -- Manolo Pájaro Santander Ingeniero de Sistemas VIII Semestre (Actual) Promoviendo el Software Libre CUSOL-UAC Linux Registered User # 522026
Re: excludeMethods parameter question
Thank u for everything! I will keep studying! :D -- Manolo Pájaro Santander Ingeniero de Sistemas VIII Semestre (Actual) Promoviendo el Software Libre CUSOL-UAC Linux Registered User # 522026
Re: SEVERE: Servlet.service() for servlet default threw exception, java.lang.IllegalStateException
2011/7/25 Emi Lu em...@encs.concordia.ca: filter-mapping filter-namestruts/filter-name url-pattern/*/url-pattern dispatcherREQUEST/dispatcher dispatcherINCLUDE/dispatcher /filter-mapping Did you try to remove these dispatcher params ? Or add FORWARD ? Regards -- Łukasz + 48 606 323 122 http://www.lenart.org.pl/ Warszawa JUG conference - Confitura http://confitura.pl/ - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org