Has anyone run into a situation where it was desirable for users to execute an
Action (a) and, while in the context of doing all of the lovely things
associated with (a), the user gestures in a way that a second Action (a) process
starts as a sort of child process -- in which case we have (temporarily) two
ActionForms with different states competing for the same HTTP session name
space?

My ActionForms are really just simple containers for the real value objects that
get passed back and forth between the EJB container and the web tier.

Because of the nature of Action (a) as a multi-page "wizard" sort of interface,
it is convenient to keep the ActionForms (af) in the session scope.

One solution I am considering is making modifications to the controller servlet
to ask a custom workflow manager service for the proper ActionForm instance
associated with the request and then having the controller servlet put that form
in the proper session scope (or even request scope--I guess at the point where
the controller is asking a service for the proper form, it might not be
necessary to put any ActionForm in the HTTP session scope).  Anyway, in this
case the Actions themselves would be none the wiser about where they get their
ActionForms.

Of course, if I go this route, I'd need to add some sort of hidden field to each
page that had some meaningful reference to a specific ActionForm object in order
to facilitate the reassociation --or perhaps I could use a stack and and simply
pop and push the appropriate ActionForms.

Has anyone else ran had this sort of need?  How did you solve it?

thanks,
Michael

Reply via email to