o

org.apache.spark.sql.execution.adaptive

DynamicJoinSelection

object DynamicJoinSelection extends Rule[LogicalPlan] with JoinSelectionHelper

This optimization rule includes three join selection:

  1. detects a join child that has a high ratio of empty partitions and adds a NO_BROADCAST_HASH hint to avoid it being broadcast, as shuffle join is faster in this case: many tasks complete immediately since one join side is empty. 2. detects a join child that every partition size is less than local map threshold and adds a PREFER_SHUFFLE_HASH hint to encourage being shuffle hash join instead of sort merge join. 3. if a join satisfies both NO_BROADCAST_HASH and PREFER_SHUFFLE_HASH, then add a SHUFFLE_HASH hint.
Linear Supertypes
JoinSelectionHelper, Rule[LogicalPlan], Logging, SQLConfHelper, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. DynamicJoinSelection
  2. JoinSelectionHelper
  3. Rule
  4. Logging
  5. SQLConfHelper
  6. AnyRef
  7. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Type Members

  1. implicit class LogStringContext extends AnyRef
    Definition Classes
    Logging

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def MDC(key: LogKey, value: Any): MDC
    Attributes
    protected
    Definition Classes
    Logging
  5. def apply(plan: LogicalPlan): LogicalPlan
    Definition Classes
    DynamicJoinSelection → Rule
  6. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  7. def canBroadcastBySize(plan: LogicalPlan, conf: SQLConf): Boolean
    Definition Classes
    JoinSelectionHelper
  8. def canBuildBroadcastLeft(joinType: JoinType): Boolean
    Definition Classes
    JoinSelectionHelper
  9. def canBuildBroadcastRight(joinType: JoinType): Boolean
    Definition Classes
    JoinSelectionHelper
  10. def canBuildShuffledHashJoinLeft(joinType: JoinType): Boolean
    Definition Classes
    JoinSelectionHelper
  11. def canBuildShuffledHashJoinRight(joinType: JoinType): Boolean
    Definition Classes
    JoinSelectionHelper
  12. def canPlanAsBroadcastHashJoin(join: Join, conf: SQLConf): Boolean
    Definition Classes
    JoinSelectionHelper
  13. def canPruneLeft(joinType: JoinType): Boolean
    Definition Classes
    JoinSelectionHelper
  14. def canPruneRight(joinType: JoinType): Boolean
    Definition Classes
    JoinSelectionHelper
  15. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
  16. def conf: SQLConf
    Definition Classes
    SQLConfHelper
  17. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  18. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  19. def getBroadcastBuildSide(join: Join, hintOnly: Boolean, conf: SQLConf): Option[BuildSide]
    Definition Classes
    JoinSelectionHelper
  20. def getBroadcastNestedLoopJoinBuildSide(hint: JoinHint, joinType: JoinType): Option[BuildSide]
    Definition Classes
    JoinSelectionHelper
  21. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @IntrinsicCandidate() @native()
  22. def getShuffleHashJoinBuildSide(join: Join, hintOnly: Boolean, conf: SQLConf): Option[BuildSide]
    Definition Classes
    JoinSelectionHelper
  23. def getSmallerSide(left: LogicalPlan, right: LogicalPlan): BuildSide
    Definition Classes
    JoinSelectionHelper
  24. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @IntrinsicCandidate() @native()
  25. def hashJoinSupported(leftKeys: Seq[Expression], rightKeys: Seq[Expression]): Boolean
    Attributes
    protected
    Definition Classes
    JoinSelectionHelper
  26. def hintToBroadcastLeft(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  27. def hintToBroadcastRight(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  28. def hintToNotBroadcastAndReplicate(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  29. def hintToNotBroadcastAndReplicateLeft(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  30. def hintToNotBroadcastAndReplicateRight(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  31. def hintToNotBroadcastLeft(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  32. def hintToNotBroadcastRight(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  33. def hintToPreferShuffleHashJoin(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  34. def hintToPreferShuffleHashJoinLeft(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  35. def hintToPreferShuffleHashJoinRight(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  36. def hintToShuffleHashJoin(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  37. def hintToShuffleHashJoinLeft(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  38. def hintToShuffleHashJoinRight(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  39. def hintToShuffleReplicateNL(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  40. def hintToSortMergeJoin(hint: JoinHint): Boolean
    Definition Classes
    JoinSelectionHelper
  41. def initializeLogIfNecessary(isInterpreter: Boolean, silent: Boolean): Boolean
    Attributes
    protected
    Definition Classes
    Logging
  42. def initializeLogIfNecessary(isInterpreter: Boolean): Unit
    Attributes
    protected
    Definition Classes
    Logging
  43. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  44. def isTraceEnabled(): Boolean
    Attributes
    protected
    Definition Classes
    Logging
  45. def log: Logger
    Attributes
    protected
    Definition Classes
    Logging
  46. def logBasedOnLevel(level: Level)(f: => MessageWithContext): Unit
    Attributes
    protected
    Definition Classes
    Logging
  47. def logDebug(msg: => String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  48. def logDebug(entry: LogEntry, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  49. def logDebug(entry: LogEntry): Unit
    Attributes
    protected
    Definition Classes
    Logging
  50. def logDebug(msg: => String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  51. def logError(msg: => String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  52. def logError(entry: LogEntry, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  53. def logError(entry: LogEntry): Unit
    Attributes
    protected
    Definition Classes
    Logging
  54. def logError(msg: => String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  55. def logInfo(msg: => String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  56. def logInfo(entry: LogEntry, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  57. def logInfo(entry: LogEntry): Unit
    Attributes
    protected
    Definition Classes
    Logging
  58. def logInfo(msg: => String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  59. def logName: String
    Attributes
    protected
    Definition Classes
    Logging
  60. def logTrace(msg: => String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  61. def logTrace(entry: LogEntry, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  62. def logTrace(entry: LogEntry): Unit
    Attributes
    protected
    Definition Classes
    Logging
  63. def logTrace(msg: => String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  64. def logWarning(msg: => String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  65. def logWarning(entry: LogEntry, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  66. def logWarning(entry: LogEntry): Unit
    Attributes
    protected
    Definition Classes
    Logging
  67. def logWarning(msg: => String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  68. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  69. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @IntrinsicCandidate() @native()
  70. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @IntrinsicCandidate() @native()
  71. lazy val ruleId: RuleId
    Attributes
    protected
    Definition Classes
    Rule
  72. val ruleName: String
    Definition Classes
    Rule
  73. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  74. def toString(): String
    Definition Classes
    AnyRef → Any
  75. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  76. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  77. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  78. def withLogContext(context: Map[String, String])(body: => Unit): Unit
    Attributes
    protected
    Definition Classes
    Logging
  79. def withSQLConf[T](pairs: (String, String)*)(f: => T): T
    Attributes
    protected
    Definition Classes
    SQLConfHelper

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

    (Since version 9)

Inherited from JoinSelectionHelper

Inherited from Rule[LogicalPlan]

Inherited from Logging

Inherited from SQLConfHelper

Inherited from AnyRef

Inherited from Any

Ungrouped