You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by wwyyzz_001 <51...@qq.com.INVALID> on 2022/09/09 02:05:30 UTC

When Struct 2.3.34 update Struct 2.5.30,the original interface cannot be accessed

Dear all:

Use Struct 2.3.34,one interface can invoke by two ways,example:

http://localhost:8080/wisdomcampus-gs/login&nbsp; can invoke, the interface can also be called under the subdirectory,

http://localhost:8080/wisdomcampus-gs/user/login&nbsp;can invoke,result is same.

Use Struct 2.5.30,one interface only invoke by one way, example:

http://localhost:8080/wisdomcampus-gs/login&nbsp; can invoke, the interface can't&nbsp; be called under the subdirectory,

http://localhost:8080/wisdomcampus-gs/user/login&nbsp;can't &nbsp;invoke, return error: No result defined for action wisdom.user.action.LoginAction and result success.




Why? How to config in Struct 2.5.30, can realization same result&nbsp; in Struct 2.3.34?&nbsp; &nbsp;

Look forward to your reply,&nbsp; &nbsp;thank you!




Mark wang

Re: When Struct 2.3.34 update Struct 2.5.30,the original interface cannot be accessed

Posted by Łukasz Lenart <lu...@gmail.com>.
And please use a proper name Struts, there is no Struct.

