You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[ESQL] Add finish() elapsed time to aggregation profiling times (#113172) (#113378)
Closes#112950
Added the `finish()` time to the `AggregationOperator` profiling times,
as `finish()` here calls the aggregator evaluators, which may take a
considerable time.
Here, I added the time to the same count of nanos, but we could separate
them in 2 fields, as aggregator times differ a lot between adding input
and outputting the result. However, I believe that would require a new
transport version?
## Example times Example of how much time is lost in the sample query
`FROM test | STATS x=COUNT_DISTINCT(a)` **with the times separated in 2
variables**:
```JSON
{
"operator": "AggregationOperator[aggregators=[Aggregator[aggregatorFunction=CountDistinctLongAggregatorFunction[channels=[1]], mode=INITIAL]]]",
"status": {
"aggregation_nanos": 571900,
"aggregation_finish_nanos": 1484600,
"pages_processed": 3
}
}
```
Another, more obvious example, where there are no input pages
```JSON
{
"operator": "AggregationOperator[aggregators=[Aggregator[aggregatorFunction=CountDistinctLongAggregatorFunction[channels=[1]], mode=INITIAL]]]",
"status": {
"aggregation_nanos": 0,
"aggregation_finish_nanos": 48800,
"pages_processed": 0
}
}
```
Copy file name to clipboardExpand all lines: x-pack/plugin/esql/compute/src/test/java/org/elasticsearch/compute/operator/AggregationOperatorStatusTests.java
Copy file name to clipboardExpand all lines: x-pack/plugin/esql/qa/server/single-node/src/javaRestTest/java/org/elasticsearch/xpack/esql/qa/single_node/RestEsqlIT.java
0 commit comments