StatefulOperatorPartitioning¶
getCompatibleDistribution¶
getCompatibleDistribution(
expressions: Seq[Expression],
numPartitions: Int,
conf: SQLConf): Distribution
getCompatibleDistribution(
expressions: Seq[Expression],
stateInfo: StatefulOperatorStateInfo,
conf: SQLConf): Distribution
getCompatibleDistribution
returns the following Distribution
s (Spark SQL) based on spark.sql.streaming.statefulOperator.useStrictDistribution configuration property:
StatefulOpClusteredDistribution
when enabledClusteredDistribution
(Spark SQL) otherwise
getCompatibleDistribution
is used when:
BaseAggregateExec
(Spark SQL) is requested for the required child output distribution (of a streaming query)UpdatingSessionsExec
is requested for the required child output distribution (of a streaming query)FlatMapGroupsWithStateExec
is requested for the required child output distributionStateStoreRestoreExec
is requested for the required child output distributionStateStoreSaveExec
is requested for the required child output distributionSessionWindowStateStoreRestoreExec
is requested for the required child output distributionSessionWindowStateStoreSaveExec
is requested for the required child output distributionStreamingDeduplicateExec
is requested for the required child output distribution