pt., 9 wrz 2022 o 12:48 Łukasz Lenart <lu...@gmail.com> napisał(a):
>
> Would you mind using some proper encoding? Your message is mess :\
> Have you tried to use 2.5 and then switch version by version? Also do
> you use the Convention plugin?
>
> Regards
> Łukasz
>
> pt., 9 wrz 2022 o 12:41 wwyyzz_001 <51...@qq.com.invalid> napisał(a):
> >
> > In Struct 2.3.34,when namespase="" is default namespase.
> > If invoke http://localhost:8080/wisdomcampus-gs/user/login,because /user not define,Struct find action in default namespase,so everythiong is ok.
> >
> >
> > But In Struct 2.5.30,config(struts.xml) is not change,invoke http://localhost:8080/wisdomcampus-gs/user/login, return error: No result defined for action wisdom.user.action.LoginAction and result success.
> > Find action was invoked in log,but not found result,so Struct throw exception in DefaultActionInvocation.executeResult(DefaultActionInvocation.java:377)
> > 1.executeResult source code:
> > &nbsp; &nbsp; private void executeResult() throws Exception {
> > &nbsp; &nbsp; &nbsp; &nbsp; result = createResult();
> >
> >
> > &nbsp; &nbsp; &nbsp; &nbsp; String timerKey = "executeResult: " + getResultCode();
> > &nbsp; &nbsp; &nbsp; &nbsp; try {
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; UtilTimerStack.push(timerKey);
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (result != null) {
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; result.execute(this);
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; } else if (resultCode != null &amp;&amp; !Action.NONE.equals(resultCode)) {
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; throw new ConfigurationException("No result defined for action " + getAction().getClass().getName()
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; + " and result " + getResultCode(), proxy.getConfig());
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; } else {
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (LOG.isDebugEnabled()) {
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; LOG.debug("No result returned for action {} at {}", getAction().getClass().getName(), proxy.getConfig().getLocation());
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }
> > &nbsp; &nbsp; &nbsp; &nbsp; } finally {
> > &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; UtilTimerStack.pop(timerKey);
> > &nbsp; &nbsp; &nbsp; &nbsp; }
> > &nbsp; &nbsp; }
> >
> >
> >
> > 2.Struct console log:
> > 2022-09-09 18:32:16 [http-nio-8080-exec-1] DEBUG SecurityMemberAccess:67 - Checking access for [target: wisdom.user.action.LoginAction@3fd415d2, member: public
> > final java.lang.String wisdom.common.JsonActionBase.execute() throws java.lang.Exception, property: null]
> > 2022-09-09 18:32:16 [http-nio-8080-exec-1] DEBUG InstantiatingNullHandler:98 - Entering nullPropertyValue [target=[wisdom.user.action.LoginAction@3fd415d2, com.
> > opensymphony.xwork2.DefaultTextProvider@e405047], property=locale]
> > 2022-09-09 18:32:16 [http-nio-8080-exec-1] DEBUG I18nInterceptor:124 - After action invocation Locale=null
> > 2022-09-09 18:32:16 [http-nio-8080-exec-1] WARN&nbsp; Dispatcher:613 - Could not find action or result: /wisdomcampus-gs/login
> > com.opensymphony.xwork2.config.ConfigurationException: No result defined for action wisdom.user.action.LoginAction and result success
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:377) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:279) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:250) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:179) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:263) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:49) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.doIntercept(ConversionErrorInterceptor.java:142) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:140) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:140) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:201) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.MultiselectInterceptor.intercept(MultiselectInterceptor.java:67) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.DateTextFieldInterceptor.intercept(DateTextFieldInterceptor.java:133) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:89) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:243) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:101) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:142) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:160) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept(PrepareInterceptor.java:175) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:121) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletConfigInterceptor.java:167) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept(AliasInterceptor.java:228) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept(ExceptionMappingInterceptor.java:196) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.factory.StrutsActionProxy.execute(StrutsActionProxy.java:48) ~[struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:574) [struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.dispatcher.ExecuteOperations.executeAction(ExecuteOperations.java:79) [struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.dispatcher.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:141) [struts2-core-2.5.30.jar:2.5.30]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.filters.ExpiresFilter.doFilter(ExpiresFilter.java:1230) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:97) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:544) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:143) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:690) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:78) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [catalina.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:616) [tomcat-coyote.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65) [tomcat-coyote.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:831) [tomcat-coyote.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1634) [tomcat-coyote.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-coyote.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_181]
> > &nbsp; &nbsp; &nbsp; &nbsp; at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_181]
> > &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:8.5.61]
> > &nbsp; &nbsp; &nbsp; &nbsp; at java.lang.Thread.run(Thread.java:748) [?:1.8.0_181]
> >
> > ------------------&nbsp;原始邮件&nbsp;------------------
> > 发件人:                                                                                                                        "Struts Users Mailing List"                                                                                    <lukaszlenart@apache.org&gt;;
> > 发送时间:&nbsp;2022年9月9日(星期五) 中午1:41
> > 收件人:&nbsp;"Struts Users Mailing List"<user@struts.apache.org&gt;;
> >
> > 主题:&nbsp;Re: When Struct 2.3.34 update Struct 2.5.30,the original interface cannot be accessed
> >
> >
> >
> > As far I see you have defined "/login" action under default namespace
> > "/" and you don't have namespace called "/user" - which means is
> > working according to the config.
> >
> > https://issues.apache.org/jira/secure/attachment/13049087/struts.xml
> > https://issues.apache.org/jira/browse/WW-5222
> >
> >
> > Regards
> > --
> > Łukasz
> > + 48 606 323 122 http://www.lenart.org.pl/
> >
> > pt., 9 wrz 2022 o 04:06 wwyyzz_001 <517654828@qq.com.invalid&gt; napisał(a):
> > &gt;
> > &gt; Dear all:
> > &gt;
> > &gt; Use Struct 2.3.34,one interface can invoke by two ways,example:
> > &gt;
> > &gt; http://localhost:8080/wisdomcampus-gs/login&amp;nbsp; can invoke, the interface can also be called under the subdirectory,
> > &gt;
> > &gt; http://localhost:8080/wisdomcampus-gs/user/login&amp;nbsp;can invoke,result is same.
> > &gt;
> > &gt; Use Struct 2.5.30,one interface only invoke by one way, example:
> > &gt;
> > &gt; http://localhost:8080/wisdomcampus-gs/login&amp;nbsp; can invoke, the interface can't&amp;nbsp; be called under the subdirectory,
> > &gt;
> > &gt; http://localhost:8080/wisdomcampus-gs/user/login&amp;nbsp;can't &amp;nbsp;invoke, return error: No result defined for action wisdom.user.action.LoginAction and result success.
> > &gt;
> > &gt;
> > &gt;
> > &gt;
> > &gt; Why? How to config in Struct 2.5.30, can realization same result&amp;nbsp; in Struct 2.3.34?&amp;nbsp; &amp;nbsp;
> > &gt;
> > &gt; Look forward to your reply,&amp;nbsp; &amp;nbsp;thank you!
> > &gt;
> > &gt;
> > &gt;
> > &gt;
> > &gt; Mark wang
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> > For additional commands, e-mail: user-help@struts.apache.org

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


