ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: cvs commit: jakarta-ant/src/testcases/org/apache/tools/ant/taskdefs ExecuteJavaTest.java TimeProcess.java ExecuteWatchdogTest.java
Date Fri, 05 Apr 2002 13:28:18 GMT
On 5 Apr 2002, <bodewig@apache.org> wrote:

>   timeout support for <java>

This has a couple of side effects that I want your opinion on before I
close the bug.

timeout for forked java has been trivial, but I had to change
ExecuteJava considerably to add it for the in-VM mode.

The main change is that Ant will now run the class in a separate
thread, if a timeout value has been specified.  I'm not sure whether
our log system can deal with it (it may receive output from a thread
that is not associated with a task).

If timeout has been triggered, all ExecuteJava does right now is to
interrupt() the spawned thread - which means it will not do too much
for run-away threads.  stop() or even destroy() look more than a
little dangerous in this context.

But then again, run-away threads without this timeout feature would
make Ant hang anyway.

Stefan

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message