From b6b414e78f125016d89e0b6295e14f68c0ad6363 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?No=C3=A9mi=20V=C3=A1nyi?= Date: Thu, 7 May 2020 12:03:29 +0200 Subject: [PATCH] Add IP* fields to fields.yml generator script (#18256) ## What does this PR do? This PR adds the following patterns to the fields.yml generator with the type `ip`: - `IP` - `IPV4` - `IPV6` ## Why is it important? From now on `fields.yml` generator is able to guess the correct type for fields which match the patterns mentioned above. --- CHANGELOG-developer.next.asciidoc | 1 + filebeat/generator/fields/fields.go | 3 +++ 2 files changed, 4 insertions(+) diff --git a/CHANGELOG-developer.next.asciidoc b/CHANGELOG-developer.next.asciidoc index 9fb3f6bf1ea..31c6dfcf2b0 100644 --- a/CHANGELOG-developer.next.asciidoc +++ b/CHANGELOG-developer.next.asciidoc @@ -86,3 +86,4 @@ The list below covers the major changes between 7.0.0-rc2 and master only. - Add support for MODULE environment variable in `mage goIntegTest` in metricbeat to run integration tests for a single module. {pull}17147[17147] - Add support for a `TEST_TAGS` environment variable to add tags for tests selection following go build tags semantics, this environment variable is used by mage test targets to add build tags. Python tests can also be tagged with a decorator (`@beat.tag('sometag')`). {pull}16937[16937] {pull}17075[17075] - Add fields validation for histogram subfields. {pull}17759[17759] +- Add IP* fields to `fields.yml` generator script in Filebeat. {issue}17998[17998] {pull}18256[18256] diff --git a/filebeat/generator/fields/fields.go b/filebeat/generator/fields/fields.go index da62419a9cf..a656dc75a08 100644 --- a/filebeat/generator/fields/fields.go +++ b/filebeat/generator/fields/fields.go @@ -45,6 +45,9 @@ var ( "GREEDYDATA": "text", "GREEDYMULTILINE": "text", "HOSTNAME": "keyword", + "IP": "ip", + "IPV4": "ip", + "IPV6": "ip", "IPHOST": "keyword", "IPORHOST": "keyword", "LOGLEVEL": "keyword",