 | JobBuilderProcessTInput, TOutput Method (IOperationInput, ActionRecordReaderTInput, RecordWriterTOutput, TaskContext, RecordReuseMode) |
Processes the specified input using the specified delegate.
Namespace:
Ookii.Jumbo.Jet.Jobs.Builder
Assembly:
Ookii.Jumbo.Jet (in Ookii.Jumbo.Jet.dll) Version: 2.0.0
Syntaxpublic StageOperation Process<TInput, TOutput>(
IOperationInput input,
Action<RecordReader<TInput>, RecordWriter<TOutput>, TaskContext> processor,
RecordReuseMode recordReuse = RecordReuseMode.Default
)
Public Function Process(Of TInput, TOutput) (
input As IOperationInput,
processor As Action(Of RecordReader(Of TInput), RecordWriter(Of TOutput), TaskContext),
Optional recordReuse As RecordReuseMode = RecordReuseMode.Default
) As StageOperation
public:
generic<typename TInput, typename TOutput>
StageOperation^ Process(
IOperationInput^ input,
Action<RecordReader<TInput>^, RecordWriter<TOutput>^, TaskContext^>^ processor,
RecordReuseMode recordReuse = RecordReuseMode::Default
)
member Process :
input : IOperationInput *
processor : Action<RecordReader<'TInput>, RecordWriter<'TOutput>, TaskContext> *
?recordReuse : RecordReuseMode
(* Defaults:
let _recordReuse = defaultArg recordReuse RecordReuseMode.Default
*)
-> StageOperation
Parameters
- input
- Type: Ookii.Jumbo.Jet.Jobs.BuilderIOperationInput
The input. - processor
- Type: SystemActionRecordReaderTInput, RecordWriterTOutput, TaskContext
The processing function to use to create the task. - recordReuse (Optional)
- Type: Ookii.Jumbo.Jet.Jobs.BuilderRecordReuseMode
The record reuse mode.
Type Parameters
- TInput
- The type of the input.
- TOutput
- The type of the output.
Return Value
Type:
StageOperationA
StageOperation instance that can be used to further customize the operation.
Remarks
This method generates a class implementing ITaskTInput, TOutput which calls the target method of the processor delegate
from the Run(RecordReaderTInput, RecordWriterTOutput) method.
Note |
---|
The task method will be called from a completely different process than the one that is using JobBuilder, so it should not really
on any external state.
|
If recordReuse is Default and the target method has the AllowRecordReuseAttribute attribute applied to it,
that attribute will be copied to the task class. If the target method has the ProcessAllInputPartitionsAttribute attribute applied to it,
that attribute will be copied to the task class.
If the target method is a public method, it will be called directly by the generated task class. Otherwise, the supplied
delegate will be serialized to the task settings and used to call the method. If the target method is an instance method, the instance it belongs to will be
serialized as well (this class must have the SerializableAttribute attribute).
See Also