Service Map: Add aggregations and query filters to use in service map queries #358
Add this suggestion to a batch that can be applied as a single commit. This suggestion is invalid because no changes were made to the code. Suggestions cannot be applied while the pull request is closed. Suggestions cannot be applied while viewing a subset of changes. Only one suggestion per line can be applied in a batch. Add this suggestion to a batch that can be applied as a single commit. Applying suggestions on deleted lines is not supported. You must change the existing code in this line in order to create a valid suggestion. Outdated suggestions cannot be applied. This suggestion has been applied or marked resolved. Suggestions cannot be applied from pending reviews. Suggestions cannot be applied on multi-line comments. Suggestions cannot be applied while the pull request is queued to merge. Suggestion cannot be applied right now. Please check back later.
Service Map feature: Add aggregations and query filters to use in service map queries
We're using some new aggregation types (
openSeachQuery.aggs) and query filters (openSearchQuery.query) in requests for service map data to Open search.Query filters are what Open Search will filter the documents by, before applying the aggregations to the filtered set.
Query filters:
Aggregations:
serviceNameAlso:
Note:
The Bool filters that we need to add in order to get the right stats for the service map are quite nested and look a bit messy. This is because
filter,must _not,must... filters always need to be nested under theboolfilter, so there's a lot of repetition in the nesting. Once we start using them, we will need to have a complex query that looks like this:What this PR does / why we need it:
Part of the service map feature
Special notes for your reviewer:
Not using them in main, but they will be used in subsequent PRs for Service map