MartijnVisser commented on code in PR #30038:
URL: https://github.com/apache/flink/pull/30038#discussion_r4666043821
##########
flink-table/flink-table-planner/src/main/scala/org/apache/flink/table/planner/plan/nodes/logical/FlinkLogicalJoin.scala:
##########
@@ -66,7 +66,12 @@ class FlinkLogicalJoin(
case JoinRelType.SEMI | JoinRelType.ANTI =>
val rightRowSize = mq.getAverageRowSize(getRight)
val ioCost = (leftRowCnt * leftRowSize) + (rightRowCnt * rightRowSize)
- val cpuCost = leftRowCnt + rightRowCnt
+ // without equi-join keys, every left row is compared with every right
row
+ val cpuCost = if (analyzeCondition().leftKeys.isEmpty) {
Review Comment:
Looks good, I'll add it to the ticket.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]