apache / datafusion-comet

Apache DataFusion Comet Spark Accelerator
https://datafusion.apache.org/comet
Apache License 2.0
823 stars 163 forks source link

fix: The spilled_bytes metric of CometSortExec should be size instead of time #984

Closed Kontinuation closed 1 month ago

Kontinuation commented 1 month ago

Which issue does this PR close?

Closes #983.

Rationale for this change

Please refer to https://github.com/apache/datafusion-comet/issues/983 for details.

What changes are included in this PR?

Fixed the metric creation code for the spilled_bytes metric of CometSortExec. I've also examined all other metrics to make sure that similar problem does not happen to other comet operators.

How are these changes tested?

This fix is so obvious so it may not worth adding a test for it. I've verified the fix manually on Spark UI:

Before After
image image
viirya commented 1 month ago

Thanks @Kontinuation