Skip to content

Vectorize the cardinality aggregator.#11182

Merged
clintropolis merged 2 commits intoapache:masterfrom
gianm:query-vectorize-cardinality
May 4, 2021
Merged

Vectorize the cardinality aggregator.#11182
clintropolis merged 2 commits intoapache:masterfrom
gianm:query-vectorize-cardinality

Conversation

@gianm
Copy link
Copy Markdown
Contributor

@gianm gianm commented Apr 29, 2021

Does not include a byRow implementation, so if byRow is true then
the aggregator still goes through the non-vectorized path.

Testing strategy:

  • New tests that exercise both styles of "aggregate" for supported types.
  • Some existing tests have also become active (note the deleted
    "cannotVectorize" lines).

Does not include a byRow implementation, so if byRow is true then
the aggregator still goes through the non-vectorized path.

Testing strategy:

- New tests that exercise both styles of "aggregate" for supported types.
- Some existing tests have also become active (note the deleted
  "cannotVectorize" lines).
Copy link
Copy Markdown
Member

@clintropolis clintropolis left a comment

Choose a reason for hiding this comment

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

lgtm 👍

@clintropolis clintropolis merged commit bef7cc9 into apache:master May 4, 2021
gianm added a commit to gianm/druid that referenced this pull request May 5, 2021
Fixes a bug introduced in apache#11182, related to the fact that in some cases,
ColumnProcessors.makeVectorProcessor will call "makeObjectProcessor"
instead of "makeSingleValueDimensionProcessor" or
"makeMultiValueDimensionProcessor". CardinalityVectorProcessorFactory
improperly ignored calls to "makeObjectProcessor".

In addition to fixing the bug, I added this detail to the javadocs for
VectorColumnProcessorFactory, to prevent others from running into the
same thing in the future. They do not currently call out this case.
gianm added a commit that referenced this pull request May 7, 2021
* Fix vectorized cardinality bug on certain string columns.

Fixes a bug introduced in #11182, related to the fact that in some cases,
ColumnProcessors.makeVectorProcessor will call "makeObjectProcessor"
instead of "makeSingleValueDimensionProcessor" or
"makeMultiValueDimensionProcessor". CardinalityVectorProcessorFactory
improperly ignored calls to "makeObjectProcessor".

In addition to fixing the bug, I added this detail to the javadocs for
VectorColumnProcessorFactory, to prevent others from running into the
same thing in the future. They do not currently call out this case.

* Improve test coverage.

* Additional fixes.
@clintropolis clintropolis added this to the 0.22.0 milestone Aug 12, 2021
@gianm gianm deleted the query-vectorize-cardinality branch September 23, 2022 19:26
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.

2 participants