Re: When Struct 2.3.34 update Struct 2.5.30,the original interface cannot be accessed

Posted by Łukasz Lenart <lu...@gmail.com>.
Would you mind using some proper encoding? Your message is mess :\
Have you tried to use 2.5 and then switch version by version? Also do
you use the Convention plugin?

Regards
Łukasz

pt., 9 wrz 2022 o 12:41 wwyyzz_001 <51...@qq.com.invalid> napisał(a):
>
> In Struct 2.3.34,when namespase="" is default namespase.
> If invoke http://localhost:8080/wisdomcampus-gs/user/login,because /user not define,Struct find action in default namespase,so everythiong is ok.
>
>
> But In Struct 2.5.30,config(struts.xml) is not change,invoke http://localhost:8080/wisdomcampus-gs/user/login, return error: No result defined for action wisdom.user.action.LoginAction and result success.
> Find action was invoked in log,but not found result,so Struct throw exception in DefaultActionInvocation.executeResult(DefaultActionInvocation.java:377)
> 1.executeResult source code:
> &nbsp; &nbsp; private void executeResult() throws Exception {
> &nbsp; &nbsp; &nbsp; &nbsp; result = createResult();
>
>
> &nbsp; &nbsp; &nbsp; &nbsp; String timerKey = "executeResult: " + getResultCode();
> &nbsp; &nbsp; &nbsp; &nbsp; try {
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; UtilTimerStack.push(timerKey);
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (result != null) {
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; result.execute(this);
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; } else if (resultCode != null &amp;&amp; !Action.NONE.equals(resultCode)) {
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; throw new ConfigurationException("No result defined for action " + getAction().getClass().getName()
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; + " and result " + getResultCode(), proxy.getConfig());
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; } else {
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (LOG.isDebugEnabled()) {
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; LOG.debug("No result returned for action {} at {}", getAction().getClass().getName(), proxy.getConfig().getLocation());
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }
> &nbsp; &nbsp; &nbsp; &nbsp; } finally {
> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; UtilTimerStack.pop(timerKey);
> &nbsp; &nbsp; &nbsp; &nbsp; }
> &nbsp; &nbsp; }
>
>
>
> 2.Struct console log:
> 2022-09-09 18:32:16 [http-nio-8080-exec-1] DEBUG SecurityMemberAccess:67 - Checking access for [target: wisdom.user.action.LoginAction@3fd415d2, member: public
> final java.lang.String wisdom.common.JsonActionBase.execute() throws java.lang.Exception, property: null]
> 2022-09-09 18:32:16 [http-nio-8080-exec-1] DEBUG InstantiatingNullHandler:98 - Entering nullPropertyValue [target=[wisdom.user.action.LoginAction@3fd415d2, com.
> opensymphony.xwork2.DefaultTextProvider@e405047], property=locale]
> 2022-09-09 18:32:16 [http-nio-8080-exec-1] DEBUG I18nInterceptor:124 - After action invocation Locale=null
> 2022-09-09 18:32:16 [http-nio-8080-exec-1] WARN&nbsp; Dispatcher:613 - Could not find action or result: /wisdomcampus-gs/login
> com.opensymphony.xwork2.config.ConfigurationException: No result defined for action wisdom.user.action.LoginAction and result success
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:377) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:279) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:250) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:179) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:263) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:49) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.doIntercept(ConversionErrorInterceptor.java:142) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:140) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:140) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:201) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.MultiselectInterceptor.intercept(MultiselectInterceptor.java:67) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.DateTextFieldInterceptor.intercept(DateTextFieldInterceptor.java:133) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:89) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:243) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:101) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:142) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:160) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept(PrepareInterceptor.java:175) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:121) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletConfigInterceptor.java:167) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept(AliasInterceptor.java:228) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept(ExceptionMappingInterceptor.java:196) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.factory.StrutsActionProxy.execute(StrutsActionProxy.java:48) ~[struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:574) [struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.dispatcher.ExecuteOperations.executeAction(ExecuteOperations.java:79) [struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.dispatcher.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:141) [struts2-core-2.5.30.jar:2.5.30]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.filters.ExpiresFilter.doFilter(ExpiresFilter.java:1230) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:97) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:544) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:143) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:690) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:78) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [catalina.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:616) [tomcat-coyote.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65) [tomcat-coyote.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:831) [tomcat-coyote.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1634) [tomcat-coyote.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-coyote.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_181]
> &nbsp; &nbsp; &nbsp; &nbsp; at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_181]
> &nbsp; &nbsp; &nbsp; &nbsp; at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:8.5.61]
> &nbsp; &nbsp; &nbsp; &nbsp; at java.lang.Thread.run(Thread.java:748) [?:1.8.0_181]
>
> ------------------&nbsp;原始邮件&nbsp;------------------
> 发件人:                                                                                                                        "Struts Users Mailing List"                                                                                    <lukaszlenart@apache.org&gt;;
> 发送时间:&nbsp;2022年9月9日(星期五) 中午1:41
> 收件人:&nbsp;"Struts Users Mailing List"<user@struts.apache.org&gt;;
>
> 主题:&nbsp;Re: When Struct 2.3.34 update Struct 2.5.30,the original interface cannot be accessed
>
>
>
> As far I see you have defined "/login" action under default namespace
> "/" and you don't have namespace called "/user" - which means is
> working according to the config.
>
> https://issues.apache.org/jira/secure/attachment/13049087/struts.xml
> https://issues.apache.org/jira/browse/WW-5222
>
>
> Regards
> --
> Łukasz
> + 48 606 323 122 http://www.lenart.org.pl/
>
> pt., 9 wrz 2022 o 04:06 wwyyzz_001 <517654828@qq.com.invalid&gt; napisał(a):
> &gt;
> &gt; Dear all:
> &gt;
> &gt; Use Struct 2.3.34,one interface can invoke by two ways,example:
> &gt;
> &gt; http://localhost:8080/wisdomcampus-gs/login&amp;nbsp; can invoke, the interface can also be called under the subdirectory,
> &gt;
> &gt; http://localhost:8080/wisdomcampus-gs/user/login&amp;nbsp;can invoke,result is same.
> &gt;
> &gt; Use Struct 2.5.30,one interface only invoke by one way, example:
> &gt;
> &gt; http://localhost:8080/wisdomcampus-gs/login&amp;nbsp; can invoke, the interface can't&amp;nbsp; be called under the subdirectory,
> &gt;
> &gt; http://localhost:8080/wisdomcampus-gs/user/login&amp;nbsp;can't &amp;nbsp;invoke, return error: No result defined for action wisdom.user.action.LoginAction and result success.
> &gt;
> &gt;
> &gt;
> &gt;
> &gt; Why? How to config in Struct 2.5.30, can realization same result&amp;nbsp; in Struct 2.3.34?&amp;nbsp; &amp;nbsp;
> &gt;
> &gt; Look forward to your reply,&amp;nbsp; &amp;nbsp;thank you!
> &gt;
> &gt;
> &gt;
> &gt;
> &gt; Mark wang
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org

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


