public abstract class AnyRpcPlugin extends Object
| Modifier | Constructor and Description |
|---|---|
protected |
AnyRpcPlugin() |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
blockUntilShutdown()
Runs the main loop for the server and waits for the server to shutdown.
|
abstract void |
initialize(int serverPort)
Initializes the plugin, possibly creating any sockets/files/channels/connections
needed.
|
abstract boolean |
serverStarted()
Returns true if the server has been started and has not stopped.
|
abstract void |
shutdown()
Performs any actions that are necessary to shut down any clients or servers started from this
plugin.
|
abstract void |
startServer(EvaluationRuntimeServerInterface evaluationRuntime,
CloneControllerServerInterface cloneController)
Starts the server using the two specified implementations of the
RPC-agnostic EvaluationRuntime and CloneController interfaces.
|
abstract void |
stopServer()
Stops the server.
|
abstract Runnable |
traceContextPropagating(Runnable runnable)
Wraps the provided
Runnable so as to assure propagation of the tracing context. |
public abstract void initialize(int serverPort)
serverPort - the port to listen for RPCs on.public abstract void startServer(EvaluationRuntimeServerInterface evaluationRuntime, CloneControllerServerInterface cloneController)
evaluationRuntime - the evaluation runtime service implementationcloneController - the clone controller service implementationpublic abstract boolean serverStarted()
public abstract void blockUntilShutdown()
This method MUST be called from the same thread that called
startServer(EvaluationRuntimeServerInterface, CloneControllerServerInterface).
AssertionError - if startServer was not called or didn't complete
successfullypublic abstract void stopServer()
AssertionError - if startServer was not called or didn't complete
successfullypublic abstract void shutdown()
public abstract Runnable traceContextPropagating(Runnable runnable)
Runnable so as to assure propagation of the tracing context.runnable - the Runnable to wrapCopyright © 2022. All rights reserved.