org.elasticsearch.action.bulk
Class TransportShardBulkAction

java.lang.Object
  extended by org.elasticsearch.common.component.AbstractComponent
      extended by org.elasticsearch.action.support.TransportAction<Request,Response>
          extended by org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>
              extended by org.elasticsearch.action.bulk.TransportShardBulkAction

public class TransportShardBulkAction
extends TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

Performs the index operation.


Nested Class Summary
 
Nested classes/interfaces inherited from class org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction
TransportShardReplicationOperationAction.AsyncShardOperationAction, TransportShardReplicationOperationAction.PrimaryOperationRequest, TransportShardReplicationOperationAction.PrimaryResponse<Response,ReplicaRequest>, TransportShardReplicationOperationAction.ReplicaOperationRequest
 
Field Summary
 
Fields inherited from class org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction
clusterService, defaultReplicationType, defaultWriteConsistencyLevel, indicesService, shardStateAction, transportOptions, transportService
 
Fields inherited from class org.elasticsearch.action.support.TransportAction
threadPool
 
Fields inherited from class org.elasticsearch.common.component.AbstractComponent
componentSettings, logger, settings
 
Constructor Summary
TransportShardBulkAction(Settings settings, TransportService transportService, ClusterService clusterService, IndicesService indicesService, ThreadPool threadPool, ShardStateAction shardStateAction, MappingUpdatedAction mappingUpdatedAction)
           
 
Method Summary
protected  ClusterBlockException checkGlobalBlock(ClusterState state, BulkShardRequest request)
           
protected  ClusterBlockException checkRequestBlock(ClusterState state, BulkShardRequest request)
           
protected  boolean checkWriteConsistency()
           
protected  String executor()
           
protected  BulkShardRequest newReplicaRequestInstance()
           
protected  BulkShardRequest newRequestInstance()
           
protected  BulkShardResponse newResponseInstance()
           
protected  void postPrimaryOperation(BulkShardRequest request, TransportShardReplicationOperationAction.PrimaryResponse<BulkShardResponse,BulkShardRequest> response)
          Called once replica operations have been dispatched on the
protected  TransportShardReplicationOperationAction.PrimaryResponse<BulkShardResponse,BulkShardRequest> shardOperationOnPrimary(ClusterState clusterState, TransportShardReplicationOperationAction.PrimaryOperationRequest shardRequest)
           
protected  void shardOperationOnReplica(TransportShardReplicationOperationAction.ReplicaOperationRequest shardRequest)
           
protected  ShardIterator shards(ClusterState clusterState, BulkShardRequest request)
           
protected  String transportAction()
           
protected  TransportRequestOptions transportOptions()
           
 
Methods inherited from class org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction
doExecute, ignoreReplicas, resolveRequest, retryPrimaryException
 
Methods inherited from class org.elasticsearch.action.support.TransportAction
execute, execute
 
Methods inherited from class org.elasticsearch.common.component.AbstractComponent
nodeName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TransportShardBulkAction

@Inject
public TransportShardBulkAction(Settings settings,
                                       TransportService transportService,
                                       ClusterService clusterService,
                                       IndicesService indicesService,
                                       ThreadPool threadPool,
                                       ShardStateAction shardStateAction,
                                       MappingUpdatedAction mappingUpdatedAction)
Method Detail

executor

protected String executor()
Specified by:
executor in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

checkWriteConsistency

protected boolean checkWriteConsistency()
Specified by:
checkWriteConsistency in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

transportOptions

protected TransportRequestOptions transportOptions()
Overrides:
transportOptions in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

newRequestInstance

protected BulkShardRequest newRequestInstance()
Specified by:
newRequestInstance in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

newReplicaRequestInstance

protected BulkShardRequest newReplicaRequestInstance()
Specified by:
newReplicaRequestInstance in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

newResponseInstance

protected BulkShardResponse newResponseInstance()
Specified by:
newResponseInstance in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

transportAction

protected String transportAction()
Specified by:
transportAction in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

checkGlobalBlock

protected ClusterBlockException checkGlobalBlock(ClusterState state,
                                                 BulkShardRequest request)
Specified by:
checkGlobalBlock in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

checkRequestBlock

protected ClusterBlockException checkRequestBlock(ClusterState state,
                                                  BulkShardRequest request)
Specified by:
checkRequestBlock in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

shards

protected ShardIterator shards(ClusterState clusterState,
                               BulkShardRequest request)
Specified by:
shards in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

shardOperationOnPrimary

protected TransportShardReplicationOperationAction.PrimaryResponse<BulkShardResponse,BulkShardRequest> shardOperationOnPrimary(ClusterState clusterState,
                                                                                                                               TransportShardReplicationOperationAction.PrimaryOperationRequest shardRequest)
Specified by:
shardOperationOnPrimary in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

postPrimaryOperation

protected void postPrimaryOperation(BulkShardRequest request,
                                    TransportShardReplicationOperationAction.PrimaryResponse<BulkShardResponse,BulkShardRequest> response)
Description copied from class: TransportShardReplicationOperationAction
Called once replica operations have been dispatched on the

Overrides:
postPrimaryOperation in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>

shardOperationOnReplica

protected void shardOperationOnReplica(TransportShardReplicationOperationAction.ReplicaOperationRequest shardRequest)
Specified by:
shardOperationOnReplica in class TransportShardReplicationOperationAction<BulkShardRequest,BulkShardRequest,BulkShardResponse>


Copyright © 2009-2012. All Rights Reserved.