Prerequisite to why I am an advocate of "Controlled" Chaining

1) I write jars that can be easily and interchangeably congifured to
work together. Therefore I must keep cross dependencies at a minimum and
avoid creating and tweaking code.
2) I advocate chaining for "read-only" processes
3) This works most fluidly when each action can use the SAME action
form. Preferably a generic mapped back. This is because the map has lose
typing as long as it's an object it will hold it.

That being said... here is a made up example:

I have a page that contains stock prices, content, and a weather
report.

These are commonly used items and they are for viewing (not data
entry). 

So, if I want to prepare that data for a view I have a few choices:

1) for every view that will use these I create a 1 to 1 relationship
with my View->ActionForm->Action and make the logic calls to prepare the
data for the view. So for each page that included various combinations
of these items you would have to write an Action/ActionForm to get the
data.

2) I could use Tiles. Which is not organizationally coherent (to me).
And you have to make several Action calls from the page level. And it is
tiles specific. BTW: I DO LIKE TILES AND USE IT EXTENSIVELY

3) You could make 3 Actions that are very simple and chain them
together as you need.Organizationally it allows you to see your process
in a config that is directly tied to the Struts-Config. and allows you
to prepare the data in one fluid request (rather than several unrelated
requests). The struts chaining DOES NOT do forwarding from one action to
the next. It calls other Actions from within a "master" action. So, the
request remains the same. There are some enhancements I want to provide
to that project. But, I don't have the time at the moment. Plus, I'm
waiting to see how the Commons Chain effects the struts chaining
effort.

Those are just my thoughts,
Brandon Goodin






---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to