Github user aarondav commented on a diff in the pull request:
https://github.com/apache/spark/pull/1152#discussion_r14052590
--- Diff:
sql/core/src/main/scala/org/apache/spark/sql/execution/Aggregate.scala ---
@@ -168,9 +174,22 @@ case class Aggregate(
currentBuffer(i).update(currentRow)
i += 1
}
+
+ // Disable partial hash-based aggregation if desired minimum
reduction is
+ // not observed after initial interval.
+ rowCount += 1
+ if (rowCount == 100 & partial) {
+ val hashTableSize = hashTable.size
+ logger.info(s"#hash table=$hashTableSize #rows=$rowCount " +
+ s"reduction=${hashTableSize.toFloat/rowCount}
minReduction=0.5")
+ if (hashTableSize > rowCount * 0) {
--- End diff --
Man, those are some high standards!
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---