Skip to content

feat(hash-aggr): Migrate Single/SinglePartitioned aggregation#5

Open
2010YOUY01 wants to merge 1 commit into
split-aggr-simplify-htfrom
split-aggr-single
Open

feat(hash-aggr): Migrate Single/SinglePartitioned aggregation#5
2010YOUY01 wants to merge 1 commit into
split-aggr-simplify-htfrom
split-aggr-single

Conversation

@2010YOUY01

Copy link
Copy Markdown
Owner

Which issue does this PR close?

Part of apache#22710

Rationale for this change

See issue for details.

This PR is stacked on apache#23309

What changes are included in this PR?

Migrate single/signle-partitioned aggregation paths

Are these changes tested?

Ut for planning the new implementation.

Functionality tests are covered by existing tests.

Are there any user-facing changes?

No

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 48b2db5d3a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

));
}

ControlFlow::Continue(original_state)

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Honor pushed-down DISTINCT limits before continuing

When enable_migration_aggregate routes a Single/SinglePartitioned DISTINCT aggregate with lim=[N] to this stream, this path always continues polling input after aggregating each batch and never checks agg.limit_options(). The older GroupedHashAggregateStream and the migrated partial/final streams stop reading and start output once the soft group limit is reached, so a single-stage SELECT DISTINCT a LIMIT 10 plan now scans all input before producing rows and an AggregateExec consumed directly can emit more than the pushed-down limit. Add the same soft-limit state/check here or avoid selecting this stream when limit_options is set.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant