Re: Migration to 2.3.20 - Issue with UnknownHandler and ConventionPlugin
Thanks Tim! Great that you was able to find the same solution as described here [1] - to put some more details here: - the issue was with default implementation of UnknownHandler which was throwing NPE by default (throw null) - that's why everything was fine before 2.3.20, DefaultActionInvocation always got an exception when was calling UnknownHandlers - because of NPE it wasn't possible to have any other UnknownHandlers - the default one was always breaking the flow - after fixing NPE, I've overlooked this flow in DAI - it was expecting an exception In the mentioned issue I've already proposed solution and Senen de Diego has also proposed some additional idea - I'm working on this right now and it will be released soon. [1] https://issues.apache.org/jira/browse/WW-4433 Regards -- Łukasz + 48 606 323 122 http://www.lenart.org.pl/ 2014-12-19 8:48 GMT+01:00 Thim Anneessens t.anneess...@ictjob.be: After a little fiddling we succeeded to migrate from 2.3.16 to 2.3.20. Everything seemed fine until we had an exception in one action and noticed that something had changed. Exception thrown from an action got lost. It did not reach the interceptor in charge of exception handling because... - The DefaultActionInvocation catched the exception and tried the unkownHandlerManager.handleUnknownMethod method. - DefaultActionInvocation tried the unkownHandlerManager.handleUnknownMethod method because we use the struts-convention plugin (same version) and that this plugin define the ConventionUnknownHandler bean. - Because the ConventionUnkownHandler.handleUnknownActionMethod does not do anything (it return null and has a big comment saying Not used, which is obviously wrong :) ), the result code for the action is null. So we fixed this by adding our own UnkownHandler which throws a NoSuchMethodException which makes the DefaultActionInvocation throw our original exception. Problem solved, but (there is always a but) 1. Maybe somebody could use this patch 2. I do not understand why the convention behavior should be to ignore action exception and stopping them to spread through the interceptor stack as they did 3. I think that this behavior should be changed in the DefaultActionInvocation. It feels unnatural to have to throw a NoSuchMethodException from an UnkownHandler in order to force the DefaultActionInvocation to throw our original exception. Anyway great release, allot of great improvements. Thanks to all committers for a great release. -- * Thim Anneessens IT Department * [image: ictjob group]
Re: Migration to 2.3.20 - Issue with UnknownHandler and ConventionPlugin
I suspected this was an oversigth. Looking forward for the definitive fix. Thanks for the feedback Łukasz. Best regards, Thim. On 12/19/2014 09:56 AM, Lukasz Lenart wrote: Thanks Tim! Great that you was able to find the same solution as described here [1] - to put some more details here: - the issue was with default implementation of UnknownHandler which was throwing NPE by default (throw null) - that's why everything was fine before 2.3.20, DefaultActionInvocation always got an exception when was calling UnknownHandlers - because of NPE it wasn't possible to have any other UnknownHandlers - the default one was always breaking the flow - after fixing NPE, I've overlooked this flow in DAI - it was expecting an exception In the mentioned issue I've already proposed solution and Senen de Diego has also proposed some additional idea - I'm working on this right now and it will be released soon. [1] https://issues.apache.org/jira/browse/WW-4433 Regards -- Łukasz + 48 606 323 122 http://www.lenart.org.pl/ 2014-12-19 8:48 GMT+01:00 Thim Anneessens t.anneess...@ictjob.be mailto:t.anneess...@ictjob.be: After a little fiddling we succeeded to migrate from 2.3.16 to 2.3.20. Everything seemed fine until we had an exception in one action and noticed that something had changed. Exception thrown from an action got lost. It did not reach the interceptor in charge of exception handling because... * The DefaultActionInvocation catched the exception and tried the unkownHandlerManager.handleUnknownMethod method. * DefaultActionInvocation tried the unkownHandlerManager.handleUnknownMethod method because we use the struts-convention plugin (same version) and that this plugin define the ConventionUnknownHandler bean. * Because the ConventionUnkownHandler.handleUnknownActionMethod does not do anything (it return null and has a big comment saying Not used, which is obviously wrong :) ), the result code for the action is null. So we fixed this by adding our own UnkownHandler which throws a NoSuchMethodException which makes the DefaultActionInvocation throw our original exception. Problem solved, but (there is always a but) 1. Maybe somebody could use this patch 2. I do not understand why the convention behavior should be to ignore action exception and stopping them to spread through the interceptor stack as they did 3. I think that this behavior should be changed in the DefaultActionInvocation. It feels unnatural to have to throw a NoSuchMethodException from an UnkownHandler in order to force the DefaultActionInvocation to throw our original exception. Anyway great release, allot of great improvements. Thanks to all committers for a great release. -- *Thim Anneessens IT Department * ictjob group -- *Thim Anneessens IT Department * ictjob group
Problem with form tag
I am using struts2.3.20. I have designed my page using divs. Everything is perfect. at the end i have added s:form tag. all the alignment went wrong. The page looks awkward. what could be the problem? *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/*
Re: Problem with form tag
The default XHTML theme? Hard to say without actionable details. On Dec 19, 2014 4:52 PM, Yaragalla Muralidhar yaragallamur...@gmail.com wrote: I am using struts2.3.20. I have designed my page using divs. Everything is perfect. at the end i have added s:form tag. all the alignment went wrong. The page looks awkward. what could be the problem? *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/*
Re: Problem with form tag
Thank u so much. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/* On Sat, Dec 20, 2014 at 3:26 AM, Dave Newton davelnew...@gmail.com wrote: The default XHTML theme? Hard to say without actionable details. On Dec 19, 2014 4:52 PM, Yaragalla Muralidhar yaragallamur...@gmail.com wrote: I am using struts2.3.20. I have designed my page using divs. Everything is perfect. at the end i have added s:form tag. all the alignment went wrong. The page looks awkward. what could be the problem? *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/*
problem with select tag
Hi i am using the select tag as below s:select name=branches headerKey=-1 headerValue=Select Branch list=branches cssClass=select required=true / by default it should show select Branch but it is showing one of the values as the default value. Am i missing something? I want Select Branches as the default option. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/*
Re: problem with select tag
Is the property set in the Acton? On Dec 19, 2014 9:54 PM, Yaragalla Muralidhar yaragallamur...@gmail.com wrote: Hi i am using the select tag as below s:select name=branches headerKey=-1 headerValue=Select Branch list=branches cssClass=select required=true / by default it should show select Branch but it is showing one of the values as the default value. Am i missing something? I want Select Branches as the default option. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/*
Re: problem with select tag
Which property are u asking? branches is properly set in action that is the reason it is showing one of the value. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/* On Sat, Dec 20, 2014 at 8:28 AM, Dave Newton davelnew...@gmail.com wrote: Is the property set in the Acton? On Dec 19, 2014 9:54 PM, Yaragalla Muralidhar yaragallamur...@gmail.com wrote: Hi i am using the select tag as below s:select name=branches headerKey=-1 headerValue=Select Branch list=branches cssClass=select required=true / by default it should show select Branch but it is showing one of the values as the default value. Am i missing something? I want Select Branches as the default option. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/*
Re: problem with select tag
i mean 'list attribute is set with the property in action class. The same code is working fine on the remaining page. Thanking you. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/* On Sat, Dec 20, 2014 at 8:32 AM, Yaragalla Muralidhar yaragallamur...@gmail.com wrote: Which property are u asking? branches is properly set in action that is the reason it is showing one of the value. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/* On Sat, Dec 20, 2014 at 8:28 AM, Dave Newton davelnew...@gmail.com wrote: Is the property set in the Acton? On Dec 19, 2014 9:54 PM, Yaragalla Muralidhar yaragallamur...@gmail.com wrote: Hi i am using the select tag as below s:select name=branches headerKey=-1 headerValue=Select Branch list=branches cssClass=select required=true / by default it should show select Branch but it is showing one of the values as the default value. Am i missing something? I want Select Branches as the default option. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/*
problem with i18n
Hi I have created an action class and i have created an properties file with the same name as action class. Then i am using the following code s:textfield name=sampleid cssClass=textField label readonly=true key=sample.reg.sampleid/ Even though the resource bundle key is specified the label is anot appearing for the text field. is there something i am missing? is some where else also need to configure for localised resource bundle? *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/*
Re: problem with select tag
Problem solved. Thank you so much. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/* On Sat, Dec 20, 2014 at 8:37 AM, Yaragalla Muralidhar yaragallamur...@gmail.com wrote: i mean 'list attribute is set with the property in action class. The same code is working fine on the remaining page. Thanking you. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/* On Sat, Dec 20, 2014 at 8:32 AM, Yaragalla Muralidhar yaragallamur...@gmail.com wrote: Which property are u asking? branches is properly set in action that is the reason it is showing one of the value. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/* On Sat, Dec 20, 2014 at 8:28 AM, Dave Newton davelnew...@gmail.com wrote: Is the property set in the Acton? On Dec 19, 2014 9:54 PM, Yaragalla Muralidhar yaragallamur...@gmail.com wrote: Hi i am using the select tag as below s:select name=branches headerKey=-1 headerValue=Select Branch list=branches cssClass=select required=true / by default it should show select Branch but it is showing one of the values as the default value. Am i missing something? I want Select Branches as the default option. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/*
Re: problem with i18n
Is there something i have to configure in struts.xml file? *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/* On Sat, Dec 20, 2014 at 9:27 AM, Yaragalla Muralidhar yaragallamur...@gmail.com wrote: Hi I have created an action class and i have created an properties file with the same name as action class. Then i am using the following code s:textfield name=sampleid cssClass=textField label readonly=true key=sample.reg.sampleid/ Even though the resource bundle key is specified the label is anot appearing for the text field. is there something i am missing? is some where else also need to configure for localised resource bundle? *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/*
Re: problem with i18n
2014-12-20 4:57 GMT+01:00 Yaragalla Muralidhar yaragallamur...@gmail.com: Hi I have created an action class and i have created an properties file with the same name as action class. Then i am using the following code s:textfield name=sampleid cssClass=textField label readonly=true key=sample.reg.sampleid/ Even though the resource bundle key is specified the label is anot appearing for the text field. is there something i am missing? is some where else also need to configure for localised resource bundle? Can you confirm that the resource file was copied to the same folder/package as the action's class (I'm not asking about the source, but compiled code)? What do you use to manage the project, Maven? Regards -- Łukasz + 48 606 323 122 http://www.lenart.org.pl/ - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org
Re: problem with i18n
I am using eclipse. yes it is copied into same package. *Thanks and Regards,* Muralidhar Yaragalla. *http://yaragalla.blogspot.in/ http://yaragalla.blogspot.in/* On Sat, Dec 20, 2014 at 12:46 PM, Lukasz Lenart lukaszlen...@apache.org wrote: 2014-12-20 4:57 GMT+01:00 Yaragalla Muralidhar yaragallamur...@gmail.com : Hi I have created an action class and i have created an properties file with the same name as action class. Then i am using the following code s:textfield name=sampleid cssClass=textField label readonly=true key=sample.reg.sampleid/ Even though the resource bundle key is specified the label is anot appearing for the text field. is there something i am missing? is some where else also need to configure for localised resource bundle? Can you confirm that the resource file was copied to the same folder/package as the action's class (I'm not asking about the source, but compiled code)? What do you use to manage the project, Maven? Regards -- Łukasz + 48 606 323 122 http://www.lenart.org.pl/ - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org