Module jdk.jshell

Class RemoteExecutionControl

java.lang.Object
jdk.jshell.execution.DirectExecutionControl
jdk.jshell.execution.RemoteExecutionControl
All Implemented Interfaces:
AutoCloseable, ExecutionControl

public class RemoteExecutionControl extends DirectExecutionControl implements ExecutionControl
The remote agent runs in the execution process (separate from the main JShell process). This agent loads code over a socket from the main JShell process, executes the code, and other misc, Specialization of DirectExecutionControl which adds stop support controlled by an external process. Designed to work with JdiDefaultExecutionControl.

The initial handshake with JdiDefaultExecutionControl is as follows: the first command line argument is -1. The port number to which the agent should connect is passed on the first line on stdin. On the second line of stdin, an Base64-encoded byte array is sent, which should be sent to the socket immediately after the connection is established.

Since:
9