JEP 102: Process API Updates

AuthorAlan Bateman
OwnerRoger Riggs
Created2011/09/01 20:00
Updated2015/09/04 15:02
Componentcore-libs / java.lang
Discussioncore dash libs dash dev at openjdk dot java dot net
Endorsed byBrian Goetz
Depends8077350: JEP 102 Process API Updates Implementation
Relates toJEP 279: Improve Test-Failure Troubleshooting


Improve the API for controlling and managing operating-system processes.


The limitations of the current API often force developers to resort to native code.


Java SE provides limited support for native operating-system processes. It provides a basic API to setup the environment and start a process. The process streams can, since Java SE 7, be redirected to files, pipes, or can be inherited. Once started, the API can be used to destroy the process and/or wait for the process to terminate.

Many enterprise applications and containers involve several Java virtual machines and processes and have long-standing needs which include:


The classes or methods introduced will require new unit tests that can be developed along with the implementation. More functional tests would be useful too.

Risks and Assumptions

The main risk with this API is differences between operating systems, in particular Windows.

The design of this API needs to accommodate possible deployment on smaller devices with different operating system models. It should also take into account environments where multiple Java virtual machines are running in the same operating system process. These considerations could lead to a more abstract API and/or increase the design effort.