Interface OperatorCoordinator.Context
- Enclosing interface:
- OperatorCoordinator
public static interface OperatorCoordinator.Context
The context gives the OperatorCoordinator access to contextual information and provides a
gateway to interact with other components, such as sending operator events.
-
Method Summary
Modifier and TypeMethodDescriptionintGets the current parallelism with which this operator is executed.voidFails the job and trigger a global failover operation.Gets the checkpoint coordinator of this job.Gets theCoordinatorStoreinstance for sharing information betweenOperatorCoordinators.org.apache.flink.api.common.JobIDgetJobID()Gets theJobIDof the job to which the coordinator belongs.Gets the ID of the operator to which the coordinator belongs.Gets the classloader that contains the additional dependencies, which are not part of the JVM's classpath.booleanGets that whether the coordinator supports an execution vertex to have multiple concurrent running execution attempts.org.apache.flink.metrics.groups.OperatorCoordinatorMetricGroupGets the metric group of the operator coordinator.
-
Method Details
-
getJobID
org.apache.flink.api.common.JobID getJobID()Gets theJobIDof the job to which the coordinator belongs. -
getOperatorId
OperatorID getOperatorId()Gets the ID of the operator to which the coordinator belongs. -
metricGroup
org.apache.flink.metrics.groups.OperatorCoordinatorMetricGroup metricGroup()Gets the metric group of the operator coordinator. -
failJob
Fails the job and trigger a global failover operation.This operation restores the entire job to the latest complete checkpoint. This is useful to recover from inconsistent situations (the view from the coordinator and its subtasks as diverged), but is expensive and should be used with care.
-
currentParallelism
int currentParallelism()Gets the current parallelism with which this operator is executed. -
getUserCodeClassloader
ClassLoader getUserCodeClassloader()Gets the classloader that contains the additional dependencies, which are not part of the JVM's classpath. -
getCoordinatorStore
CoordinatorStore getCoordinatorStore()Gets theCoordinatorStoreinstance for sharing information betweenOperatorCoordinators. -
isConcurrentExecutionAttemptsSupported
boolean isConcurrentExecutionAttemptsSupported()Gets that whether the coordinator supports an execution vertex to have multiple concurrent running execution attempts. -
getCheckpointCoordinator
Gets the checkpoint coordinator of this job. Return null if checkpoint is disabled.
-