mhilton commented on code in PR #12099: URL: https://github.com/apache/datafusion/pull/12099#discussion_r1725428538
########## datafusion/physical-plan/src/sorts/sort.rs: ########## @@ -552,7 +552,9 @@ impl ExternalSorter { let fetch = self.fetch; let expressions = Arc::clone(&self.expr); let stream = futures::stream::once(futures::future::lazy(move |_| { + let timer = metrics.elapsed_compute().timer(); Review Comment: Where I have put the timer is part of the stream, so would not execute until the stream is polled, that means it wouldn't be tracked if the timer was moved to `in_mem_sort_stream`. I agree there should probably be another one there too though. `in_mem_sort` looks to be reasonably trivial to me, but I could add timers in the non-async blocks too if you think it's worthwhile. -- 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: github-unsubscr...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org