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

Use composite agg on date_histogram aggs in Monitoring UI code #36358

Closed
ycombinator opened this issue May 9, 2019 · 2 comments
Closed

Use composite agg on date_histogram aggs in Monitoring UI code #36358

ycombinator opened this issue May 9, 2019 · 2 comments
Labels
enhancement New value added to drive a business result Team:Monitoring Stack Monitoring team

Comments

@ycombinator
Copy link
Contributor

The Monitoring UI code uses timeseries charts in several places. As such it makes heavy use of the date_histogram aggregation. Occasionally, if the interval of this aggregation is set to something too granular, the ES query errors out with an error like this:

{
      "took" : 3354,
      "timed_out" : false,
      "_shards" : {
        "total" : 7,
        "successful" : 5,
        "skipped" : 0,
        "failed" : 2,
        "failures" : [
          {
            "shard" : 0,
            "index" : ".monitoring-xxxx-7-2019.05.07",
            "node" : "xxxxxxxx",
            "reason" : {
              "type" : "too_many_buckets_exception",
              "reason" : "Trying to create too many buckets. Must be less than or equal to: [10000] but was [10001]. This limit can be set by changing the [search.max_buckets] cluster level setting.",
              "max_buckets" : 10000
            }
          },
          {
            "shard" : 0,
            "index" : ".monitoring-xxxx-7-2019.05.08",
            "node" : "xxxxxxxx",
            "reason" : {
              "type" : "too_many_buckets_exception",
              "reason" : "Trying to create too many buckets. Must be less than or equal to: [10000] but was [10001]. This limit can be set by changing the [search.max_buckets] cluster level setting.",
              "max_buckets" : 10000
            }
          }
        ]
      },
      "hits" : {
        "total" : {
          "value" : 0,
          "relation" : "eq"
        },
        "max_score" : null,
        "hits" : [ ]
      },
      "aggregations" : {
        "check" : {
          "buckets" : [ ]
        }
      }
    }

One solution to this might be to wrap the date_histogram aggregation in a composite aggregation.

@ycombinator ycombinator added Team:Monitoring Stack Monitoring team enhancement New value added to drive a business result labels May 9, 2019
@elasticmachine
Copy link
Contributor

Pinging @elastic/stack-monitoring

@chrisronline
Copy link
Contributor

I'm going to close this since the ask is too general. We already have addressed this in a few key places and will continue to make these changes as necessary

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 Team:Monitoring Stack Monitoring team
Projects
None yet
Development

No branches or pull requests

3 participants