Hello.
I need a flexible way to organize a pipeline of different "sub-programs"
(probably perl and c). The "sub-programs" are triggered according to the
output of the prior programs and according to certain parameters. The
pipeline will have the form of a graph with branching of the program
flow according to boolean expressions which depend of the output of
prior "sub-programs".
I need to program a software which triggers this pipeline and which
organizes the aforementioned parameters and even the complete form of
the graph and which lets the user to edit these with the help of a GUI.
This seems to be a very common problem. Are there any java-libraries or
frameworks that support the development of such software?
Thanks a lot,
Harald
Check out Jakarta's commons-chain. It allows you to build a "chain of
command" where each command performs some computation, maybe throws an
exception if an error is encountered, and otherwise the next command is
invoked. A "context" is passed from command to command and each
command has the ability to read from the context or write to it. The
context is essentially a java.util.Map.
You could come up with a set of Command classes that execute a Perl or
C or other programs. You could probably do this really cleanly with
commons-chain.
Also, it's an Apache project, is open-source, and is mature:
http://jakarta.apache.org/commons/chain/
Check it out.
Hernan
bernd - 19 Jan 2006 12:54 GMT
Hi,
thanks a lot for this pointer, Hernan. Commons-chain comes very near to
the thing that I need.
But as far as I can see after reading two articles, there is no way to
manage parameters (which effect the behavior of the commands) in a
centralized manner e.g. through xml. And I can not see that it would be
possible to fork the execution of commands; but I need to trigger
different kinds of commands depending on the context. It should be
possible to edit this structure through xml, also.
So I think I need more a "graph" than a "chain".
Regards,
Harald