Re: Struts 1.3 chaining flow diagram
Since Struts 1.3.0 doesn't exist yet :), please redirect this post to the DEV@ list. -Ted. On Tue, 22 Mar 2005 11:46:05 +0530, Rajaneesh [EMAIL PROTECTED] wrote: Hi, With respect to the previous versions of struts, we had the controller 1. instantiating populating ActionForm, 2. Validating the fields in the action form, 3. Calling the execute method of Action 4. Getting the action forward from the execute method. With respect to Struts 1.3 are the same accomplished by (in the same order) 1. AbstractCreateActionForm, AbstractPolulateActionForm 2. AbstractValidateActionForm 3. AbstractCreateAction, ExecuteCommand 4. AbstractPerformForward Could you please let me know if these are called by ComposableRequestProcessor and needs to be extended by the user? Regards Rajaneesh - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cancel button doesn't cancel server side validation
Thanks for your reply. That property is required by LookupDispatchAction. The action is defined as the following: action path=/submit202 type=SubmitFormAction parameter=action name=202Form scope=request validate=true input=/sitemplates/form202.jsp forward name=refresh path=/templates/form202.jsp/ /action If I don't have that property, I got errors like: Request[/submit202] does not contain handler parameter named 'action'. This may be caused by whitespace in the label text. Thanks Bqiao On Mon, 21 Mar 2005 10:18:57 -0800, K.C. Baltz [EMAIL PROTECTED] wrote: I've never needed a property attribute with the html:cancel control. Perhaps that's the problem? Make sure you have a cancel() method in your DispatchAction K.C. Bing Qiao wrote: Hi, I am using Struts Validator for a LookupDispatchAction. I'm using both client and server sides validation. The problem is I can only disable the client side validation by using html:cancel tag. html:cancel styleClass=button style=width: 100px property=action bean:message key=sibutton.cancel/ /html:cancel I doubt if the property is the problem but can't be sure. Besides it is required by LookupDispatchAction. Is there limitation for this tag to be used for LookupDispatchAction? Thanks a lot! Bqiao - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Locale question
Is Action.LOCALE_KEY deprecated ? -- regards, Sergey mailto:[EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Locale question
Yes, it's gone in 1.2.4 and replaced by Globals.LOCALE_KEY. Erik Sergey Livanov wrote: Is Action.LOCALE_KEY deprecated ? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re[2]: Locale question
Erik! Where can I find some docs and samples about Globals obj ? EW Yes, it's gone in 1.2.4 and replaced by Globals.LOCALE_KEY. EW Erik EW Sergey Livanov wrote: Is Action.LOCALE_KEY deprecated ? EW - EW To unsubscribe, e-mail: [EMAIL PROTECTED] EW For additional commands, e-mail: [EMAIL PROTECTED] -- , Sergey mailto:[EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Locale question
Well, one place to look would be the API documentation: http://struts.apache.org/api/index.html Click on Globals in the All Classes frame and check out the Field Summary. Also, click on one of the key fields and you'll see a link to Constant Field Values. Follow that for a summary page concerning all Struts constants. If you are asking for a how-to guide concerning the use of Struts constants or a logical explanation of how they are used, I don't know of one, but I would also be interested if one were available. Ultimately, obtaining the source code is a surefire way to understand what's going on. Hope that helps, Erik Sergey Livanov wrote: Erik! Where can I find some docs and samples about Globals obj ? EW Yes, it's gone in 1.2.4 and replaced by Globals.LOCALE_KEY. EW Erik EW Sergey Livanov wrote: Is Action.LOCALE_KEY deprecated ? EW - EW To unsubscribe, e-mail: [EMAIL PROTECTED] EW For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Re[2]: Locale question
Globals contain nothing but public static final constants use in the entire struts framework. You can download the source code and with help of the good tool you can find its usage in the code / Ashwani -Original Message- From: Sergey Livanov [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 22, 2005 7:04 PM To: Struts Users Mailing List Subject: Re[2]: Locale question Erik! Where can I find some docs and samples about Globals obj ? EW Yes, it's gone in 1.2.4 and replaced by Globals.LOCALE_KEY. EW Erik EW Sergey Livanov wrote: Is Action.LOCALE_KEY deprecated ? EW - EW To unsubscribe, e-mail: [EMAIL PROTECTED] EW For additional commands, e-mail: [EMAIL PROTECTED] -- , Sergey mailto:[EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This message contains information that may be privileged or confidential and is the property of the Capgemini Group. It is intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorized to read, print, retain, copy, disseminate, distribute, or use this message or any part thereof. If you receive this message in error, please notify the sender immediately and delete all copies of this message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
submit with the Enter from the keyboard ??
When I hit on the enter key, it wont submit the form unless I use the mouse to click on the button. I tried with both method, it doesnt work. Unless I put both codes together, and it will work.. any idea? Method 1 input type=text name=fullName value=Enter Name Here onFocus=javascript:clickme();/ input type=button class=btn2 value=bean:message key=common.button.search/ onclick=javascript:doSubmitForm('showList')/ Method 2 html:text property=fullName value=Enter Name Here onFocus=javascript:clickme();/ html:button property=action onclick=javascript:doSubmitForm('showList1') bean:message key=common.button.search/ /html:button - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: submit with the Enter from the keyboard ??
Try html:submit/ instead of html:button/. See http://www.w3.org/TR/html401/interact/forms.html#buttons for a quick description of the difference between input type='submit' and input type='button'. (While you're there, read the whole page. It's filled with good information on HTML form submission.) -- Jeff On Mon, 21 Mar 2005 14:35:31 +0800, Yen [EMAIL PROTECTED] wrote: When I hit on the enter key, it wont submit the form unless I use the mouse to click on the button. I tried with both method, it doesnt work. Unless I put both codes together, and it will work.. any idea? Method 1 input type=text name=fullName value=Enter Name Here onFocus=javascript:clickme();/ input type=button class=btn2 value=bean:message key=common.button.search/ onclick=javascript:doSubmitForm('showList')/ Method 2 html:text property=fullName value=Enter Name Here onFocus=javascript:clickme();/ html:button property=action onclick=javascript:doSubmitForm('showList1') bean:message key=common.button.search/ /html:button - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jeff Beal Webmedx, Inc. Pittsburgh, PA USA - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
request information to 2 databases
Hi, I would like, from a struts action, to query informations from 2 different databases: mySql and Oracle. both are on different servers, respectively (Jupiter:2740) and (orion:2556). How should I configure the system for being able to do that. Any references would be appreciated. Thanks. __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
Re: request information to 2 databases
Simply define 2 datasources as resources for your webapp and get them using a JNDI lookup. You will not have a share transactionnal context until you use JTA and 2-pass commit, but for readonly access, you don't need it. Nico. Ryan julius a écrit : Hi, I would like, from a struts action, to query informations from 2 different databases: mySql and Oracle. both are on different servers, respectively (Jupiter:2740) and (orion:2556). How should I configure the system for being able to do that. Any references would be appreciated. Thanks. __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com This message contains information that may be privileged or confidential and is the property of the Capgemini Group. It is intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorized to read, print, retain, copy, disseminate, distribute, or use this message or any part thereof. If you receive this message in error, please notify the sender immediately and delete all copies of this message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Two cancel buttons in one form
Hi all, I want to have two cancel buttons in a form, however I run into the problem of not being able to distinguish which one is being pressed (one cancels the whole operation and the other returns to the first screen). The reason is that they both use the Globals.CANCEL_KEY parameter. What is the best way to get around this? Thanks, Abdullah - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
multi-page validation form
I'm trying to create a form that will be validated over a series of jsp's. I'm using the page property with individual fields to specify whether they should be validated on a particular page and then setting the hidden page property to whatever the corurrent jsp page. This is how my field looks in the validation.xml field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field But it just seems to ignore this validation whatever I set the form page property to. I'm expecting it to perform this validation if the form page property is = 2, and ignore the validation altogether if the form page property is 2. I have noticed that changing the page value to an integer (without the quotes) eg field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field it does the validation, but it will do it no matter what I set the page form property to. Has anybody got this working or know what I'm doing wrong? I appreciate any help, thank you, Jack
Re: Two cancel buttons in one form
Abdullah Jibaly wrote: Hi all, I want to have two cancel buttons in a form, however I run into the problem of not being able to distinguish which one is being pressed (one cancels the whole operation and the other returns to the first screen). The reason is that they both use the Globals.CANCEL_KEY parameter. What is the best way to get around this? There sure is. Have one button set one value, and the other button set another. In your Action, look at which value you've been passed and act accordingly. So replace your Globals.CANCEL_KEY with Globals.CANCEL_RETURN and Globals.CANCEL_CANCEL or some such and that should work. Brandon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multi-page validation form
Jack Perrett wrote: I'm trying to create a form that will be validated over a series of jsp's. I'm using the page property with individual fields to specify whether they should be validated on a particular page and then setting the hidden page property to whatever the corurrent jsp page. This is how my field looks in the validation.xml field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field But it just seems to ignore this validation whatever I set the form page property to. I'm expecting it to perform this validation if the form page property is = 2, and ignore the validation altogether if the form page property is 2. I have noticed that changing the page value to an integer (without the quotes) eg field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field it does the validation, but it will do it no matter what I set the page form property to. Has anybody got this working or know what I'm doing wrong? I appreciate any help, thank you, Yup, it's quite easy. Just set a hidden value in the page. input type=hidden property=page value=1/ Then in your validation.xml for your form do this: form name=yourform field property=fieldname depends=required page=1 /field /form Hope this helps. Brandon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Two cancel buttons in one form
I ended up putting this in my base action class. Is there a better alternative? public String getCancelledValue(HttpServletRequest request) { return (String) request.getAttribute(org.apache.struts.Globals.CANCEL_KEY); } -Original Message- From: Abdullah Jibaly Sent: Tuesday, March 22, 2005 9:57 AM To: Struts Users Mailing List Subject: Two cancel buttons in one form Hi all, I want to have two cancel buttons in a form, however I run into the problem of not being able to distinguish which one is being pressed (one cancels the whole operation and the other returns to the first screen). The reason is that they both use the Globals.CANCEL_KEY parameter. What is the best way to get around this? Thanks, Abdullah - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Two cancel buttons in one form
Brandon, The problem is that Struts does not give you access to the value of the cancel button when using html:cancel value=Return / It only gives you the isCancelled method which indicated whether or not it was set. I guess I'll just get it manually as mentioned in the other post. Thanks! Abdullah -Original Message- From: Brandon Mercer [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 22, 2005 10:02 AM To: Struts Users Mailing List Subject: Re: Two cancel buttons in one form Abdullah Jibaly wrote: Hi all, I want to have two cancel buttons in a form, however I run into the problem of not being able to distinguish which one is being pressed (one cancels the whole operation and the other returns to the first screen). The reason is that they both use the Globals.CANCEL_KEY parameter. What is the best way to get around this? There sure is. Have one button set one value, and the other button set another. In your Action, look at which value you've been passed and act accordingly. So replace your Globals.CANCEL_KEY with Globals.CANCEL_RETURN and Globals.CANCEL_CANCEL or some such and that should work. Brandon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multi-page validation form
Thanks for gettig back to me so quickly. I am actually setting the hidden page property. I'm using a StrutsTest so the jsp doesn't actually exist at the moment but I'm creating a form, and setting the fields, and then using form.setPage(2); to set the this property. So I'm effectively submitting a form with the hidden page property set to 2. any ideas what else could be stopping it? - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:04 PM Subject: Re: multi-page validation form Jack Perrett wrote: I'm trying to create a form that will be validated over a series of jsp's. I'm using the page property with individual fields to specify whether they should be validated on a particular page and then setting the hidden page property to whatever the corurrent jsp page. This is how my field looks in the validation.xml field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field But it just seems to ignore this validation whatever I set the form page property to. I'm expecting it to perform this validation if the form page property is = 2, and ignore the validation altogether if the form page property is 2. I have noticed that changing the page value to an integer (without the quotes) eg field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field it does the validation, but it will do it no matter what I set the page form property to. Has anybody got this working or know what I'm doing wrong? I appreciate any help, thank you, Yup, it's quite easy. Just set a hidden value in the page. input type=hidden property=page value=1/ Then in your validation.xml for your form do this: form name=yourform field property=fieldname depends=required page=1 /field /form Hope this helps. Brandon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Something strange is happening
Maybe it is my system but something strange started happening this morning. I have an app that I have been deploying on tomcat, and I needed to add some ejb's to the app so I went to jboss. (that's just for background since it may be a weird jboss problem) The app uses tiles and was deploying fine in tomcat. Now when I deploy it in jboss I get a weird error that the definitions defined in the tiles doctype must be well formed. (the error pointing to the tiles-definitions.dtd on Jakarta) That would be ok, except if I copy the dtd locally and reference the local copy in my app all deploys fine. (which to me must mean the dtd is not malformed as I got it from Jakarta) Anyone seen this? It is not a major thing it just bugs me. Al - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multi-page validation form
Jack Perrett wrote: Thanks for gettig back to me so quickly. I am actually setting the hidden page property. I'm using a StrutsTest so the jsp doesn't actually exist at the moment but I'm creating a form, and setting the fields, and then using form.setPage(2); to set the this property. So I'm effectively submitting a form with the hidden page property set to 2. any ideas what else could be stopping it? - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:04 PM Subject: Re: multi-page validation form Jack Perrett wrote: I'm trying to create a form that will be validated over a series of jsp's. I'm using the page property with individual fields to specify whether they should be validated on a particular page and then setting the hidden page property to whatever the corurrent jsp page. This is how my field looks in the validation.xml field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field But it just seems to ignore this validation whatever I set the form page property to. I'm expecting it to perform this validation if the form page property is = 2, and ignore the validation altogether if the form page property is 2. It's not going to validate this page when it's GREATER than or = to 2... only if it's value is two. That's the first thing. The second thing is, that in your JSP you need to also have hidden fields for the form fields you've collected on the previous pages. Like this. html:hidden property=previousvalue/ html:hidden property=previousvalue2/ html:hidden property=previousvalue3/ :-) Brandon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multi-page validation form
All the previous form properties are set using the StrutsTest so all the required fields are in the form. This is not the issue however, the validation is just plain ignoring the validation, whatever the form property is set to - it should at least be performing the valiadtion on the fields with the correct page value but is just ignoring these. The documentation her does suggest that it will perfrom the validation on any fields with a page property set less than or equal to the form page property http://struts.apache.org/userGuide/dev_validator.html - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:29 PM Subject: Re: multi-page validation form Jack Perrett wrote: Thanks for gettig back to me so quickly. I am actually setting the hidden page property. I'm using a StrutsTest so the jsp doesn't actually exist at the moment but I'm creating a form, and setting the fields, and then using form.setPage(2); to set the this property. So I'm effectively submitting a form with the hidden page property set to 2. any ideas what else could be stopping it? - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:04 PM Subject: Re: multi-page validation form Jack Perrett wrote: I'm trying to create a form that will be validated over a series of jsp's. I'm using the page property with individual fields to specify whether they should be validated on a particular page and then setting the hidden page property to whatever the corurrent jsp page. This is how my field looks in the validation.xml field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field But it just seems to ignore this validation whatever I set the form page property to. I'm expecting it to perform this validation if the form page property is = 2, and ignore the validation altogether if the form page property is 2. It's not going to validate this page when it's GREATER than or = to 2... only if it's value is two. That's the first thing. The second thing is, that in your JSP you need to also have hidden fields for the form fields you've collected on the previous pages. Like this. html:hidden property=previousvalue/ html:hidden property=previousvalue2/ html:hidden property=previousvalue3/ :-) Brandon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Action Mapping Forward Params
Hello Guys, I have a form that is called with a dymanic param in a url. Now after saving the form succesfully or not i need to go back to the same form. But to load the form correctly I need the parameter I have started with. How do I include dynamic url parameters inside the action mappings specifically the forward element? TIA! Richard - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multi-page validation form
Jack Perrett wrote: All the previous form properties are set using the StrutsTest so all the required fields are in the form. This is not the issue however, the validation is just plain ignoring the validation, whatever the form property is set to - it should at least be performing the valiadtion on the fields with the correct page value but is just ignoring these. The documentation her does suggest that it will perfrom the validation on any fields with a page property set less than or equal to the form page Ahhh yes, but you said GREATER than or equal to with the logic you wrote. I was just making sure ;-). Another thing I'd check is to see if there are any typo's in the validation.xml file. Make sure the form defined in the struts-config is the same as the one in the validation.xml... I've had that cause validation not work. Other than that, I don't think I can offer much more help. Good luck! Brandon property http://struts.apache.org/userGuide/dev_validator.html - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:29 PM Subject: Re: multi-page validation form Jack Perrett wrote: Thanks for gettig back to me so quickly. I am actually setting the hidden page property. I'm using a StrutsTest so the jsp doesn't actually exist at the moment but I'm creating a form, and setting the fields, and then using form.setPage(2); to set the this property. So I'm effectively submitting a form with the hidden page property set to 2. any ideas what else could be stopping it? - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:04 PM Subject: Re: multi-page validation form Jack Perrett wrote: I'm trying to create a form that will be validated over a series of jsp's. I'm using the page property with individual fields to specify whether they should be validated on a particular page and then setting the hidden page property to whatever the corurrent jsp page. This is how my field looks in the validation.xml field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field But it just seems to ignore this validation whatever I set the form page property to. I'm expecting it to perform this validation if the form page property is = 2, and ignore the validation altogether if the form page property is 2. It's not going to validate this page when it's GREATER than or = to 2... only if it's value is two. That's the first thing. The second thing is, that in your JSP you need to also have hidden fields for the form fields you've collected on the previous pages. Like this. html:hidden property=previousvalue/ html:hidden property=previousvalue2/ html:hidden property=previousvalue3/ :-) Brandon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: multi-page validation form
Having done exactly the same thing, I know it works (though it's been a while so I'm trying to remember everthing I've done). Do you also have a page number defined for the Javascript include tag e.g. html:javascript formName=myForm page=3/ Jay http://www.vtgroup.com/ -Original Message- From: Brandon Mercer [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 22, 2005 11:15 AM To: Struts Users Mailing List Subject: Re: multi-page validation form Jack Perrett wrote: All the previous form properties are set using the StrutsTest so all the required fields are in the form. This is not the issue however, the validation is just plain ignoring the validation, whatever the form property is set to - it should at least be performing the valiadtion on the fields with the correct page value but is just ignoring these. The documentation her does suggest that it will perfrom the validation on any fields with a page property set less than or equal to the form page Ahhh yes, but you said GREATER than or equal to with the logic you wrote. I was just making sure ;-). Another thing I'd check is to see if there are any typo's in the validation.xml file. Make sure the form defined in the struts-config is the same as the one in the validation.xml... I've had that cause validation not work. Other than that, I don't think I can offer much more help. Good luck! Brandon property http://struts.apache.org/userGuide/dev_validator.html - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:29 PM Subject: Re: multi-page validation form Jack Perrett wrote: Thanks for gettig back to me so quickly. I am actually setting the hidden page property. I'm using a StrutsTest so the jsp doesn't actually exist at the moment but I'm creating a form, and setting the fields, and then using form.setPage(2); to set the this property. So I'm effectively submitting a form with the hidden page property set to 2. any ideas what else could be stopping it? - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:04 PM Subject: Re: multi-page validation form Jack Perrett wrote: I'm trying to create a form that will be validated over a series of jsp's. I'm using the page property with individual fields to specify whether they should be validated on a particular page and then setting the hidden page property to whatever the corurrent jsp page. This is how my field looks in the validation.xml field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field But it just seems to ignore this validation whatever I set the form page property to. I'm expecting it to perform this validation if the form page property is = 2, and ignore the validation altogether if the form page property is 2. It's not going to validate this page when it's GREATER than or = to 2... only if it's value is two. That's the first thing. The second thing is, that in your JSP you need to also have hidden fields for the form fields you've collected on the previous pages. Like this. html:hidden property=previousvalue/ html:hidden property=previousvalue2/ html:hidden property=previousvalue3/ :-) Brandon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multi-page validation form
thanks for your help I know the validation.xml is well formed because it will work perfectly without any page properties. It's just when I start using them that the validation stops - think I will just have to create my own field and use the compare two fields technique instead. - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 5:14 PM Subject: Re: multi-page validation form Jack Perrett wrote: All the previous form properties are set using the StrutsTest so all the required fields are in the form. This is not the issue however, the validation is just plain ignoring the validation, whatever the form property is set to - it should at least be performing the valiadtion on the fields with the correct page value but is just ignoring these. The documentation her does suggest that it will perfrom the validation on any fields with a page property set less than or equal to the form page Ahhh yes, but you said GREATER than or equal to with the logic you wrote. I was just making sure ;-). Another thing I'd check is to see if there are any typo's in the validation.xml file. Make sure the form defined in the struts-config is the same as the one in the validation.xml... I've had that cause validation not work. Other than that, I don't think I can offer much more help. Good luck! Brandon property http://struts.apache.org/userGuide/dev_validator.html - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:29 PM Subject: Re: multi-page validation form Jack Perrett wrote: Thanks for gettig back to me so quickly. I am actually setting the hidden page property. I'm using a StrutsTest so the jsp doesn't actually exist at the moment but I'm creating a form, and setting the fields, and then using form.setPage(2); to set the this property. So I'm effectively submitting a form with the hidden page property set to 2. any ideas what else could be stopping it? - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:04 PM Subject: Re: multi-page validation form Jack Perrett wrote: I'm trying to create a form that will be validated over a series of jsp's. I'm using the page property with individual fields to specify whether they should be validated on a particular page and then setting the hidden page property to whatever the corurrent jsp page. This is how my field looks in the validation.xml field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field But it just seems to ignore this validation whatever I set the form page property to. I'm expecting it to perform this validation if the form page property is = 2, and ignore the validation altogether if the form page property is 2. It's not going to validate this page when it's GREATER than or = to 2... only if it's value is two. That's the first thing. The second thing is, that in your JSP you need to also have hidden fields for the form fields you've collected on the previous pages. Like this. html:hidden property=previousvalue/ html:hidden property=previousvalue2/ html:hidden property=previousvalue3/ :-) Brandon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multi-page validation form
No. I don't actually have a jsp page. I'm generating a form in a StrutsTest and then testing what my action does with it. It looks like this: public void testAction() { setRequestPathInfo(/myAction.do); setActionForm(populateForm()); actionPerform(); verifyForward(correctActionForward); verifyNoActionErrors(); } public form populateForm() { MyForm form = new MyForm(); form.setMyField1(); form.setMyField2(); form.setPage(1); // This sets the page variable in the form return form; } So anyway, the form always gets validated. Even when the page is set to a number where the fields have not been set any ideas? - Original Message - From: [EMAIL PROTECTED] To: user@struts.apache.org Sent: Tuesday, March 22, 2005 5:28 PM Subject: RE: multi-page validation form Having done exactly the same thing, I know it works (though it's been a while so I'm trying to remember everthing I've done). Do you also have a page number defined for the Javascript include tag e.g. html:javascript formName=myForm page=3/ Jay http://www.vtgroup.com/ -Original Message- From: Brandon Mercer [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 22, 2005 11:15 AM To: Struts Users Mailing List Subject: Re: multi-page validation form Jack Perrett wrote: All the previous form properties are set using the StrutsTest so all the required fields are in the form. This is not the issue however, the validation is just plain ignoring the validation, whatever the form property is set to - it should at least be performing the valiadtion on the fields with the correct page value but is just ignoring these. The documentation her does suggest that it will perfrom the validation on any fields with a page property set less than or equal to the form page Ahhh yes, but you said GREATER than or equal to with the logic you wrote. I was just making sure ;-). Another thing I'd check is to see if there are any typo's in the validation.xml file. Make sure the form defined in the struts-config is the same as the one in the validation.xml... I've had that cause validation not work. Other than that, I don't think I can offer much more help. Good luck! Brandon property http://struts.apache.org/userGuide/dev_validator.html - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:29 PM Subject: Re: multi-page validation form Jack Perrett wrote: Thanks for gettig back to me so quickly. I am actually setting the hidden page property. I'm using a StrutsTest so the jsp doesn't actually exist at the moment but I'm creating a form, and setting the fields, and then using form.setPage(2); to set the this property. So I'm effectively submitting a form with the hidden page property set to 2. any ideas what else could be stopping it? - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:04 PM Subject: Re: multi-page validation form Jack Perrett wrote: I'm trying to create a form that will be validated over a series of jsp's. I'm using the page property with individual fields to specify whether they should be validated on a particular page and then setting the hidden page property to whatever the corurrent jsp page. This is how my field looks in the validation.xml field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field But it just seems to ignore this validation whatever I set the form page property to. I'm expecting it to perform this validation if the form page property is = 2, and ignore the validation altogether if the form page property is 2. It's not going to validate this page when it's GREATER than or = to 2... only if it's value is two. That's the first thing. The second thing is, that in your JSP you need to also have hidden fields for the form fields you've collected on the previous pages. Like this. html:hidden property=previousvalue/ html:hidden property=previousvalue2/ html:hidden property=previousvalue3/ :-) Brandon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional
lazyBean and nested:checkbox
I was just looking at the LazyValidatorForm page. Great addition to the struts project IMO. Quick question, to use them in nested situations (I saw the NestedLazyBean example) , does one still have to implement a reset() method to reset checkboxes to false? -- Plato is my friend, Aristotle is my friend, but my greatest friend is truth. - Isaac Newton - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Problem with hot deployment
I'm trying to use hot deployment on an exploded archive with Weblogic 8 and struts 1.2. Whenever I modify and recompile an Action I get an exception. Does this look familiar to anyone? Thanks! Mark java.lang.ClassCastException at org.apache.struts.action.ActionServlet.getProcessorForModule(ActionServlet.j ava:605) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1160) at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:415) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(Servle tStubImpl.java:1006) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java :419) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java :315) at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(W ebAppServletContext.java:6718) at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubjec t.java:321) at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletCo ntext.java:3764) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java :2644) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:219) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:178) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
select list issues:
Hello, I am trying to do something pretty simple I would think. I am also trying to use html:select tags, logic, etc. to keep the project uniform. I have a jsp page that I need to show a set of users in a select list. So I have an action that creates a bean in memory and does not validate. action path=/displaySelect type=foo.WorkAsUser scope=request name=usersbean validate=false input=/jsp/admin/mainAdmin.jsp forward name=Success path=/jsp/admin/testSelect.jsp / !-- test above only -- /action In the foo.WorkAsUser Class, I am doing a query and grabbing the data into a Vector: Then I cast the form (in this action) class back to the usersbean (type). eg: com.UsersBean usersbean = (UsersBean)form; Then I am setting the bean with the Vector. usersbean.setSelectVector(vector); So at this point, I believe to have a good vector of String names options, in the usersBean. Now in the JSP page how do I incorporate this bean into something like this: html:select property=multipleSelect size=10 multiple=true html:options name=multipleValues labelName=multipleValues / /html:select I cannot find the answer. I do have a form tag in this jsp page that calls once again for this usersbean: So I know I own the bean in the request scope, but how do put all this data into a select list? Any ideas Thanks, Scott
RE: multi-page validation form
Apologies for not reading more closely. And now that I have, I'm a little confused. Your original post said But it just seems to ignore this validation whatever I set the form page property to. But below, you say the form always gets validated. Even when the page is set to a number where the fields have not been set. Are the validations firing, just not when you expect, or not firing at all? If not at all, have your set validate to true in your action def in struts-config? (BTW, if I'm off in the weeds, let me know that too. I've done this with a collection of JSP pages sharing a form def, but not via StrutsTest.) Jay http://www.vtgroup.com/ -Original Message- From: Jack Perrett [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 22, 2005 11:58 AM To: Struts Users Mailing List Subject: Re: multi-page validation form No. I don't actually have a jsp page. I'm generating a form in a StrutsTest and then testing what my action does with it. It looks like this: public void testAction() { setRequestPathInfo(/myAction.do); setActionForm(populateForm()); actionPerform(); verifyForward(correctActionForward); verifyNoActionErrors(); } public form populateForm() { MyForm form = new MyForm(); form.setMyField1(); form.setMyField2(); form.setPage(1); // This sets the page variable in the form return form; } So anyway, the form always gets validated. Even when the page is set to a number where the fields have not been set any ideas? - Original Message - From: [EMAIL PROTECTED] To: user@struts.apache.org Sent: Tuesday, March 22, 2005 5:28 PM Subject: RE: multi-page validation form Having done exactly the same thing, I know it works (though it's been a while so I'm trying to remember everthing I've done). Do you also have a page number defined for the Javascript include tag e.g. html:javascript formName=myForm page=3/ Jay http://www.vtgroup.com/ -Original Message- From: Brandon Mercer [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 22, 2005 11:15 AM To: Struts Users Mailing List Subject: Re: multi-page validation form Jack Perrett wrote: All the previous form properties are set using the StrutsTest so all the required fields are in the form. This is not the issue however, the validation is just plain ignoring the validation, whatever the form property is set to - it should at least be performing the valiadtion on the fields with the correct page value but is just ignoring these. The documentation her does suggest that it will perfrom the validation on any fields with a page property set less than or equal to the form page Ahhh yes, but you said GREATER than or equal to with the logic you wrote. I was just making sure ;-). Another thing I'd check is to see if there are any typo's in the validation.xml file. Make sure the form defined in the struts-config is the same as the one in the validation.xml... I've had that cause validation not work. Other than that, I don't think I can offer much more help. Good luck! Brandon property http://struts.apache.org/userGuide/dev_validator.html - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:29 PM Subject: Re: multi-page validation form Jack Perrett wrote: Thanks for gettig back to me so quickly. I am actually setting the hidden page property. I'm using a StrutsTest so the jsp doesn't actually exist at the moment but I'm creating a form, and setting the fields, and then using form.setPage(2); to set the this property. So I'm effectively submitting a form with the hidden page property set to 2. any ideas what else could be stopping it? - Original Message - From: Brandon Mercer [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, March 22, 2005 4:04 PM Subject: Re: multi-page validation form Jack Perrett wrote: I'm trying to create a form that will be validated over a series of jsp's. I'm using the page property with individual fields to specify whether they should be validated on a particular page and then setting the hidden page property to whatever the corurrent jsp page. This is how my field looks in the validation.xml field property=adults page=2 depends=required arg0 key=passengerBookingForm.adults/ /field But it just seems to ignore this validation whatever I set the form page property to. I'm expecting it to perform this validation if the form page property is = 2, and ignore the validation altogether if the form page property is 2. It's not going to validate this page when it's GREATER than or = to 2... only if it's value is two. That's the first thing. The second thing is, that in your JSP you need to also have hidden fields for the
The F5 problem - Best Practice (ActionHierarchy)
Hi, I have a problem which I think is common to many of the developers one the list, and where I'd like to hark to your opinions / solutions. I think it's a common use case in web applications, where you have to present a list of something, lets say a list of bikes. You have normally some common functionality, like ShowList, Edit/New (presents a dialog), Create/Update and a Delete operation. Now my problem is, that after delete,create or update I normally show the updated list, by actually executing the Show action. I know about two ways to implement this derive the delete action from show action, and call super.execute(), or send a redirect from delete action to the show action. Example: action path=/bikesShow type=net.anotheria.bikes.action.ShowBikesAction scope=request forward name=success path=/net/anotheria/bikes/jsp/Bikes.jsp/ /action action path=/bikeDelete type=net.anotheria.bikes.action.DeleteBikeAction scope=request forward name=success path=/net/anotheria/bikes/jsp/Bikes.jsp/ /action After bikeDelete has been called, it calls the super.execute from ShowBikesAction it's extending, and the updated list is presented. Works fine ... until the user hits the refresh button. Since the url in the browser is bikeDelete and not bikesShow the delete action will be called again. It's getting even worser with create action which then would actually create a second record. Now, I could avoid creating second object or trying to delete already deleted object by inserting an execute-once-tokens, but it feels like fixing a bad design, so I'd like to avoid it. Another approach I know of, is to define the delete action without a forward and actually send a redirect after the deletion is complete. This would solve the F5 problem, but produces an additional request from browser to server, and makes the whole app slower. Do you know any other solutions? I have searched for an opportunity to solve this problem with a tricky js, actually replacing the url of the current document in the browser without request, but i found none :-( Any other ideas, options? Thanx in advance Regards Leon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: The F5 problem - Best Practice (ActionHierarchy)
I think doing the post-redirect-get (the second option you mentioned) is the best way to solve your problem, according to what most people recommend. Abdullah -Original Message- From: Leon Rosenberg [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 22, 2005 3:32 PM To: 'Struts Users Mailing List' Subject: The F5 problem - Best Practice (ActionHierarchy) Hi, I have a problem which I think is common to many of the developers one the list, and where I'd like to hark to your opinions / solutions. I think it's a common use case in web applications, where you have to present a list of something, lets say a list of bikes. You have normally some common functionality, like ShowList, Edit/New (presents a dialog), Create/Update and a Delete operation. Now my problem is, that after delete,create or update I normally show the updated list, by actually executing the Show action. I know about two ways to implement this derive the delete action from show action, and call super.execute(), or send a redirect from delete action to the show action. Example: action path=/bikesShow type=net.anotheria.bikes.action.ShowBikesAction scope=request forward name=success path=/net/anotheria/bikes/jsp/Bikes.jsp/ /action action path=/bikeDelete type=net.anotheria.bikes.action.DeleteBikeAction scope=request forward name=success path=/net/anotheria/bikes/jsp/Bikes.jsp/ /action After bikeDelete has been called, it calls the super.execute from ShowBikesAction it's extending, and the updated list is presented. Works fine ... until the user hits the refresh button. Since the url in the browser is bikeDelete and not bikesShow the delete action will be called again. It's getting even worser with create action which then would actually create a second record. Now, I could avoid creating second object or trying to delete already deleted object by inserting an execute-once-tokens, but it feels like fixing a bad design, so I'd like to avoid it. Another approach I know of, is to define the delete action without a forward and actually send a redirect after the deletion is complete. This would solve the F5 problem, but produces an additional request from browser to server, and makes the whole app slower. Do you know any other solutions? I have searched for an opportunity to solve this problem with a tricky js, actually replacing the url of the current document in the browser without request, but i found none :-( Any other ideas, options? Thanx in advance Regards Leon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Embedding messages within messages
Can you do something like this inside your message-resources files? //--- applicationName=My Application error.application=You have run into an error caused the the ${applicationName} application. //--- I want to have a paramaterized error message, but I want the parameter to basically be predefined as another resource key. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: The F5 problem - Best Practice (ActionHierarchy)
Leon: My suggestion is to use Tokens. I know you dont feel very nice about it but it is a practical (this is the keyword) solution. From my personal experience avoid JavaScript as far as possible. It does come across as a nice solution but becomes very painful to maintain. Cheers Rajesh --- Original Message --- From: Leon Rosenberg [EMAIL PROTECTED] To: 'Struts Users Mailing List' user@struts.apache.org Cc: Sent: Wed 3/23/05 8:32 AM EST Subject: The F5 problem - Best Practice (ActionHierarchy) Hi, I have a problem which I think is common to many of the developers one the list, and where I'd like to hark to your opinions / solutions. I think it's a common use case in web applications, where you have to present a list of something, lets say a list of bikes. You have normally some common functionality, like ShowList, Edit/New (presents a dialog), Create/Update and a Delete operation. Now my problem is, that after delete,create or update I normally show the updated list, by actually executing the Show action. I know about two ways to implement this derive the delete action from show action, and call super.execute(), or send a redirect from delete action to the show action. Example: action path=/bikesShow type=net.anotheria.bikes.action.ShowBikesAction scope=request forward name=success path=/net/anotheria/bikes/jsp/Bikes.jsp/ /action action path=/bikeDelete type=net.anotheria.bikes.action.DeleteBikeAction scope=request forward name=success path=/net/anotheria/bikes/jsp/Bikes.jsp/ /action After bikeDelete has been called, it calls the super.execute from ShowBikesAction it's extending, and the updated list is presented. Works fine ... until the user hits the refresh button. Since the url in the browser is bikeDelete and not bikesShow the delete action will be called again. It's getting even worser with create action which then would actually create a second record. Now, I could avoid creating second object or trying to delete already deleted object by inserting an execute-once-tokens, but it feels like fixing a bad design, so I'd like to avoid it. Another approach I know of, is to define the delete action without a forward and actually send a redirect after the deletion is complete. This would solve the F5 problem, but produces an additional request from browser to server, and makes the whole app slower. Do you know any other solutions? I have searched for an opportunity to solve this problem with a tricky js, actually replacing the url of the current document in the browser without request, but i found none :-( Any other ideas, options?
Re: Embedding messages within messages
That has actually been on my todo list for quite a while now. Struts will be changing soon to use commons-resources so it would be better to focus such an effort over there. I'm hoping to get back to working on commons-resources soon. My current focus (with what little time I have) is to finish up with taglibs and the nightlies. -- James Mitchell Software Engineer / Open Source Evangelist EdgeTech, Inc. 678.910.8017 AIM: jmitchtx - Original Message - From: snekse [EMAIL PROTECTED] To: STRUTS-USER-LIST user@struts.apache.org Sent: Tuesday, March 22, 2005 5:31 PM Subject: Embedding messages within messages Can you do something like this inside your message-resources files? //--- applicationName=My Application error.application=You have run into an error caused the the ${applicationName} application. //--- I want to have a paramaterized error message, but I want the parameter to basically be predefined as another resource key. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Struts webapp caused out of memory after some reload
Hi, I'm running a server (Apache Tomcat 5.0.28 with 512 MB RAM) which hosting two webapps, one using Spring and other using Struts. The problem is, after i reload the Struts webapp for about 15-20 times i'm getting out of memory error. This is not happend with the Spring webapp. After some search, i found that Spring has IntrospectorCleanupListener http://www.springframework.org/docs/api/org/springframework/web/util/IntrospectorCleanupListener.html which can handle this kind situation. A post about this is: http://issues.apache.org/bugzilla/show_bug.cgi?id=26135 The question is, doesn't struts have its own solving? or do i have to use Spring's IntrospectorCleanupListener so i won't get out of memory error again?? Thank you very much for the help. I'm still new with struts. And last night I dont have a decent sleep because of this problem ;) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
WrapDynaBean : netsed properties
Hello, Current version of WrapDynaBean does not support nested properties of bean ( does not do recursion when introspecting the bean) Is there intent to support that in next release ? Thanks
Re: Struts webapp caused out of memory after some reload
Thank you for your fast response Yes, i realize that so many reloading in a production server is bad practice. This is due 'the not very ideal' environment and policy in my company. I'm doing it because I have different platform for development and production. My company using Linux Redhat as production server, while I'm using win 2000 for development (yes, they would be mad if I change my system into Linux!). Everything start goes wrong when dealing with file path and library dependencies (JasperReport is throwing lot of error because of some library is deprecated in Redhat, etc). That's why I need so many reload on production server, debugging purpose, major pain it is. Anyway, thats not the concern. The interesting part is when I reload my application the memory is keep growing in a certain increment. Should I keep using IntrospectorCleanupListener from Spring? is it bad one? I'm sorry if my question is stupid. I'm still trying to learn the best one with Struts. I love it since the first look. ;) Best regards On Tue, 22 Mar 2005 22:38:05 -0500, James Mitchell [EMAIL PROTECTED] wrote: Struts does not provide this sort of thing. In the environments that I typically work in, production releases are handled by a release manager(s). When a new release goes out, the server is usually brought down and the new build is pushed out, then brought back up. This being done after normal working hours of course. I'd be interested to hear if you are using it successfully in a production environment. I'd also be interested in how many times and why you need to reload a production application. Using something like this during development is a no-brainer, but I was just wondering. -- James Mitchell Software Engineer / Open Source Evangelist EdgeTech, Inc. 678.910.8017 AIM: jmitchtx - Original Message - From: Yuniar Setiawan [EMAIL PROTECTED] To: user@struts.apache.org Sent: Tuesday, March 22, 2005 9:47 PM Subject: Struts webapp caused out of memory after some reload Hi, I'm running a server (Apache Tomcat 5.0.28 with 512 MB RAM) which hosting two webapps, one using Spring and other using Struts. The problem is, after i reload the Struts webapp for about 15-20 times i'm getting out of memory error. This is not happend with the Spring webapp. After some search, i found that Spring has IntrospectorCleanupListener http://www.springframework.org/docs/api/org/springframework/web/util/IntrospectorCleanupListener.html which can handle this kind situation. A post about this is: http://issues.apache.org/bugzilla/show_bug.cgi?id=26135 The question is, doesn't struts have its own solving? or do i have to use Spring's IntrospectorCleanupListener so i won't get out of memory error again?? Thank you very much for the help. I'm still new with struts. And last night I dont have a decent sleep because of this problem ;) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: select list issues:
I assume you know about the HTML tag Users Guide? (http://struts.apache.org/userGuide/struts-html.html) Richard. On Tue, 22 Mar 2005 14:35:25 -0600, Scott Purcell [EMAIL PROTECTED] wrote: Hello, I am trying to do something pretty simple I would think. I am also trying to use html:select tags, logic, etc. to keep the project uniform. I have a jsp page that I need to show a set of users in a select list. So I have an action that creates a bean in memory and does not validate. action path=/displaySelect type=foo.WorkAsUser scope=request name=usersbean validate=false input=/jsp/admin/mainAdmin.jsp forward name=Success path=/jsp/admin/testSelect.jsp / !-- test above only -- /action In the foo.WorkAsUser Class, I am doing a query and grabbing the data into a Vector: Then I cast the form (in this action) class back to the usersbean (type). eg: com.UsersBean usersbean = (UsersBean)form; Then I am setting the bean with the Vector. usersbean.setSelectVector(vector); So at this point, I believe to have a good vector of String names options, in the usersBean. Now in the JSP page how do I incorporate this bean into something like this: html:select property=multipleSelect size=10 multiple=true html:options name=multipleValues labelName=multipleValues / /html:select I cannot find the answer. I do have a form tag in this jsp page that calls once again for this usersbean: So I know I own the bean in the request scope, but how do put all this data into a select list? Any ideas Thanks, Scott - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problems using JSTL with struts
I have done that and I keep having the same problem. I'm completly loose. Rodolfo García Esteban Canal Isabel II División de Aplicaciones Técnicas C/ Santa Engracia, 125 Edificio 8 Tel. 91 545 10 00 - Ext. 2128 Fax. 91 545 14 41 ___ Tom Ziemer [EMAIL PROTECTED] 18/03/2005 11:00 Por favor, responda a Struts Users Mailing List Para: Struts Users Mailing List user@struts.apache.org cc: (cco: Rodolfo García Esteban/CYII) Asunto: Re: Problems using JSTL with struts Hi, I had a similar problem. What I did was: a) put jstl.jar and standard.jar in WEB-INF/lib b) modify your web.xml - it should start with this line: web-app xmlns=http://java.sun.com/xml/ns/j2ee; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee web-app_2_4.xsd version=2.4 When I used my old web.xml with web-app_2_2.dtd, it didn't work. Can anybody explain this? Regards, Tom Rodolfo García Esteban/CYII wrote: Hi, I have a little application done with struts 1.2 and hibernate 2.1, I want to migrate it to JSTL 2.0, and struts-EL. I have done the next: 1. Install jstl, adding to the WEB-INF/lib jstl.jar 2. Writing in the pages then taglib clause to import the tags. But I have the next problems. 1 when I do c:set for get the actionForm return null, I can manage the form. 2. when I do c:out value=${}, in then web I don't see then content of , I see as a literal ${}. Has somebody use JSTL and Struts-EL with Struts 1.2? Do somebody knows the solution for my problem? I would apreciatte any help Best regards Rodolfo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]