-
Notifications
You must be signed in to change notification settings - Fork 25.4k
[ES|QL] Introduce AggregateMetricDoubleBlock #127299
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
Conversation
066a38d
to
daba3fc
Compare
daba3fc
to
865a57b
Compare
} | ||
|
||
@Override | ||
public int getTotalValueCount() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the same as CompositeBlock but I'm not sure if this is what we want for AggregateMetricDouble?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've left several suggestions, but the PR looks great. Thanks Larisa!
x-pack/plugin/esql/compute/src/main/java/org/elasticsearch/compute/data/Block.java
Show resolved
Hide resolved
...in/esql/compute/src/main/java/org/elasticsearch/compute/data/AggregateMetricDoubleBlock.java
Outdated
Show resolved
Hide resolved
...in/esql/compute/src/main/java/org/elasticsearch/compute/data/AggregateMetricDoubleBlock.java
Show resolved
Hide resolved
...in/esql/compute/src/main/java/org/elasticsearch/compute/data/AggregateMetricDoubleBlock.java
Show resolved
Hide resolved
x-pack/plugin/esql/compute/src/main/java/org/elasticsearch/compute/data/CompositeBlock.java
Outdated
Show resolved
Hide resolved
...lugin/esql/compute/src/main/java/org/elasticsearch/compute/operator/topn/ValueExtractor.java
Outdated
Show resolved
Hide resolved
x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/action/ResponseXContentUtils.java
Outdated
Show resolved
Hide resolved
...g/elasticsearch/xpack/esql/expression/function/scalar/convert/FromAggregateMetricDouble.java
Outdated
Show resolved
Hide resolved
...pack/esql/expression/function/scalar/convert/ToStringFromAggregateMetricDoubleEvaluator.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work, Larisa!
...in/esql/compute/src/main/java/org/elasticsearch/compute/data/AggregateMetricDoubleBlock.java
Outdated
Show resolved
Hide resolved
...org/elasticsearch/xpack/esql/expression/function/scalar/convert/ToAggregateMetricDouble.java
Outdated
Show resolved
Hide resolved
...in/esql/compute/src/main/java/org/elasticsearch/compute/data/AggregateMetricDoubleBlock.java
Show resolved
Hide resolved
Pinging @elastic/es-analytical-engine (Team:Analytics) |
Hi @limotova, I've created a changelog YAML for you. |
Pinging @elastic/es-storage-engine (Team:StorageEngine) |
|
||
@Override | ||
public boolean mayHaveNulls() { | ||
return Stream.of(minBlock, maxBlock, sumBlock, countBlock).anyMatch(Block::mayHaveNulls); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: I thought there was a push to skip streams as they're unnecessarily expensive?
Backports the following commits to 8.19: - [ES|QL] Introduce AggregateMetricDoubleBlock (elastic#127299)
Backports the following commits to 8.19: - [ES|QL] Introduce AggregateMetricDoubleBlock (elastic#127299)
Backports the following commits to 8.19: - [ES|QL] Introduce AggregateMetricDoubleBlock (elastic#127299)
In elastic#127623 we backported elastic#127299 and added a backport transport version for it - `ESQL_AGGREGATE_METRIC_DOUBLE_BLOCK_8_19` aka `8_841_0_24`. This brings that version forwards to `main` and adds support for parsing streams with that version. In elastic#127639 we backported elastic#126401 and added a backport transport version for it - `PINNED_RETRIEVER_8_19` aka `8_841_0_23`. This brings that version forwards to `main` and adds support for parsing streams with that versions. In elastic#127633 we a claimed a backport transport version to backport elastic#127314 - `INTRODUCE_FAILURES_LIFECYCLE_BACKPORT_8_19` aka `8_841_0_23`. That's the same versions as `PINNED_RETRIEVER_8_19`. It's just that this one is in `main` and `PINNED_RETRIEVER_8_19` is in `8.19`. To allow me to bring `PINNED_RETRIEVER_8_19` for wards I've had to revert elastic#127633. Closes elastic#127667
In #127623 we backported #127299 and added a backport transport version for it - `ESQL_AGGREGATE_METRIC_DOUBLE_BLOCK_8_19` aka `8_841_0_24`. This brings that version forwards to `main` and adds support for parsing streams with that version. In #127639 we backported #126401 and added a backport transport version for it - `PINNED_RETRIEVER_8_19` aka `8_841_0_23`. This brings that version forwards to `main` and adds support for parsing streams with that versions. In #127633 we a claimed a backport transport version to backport #127314 - `INTRODUCE_FAILURES_LIFECYCLE_BACKPORT_8_19` aka `8_841_0_23`. That's the same versions as `PINNED_RETRIEVER_8_19`. It's just that this one is in `main` and `PINNED_RETRIEVER_8_19` is in `8.19`. To allow me to bring `PINNED_RETRIEVER_8_19` for wards I've had to revert #127633. Closes #127667
In elastic#127623 we backported elastic#127299 and added a backport transport version for it - `ESQL_AGGREGATE_METRIC_DOUBLE_BLOCK_8_19` aka `8_841_0_24`. This brings that version forwards to `main` and adds support for parsing streams with that version. In elastic#127639 we backported elastic#126401 and added a backport transport version for it - `PINNED_RETRIEVER_8_19` aka `8_841_0_23`. This brings that version forwards to `main` and adds support for parsing streams with that versions. In elastic#127633 we a claimed a backport transport version to backport elastic#127314 - `INTRODUCE_FAILURES_LIFECYCLE_BACKPORT_8_19` aka `8_841_0_23`. That's the same versions as `PINNED_RETRIEVER_8_19`. It's just that this one is in `main` and `PINNED_RETRIEVER_8_19` is in `8.19`. To allow me to bring `PINNED_RETRIEVER_8_19` for wards I've had to revert elastic#127633. Closes elastic#127667
This commit adds a new Block type named AggregateMetricDoubleBlock and
refactors AggregateMetricDouble to use it instead of CompositeBlock.
The reasoning behind this is that there were many areas where we lost
the distinction between a generic CompositeBlock vs using CompositeBlock
specifically for AggregateMetricDoubles, and we felt it was best to
split them into their own types.