> It may be better to stay away from a grammar that gives the
> rules and use something like:
>
> <target name="d" depends="e" ... </target>
> <target name="e" " ... <parallelexecute targets="a,c" ...
> </parallelexecute> ... </target>
> <target name="c" depends="b" ... </target>
> <target name="b" ... </target>
You could provide another executor ;)
In my approach I dont want the user to change the buildfile. Just set
the property on command line.
ant -Dant.executor.class=ParallelExecutor ...
> How do you propose to handle potential fatal/non fatal
> errors?
The implementation collects thrown BuildExceptions from the target.
A target will be started, if no dependend target has failed.
Why not try to build the jar only because the test fails? If there is a
dependency you should
describe that dependency using the depends-attribute.
>If target a exits due to an error, should there be an
> option to kill a or allow it to complete (similar to
> failonerror="yes/no")? If both a and (b,c) must succeed for
> d, should a be killed if b or c fails?
If you want to have that, use
<target depends="" if=""/>
If there is no dependency - why stop the build?
> It was not difficult, but error handling was always the issue.
My biggest problem is spreading all the logs. In a single thread you
have output like
target-1
target-1
target-2
target-2
When parallelizing that you could earn
target-2
target-1
target-2
target-1
I thought about using a logger per thread
Logger log = Logger.getLogger( targetName + "." + threadNumber );
Jan
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]