commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mattias J <>
Subject Re: Commons Chain Alternate Flows
Date Fri, 27 May 2005 14:43:19 GMT
At 2005-05-27 16:26, you wrote:
>I'm using Commons Chain to execute a series of commands.  What I'm
>trying to ascertain is if it is possible to add alternate flows (e.g.
>exception cases) to the chain config XML file.  Currently my chain
>contains a serial list of commands to execute with a common context.
>I'd like to be able to define alternate chains to execute under
>conditions such as exception cases but without the command that threw
>the exception (or set a flag) knowing what the chain configuration was
>set to - i.e. it should all be defined in the chain config - not in the

Not really sure I understand the problem, but maybe you could create a 
"conditional" Filter, that handles this for you, and then set the different 
chains on this Filter (like "normal chain", "chain if exception"). This 
will not be configurable by Chain XML config, but you could use Spring.

>Has anyone done this?

Haven't tried this myself though.

   /Mattias Jiderhamn 

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message