-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[Alerting Framework] Create a new rule count/summary endpoint #119226
Comments
Pinging @elastic/kibana-alerting-services (Team:Alerting Services) |
Alerting rules client currently has an "aggregate" API that returns a count of rules by execution status. This was implemented before the saved objects client added aggregation support so what it really does is perform a find query for each execution status and reduce the results into a single result. kibana/x-pack/plugins/alerting/server/rules_client/rules_client.ts Lines 646 to 683 in 998a0db
The intent was always to replace this with a real aggregation once the saved objects client supported aggregations, which it now does: #96292, so it seems like it would make the most sense to update the |
I think this got forgotten and should have been added to the R&AM project board for triage. cc @XavierM |
@simianhacker if you want to confirm for @XavierM if this is still something we'd like to have, in case they want more specific requirements? |
@XavierM Do you have plans for this? |
In #116476 we were discussing how to search for rules, and @ymao1 pointed us to the GET rule by ID or FIND rules endpoints. We're going to move forward with those but I thought it might be useful to have an endpoint that could make a more efficient ES query and just return the overall counts for some things, based on the same filter/query options available int he find rules endpoint.
For example:
The basic idea is just that we want this above information in as performant a way as can be managed, and right now we'll have to query the rules and loop over the results to count these. Thoughts?
The text was updated successfully, but these errors were encountered: