Skip to content

Commit

Permalink
Adds documentation about a painless script (elastic#98509)
Browse files Browse the repository at this point in the history
## Summary

Adds dev documentation about a painless script in our code and when we could remove it. See:
elastic/elasticsearch#72276
elastic#78912
  • Loading branch information
FrankHassanabad authored and kibanamachine committed Apr 27, 2021
1 parent 52b52b1 commit 51f0a56
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,11 @@ const getTermsAggregationTypeFromField = (field: string): AggregationRequest =>
host_ip: {
terms: {
script: {
// We might be able to remove this when PR is fixed in Elasticsearch: https://github.com/elastic/elasticsearch/issues/72276
// Currently we cannot use "value_type" with an aggregation when we have a mapping conflict which is why this painless script exists
// See public ticket: https://github.com/elastic/kibana/pull/78912
// See private ticket: https://github.com/elastic/security-team/issues/333
// for more details on the use cases and causes of the conflicts and why this is here.
source: "doc['host.ip']",
lang: 'painless',
},
Expand Down

0 comments on commit 51f0a56

Please sign in to comment.