Add RESULT_COLLECTOR profiling metric#38
Open
krleonid wants to merge 6 commits into
Open
Conversation
Instruments the executor.GetResult() call in FetchResultInternal with a new phase timing metric to measure time spent collecting and materializing query results. This helps diagnose latency gaps between DuckDB's reported execution time and actual wall-clock time. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Instruments two additional unprofiled gaps in the query execution path: - EXECUTOR_INITIALIZE: time spent building pipelines and scheduling tasks - CLEANUP: time spent in post-execution cleanup including transaction commit Together with RESULT_COLLECTOR, these cover all major gaps between profiler.StartQuery() and profiler.EndQuery(). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ANUP The result collector's work is already captured in CPU_TIME as part of pipeline execution. The EXECUTOR_INITIALIZE and CLEANUP phase metrics cover the actual unprofiled gaps in the query lifecycle. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
RESULT_COLLECTORphase timing metric that measures time spent inexecutor.GetResult()during result materializationTest plan
test_custom_profiling_result_collector.testpasses (30 assertions)scripts/generate_metric_enums.py(72 metrics, 10 phase_timing)🤖 Generated with Claude Code