回复: When Struct 2.3.34 update Struct 2.5.30,the original interface cannot be accessed

Posted by wwyyzz_001 <51...@qq.com.INVALID>.
In Struct 2.3.34,when namespase="" is default namespase.
If invoke http://localhost:8080/wisdomcampus-gs/user/login,because /user not define,Struct find action in default namespase,so everythiong is ok.


But In Struct 2.5.30,config(struts.xml) is not change,invoke http://localhost:8080/wisdomcampus-gs/user/login, return error: No result defined for action wisdom.user.action.LoginAction and result success.
Find action was invoked in log,but not found result,so Struct throw exception in DefaultActionInvocation.executeResult(DefaultActionInvocation.java:377)
1.executeResult source code:
&nbsp; &nbsp; private void executeResult() throws Exception {
&nbsp; &nbsp; &nbsp; &nbsp; result = createResult();


&nbsp; &nbsp; &nbsp; &nbsp; String timerKey = "executeResult: " + getResultCode();
&nbsp; &nbsp; &nbsp; &nbsp; try {
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; UtilTimerStack.push(timerKey);
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (result != null) {
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; result.execute(this);
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; } else if (resultCode != null &amp;&amp; !Action.NONE.equals(resultCode)) {
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; throw new ConfigurationException("No result defined for action " + getAction().getClass().getName()
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; + " and result " + getResultCode(), proxy.getConfig());
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; } else {
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (LOG.isDebugEnabled()) {
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; LOG.debug("No result returned for action {} at {}", getAction().getClass().getName(), proxy.getConfig().getLocation());
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }
&nbsp; &nbsp; &nbsp; &nbsp; } finally {
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; UtilTimerStack.pop(timerKey);
&nbsp; &nbsp; &nbsp; &nbsp; }
&nbsp; &nbsp; }



2.Struct console log:
2022-09-09 18:32:16 [http-nio-8080-exec-1] DEBUG SecurityMemberAccess:67 - Checking access for [target: wisdom.user.action.LoginAction@3fd415d2, member: public
final java.lang.String wisdom.common.JsonActionBase.execute() throws java.lang.Exception, property: null]
2022-09-09 18:32:16 [http-nio-8080-exec-1] DEBUG InstantiatingNullHandler:98 - Entering nullPropertyValue [target=[wisdom.user.action.LoginAction@3fd415d2, com.
opensymphony.xwork2.DefaultTextProvider@e405047], property=locale]
2022-09-09 18:32:16 [http-nio-8080-exec-1] DEBUG I18nInterceptor:124 - After action invocation Locale=null
2022-09-09 18:32:16 [http-nio-8080-exec-1] WARN&nbsp; Dispatcher:613 - Could not find action or result: /wisdomcampus-gs/login
com.opensymphony.xwork2.config.ConfigurationException: No result defined for action wisdom.user.action.LoginAction and result success
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:377) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:279) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:250) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:179) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:263) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:49) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.doIntercept(ConversionErrorInterceptor.java:142) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:140) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:140) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:201) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.MultiselectInterceptor.intercept(MultiselectInterceptor.java:67) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.DateTextFieldInterceptor.intercept(DateTextFieldInterceptor.java:133) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:89) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:243) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:101) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:142) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:160) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept(PrepareInterceptor.java:175) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:99) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:121) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletConfigInterceptor.java:167) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept(AliasInterceptor.java:228) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept(ExceptionMappingInterceptor.java:196) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:249) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.factory.StrutsActionProxy.execute(StrutsActionProxy.java:48) ~[struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:574) [struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.dispatcher.ExecuteOperations.executeAction(ExecuteOperations.java:79) [struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.struts2.dispatcher.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:141) [struts2-core-2.5.30.jar:2.5.30]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.filters.ExpiresFilter.doFilter(ExpiresFilter.java:1230) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:97) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:544) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:143) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:690) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:78) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [catalina.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:616) [tomcat-coyote.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65) [tomcat-coyote.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:831) [tomcat-coyote.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1634) [tomcat-coyote.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-coyote.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_181]
&nbsp; &nbsp; &nbsp; &nbsp; at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_181]
&nbsp; &nbsp; &nbsp; &nbsp; at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:8.5.61]
&nbsp; &nbsp; &nbsp; &nbsp; at java.lang.Thread.run(Thread.java:748) [?:1.8.0_181]

