Package org.apache.storm.executor
Class Executor
java.lang.Object
org.apache.storm.executor.Executor
- All Implemented Interfaces:
Callable,org.apache.storm.shade.org.jctools.queues.MessagePassingQueue.Consumer<Object>,JCQueue.Consumer
- Direct Known Subclasses:
BoltExecutor,SpoutExecutor
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final booleanprotected final Stringprotected ExecutorTransferprotected final List<LoadAwareCustomStreamGrouping>protected final Booleanprotected Stringprotected intprotected final Booleanprotected final AtomicBooleanprotected final org.apache.storm.shade.org.jctools.queues.MpscChunkedArrayQueue<AddressedTuple>protected final Randomprotected final JCQueueprotected final IReportErrorprotected final ReportErrorAndDieprotected final BooleanSupplierprotected final HashMapprotected final AtomicBooleanprotected final IStormClusterStateprotected final AtomicReference<Map<String,DebugOptions>> protected final Stringprotected final Map<String,Map<String, LoadAwareCustomStreamGrouping>> protected final Runnableprotected final Stringprotected final WorkerStateprotected final CountDownLatchprotected final WorkerTopologyContext -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidprotected voidacceptTupleAction(int taskId, TupleImpl tuple) execute()separated from mkExecutor in order to replace executor transfer in executor data for testing.voidflush()abstract CommonStatsgetStats()getType()voidvoidmetricsTick(Task task, TupleImpl tuple) static ExecutormkExecutor(WorkerState workerState, List<Long> executorId, Map<String, String> credentials) booleanvoidreflectNewLoadMapping(LoadMapping loadMapping) booleanvoidsetLocalExecutorTransfer(ExecutorTransfer executorTransfer) voidprotected voidprotected voidsetupTicks(boolean isSpout) abstract voidtupleActionFn(int taskId, TupleImpl tuple) protected void
-
Field Details
-
workerData
-
workerTopologyContext
-
executorId
-
taskIds
-
componentId
-
openOrPrepareWasCalled
-
topoConf
-
conf
-
stormId
-
workerReady
-
stormActive
-
stormComponentDebug
-
suicideFn
-
stormClusterState
-
taskToComponent
-
intervalToTaskToMetricToRegistry
-
streamToComponentToGrouper
-
groupers
-
reportErrorDie
-
sampler
-
type
-
reportError
-
rand
-
receiveQueue
-
credentials
-
isDebug
-
hasEventLoggers
-
ackingEnabled
protected final boolean ackingEnabled -
pendingEmits
protected final org.apache.storm.shade.org.jctools.queues.MpscChunkedArrayQueue<AddressedTuple> pendingEmits -
executorTransfer
-
idToTask
-
idToTaskBase
protected int idToTaskBase -
hostname
-
-
Constructor Details
-
Executor
-
-
Method Details
-
mkExecutor
-
getPendingEmits
-
execute
separated from mkExecutor in order to replace executor transfer in executor data for testing.- Throws:
Exception
-
tupleActionFn
- Throws:
Exception
-
accept
- Specified by:
acceptin interfaceJCQueue.Consumer- Specified by:
acceptin interfaceorg.apache.storm.shade.org.jctools.queues.MessagePassingQueue.Consumer<Object>
-
acceptTupleAction
-
setNeedToRefreshCreds
public void setNeedToRefreshCreds() -
updateExecCredsIfRequired
protected void updateExecCredsIfRequired() -
flush
public void flush()- Specified by:
flushin interfaceJCQueue.Consumer
-
metricsTick
-
setupMetrics
protected void setupMetrics() -
setupTicks
protected void setupTicks(boolean isSpout) -
reflectNewLoadMapping
-
publishFlushTuple
public boolean publishFlushTuple() -
getExecutorId
-
getTaskIds
-
getComponentId
-
getOpenOrPrepareWasCalled
-
getTopoConf
-
getStormId
-
getStats
-
getType
-
getIsDebug
-
getExecutorTransfer
-
getReportError
-
getWorkerTopologyContext
-
samplerCheck
public boolean samplerCheck() -
getStormComponentDebug
-
getReceiveQueue
-
getStormClusterState
-
getWorkerData
-
getStreamToComponentToGrouper
-
getIntervalToTaskToMetricToRegistry
-
setLocalExecutorTransfer
-
incrementReportedErrorCount
public void incrementReportedErrorCount()
-