ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jose Alberto Fernandez <JFernan...@viquity.com>
Subject RE: Redirecting output and background processes
Date Thu, 28 Sep 2000 03:41:33 GMT
> From: Conor MacNeill [mailto:conor@ebinteractive.com.au]
> 
> > >
> > > Conor has some stuff in his "unfinished works" that would 
> allow any
> > > task to be called in a different thread than the main build
> > > process. I'm not sure whether Ant would keep running 
> while one thread
> > > in the same JVM is waiting on Runtime.exec to finish on 
> all OS's - but
> > > this could probably be the solution.
> > >
> > Connor mentioned this to me. However, I wonder if it will be
> > usefull to have
> > a real fork kind of thing. Using "&" in unix and "start" on windows.
> > Do not know for other OSs.
> >
> 
> The way I have done it so far is to only allow tasks to run 
> async within the
> context of a single target. At the end of the target all task 
> threads are
> joined and any exceptions in the individual threads are rethrown,
> potentially causing the build to fail.
> 
> I think that is an appropriate level of async behaviour.
> 

Well this is where my comments about using ANT for more than building comes
into play. The level of async that I am interested with is more for testing
enviroments than for building environments.

So imagine in conjunction with JUnit tests. Your test cases are executed
synchronously on the build, but you need to execute your server application
in the background. You need to be able to start it, and eventually stop it.
So on thise circumstances you really want a fork.

The alternative is to provide scripts in all the different OSs that you are
to call to just start and stop the server. I would like to use ANT instead.

Jose Alberto
 

Mime
View raw message