Hi, we recently upgraded from Struts 2.0.14 to 2.2.1 and I notice that

the following JSP code to inject an object property from one action into
another action has stopped working:

<s:if test="photoSet.keywordListLazyLoad != null">
<s:action namespace="/search" name="KeywordList" executeResult="true"
ignoreContextParams="true">
<s:param name="keywordList" value="photoSet.keywordListLazyLoad"/>
</s:action>
</s:if>

So it checks that the object is not null and then tries to set it on the
parameter "keywordList". This worked perfectly fine in 2.0.x, but in 2.2
on the server side we get:

java.lang.NoSuchMethodException:
KeywordListAction.setKeywordList([Ljava.lang.String;)
    at ognl.OgnlRuntime.callAppropriateMethod(OgnlRuntime.java:1226)
    at ognl.OgnlRuntime.setMethodValue(OgnlRuntime.java:1474)
    at
ognl.ObjectPropertyAccessor.setPossibleProperty(ObjectPropertyAccessor.java:85)
    at
ognl.ObjectPropertyAccessor.setProperty(ObjectPropertyAccessor.java:162)

And the resulting error displayed on the web page is:

Exception name: No result defined for action KeywordListAction and
result input
No result defined for action KeywordListAction and result input at
com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:375)
at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:277)
at
com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:263)
at
org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept
(AnnotationValidationInterceptor.java:68) at
com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept

Is this a bug or do I need to do something differently for 2.2?

Raj.



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

Reply via email to