You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Pro1712 <Pr...@yahoo.de> on 2010/12/23 13:30:42 UTC
Re: Setting object from param tag fails in Struts 2.2.1
Hi!
I'm updating from Struts 2.1.8.1 to 2.2.1.1.
I use this action:
<mm:action name="ActionLinksAction" executeResult="true"
ignoreContextParams="true">
<mm:param name="direction" value="'vertical'" />
<mm:param name="position" value="'anlegen'" />
<mm:param name="cssIconStyle" value="'item_header_table_backcolor'" />
</mm:action>
ActionLinksAction has this method:
public void setActionLinks(final LinkedHashMap<String, Object> actionLinks)
{
actionLinks_ = actionLinks;
}
This should be filled from the context.
The page from which the action is called has a property getActionLinks and
returns the data.
This works in 2.1.8.1 but not in 2.2.1.1!
I did not change any code. I only updated the libs.
Is there any change from 2.1.8.1 to 2.2.1.1?
Maurizio Cucchiara wrote:
>
> 2010/11/17 Raj Nagappan <ra...@velocitylabs.com>
>
>>
>> I would say this is a regression bug from 2.0.x, yes?
>>
>>
> I guess you're right.
> Take a look at https://issues.apache.org/jira/browse/WW-1960
> Could you open an issue, referencing the one above?
> I'm sure someone helps you.
> In the meanwhile could you try to change action's behavior?
>
> <s:action namespace="/search" name="KeywordList" executeResult="true"
> ignoreContextParams="true">
> <%--REMOVE THIS LINE <s:param name="keywordList"
> value="photoSet.keywordListLazyLoad"/>--%>
> </s:action>
>
> and create a new method inside your KeywordList action called set
> KeywordListLazyLoad()
> --
> Maurizio Cucchiara
>
>
--
View this message in context: http://old.nabble.com/Setting-object-from-param-tag-fails-in-Struts-2.2.1-tp30216692p30520424.html
Sent from the Struts - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: Setting object from param tag fails in Struts 2.2.1
Posted by Maurizio Cucchiara <ma...@gmail.com>.
Not much has changed since the 2.2.1 version
2011/1/5 Pro1712 <Pr...@yahoo.de>:
>
> It works with the latest build (#252)!
> Do you see any problems using this version in a production environment?
>
> --
> View this message in context: http://old.nabble.com/Setting-object-from-param-tag-fails-in-Struts-2.2.1-tp30216692p30593987.html
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
--
Maurizio Cucchiara
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: Setting object from param tag fails in Struts 2.2.1
Posted by Pro1712 <Pr...@yahoo.de>.
It works with the latest build (#252)!
Do you see any problems using this version in a production environment?
--
View this message in context: http://old.nabble.com/Setting-object-from-param-tag-fails-in-Struts-2.2.1-tp30216692p30593987.html
Sent from the Struts - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: Setting object from param tag fails in Struts 2.2.1
Posted by Lukasz Lenart <lu...@googlemail.com>.
Here you have the whole packages
https://hudson.apache.org/hudson/job/Struts2/lastBuild/org.apache.struts$struts2-assembly/
Kind regards
--
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/
Kapituła Javarsovia http://javarsovia.pl
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: Setting object from param tag fails in Struts 2.2.1
Posted by Maurizio Cucchiara <ma...@gmail.com>.
> So should I stay with 2.1.8.1 and wait for 2.2.2?
while waiting for the next release you could download the *latest
build* [1] [2], and see it works as you expect (please let us know)
[1] https://hudson.apache.org/hudson/job/Struts2/lastBuild/org.apache.struts$struts2-core/
[2] https://hudson.apache.org/hudson/job/Struts2/lastBuild/org.apache.struts.xwork$xwork-core/
--
Maurizio Cucchiara
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: Setting object from param tag fails in Struts 2.2.1
Posted by Pro1712 <Pr...@yahoo.de>.
So should I stay with 2.1.8.1 and wait for 2.2.2?
When will this version be released?
Maurizio Cucchiara wrote:
>
> As far as I know this behavior was fixed with the patch sent by Lukasz
> (see [1] and also [2]).
> I can't figure out what happened, as far I can see in subversion logs
> [3] the patch was submitted three months ago, though source code of
> last struts2 version contains the old version of ChainInterceptor.
>
>
> [1] https://issues.apache.org/jira/browse/WW-3503
> [2] https://issues.apache.org/jira/browse/WW-3488
> [3]
> http://svn.apache.org/viewvc/struts/struts2/trunk/xwork-core/src/main/java/com/opensymphony/xwork2/interceptor/ChainingInterceptor.java?p2=/struts/struts2/trunk/xwork-core/src/main/java/com/opensymphony/xwork2/interceptor/ChainingInterceptor.java&p1=/struts/struts2/trunk/xwork-core/src/main/java/com/opensymphony/xwork2/interceptor/ChainingInterceptor.java&r1=997345&r2=997344&view=diff&pathrev=997345
>
--
View this message in context: http://old.nabble.com/Setting-object-from-param-tag-fails-in-Struts-2.2.1-tp30216692p30584769.html
Sent from the Struts - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: Setting object from param tag fails in Struts 2.2.1
Posted by Maurizio Cucchiara <ma...@gmail.com>.
As far as I know this behavior was fixed with the patch sent by Lukasz
(see [1] and also [2]).
I can't figure out what happened, as far I can see in subversion logs
[3] the patch was submitted three months ago, though source code of
last struts2 version contains the old version of ChainInterceptor.
[1] https://issues.apache.org/jira/browse/WW-3503
[2] https://issues.apache.org/jira/browse/WW-3488
[3] http://svn.apache.org/viewvc/struts/struts2/trunk/xwork-core/src/main/java/com/opensymphony/xwork2/interceptor/ChainingInterceptor.java?p2=/struts/struts2/trunk/xwork-core/src/main/java/com/opensymphony/xwork2/interceptor/ChainingInterceptor.java&p1=/struts/struts2/trunk/xwork-core/src/main/java/com/opensymphony/xwork2/interceptor/ChainingInterceptor.java&r1=997345&r2=997344&view=diff&pathrev=997345
2010/12/23 Dave Newton <da...@gmail.com>:
> On Thu, Dec 23, 2010 at 7:30 AM, Pro1712 wrote:
>
>> I use this action:
>> <mm:action name="ActionLinksAction" executeResult="true"
>> ignoreContextParams="true">
>> <mm:param name="direction" value="'vertical'" />
>> <mm:param name="position" value="'anlegen'" />
>> <mm:param name="cssIconStyle" value="'item_header_table_backcolor'"
>> />
>> </mm:action>
>>
>> ActionLinksAction has this method:
>> public void setActionLinks(final LinkedHashMap<String, Object> actionLinks)
>> {
>> actionLinks_ = actionLinks;
>> }
>>
>> This should be filled from the context.
>>
>
> Why/how? The action tag will just push the action onto the stack and set the
> parameters you've defined. There's no context copy into the new action, if I
> remember correct (which I may well not).
>
>
>> The page from which the action is called has a property getActionLinks and
>> returns the data.
>>
>
> That would return the actionLinks from the *original* action, because it's
> the first object on the stack with a publicly-accessible getter, no? I don't
> see why the action being called would have setActionLinks() called.
>
> Dave
>
--
Maurizio Cucchiara
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: Setting object from param tag fails in Struts 2.2.1
Posted by Dave Newton <da...@gmail.com>.
On Thu, Dec 23, 2010 at 7:30 AM, Pro1712 wrote:
> I use this action:
> <mm:action name="ActionLinksAction" executeResult="true"
> ignoreContextParams="true">
> <mm:param name="direction" value="'vertical'" />
> <mm:param name="position" value="'anlegen'" />
> <mm:param name="cssIconStyle" value="'item_header_table_backcolor'"
> />
> </mm:action>
>
> ActionLinksAction has this method:
> public void setActionLinks(final LinkedHashMap<String, Object> actionLinks)
> {
> actionLinks_ = actionLinks;
> }
>
> This should be filled from the context.
>
Why/how? The action tag will just push the action onto the stack and set the
parameters you've defined. There's no context copy into the new action, if I
remember correct (which I may well not).
> The page from which the action is called has a property getActionLinks and
> returns the data.
>
That would return the actionLinks from the *original* action, because it's
the first object on the stack with a publicly-accessible getter, no? I don't
see why the action being called would have setActionLinks() called.
Dave