public abstract class BaseExecutionContext extends Object implements ExecutionContext
ExecutionContext.
A concrete subclass should implement createStepContext(java.lang.String, java.lang.String) to create the appropriate
ExecutionContext.StepContext implementation. Any StepContext created will
be cached for the lifetime of this ExecutionContext.
| Modifier and Type | Class and Description |
|---|---|
static class |
BaseExecutionContext.StepContext
Base class for implementations of
ExecutionContext.StepContext. |
| Constructor and Description |
|---|
BaseExecutionContext() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract ExecutionContext.StepContext |
createStepContext(String stepName,
String transformName)
Implementations should override this to create the specific type
of
BaseExecutionContext.StepContext they need. |
Collection<ExecutionContext.StepContext> |
getAllStepContexts()
Returns a collection view of all of the
BaseExecutionContext.StepContexts. |
ExecutionContext.StepContext |
getStepContext(String stepName,
String transformName)
Returns the
BaseExecutionContext.StepContext associated with the given step. |
void |
noteOutput(WindowedValue<?> output)
Hook for subclasses to implement that will be called whenever
DoFn.Context.output(OutputT)
is called. |
void |
noteSideOutput(TupleTag<?> tag,
WindowedValue<?> output)
Hook for subclasses to implement that will be called whenever
DoFn.Context.sideOutput(com.google.cloud.dataflow.sdk.values.TupleTag<T>, T)
is called. |
protected abstract ExecutionContext.StepContext createStepContext(String stepName, String transformName)
BaseExecutionContext.StepContext they need.public ExecutionContext.StepContext getStepContext(String stepName, String transformName)
BaseExecutionContext.StepContext associated with the given step.getStepContext in interface ExecutionContextpublic Collection<ExecutionContext.StepContext> getAllStepContexts()
BaseExecutionContext.StepContexts.getAllStepContexts in interface ExecutionContextpublic void noteOutput(WindowedValue<?> output)
DoFn.Context.output(OutputT)
is called.noteOutput in interface ExecutionContextpublic void noteSideOutput(TupleTag<?> tag, WindowedValue<?> output)
DoFn.Context.sideOutput(com.google.cloud.dataflow.sdk.values.TupleTag<T>, T)
is called.noteSideOutput in interface ExecutionContext