------------------&nbsp;原始邮件&nbsp;------------------
发件人:                                                                                                                        "Struts Users Mailing List"                                                                                    <lukaszlenart@apache.org&gt;;
发送时间:&nbsp;2022年9月9日(星期五) 中午1:41
收件人:&nbsp;"Struts Users Mailing List"<user@struts.apache.org&gt;;

主题:&nbsp;Re: When Struct 2.3.34 update Struct 2.5.30,the original interface cannot be accessed



As far I see you have defined "/login" action under default namespace
"/" and you don't have namespace called "/user" - which means is
working according to the config.

https://issues.apache.org/jira/secure/attachment/13049087/struts.xml
https://issues.apache.org/jira/browse/WW-5222


Regards
--
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

pt., 9 wrz 2022 o 04:06 wwyyzz_001 <517654828@qq.com.invalid&gt; napisał(a):
&gt;
&gt; Dear all:
&gt;
&gt; Use Struct 2.3.34,one interface can invoke by two ways,example:
&gt;
&gt; http://localhost:8080/wisdomcampus-gs/login&amp;nbsp; can invoke, the interface can also be called under the subdirectory,
&gt;
&gt; http://localhost:8080/wisdomcampus-gs/user/login&amp;nbsp;can invoke,result is same.
&gt;
&gt; Use Struct 2.5.30,one interface only invoke by one way, example:
&gt;
&gt; http://localhost:8080/wisdomcampus-gs/login&amp;nbsp; can invoke, the interface can't&amp;nbsp; be called under the subdirectory,
&gt;
&gt; http://localhost:8080/wisdomcampus-gs/user/login&amp;nbsp;can't &amp;nbsp;invoke, return error: No result defined for action wisdom.user.action.LoginAction and result success.
&gt;
&gt;
&gt;
&gt;
&gt; Why? How to config in Struct 2.5.30, can realization same result&amp;nbsp; in Struct 2.3.34?&amp;nbsp; &amp;nbsp;
&gt;
&gt; Look forward to your reply,&amp;nbsp; &amp;nbsp;thank you!
&gt;
&gt;
&gt;
&gt;
&gt; Mark wang

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

