Package org.elasticsearch.action.bulk
Class BulkShardRequest
- All Implemented Interfaces:
org.apache.lucene.util.Accountable
,IndicesRequest
,WriteRequest<BulkShardRequest>
,Writeable
,RefCounted
,TaskAwareRequest
,RawIndexingDataTransportRequest
public class BulkShardRequest
extends ReplicatedWriteRequest<BulkShardRequest>
implements org.apache.lucene.util.Accountable, RawIndexingDataTransportRequest
-
Nested Class Summary
Nested classes/interfaces inherited from class org.elasticsearch.transport.TransportRequest
TransportRequest.Empty
Nested classes/interfaces inherited from interface org.elasticsearch.action.IndicesRequest
IndicesRequest.Replaceable
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
Nested classes/interfaces inherited from interface org.elasticsearch.action.support.WriteRequest
WriteRequest.RefreshPolicy
-
Field Summary
Fields inherited from class org.elasticsearch.action.support.replication.ReplicationRequest
DEFAULT_TIMEOUT, index, shardId, timeout, waitForActiveShards
Fields inherited from interface org.apache.lucene.util.Accountable
NULL_ACCOUNTABLE
-
Constructor Summary
ConstructorDescriptionBulkShardRequest
(ShardId shardId, WriteRequest.RefreshPolicy refreshPolicy, BulkItemRequest[] items) -
Method Summary
Modifier and TypeMethodDescriptionReturns optional description of the request to be displayed by the task managerString[]
indices()
Returns the array of indices that the action relates toitems()
void
onRetry()
This method is called before this replication request is retried the first time.long
protected BulkShardRequest
routedBasedOnClusterVersion
(long routedBasedOnClusterVersion) Sets the minimum version of the cluster state that is required on the next node before we redirect to another primary.toString()
void
writeTo
(StreamOutput out) Write this into the StreamOutput.Methods inherited from class org.elasticsearch.action.support.replication.ReplicatedWriteRequest
getRefreshPolicy, setRefreshPolicy, writeThin
Methods inherited from class org.elasticsearch.action.support.replication.ReplicationRequest
createTask, index, index, indicesOptions, shardId, timeout, timeout, timeout, validate, waitForActiveShards, waitForActiveShards, waitForActiveShards
Methods inherited from class org.elasticsearch.action.ActionRequest
getShouldStoreResult
Methods inherited from class org.elasticsearch.transport.TransportRequest
getParentTask, setParentTask
Methods inherited from class org.elasticsearch.transport.TransportMessage
decRef, hasReferences, incRef, remoteAddress, remoteAddress, tryIncRef
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.apache.lucene.util.Accountable
getChildResources
Methods inherited from interface org.elasticsearch.action.IndicesRequest
includeDataStreams
Methods inherited from interface org.elasticsearch.transport.RawIndexingDataTransportRequest
isRawIndexingData
Methods inherited from interface org.elasticsearch.tasks.TaskAwareRequest
setParentTask
Methods inherited from interface org.elasticsearch.action.support.WriteRequest
setRefreshPolicy, validate
-
Field Details
-
COMPACT_SHARD_ID_VERSION
-
-
Constructor Details
-
BulkShardRequest
- Throws:
IOException
-
BulkShardRequest
public BulkShardRequest(ShardId shardId, WriteRequest.RefreshPolicy refreshPolicy, BulkItemRequest[] items)
-
-
Method Details
-
items
-
indices
Description copied from interface:IndicesRequest
Returns the array of indices that the action relates to- Specified by:
indices
in interfaceIndicesRequest
- Overrides:
indices
in classReplicationRequest<BulkShardRequest>
-
writeTo
Description copied from interface:Writeable
Write this into the StreamOutput.- Specified by:
writeTo
in interfaceWriteable
- Overrides:
writeTo
in classReplicatedWriteRequest<BulkShardRequest>
- Throws:
IOException
-
toString
- Specified by:
toString
in classReplicationRequest<BulkShardRequest>
-
getDescription
Description copied from interface:TaskAwareRequest
Returns optional description of the request to be displayed by the task manager- Specified by:
getDescription
in interfaceTaskAwareRequest
- Overrides:
getDescription
in classReplicationRequest<BulkShardRequest>
-
routedBasedOnClusterVersion
Description copied from class:ReplicationRequest
Sets the minimum version of the cluster state that is required on the next node before we redirect to another primary. Used to prevent redirect loops, see alsoAbstractRunnable.doRun()
- Overrides:
routedBasedOnClusterVersion
in classReplicationRequest<BulkShardRequest>
-
onRetry
public void onRetry()Description copied from class:ReplicationRequest
This method is called before this replication request is retried the first time.- Overrides:
onRetry
in classReplicationRequest<BulkShardRequest>
-
ramBytesUsed
public long ramBytesUsed()- Specified by:
ramBytesUsed
in interfaceorg.apache.lucene.util.Accountable
-