On 25 Mar 2014, at 08:45, Kasper Nielsen <kaspe...@gmail.com> wrote:

> On Mon, Mar 24, 2014 at 10:11 PM, roger riggs <roger.ri...@oracle.com>wrote:
> 
>> Hi,
>> 
>> I'm starting to work on JEP 102, Process API Updates for JDK 9.
>> 
>> Are there use cases for which this is insufficient?  Please comment.
>> 
>> 
> What about a non-blocking waitFor mechanism such as
> 
> void onTerminate(IntConsumer consumer) or
> CompletionStage<Integer> onTerminate();
> 
> Would be useful for spawning many small processes.
> 
> 
> Also a waitFor method taking a timeout parameter. So you, for example, can
> wait for the subprocess to exit within 10 seconds. And if not kill it.

Have you looked at these new methods in Java 8? Or are you looking for 
something different?

http://download.java.net/jdk8/docs/api/java/lang/Process.html#waitFor-long-java.util.concurrent.TimeUnit-
http://download.java.net/jdk8/docs/api/java/lang/Process.html#destroyForcibly--

-Chris.

> 
> - Kasper

Reply via email to