yashdotrv commented on issue #27591: URL: https://github.com/apache/datafusion/issues/27591#issuecomment-7115015490
Hi @comphead, thanks for opening this issue, we run df in production for analytical workloads at my org, and we’ve run into this exact behavior, especially with observability and time-series data where key distributions are non-uniform across partitions. And my understanding of the problem aligns with what you've described: - One-Way Latch: `SkipAggregationProbe` evaluates the initial window (`skip_partial_aggregation_probe_rows_threshold`, default 100k). If the distinct-to-total ratio exceeds `skip_partial_aggregation_probe_ratio_threshold` (0.8), or if early emits under transient memory pressure skew the counters, it permanently locks into skip mode (`is_locked = should_skip`). - Impact on Shifting Distributions: Because it never re-evaluates, an initial burst of high-cardinality keys permanently prevents partial aggregation for subsequent batches that may be highly repetitive. This bypasses local reduction entirely and pushes massive, unaggregated state downstream into the final aggregation stage, driving up memory pressure and shuffle costs. I would love to take this on and contribute a fix... so could you assign this issue to me? Before opening a draft PR, please let me know if you have any existing preferences regarding the re-probe state transitions or configuration knobs. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
