Interface SparkExecutionOperator
-
- All Superinterfaces:
ActualOperator,ElementaryOperator,ExecutionOperator,Operator
- All Known Implementing Classes:
SparkBernoulliSampleOperator,SparkBroadcastOperator,SparkCacheOperator,SparkCartesianOperator,SparkCoGroupOperator,SparkCollectionSource,SparkCollectOperator,SparkCountOperator,SparkDecisionTreeClassificationOperator,SparkDistinctOperator,SparkDoWhileOperator,SparkFilterOperator,SparkFlatMapOperator,SparkGlobalMaterializedGroupOperator,SparkGlobalReduceOperator,SparkIEJoinOperator,SparkIESelfJoinOperator,SparkIntersectOperator,SparkJoinOperator,SparkKafkaTopicSink,SparkKafkaTopicSource,SparkKMeansOperator,SparkLinearRegressionOperator,SparkLocalCallbackSink,SparkLoopOperator,SparkMapOperator,SparkMapPartitionsOperator,SparkMaterializedGroupByOperator,SparkModelTransformOperator,SparkObjectFileSink,SparkObjectFileSource,SparkPredictOperator,SparkRandomPartitionSampleOperator,SparkReduceByOperator,SparkRepeatOperator,SparkShufflePartitionSampleOperator,SparkSortOperator,SparkTextFileSink,SparkTextFileSource,SparkTsvFileSink,SparkTsvFileSource,SparkUnionAllOperator,SparkZipWithIdOperator,SqlToRddOperator
public interface SparkExecutionOperator extends ExecutionOperator
Execution operator for theSparkPlatform.
-
-
Field Summary
-
Fields inherited from interface org.apache.wayang.core.plan.wayangplan.Operator
FIRST_EPOCH
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description booleancontainsAction()Tell whether this instances is a Spark action.Tuple<java.util.Collection<ExecutionLineageNode>,java.util.Collection<ChannelInstance>>evaluate(ChannelInstance[] inputs, ChannelInstance[] outputs, SparkExecutor sparkExecutor, OptimizationContext.OperatorContext operatorContext)Evaluates this operator.default SparkPlatformgetPlatform()default voidname(org.apache.spark.api.java.JavaPairRDD<?,?> rdd)Utility method to name an RDD according to this instance's name.default voidname(org.apache.spark.api.java.JavaRDD<?> rdd)Utility method to name an RDD according to this instance's name.-
Methods inherited from interface org.apache.wayang.core.plan.wayangplan.ActualOperator
accept
-
Methods inherited from interface org.apache.wayang.core.plan.wayangplan.ElementaryOperator
createCardinalityEstimator, getCardinalityEstimator, isAuxiliary, setAuxiliary, setCardinalityEstimator
-
Methods inherited from interface org.apache.wayang.core.plan.wayangplan.ExecutionOperator
copy, createLoadProfileEstimator, createOutputChannelInstances, getLimitBaseKey, getLoadProfileEstimatorConfigurationKey, getLoadProfileEstimatorConfigurationKeys, getOriginal, getOutputChannelDescriptor, getSupportedInputChannels, getSupportedOutputChannels, isFiltered
-
Methods inherited from interface org.apache.wayang.core.plan.wayangplan.Operator
addBroadcastInput, addTargetPlatform, broadcastTo, broadcastTo, collectMappedInputSlots, collectMappedOutputSlots, connectTo, connectTo, getAllInputs, getAllOutputs, getCardinalityPusher, getContainer, getEffectiveOccupant, getEffectiveOccupant, getEpoch, getEstimationContextProperties, getForwards, getInnermostLoop, getInput, getInput, getLoopStack, getName, getNumBroadcastInputs, getNumInputs, getNumOutputs, getNumRegularInputs, getOuterInputSlot, getOutermostInputSlot, getOutermostOutputSlots, getOutput, getOutput, getParent, getTargetPlatforms, isAlternative, isElementary, isExecutionOperator, isFeedbackInput, isFeedforwardOutput, isLoopHead, isLoopSubplan, isOwnerOf, isReading, isSink, isSource, isSubplan, isSupportingBroadcastInputs, isUnconnected, propagateInputCardinality, propagateOutputCardinality, propagateOutputCardinality, setContainer, setEpoch, setInput, setName, setOutput
-
-
-
-
Method Detail
-
getPlatform
default SparkPlatform getPlatform()
- Specified by:
getPlatformin interfaceExecutionOperator- Returns:
- the platform that can run this operator
-
evaluate
Tuple<java.util.Collection<ExecutionLineageNode>,java.util.Collection<ChannelInstance>> evaluate(ChannelInstance[] inputs, ChannelInstance[] outputs, SparkExecutor sparkExecutor, OptimizationContext.OperatorContext operatorContext)
Evaluates this operator. Takes a set ofChannelInstances according to the operator inputs and manipulates a set ofChannelInstances according to the operator outputs -- unless the operator is a sink, then it triggers execution.In addition, this method should give feedback of what this instance was doing by wiring the
LazyExecutionLineageNodes of input and ouputChannelInstances and providing aCollectionof executedExecutionLineageNodes.- Parameters:
inputs-ChannelInstances that satisfy the inputs of this operatoroutputs-ChannelInstances that accept the outputs of this operatorsparkExecutor-SparkExecutorthat executes this instanceoperatorContext- optimization information for this instance- Returns:
Collections of what has been executed and produced
-
containsAction
boolean containsAction()
Tell whether this instances is a Spark action. This is important to keep track on when Spark is actually initialized.- Returns:
- whether this instance issues Spark actions
-
name
default void name(org.apache.spark.api.java.JavaRDD<?> rdd)
Utility method to name an RDD according to this instance's name.- Parameters:
rdd- that should be renamed- See Also:
Operator.getName()
-
name
default void name(org.apache.spark.api.java.JavaPairRDD<?,?> rdd)
Utility method to name an RDD according to this instance's name.- Parameters:
rdd- that should be renamed- See Also:
Operator.getName()
-
-