ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Loughran <>
Subject Re: java/exec task - process tracking
Date Mon, 06 Mar 2006 13:50:41 GMT
Frederic CHALONS wrote:
> Hi,
> I am using a ant file to launch various processes.
> Previously, this was done via a bash file via.
> With bash, I could retrieve PIDs from $! variable to keep track of launched
> processes.
> How may I achieve something similar with Ant.
> May I retrieve pid associated to an java/exec task?
> So far, I am still using a minimal bash script to retrieve the PIDs after
> invoking Ant.

There's nothing in java pre-1.5 that even vaguely resembles a PID, so no 
way for ant to get at it.

> Any other alternatives?
> Any solutions supporting Windows too in addition to Unix/Linux systems?

java1.5 has jps and jconsole; every ps can run with jmx management 
turned on if you fiddle with the parameters.

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

View raw message