Interface ControlClient
- All Superinterfaces:
AutoCloseable
- All Known Implementing Classes:
JeroMQControlClient
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceUsed to open on-demand instances of theControlClient. -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Closes this instance ofControlClientvoidcloseBinding(NodeId nodeId) Issues the command to close a binding.voidcloseRoutesViaInstance(InstanceId instanceId, String instanceConnectAddress) Close the routes via theInstanceId.Gets theInstanceIdfor the remote instance.Gets the routing status for the system.openBinding(NodeId nodeId) Opens anInstanceConnectionService.InstanceBindingprovided theNodeIdand returns theInstanceConnectionService.InstanceBinding.openRouteToNode(NodeId nodeId, String instanceInvokerAddress) Issues the command to open up a route to the node.voidsetReceiveTimeout(long timeout, TimeUnit timeUnit) Allows for the adjustment of thisControlClient's receive timeout.
-
Method Details
-
getRoutingStatus
RoutingStatus getRoutingStatus()Gets the routing status for the system.- Returns:
- the routing status.
-
getInstanceStatus
InstanceStatus getInstanceStatus()Gets theInstanceIdfor the remote instance.- Returns:
- the
InstanceStatus
-
openRouteToNode
Issues the command to open up a route to the node.- Parameters:
nodeId- theNodeIdinstanceInvokerAddress-- Returns:
- the connect address for the node
-
closeRoutesViaInstance
Close the routes via theInstanceId. If no routes are known, then nothing happens.- Parameters:
instanceId- theInstanceId
-
openBinding
Opens anInstanceConnectionService.InstanceBindingprovided theNodeIdand returns theInstanceConnectionService.InstanceBinding.- Parameters:
nodeId- theNodeId- Returns:
- the
InstanceConnectionService.InstanceBinding
-
closeBinding
Issues the command to close a binding. This will invalidate allInstanceConnectionService.InstanceBindings to thatNodeId.- Parameters:
nodeId-
-
setReceiveTimeout
Allows for the adjustment of thisControlClient's receive timeout.- Parameters:
timeout- the timeouttimeUnit- theTimeUnit
-
close
void close()Closes this instance ofControlClient- Specified by:
closein interfaceAutoCloseable
-