Streamable, Writeable, TaskAwareRequestTransportReplicationAction.ConcreteReplicaRequestpublic static class TransportReplicationAction.ConcreteShardRequest<R extends TransportRequest> extends TransportRequest
TransportRequest.EmptyWriteable.Reader<V>, Writeable.Writer<V>| Constructor | Description |
|---|---|
ConcreteShardRequest(java.util.function.Supplier<R> requestSupplier) |
|
ConcreteShardRequest(R request,
java.lang.String targetAllocationID,
long primaryTerm) |
| Modifier and Type | Method | Description |
|---|---|---|
Task |
createTask(long id,
java.lang.String type,
java.lang.String action,
TaskId parentTaskId,
java.util.Map<java.lang.String,java.lang.String> headers) |
Returns the task object that should be used to keep track of the processing of the request.
|
java.lang.String |
getDescription() |
Returns optional description of the request to be displayed by the task manager
|
TaskId |
getParentTask() |
Get a reference to the task that created this request.
|
long |
getPrimaryTerm() |
|
R |
getRequest() |
|
java.lang.String |
getTargetAllocationID() |
|
void |
readFrom(StreamInput in) |
Set this object's fields from a StreamInput.
|
void |
setParentTask(java.lang.String parentTaskNode,
long parentTaskId) |
Set a reference to task that caused this task to be run.
|
void |
setParentTask(TaskId taskId) |
Set a reference to task that created this request.
|
java.lang.String |
toString() |
|
void |
writeTo(StreamOutput out) |
Write this object's fields to a StreamOutput.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitnewWriteableReaderremoteAddress, remoteAddresspublic ConcreteShardRequest(java.util.function.Supplier<R> requestSupplier)
public ConcreteShardRequest(R request, java.lang.String targetAllocationID, long primaryTerm)
public void setParentTask(java.lang.String parentTaskNode,
long parentTaskId)
TaskAwareRequestpublic void setParentTask(TaskId taskId)
TransportRequestsetParentTask in interface TaskAwareRequestsetParentTask in class TransportRequestpublic TaskId getParentTask()
TransportRequestTaskId.EMPTY_TASK_ID, meaning "there is no parent".getParentTask in interface TaskAwareRequestgetParentTask in class TransportRequestpublic Task createTask(long id, java.lang.String type, java.lang.String action, TaskId parentTaskId, java.util.Map<java.lang.String,java.lang.String> headers)
TaskAwareRequestpublic java.lang.String getDescription()
TaskAwareRequestpublic void readFrom(StreamInput in) throws java.io.IOException
StreamablereadFrom in interface StreamablereadFrom in class TransportRequestjava.io.IOExceptionpublic void writeTo(StreamOutput out) throws java.io.IOException
StreamablewriteTo in interface StreamablewriteTo in interface WriteablewriteTo in class TransportRequestjava.io.IOExceptionpublic R getRequest()
public java.lang.String getTargetAllocationID()
public long getPrimaryTerm()
public java.lang.String toString()
toString in class java.lang.Object