Constructor and Description |
---|
ManagementClient(IClientRouter router,
long epoch) |
Modifier and Type | Method and Description |
---|---|
CreateWorkflowResponse |
addNodeRequest(String endpoint)
Send a add node request to an orchestrator
|
CompletableFuture<Boolean> |
bootstrapManagement(Layout l)
Bootstraps a management server.
|
CreateWorkflowResponse |
forceRemoveNode(String endpoint)
Send a force remove node request to an orchestrator service node.
|
CompletableFuture<Layout> |
getLayout()
Requests for the layout persisted by the management server.
|
CompletableFuture<Boolean> |
handleFailure(long detectorEpoch,
Set<String> failedNodes)
Sends the failure detected to the relevant management server.
|
CompletableFuture<Boolean> |
handleHealing(long detectorEpoch,
Set<String> healedNodes)
Sends the healed nodes detected to the relevant management server.
|
CreateWorkflowResponse |
healNodeRequest(String endpoint,
boolean isLayoutServer,
boolean isSequencerServer,
boolean isLogUnitServer,
int stripeIndex)
Creates a workflow request to heal a node.
|
CreateWorkflowResponse |
mergeSegments(String endpoint)
Creates a workflow request to restore all redundancies and merge all segments.
|
QueryResponse |
queryRequest(UUID workflowId)
Query the state of a workflow on a particular orchestrator.
|
CreateWorkflowResponse |
removeNode(String endpoint)
Return a workflow id for this remove operation request.
|
CompletableFuture<FailureDetectorMetrics> |
sendFailureDetectorMetricsRequest() |
void |
sendMessage(CorfuMsg msg) |
CompletableFuture<NodeState> |
sendNodeStateRequest() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getHandledTypes, getMsgHandler, getRouter, handleMessage, setRouter
public ManagementClient(IClientRouter router, long epoch)
public CompletableFuture<Boolean> bootstrapManagement(Layout l)
l
- The layout to bootstrap with.public CompletableFuture<Boolean> handleFailure(long detectorEpoch, Set<String> failedNodes)
failedNodes
- The failed nodes set to be handled.public CompletableFuture<Boolean> handleHealing(long detectorEpoch, Set<String> healedNodes)
healedNodes
- The healed nodes set to be handled.public CompletableFuture<NodeState> sendNodeStateRequest()
public CompletableFuture<FailureDetectorMetrics> sendFailureDetectorMetricsRequest()
public CompletableFuture<Layout> getLayout()
public CreateWorkflowResponse addNodeRequest(@Nonnull String endpoint) throws TimeoutException
endpoint
- the endpoint to add to the clusterTimeoutException
- when the rpc times outpublic CreateWorkflowResponse healNodeRequest(@Nonnull String endpoint, boolean isLayoutServer, boolean isSequencerServer, boolean isLogUnitServer, int stripeIndex) throws TimeoutException
endpoint
- Endpoint of the node to be healed.isLayoutServer
- True if the node to be healed is a layout server.isSequencerServer
- True if the node to be healed is a sequencer server.isLogUnitServer
- True if the node to be healed is a logunit server.stripeIndex
- Stripe index of the node if it is a logunit server.TimeoutException
- when the rpc times outpublic CreateWorkflowResponse mergeSegments(@Nonnull String endpoint) throws TimeoutException
endpoint
- Endpoint to restore redundancy.TimeoutException
- when the rpc times outpublic QueryResponse queryRequest(@Nonnull UUID workflowId) throws TimeoutException
workflowId
- the workflow to queryTimeoutException
- when the rpc times outpublic CreateWorkflowResponse removeNode(@Nonnull String endpoint) throws TimeoutException
endpoint
- the endpoint to removeTimeoutException
- when the rpc times outpublic CreateWorkflowResponse forceRemoveNode(@Nonnull String endpoint) throws TimeoutException
endpoint
- the endpoint to force removeTimeoutException
- when the rpc times outpublic void sendMessage(CorfuMsg msg)
Copyright © 2019 CorfuDB. All rights reserved.