Skip to content

MQE: include query planning and materialization in activity tracker #11212

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 16, 2025

Conversation

charleskorn
Copy link
Contributor

What this PR does

This PR changes the behaviour of MQE to create activity tracker entries while running planning or materialization (converting a query plan to operators).

Which issue(s) this PR fixes or relates to

(none)

Checklist

  • Tests updated.
  • [n/a] Documentation added.
  • [covered by Mimir Query Engine #10067] CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX].
  • [n/a] about-versioning.md updated with experimental features.

@charleskorn charleskorn marked this pull request as ready for review April 14, 2025 06:50
@charleskorn charleskorn requested a review from a team as a code owner April 14, 2025 06:50
@charleskorn charleskorn force-pushed the charleskorn/mqe-query-planner-activity-tracker branch from 7f71136 to 3041797 Compare April 14, 2025 10:21
Copy link
Contributor

@56quarters 56quarters left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just a few non-blocking comments.

queryTrackingTestingQueryable.activeQueryAtQueryTime = trackedQuery{}

q, err := createQuery(expr)
for _, usePlanner := range []bool{true, false} {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Personal preference so feel free to ignore, but I'm not a fan of tests that end up nested like this with multiple on/off conditionals. Instead I try to split the conditionals into top-level tests and create helpers for the shared setup / teardown.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How's this? c9482af

@charleskorn charleskorn force-pushed the charleskorn/mqe-query-planner-activity-tracker branch from c9482af to a030611 Compare April 16, 2025 00:31
@charleskorn
Copy link
Contributor Author

Given the approval, I'm going to merge this, but let me know if you have any feedback on my changes.

@charleskorn charleskorn enabled auto-merge (squash) April 16, 2025 00:38
@charleskorn charleskorn merged commit e3168eb into main Apr 16, 2025
26 checks passed
@charleskorn charleskorn deleted the charleskorn/mqe-query-planner-activity-tracker branch April 16, 2025 00:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants