The ChainAction was intended to be another option for users in defining
their actions in the struts-config.  User's are not forced to chain actions
together in each ActionMapping.  For this reason in lieu of a Custom Reqeust
Processor, we decided to use the existing Struts Action architecture to
chain Actions together.  We were able to implement this COR pattern without
making any changes to the existing Struts Architecture.

The chains of Actions could be maintained in additional config xml file to
be used in combination with the existing struts configuration.  Obviously
this configuration file is not manditory, as users can choose not to define
ChainAction's in their struts-config.


----- Original Message -----
From: "Daniel Honig" <[EMAIL PROTECTED]>
To: "Struts Developers List" <[EMAIL PROTECTED]>; "Karl Baum"
<[EMAIL PROTECTED]>
Sent: Tuesday, November 12, 2002 7:37 PM
Subject: RE: ChainAction class


> I would just like to instigate some trouble along with this question
> since I am a big fan of the "Chain Of Repsonsibility" pattern
> and agree that it can do a nice job of creating atomic
> and reusable code structures.
>
> I would also like to say that I think it could be confusing
> to have a chain action.  The example provided for invoking
> actions based on Locale is handled by implementing someone's
> own custom RequestProcessor.  Fan of the COR pattern I may be
> but implementing a custom RequestProcessor seems cleaner.
>
> One problem if you implement COR is how do you assemble and execute
chains?
> Where do you store this info?
>
> Servlet Filters offer another chance to implement COR.
>
> Perhaps I'm hallucinating again,  but has craig talked about COR and Java
> Server Faces?
>
> I think its' great if the contribution doesn't hurt anything else and
> pending
> the design is good.  But I think most cases for use in a COR environment
> can be handled other ways.  COR is a nice way to redirect output streams
> for several transformations of the output stream.  Say you had one action
> that read data from a database and output xml.  You could continue to add
> chain processors until it outputs a PDF file.
>
>
> -Daniel
>
> -----Original Message-----
> From: Karl Baum [mailto:kbaum@;Tallan.com]
> Sent: Tuesday, November 12, 2002 4:19 PM
> To: Struts Developers Lis
> Subject: ChainAction class
>
>
> Over the past year and a half, I have developed using the Struts platform.
>
> During this time, my colleagues and I created an Action class which allows
> other actions to be chained together.  This design resembled the Chain of
> Responsibility pattern.   The ChainAction class was well received by the
> many other developers on our project.  Most importantly it helped keep our
> Action components simple and modular and promoted reuse in our code.  In
> addition, the ChainAction class allowed for different Actions to be
executed
> based on Locale.
>
> I have been benefiting from the Struts Model View Controller framework for
> some time and would like to contribute the ChainAction class to the
> framework.  The addition of the ChainAction class would require no change
> to the existing Struts code base and would only offer Struts users an
> additional Action class implementation.
>
> I would like to gauge the interest other Struts developers have in this
> idea.  Thanks.
>
> Karl
>
>
>
> --
> To unsubscribe, e-mail:
<mailto:struts-dev-unsubscribe@;jakarta.apache.org>
> For additional commands, e-mail:
<mailto:struts-dev-help@;jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <mailto:struts-dev-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-dev-help@;jakarta.apache.org>

Reply via email to