It's not a secret anymore!
The moose likes Struts and the fly likes Struts form bean scope Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts form bean scope" Watch "Struts form bean scope" New topic

Struts form bean scope

reddy raja

Joined: Sep 21, 2009
Posts: 17
Hi all,
I am new to struts i have doubt in using struts form bean scope. i am using struts 1.2 in my project .i have a requirement where i want to populate the values of one page in corresponding next page .I can get the values by using same form bean for both the pages.I used form bean scope as session .But people saying this will decrease the performance of project .If i keep form bean scope as request then at the time of validations values are missing.I cannot use hidden fields because of security purpose.

so please suggest me something .

Thank you.

David Newton

Joined: Sep 29, 2008
Posts: 12617

Who says it'll decrease the performance of your project?

The only reason keeping data in session *might* reduce performance is if there's a *lot* of data in the session, but session forms are unlikely to be the culprit. And you can always remove them from session once you're not processing the form any more.
I agree. Here's the link:
subject: Struts form bean scope
It's not a secret anymore!