Packages

case class DistanceJoinExec(left: SparkPlan, right: SparkPlan, leftShape: Expression, rightShape: Expression, swappedLeftAndRight: Boolean, distance: Expression, spatialPredicate: SpatialPredicate, extraCondition: Option[Expression] = None) extends SparkPlan with SedonaBinaryExecNode with TraitJoinQueryExec with Logging with Product with Serializable

Distance joins requires matching geometries to be in the same partition, despite not necessarily overlapping. To create an overlap and guarantee matching geometries end up in the same partition, the left geometry is expanded before partitioning. It's the logical equivalent of:

select * from a join b on ST_Distance(a.geom, b.geom) <= 1

becomes

select * from a join b on ST_Intersects(ST_Envelope(ST_Buffer(a.geom, 1)), b.geom) and ST_Distance(a.geom, b.geom) <= 1

left

left side of the join

right

right side of the join

leftShape

expression for the first argument of spatialPredicate

rightShape

expression for the second argument of spatialPredicate

swappedLeftAndRight

boolean indicating whether left and right plans were swapped

distance

- ST_Distance(left, right) <= distance. Distance can be literal or a computation over 'left'.

spatialPredicate

spatial predicate as join condition

extraCondition

extra join condition other than spatialPredicate

Linear Supertypes
TraitJoinQueryExec, TraitJoinQueryBase, SedonaBinaryExecNode, SparkPlan, Serializable, Serializable, Logging, QueryPlan[SparkPlan], SQLConfHelper, TreeNode[SparkPlan], TreePatternBits, Product, Equals, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. DistanceJoinExec
  2. TraitJoinQueryExec
  3. TraitJoinQueryBase
  4. SedonaBinaryExecNode
  5. SparkPlan
  6. Serializable
  7. Serializable
  8. Logging
  9. QueryPlan
  10. SQLConfHelper
  11. TreeNode
  12. TreePatternBits
  13. Product
  14. Equals
  15. AnyRef
  16. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new DistanceJoinExec(left: SparkPlan, right: SparkPlan, leftShape: Expression, rightShape: Expression, swappedLeftAndRight: Boolean, distance: Expression, spatialPredicate: SpatialPredicate, extraCondition: Option[Expression] = None)

    left

    left side of the join

    right

    right side of the join

    leftShape

    expression for the first argument of spatialPredicate

    rightShape

    expression for the second argument of spatialPredicate

    swappedLeftAndRight

    boolean indicating whether left and right plans were swapped

    distance

    - ST_Distance(left, right) <= distance. Distance can be literal or a computation over 'left'.

    spatialPredicate

    spatial predicate as join condition

    extraCondition

    extra join condition other than spatialPredicate

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. lazy val allAttributes: AttributeSeq
    Definition Classes
    QueryPlan
  5. def apply(number: Int): TreeNode[_]
    Definition Classes
    TreeNode
  6. def argString(maxFields: Int): String
    Definition Classes
    TreeNode
  7. def asCode: String
    Definition Classes
    TreeNode
  8. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  9. final lazy val canonicalized: SparkPlan
    Definition Classes
    QueryPlan
    Annotations
    @transient()
  10. final def children: Seq[SparkPlan]
    Definition Classes
    SedonaBinaryExecNode → TreeNode
  11. def cleanupResources(): Unit
    Attributes
    protected[sql]
    Definition Classes
    SparkPlan
  12. def clone(): SparkPlan
    Definition Classes
    TreeNode → AnyRef
  13. def collect[B](pf: PartialFunction[SparkPlan, B]): Seq[B]
    Definition Classes
    TreeNode
  14. def collectFirst[B](pf: PartialFunction[SparkPlan, B]): Option[B]
    Definition Classes
    TreeNode
  15. def collectLeaves(): Seq[SparkPlan]
    Definition Classes
    TreeNode
  16. def collectWithSubqueries[B](f: PartialFunction[SparkPlan, B]): Seq[B]
    Definition Classes
    QueryPlan
  17. def conf: SQLConf
    Definition Classes
    SparkPlan → SQLConfHelper
  18. final def containsAllPatterns(patterns: TreePattern*): Boolean
    Definition Classes
    TreePatternBits
  19. final def containsAnyPattern(patterns: TreePattern*): Boolean
    Definition Classes
    TreePatternBits
  20. lazy val containsChild: Set[TreeNode[_]]
    Definition Classes
    TreeNode
  21. final def containsPattern(t: TreePattern): Boolean
    Definition Classes
    TreePatternBits
    Annotations
    @inline()
  22. def copyTagsFrom(other: SparkPlan): Unit
    Definition Classes
    TreeNode
  23. lazy val deterministic: Boolean
    Definition Classes
    QueryPlan
  24. val distance: Expression
  25. def doCanonicalize(): SparkPlan
    Attributes
    protected
    Definition Classes
    QueryPlan
  26. def doExecute(): RDD[InternalRow]
    Attributes
    protected
    Definition Classes
    TraitJoinQueryExec
  27. def doExecuteBroadcast[T](): Broadcast[T]
    Attributes
    protected[sql]
    Definition Classes
    SparkPlan
  28. def doExecuteColumnar(): RDD[ColumnarBatch]
    Attributes
    protected
    Definition Classes
    SparkPlan
  29. def doPrepare(): Unit
    Attributes
    protected
    Definition Classes
    SparkPlan
  30. def doSpatialPartitioning(dominantShapes: SpatialRDD[Geometry], followerShapes: SpatialRDD[Geometry], numPartitions: Integer, sedonaConf: SedonaConf): Unit
    Definition Classes
    TraitJoinQueryBase
  31. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  32. final def execute(): RDD[InternalRow]
    Definition Classes
    SparkPlan
  33. final def executeBroadcast[T](): Broadcast[T]
    Definition Classes
    SparkPlan
  34. def executeCollect(): Array[InternalRow]
    Definition Classes
    SparkPlan
  35. def executeCollectPublic(): Array[Row]
    Definition Classes
    SparkPlan
  36. final def executeColumnar(): RDD[ColumnarBatch]
    Definition Classes
    SparkPlan
  37. final def executeQuery[T](query: ⇒ T): T
    Attributes
    protected
    Definition Classes
    SparkPlan
  38. def executeTail(n: Int): Array[InternalRow]
    Definition Classes
    SparkPlan
  39. def executeTake(n: Int): Array[InternalRow]
    Definition Classes
    SparkPlan
  40. def executeToIterator(): Iterator[InternalRow]
    Definition Classes
    SparkPlan
  41. def exists(f: (SparkPlan) ⇒ Boolean): Boolean
    Definition Classes
    TreeNode
  42. final def expressions: Seq[Expression]
    Definition Classes
    QueryPlan
  43. val extraCondition: Option[Expression]
    Definition Classes
    DistanceJoinExecTraitJoinQueryExec
  44. def fastEquals(other: TreeNode[_]): Boolean
    Definition Classes
    TreeNode
  45. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  46. def find(f: (SparkPlan) ⇒ Boolean): Option[SparkPlan]
    Definition Classes
    TreeNode
  47. def flatMap[A](f: (SparkPlan) ⇒ TraversableOnce[A]): Seq[A]
    Definition Classes
    TreeNode
  48. def foreach(f: (SparkPlan) ⇒ Unit): Unit
    Definition Classes
    TreeNode
  49. def foreachUp(f: (SparkPlan) ⇒ Unit): Unit
    Definition Classes
    TreeNode
  50. def formattedNodeName: String
    Attributes
    protected
    Definition Classes
    QueryPlan
  51. def generateTreeString(depth: Int, lastChildren: Seq[Boolean], append: (String) ⇒ Unit, verbose: Boolean, prefix: String, addSuffix: Boolean, maxFields: Int, printNodeId: Boolean, indent: Int): Unit
    Definition Classes
    TreeNode
  52. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  53. def getDefaultTreePatternBits: BitSet
    Attributes
    protected
    Definition Classes
    TreeNode
  54. def getTagValue[T](tag: TreeNodeTag[T]): Option[T]
    Definition Classes
    TreeNode
  55. def hashCode(): Int
    Definition Classes
    TreeNode → AnyRef → Any
  56. val id: Int
    Definition Classes
    SparkPlan
  57. def initializeLogIfNecessary(isInterpreter: Boolean, silent: Boolean): Boolean
    Attributes
    protected
    Definition Classes
    Logging
  58. def initializeLogIfNecessary(isInterpreter: Boolean): Unit
    Attributes
    protected
    Definition Classes
    Logging
  59. def innerChildren: Seq[QueryPlan[_]]
    Definition Classes
    QueryPlan → TreeNode
  60. def inputSet: AttributeSet
    Definition Classes
    QueryPlan
  61. def isCanonicalizedPlan: Boolean
    Attributes
    protected
    Definition Classes
    QueryPlan
  62. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  63. def isRuleIneffective(ruleId: RuleId): Boolean
    Attributes
    protected
    Definition Classes
    TreeNode
  64. def isTraceEnabled(): Boolean
    Attributes
    protected
    Definition Classes
    Logging
  65. def joinPartitionNumOptimizer(dominantSidePartNum: Int, followerSidePartNum: Int, dominantSideCount: Long): Int
    Definition Classes
    TraitJoinQueryExec
  66. def jsonFields: List[JField]
    Attributes
    protected
    Definition Classes
    TreeNode
  67. val left: SparkPlan
  68. val leftShape: Expression
    Definition Classes
    DistanceJoinExecTraitJoinQueryExec
  69. final def legacyWithNewChildren(newChildren: Seq[SparkPlan]): SparkPlan
    Attributes
    protected
    Definition Classes
    TreeNode
  70. def log: Logger
    Attributes
    protected
    Definition Classes
    Logging
  71. def logDebug(msg: ⇒ String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  72. def logDebug(msg: ⇒ String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  73. def logError(msg: ⇒ String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  74. def logError(msg: ⇒ String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  75. def logInfo(msg: ⇒ String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  76. def logInfo(msg: ⇒ String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  77. def logName: String
    Attributes
    protected
    Definition Classes
    Logging
  78. def logTrace(msg: ⇒ String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  79. def logTrace(msg: ⇒ String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  80. def logWarning(msg: ⇒ String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  81. def logWarning(msg: ⇒ String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  82. def logicalLink: Option[LogicalPlan]
    Definition Classes
    SparkPlan
  83. def longMetric(name: String): SQLMetric
    Definition Classes
    SparkPlan
  84. def makeCopy(newArgs: Array[AnyRef]): SparkPlan
    Definition Classes
    SparkPlan → TreeNode
  85. def map[A](f: (SparkPlan) ⇒ A): Seq[A]
    Definition Classes
    TreeNode
  86. def mapChildren(f: (SparkPlan) ⇒ SparkPlan): SparkPlan
    Definition Classes
    TreeNode
  87. def mapExpressions(f: (Expression) ⇒ Expression): DistanceJoinExec.this.type
    Definition Classes
    QueryPlan
  88. def mapProductIterator[B](f: (Any) ⇒ B)(implicit arg0: ClassTag[B]): Array[B]
    Attributes
    protected
    Definition Classes
    TreeNode
  89. def markRuleAsIneffective(ruleId: RuleId): Unit
    Attributes
    protected
    Definition Classes
    TreeNode
  90. def metrics: Map[String, SQLMetric]
    Definition Classes
    SparkPlan
  91. final def missingInput: AttributeSet
    Definition Classes
    QueryPlan
  92. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  93. def nodeName: String
    Definition Classes
    TreeNode
  94. val nodePatterns: Seq[TreePattern]
    Attributes
    protected
    Definition Classes
    TreeNode
  95. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  96. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  97. def numberedTreeString: String
    Definition Classes
    TreeNode
  98. val origin: Origin
    Definition Classes
    TreeNode
  99. def otherCopyArgs: Seq[AnyRef]
    Attributes
    protected
    Definition Classes
    TreeNode
  100. def output: Seq[Attribute]
    Definition Classes
    TraitJoinQueryExec
  101. def outputOrdering: Seq[SortOrder]
    Definition Classes
    SparkPlan
  102. def outputPartitioning: Partitioning
    Definition Classes
    SparkPlan
  103. lazy val outputSet: AttributeSet
    Definition Classes
    QueryPlan
    Annotations
    @transient()
  104. def p(number: Int): SparkPlan
    Definition Classes
    TreeNode
  105. final def prepare(): Unit
    Definition Classes
    SparkPlan
  106. def prepareSubqueries(): Unit
    Attributes
    protected
    Definition Classes
    SparkPlan
  107. def prettyJson: String
    Definition Classes
    TreeNode
  108. def printSchema(): Unit
    Definition Classes
    QueryPlan
  109. def producedAttributes: AttributeSet
    Definition Classes
    QueryPlan
  110. lazy val references: AttributeSet
    Definition Classes
    QueryPlan
    Annotations
    @transient()
  111. def requiredChildDistribution: Seq[Distribution]
    Definition Classes
    SparkPlan
  112. def requiredChildOrdering: Seq[Seq[SortOrder]]
    Definition Classes
    SparkPlan
  113. def resetMetrics(): Unit
    Definition Classes
    SparkPlan
  114. def rewriteAttrs(attrMap: AttributeMap[Attribute]): SparkPlan
    Definition Classes
    QueryPlan
  115. val right: SparkPlan
  116. val rightShape: Expression
    Definition Classes
    DistanceJoinExecTraitJoinQueryExec
  117. final def sameResult(other: SparkPlan): Boolean
    Definition Classes
    QueryPlan
  118. lazy val schema: StructType
    Definition Classes
    QueryPlan
  119. def schemaString: String
    Definition Classes
    QueryPlan
  120. final def semanticHash(): Int
    Definition Classes
    QueryPlan
  121. final val session: SparkSession
    Definition Classes
    SparkPlan
  122. def setLogicalLink(logicalPlan: LogicalPlan): Unit
    Definition Classes
    SparkPlan
  123. def setTagValue[T](tag: TreeNodeTag[T], value: T): Unit
    Definition Classes
    TreeNode
  124. def simpleString(maxFields: Int): String
    Definition Classes
    QueryPlan → TreeNode
  125. def simpleStringWithNodeId(): String
    Definition Classes
    QueryPlan → TreeNode
  126. def sparkContext: SparkContext
    Attributes
    protected
    Definition Classes
    SparkPlan
  127. val spatialPredicate: SpatialPredicate
    Definition Classes
    DistanceJoinExecTraitJoinQueryExec
  128. def statePrefix: String
    Attributes
    protected
    Definition Classes
    QueryPlan
  129. def stringArgs: Iterator[Any]
    Attributes
    protected
    Definition Classes
    TreeNode
  130. lazy val subqueries: Seq[SparkPlan]
    Definition Classes
    QueryPlan
    Annotations
    @transient()
  131. def subqueriesAll: Seq[SparkPlan]
    Definition Classes
    QueryPlan
  132. def supportsColumnar: Boolean
    Definition Classes
    SparkPlan
  133. def supportsRowBased: Boolean
    Definition Classes
    SparkPlan
  134. val swappedLeftAndRight: Boolean
    Definition Classes
    DistanceJoinExecTraitJoinQueryExec
  135. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  136. def toExpandedEnvelopeRDD(rdd: RDD[UnsafeRow], shapeExpression: Expression, boundRadius: Expression): SpatialRDD[Geometry]
    Definition Classes
    TraitJoinQueryBase
  137. def toJSON: String
    Definition Classes
    TreeNode
  138. def toRowBased: SparkPlan
    Definition Classes
    SparkPlan
  139. def toSpatialRDD(rdd: RDD[UnsafeRow], shapeExpression: Expression): SpatialRDD[Geometry]
    Definition Classes
    TraitJoinQueryBase
  140. def toSpatialRddPair(buildRdd: RDD[UnsafeRow], buildExpr: Expression, streamedRdd: RDD[UnsafeRow], streamedExpr: Expression): (SpatialRDD[Geometry], SpatialRDD[Geometry])
    Definition Classes
    DistanceJoinExecTraitJoinQueryBase
  141. def toString(): String
    Definition Classes
    TreeNode → AnyRef → Any
  142. def transform(rule: PartialFunction[SparkPlan, SparkPlan]): SparkPlan
    Definition Classes
    TreeNode
  143. def transformAllExpressions(rule: PartialFunction[Expression, Expression]): DistanceJoinExec.this.type
    Definition Classes
    QueryPlan
  144. def transformAllExpressionsWithPruning(cond: (TreePatternBits) ⇒ Boolean, ruleId: RuleId)(rule: PartialFunction[Expression, Expression]): DistanceJoinExec.this.type
    Definition Classes
    QueryPlan
  145. def transformDown(rule: PartialFunction[SparkPlan, SparkPlan]): SparkPlan
    Definition Classes
    TreeNode
  146. def transformDownWithPruning(cond: (TreePatternBits) ⇒ Boolean, ruleId: RuleId)(rule: PartialFunction[SparkPlan, SparkPlan]): SparkPlan
    Definition Classes
    TreeNode
  147. def transformDownWithSubqueries(f: PartialFunction[SparkPlan, SparkPlan]): SparkPlan
    Definition Classes
    QueryPlan
  148. def transformDownWithSubqueriesAndPruning(cond: (TreePatternBits) ⇒ Boolean, ruleId: RuleId)(f: PartialFunction[SparkPlan, SparkPlan]): SparkPlan
    Definition Classes
    QueryPlan
  149. def transformExpressions(rule: PartialFunction[Expression, Expression]): DistanceJoinExec.this.type
    Definition Classes
    QueryPlan
  150. def transformExpressionsDown(rule: PartialFunction[Expression, Expression]): DistanceJoinExec.this.type
    Definition Classes
    QueryPlan
  151. def transformExpressionsDownWithPruning(cond: (TreePatternBits) ⇒ Boolean, ruleId: RuleId)(rule: PartialFunction[Expression, Expression]): DistanceJoinExec.this.type
    Definition Classes
    QueryPlan
  152. def transformExpressionsUp(rule: PartialFunction[Expression, Expression]): DistanceJoinExec.this.type
    Definition Classes
    QueryPlan
  153. def transformExpressionsUpWithPruning(cond: (TreePatternBits) ⇒ Boolean, ruleId: RuleId)(rule: PartialFunction[Expression, Expression]): DistanceJoinExec.this.type
    Definition Classes
    QueryPlan
  154. def transformExpressionsWithPruning(cond: (TreePatternBits) ⇒ Boolean, ruleId: RuleId)(rule: PartialFunction[Expression, Expression]): DistanceJoinExec.this.type
    Definition Classes
    QueryPlan
  155. def transformUp(rule: PartialFunction[SparkPlan, SparkPlan]): SparkPlan
    Definition Classes
    TreeNode
  156. def transformUpWithBeforeAndAfterRuleOnChildren(cond: (SparkPlan) ⇒ Boolean, ruleId: RuleId)(rule: PartialFunction[(SparkPlan, SparkPlan), SparkPlan]): SparkPlan
    Definition Classes
    TreeNode
  157. def transformUpWithNewOutput(rule: PartialFunction[SparkPlan, (SparkPlan, Seq[(Attribute, Attribute)])], skipCond: (SparkPlan) ⇒ Boolean, canGetOutput: (SparkPlan) ⇒ Boolean): SparkPlan
    Definition Classes
    QueryPlan
  158. def transformUpWithPruning(cond: (TreePatternBits) ⇒ Boolean, ruleId: RuleId)(rule: PartialFunction[SparkPlan, SparkPlan]): SparkPlan
    Definition Classes
    TreeNode
  159. def transformUpWithSubqueries(f: PartialFunction[SparkPlan, SparkPlan]): SparkPlan
    Definition Classes
    QueryPlan
  160. def transformWithPruning(cond: (TreePatternBits) ⇒ Boolean, ruleId: RuleId)(rule: PartialFunction[SparkPlan, SparkPlan]): SparkPlan
    Definition Classes
    TreeNode
  161. def transformWithSubqueries(f: PartialFunction[SparkPlan, SparkPlan]): SparkPlan
    Definition Classes
    QueryPlan
  162. lazy val treePatternBits: BitSet
    Definition Classes
    QueryPlan → TreeNode → TreePatternBits
  163. def treeString(append: (String) ⇒ Unit, verbose: Boolean, addSuffix: Boolean, maxFields: Int, printOperatorId: Boolean): Unit
    Definition Classes
    TreeNode
  164. final def treeString(verbose: Boolean, addSuffix: Boolean, maxFields: Int, printOperatorId: Boolean): String
    Definition Classes
    TreeNode
  165. final def treeString: String
    Definition Classes
    TreeNode
  166. def unsetTagValue[T](tag: TreeNodeTag[T]): Unit
    Definition Classes
    TreeNode
  167. def updateOuterReferencesInSubquery(plan: SparkPlan, attrMap: AttributeMap[Attribute]): SparkPlan
    Attributes
    protected
    Definition Classes
    QueryPlan
  168. def vectorTypes: Option[Seq[String]]
    Definition Classes
    SparkPlan
  169. def verboseString(maxFields: Int): String
    Definition Classes
    QueryPlan → TreeNode
  170. def verboseStringWithOperatorId(): String
    Definition Classes
    QueryPlan
  171. def verboseStringWithSuffix(maxFields: Int): String
    Definition Classes
    TreeNode
  172. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  173. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  174. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  175. def waitForSubqueries(): Unit
    Attributes
    protected
    Definition Classes
    SparkPlan
  176. final def withNewChildren(newChildren: Seq[SparkPlan]): SparkPlan
    Definition Classes
    TreeNode
  177. def withNewChildrenInternal(newLeft: SparkPlan, newRight: SparkPlan): SparkPlan
    Attributes
    protected
    Definition Classes
    DistanceJoinExecSedonaBinaryExecNode
  178. final def withNewChildrenInternal(newChildren: IndexedSeq[SparkPlan]): SparkPlan
    Definition Classes
    SedonaBinaryExecNode → TreeNode

Inherited from TraitJoinQueryExec

Inherited from TraitJoinQueryBase

Inherited from SedonaBinaryExecNode

Inherited from SparkPlan

Inherited from Serializable

Inherited from Serializable

Inherited from Logging

Inherited from QueryPlan[SparkPlan]

Inherited from SQLConfHelper

Inherited from TreeNode[SparkPlan]

Inherited from TreePatternBits

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped