Skip to content
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

Pipeline aggregation doesn't deduplicate underlying aggs #26611

Closed
Tracked by #60126
honzakral opened this issue Dec 4, 2018 · 3 comments
Closed
Tracked by #60126

Pipeline aggregation doesn't deduplicate underlying aggs #26611

honzakral opened this issue Dec 4, 2018 · 3 comments
Labels
enhancement New value added to drive a business result Feature:Aggregations Aggregation infrastructure (AggConfig, esaggs, ...) Feature:Search Querying infrastructure in Kibana impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. loe:small Small Level of Effort

Comments

@honzakral
Copy link
Contributor

Kibana version: 6.5.1

Steps to reproduce:

  1. Define two pipeline aggregations as metrics on the same underlying bucketing aggregation
  2. Kibana will ask both aggs to be calculated

Expected behavior: Kibana should deduplicate the same underlying aggregation and only run them once.

Screenshots (if relevant):
screenshot from 2018-12-04 10-11-30

Imagine asking for both avg and max buckets, underlying request then looks like:

{
  "aggs": {
    "1": {
      "max_bucket": {
        "buckets_path": "1-bucket>_count"
      }
    },
    "2": {
      "avg_bucket": {
        "buckets_path": "2-bucket>_count"
      }
    },
    "1-bucket": {
      "date_histogram": {
        "field": "Date",
        "interval": "1M",
        "time_zone": "Europe/Berlin",
        "min_doc_count": 1
      }
    },
    "2-bucket": {
      "date_histogram": {
        "field": "Date",
        "interval": "1M",
        "time_zone": "Europe/Berlin",
        "min_doc_count": 1
      }
    }
  },
  "size": 0,
  "_source": {
    "excludes": []
  },
  "stored_fields": [
    "*"
  ],
  "script_fields": {},
  "docvalue_fields": [
    {
      "field": "Date",
      "format": "date_time"
    }
  ],
  "query": {
    "bool": {
      "must": [],
      "filter": [
        {
          "match_all": {}
        }
      ],
      "should": [],
      "must_not": []
    }
  }
}
@nreese nreese added bug Fixes for quality problems that affect the customer experience Team:Visualizations Visualization editors, elastic-charts and infrastructure labels Dec 4, 2018
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app

@timroes timroes added enhancement New value added to drive a business result and removed bug Fixes for quality problems that affect the customer experience labels Jan 30, 2019
@timroes timroes added Feature:Search Querying infrastructure in Kibana Team:AppArch and removed Team:Visualizations Visualization editors, elastic-charts and infrastructure labels Apr 7, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app-arch (Team:AppArch)

@timroes timroes added the Feature:Aggregations Aggregation infrastructure (AggConfig, esaggs, ...) label Apr 7, 2020
@exalate-issue-sync exalate-issue-sync bot added impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. loe:small Small Level of Effort labels Jun 2, 2021
@lukasolson
Copy link
Member

Closing as this is an optimization that should be made directly in ES.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New value added to drive a business result Feature:Aggregations Aggregation infrastructure (AggConfig, esaggs, ...) Feature:Search Querying infrastructure in Kibana impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. loe:small Small Level of Effort
Projects
None yet
Development

No branches or pull requests

5 participants