Thank you, but replacing existing tasks is dangerous, unless the code will go into ANT sources. I am already using beta 3. I will try your sources. Sincerely, Alexey Solofnenko. -----Original Message----- From: Hal Hildebrand (web) [mailto:Hal.Hildebrand@hellblazer.com] Sent: Saturday, June 29, 2002 7:39 PM To: Ant Users List Subject: Re: What to do if ed program hangs? Importance: High Attached are two patched files to Ant 1.5 beta 2. With these fixes you can do: ... Do your testing here ... The patched Parallel task's semantics are changed. If any one of the parallel threads of the task throws an exception, all the threads are interrupted. This means that if you do ... start your server ... ... wait for server to come up ... ... do your tests ... ... shutdown the server ... and an exception occurs (such as a build exception) in the second sequential task, the parallel task will exit after interrupting the first thread. This is where the second patched file, Execute comes in. The patch here is to handle the InterruptedException correctly (or at least handle it) by always ensuring that the process is destroyed. Thus if a build exception occurs, the first task (which spawns the application server process) is interrupted and the process is killed. Combined with the use of a timeout using the waitfor task, it's a leash to yank back those pesky processes and make 'em heel. Combined with the try-finally task from the source forge ant contrib, you pretty much have all the elements to manage multiple processes in Ant. ----- Original Message ----- From: "Alexey Solofnenko" > Hello, > > we are performing unit testing of our RMI servers during build process on > Windows. The tests are started from ANT, but execute in a different > environment. Unfortunately the servers not always stop correctly and the > build hangs. What would be a good way to kill the processes, so ANT build > will continue? > > - Alexey. > > -- > To unsubscribe, e-mail: > For additional commands, e-mail: > > > -- To unsubscribe, e-mail: For additional commands, e-mail: