@Internal public abstract class AbstractExternalTwoInputPythonFunctionOperator<IN1,IN2,OUT> extends AbstractExternalDataStreamPythonFunctionOperator<OUT> implements org.apache.flink.streaming.api.operators.TwoInputStreamOperator<IN1,IN2,OUT>, org.apache.flink.streaming.api.operators.BoundedMultiInput
AbstractExternalTwoInputPythonFunctionOperator is responsible for launching beam runner
which will start a python harness to execute two-input user defined python function.| 限定符和类型 | 字段和说明 |
|---|---|
protected org.apache.flink.core.memory.ByteArrayOutputStreamWithPos |
baos |
protected org.apache.flink.core.memory.DataOutputViewStreamWrapper |
baosWrapper |
pythonFunctionRunnerbundleFinishedCallback, config, elementCount, lastFinishBundleTime, maxBundleSize, systemEnvEnabled| 构造器和说明 |
|---|
AbstractExternalTwoInputPythonFunctionOperator(org.apache.flink.configuration.Configuration config,
DataStreamPythonFunctionInfo pythonFunctionInfo,
org.apache.flink.api.common.typeinfo.TypeInformation<IN1> inputTypeInfo1,
org.apache.flink.api.common.typeinfo.TypeInformation<IN2> inputTypeInfo2,
org.apache.flink.api.common.typeinfo.TypeInformation<OUT> outputTypeInfo) |
| 限定符和类型 | 方法和说明 |
|---|---|
FlinkFnApi.CoderInfoDescriptor |
createInputCoderInfoDescriptor() |
FlinkFnApi.CoderInfoDescriptor |
createOutputCoderInfoDescriptor() |
void |
emitResult(org.apache.flink.api.java.tuple.Tuple3<String,byte[],Integer> resultTuple)
Sends the execution result to the downstream operator.
|
void |
endInput(int inputId) |
protected org.apache.flink.api.common.typeinfo.TypeInformation<IN1> |
getLeftInputType() |
protected org.apache.flink.api.common.typeinfo.TypeInformation<IN2> |
getRightInputType() |
void |
open() |
void |
processElement(boolean isLeft,
long timestamp,
long watermark,
Object element) |
addSideOutputTags, createSideOutputCoderDescriptors, getInternalParameters, getOutputTagById, getProducedType, getPythonEnv, getPythonFunctionInfo, getSideOutputTags, getSideOutputTypeSerializerById, setNumPartitionsclose, createPythonEnvironmentManager, createPythonFunctionRunner, emitResults, invokeFinishBundlecheckInvokeFinishBundleByCount, finish, getConfiguration, getFlinkMetricContainer, isBundleFinished, prepareSnapshotPreBarrier, processWatermark, setCurrentKeygetChainingStrategy, getContainingTask, getCurrentKey, getExecutionConfig, getInternalTimerService, getKeyedStateBackend, getKeyedStateStore, getMetricGroup, getOperatorConfig, getOperatorID, getOperatorName, getOperatorStateBackend, getOrCreateKeyedState, getPartitionedState, getPartitionedState, getProcessingTimeService, getRuntimeContext, getStateKeySelector1, getStateKeySelector2, getTimeServiceManager, getUserCodeClassloader, hasKeyContext1, hasKeyContext2, initializeState, initializeState, isUsingCustomRawKeyedState, notifyCheckpointAborted, notifyCheckpointComplete, processLatencyMarker, processLatencyMarker1, processLatencyMarker2, processRecordAttributes, processRecordAttributes1, processRecordAttributes2, processWatermark1, processWatermark2, processWatermarkStatus, processWatermarkStatus1, processWatermarkStatus2, reportOrForwardLatencyMarker, setChainingStrategy, setKeyContextElement1, setKeyContextElement2, setMailboxExecutor, setProcessingTimeService, setup, snapshotState, snapshotState, useSplittableTimersclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitprocessElement1, processElement2, processLatencyMarker1, processLatencyMarker2, processRecordAttributes1, processRecordAttributes2, processWatermark1, processWatermark2, processWatermarkStatus1, processWatermarkStatus2close, finish, getMetricGroup, getOperatorAttributes, getOperatorID, initializeState, prepareSnapshotPreBarrier, setKeyContextElement1, setKeyContextElement2, snapshotStatenotifyCheckpointAborted, notifyCheckpointCompletecopyprotected transient org.apache.flink.core.memory.ByteArrayOutputStreamWithPos baos
protected transient org.apache.flink.core.memory.DataOutputViewStreamWrapper baosWrapper
public AbstractExternalTwoInputPythonFunctionOperator(org.apache.flink.configuration.Configuration config,
DataStreamPythonFunctionInfo pythonFunctionInfo,
org.apache.flink.api.common.typeinfo.TypeInformation<IN1> inputTypeInfo1,
org.apache.flink.api.common.typeinfo.TypeInformation<IN2> inputTypeInfo2,
org.apache.flink.api.common.typeinfo.TypeInformation<OUT> outputTypeInfo)
public void open()
throws Exception
open 在接口中 org.apache.flink.streaming.api.operators.StreamOperator<OUT>open 在类中 AbstractExternalDataStreamPythonFunctionOperator<OUT>Exceptionpublic void endInput(int inputId)
throws Exception
endInput 在接口中 org.apache.flink.streaming.api.operators.BoundedMultiInputExceptionpublic void emitResult(org.apache.flink.api.java.tuple.Tuple3<String,byte[],Integer> resultTuple) throws Exception
emitResult 在类中 AbstractExternalPythonFunctionOperator<OUT>Exceptionpublic void processElement(boolean isLeft,
long timestamp,
long watermark,
Object element)
throws Exception
Exceptionpublic FlinkFnApi.CoderInfoDescriptor createInputCoderInfoDescriptor()
public FlinkFnApi.CoderInfoDescriptor createOutputCoderInfoDescriptor()
protected org.apache.flink.api.common.typeinfo.TypeInformation<IN1> getLeftInputType()
protected org.apache.flink.api.common.typeinfo.TypeInformation<IN2> getRightInputType()
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.