Re: When Struct 2.3.34 update Struct 2.5.30,the original interface cannot be accessed

Posted by Lukasz Lenart <lu...@apache.org>.
As far I see you have defined "/login" action under default namespace
"/" and you don't have namespace called "/user" - which means is
working according to the config.

https://issues.apache.org/jira/secure/attachment/13049087/struts.xml
https://issues.apache.org/jira/browse/WW-5222


Regards
--
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

pt., 9 wrz 2022 o 04:06 wwyyzz_001 <51...@qq.com.invalid> napisał(a):
>
> Dear all:
>
> Use Struct 2.3.34,one interface can invoke by two ways,example:
>
> http://localhost:8080/wisdomcampus-gs/login&nbsp; can invoke, the interface can also be called under the subdirectory,
>
> http://localhost:8080/wisdomcampus-gs/user/login&nbsp;can invoke,result is same.
>
> Use Struct 2.5.30,one interface only invoke by one way, example:
>
> http://localhost:8080/wisdomcampus-gs/login&nbsp; can invoke, the interface can't&nbsp; be called under the subdirectory,
>
> http://localhost:8080/wisdomcampus-gs/user/login&nbsp;can't &nbsp;invoke, return error: No result defined for action wisdom.user.action.LoginAction and result success.
>
>
>
>
> Why? How to config in Struct 2.5.30, can realization same result&nbsp; in Struct 2.3.34?&nbsp; &nbsp;
>
> Look forward to your reply,&nbsp; &nbsp;thank you!
>
>
>
>
> Mark wang

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