Skip to content

Commit

Permalink
[1.7] Add composable index templates artifacts (#1156) (#1180)
Browse files Browse the repository at this point in the history
Backports the following commits to 1.7:

* Add composable index templates artifacts (#1156)
* Move _meta section back inside mappings, in legacy templates. (#1186)
  • Loading branch information
Mathieu Martin authored Dec 14, 2020
1 parent c2b2283 commit 2000924
Show file tree
Hide file tree
Showing 76 changed files with 7,766 additions and 51 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.next.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ Thanks, you're awesome :-) -->

#### Added

* Added component templates for ECS field sets. #1156, #1186

#### Improvements

* Added a notice highlighting that the `tracing` fields are not nested under the
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ check-license-headers:
# Clean deletes all temporary and generated content.
.PHONY: clean
clean:
rm -rf build
rm -rf build generated/elasticsearch/component experimental/generated/elasticsearch/component
# Clean all markdown files for use-cases
find ./use-cases -type f -name '*.md' -not -name 'README.md' -print0 | xargs -0 rm --

Expand Down
43 changes: 43 additions & 0 deletions experimental/generated/elasticsearch/component/agent.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"_meta": {
"documentation": "https://www.elastic.co/guide/en/ecs/current/ecs-agent.html",
"ecs_version": "1.7.0+exp"
},
"template": {
"mappings": {
"properties": {
"agent": {
"properties": {
"build": {
"properties": {
"original": {
"type": "wildcard"
}
}
},
"ephemeral_id": {
"ignore_above": 1024,
"type": "keyword"
},
"id": {
"ignore_above": 1024,
"type": "keyword"
},
"name": {
"ignore_above": 1024,
"type": "keyword"
},
"type": {
"ignore_above": 1024,
"type": "keyword"
},
"version": {
"ignore_above": 1024,
"type": "keyword"
}
}
}
}
}
}
}
26 changes: 26 additions & 0 deletions experimental/generated/elasticsearch/component/base.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"_meta": {
"documentation": "https://www.elastic.co/guide/en/ecs/current/ecs-base.html",
"ecs_version": "1.7.0+exp"
},
"template": {
"mappings": {
"properties": {
"@timestamp": {
"type": "date"
},
"labels": {
"type": "object"
},
"message": {
"norms": false,
"type": "text"
},
"tags": {
"ignore_above": 1024,
"type": "keyword"
}
}
}
}
}
171 changes: 171 additions & 0 deletions experimental/generated/elasticsearch/component/client.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,171 @@
{
"_meta": {
"documentation": "https://www.elastic.co/guide/en/ecs/current/ecs-client.html",
"ecs_version": "1.7.0+exp"
},
"template": {
"mappings": {
"properties": {
"client": {
"properties": {
"address": {
"ignore_above": 1024,
"type": "keyword"
},
"as": {
"properties": {
"number": {
"type": "long"
},
"organization": {
"properties": {
"name": {
"fields": {
"text": {
"norms": false,
"type": "text"
}
},
"type": "wildcard"
}
}
}
}
},
"bytes": {
"type": "long"
},
"domain": {
"type": "wildcard"
},
"geo": {
"properties": {
"city_name": {
"ignore_above": 1024,
"type": "keyword"
},
"continent_name": {
"ignore_above": 1024,
"type": "keyword"
},
"country_iso_code": {
"ignore_above": 1024,
"type": "keyword"
},
"country_name": {
"ignore_above": 1024,
"type": "keyword"
},
"location": {
"type": "geo_point"
},
"name": {
"type": "wildcard"
},
"region_iso_code": {
"ignore_above": 1024,
"type": "keyword"
},
"region_name": {
"ignore_above": 1024,
"type": "keyword"
}
}
},
"ip": {
"type": "ip"
},
"mac": {
"ignore_above": 1024,
"type": "keyword"
},
"nat": {
"properties": {
"ip": {
"type": "ip"
},
"port": {
"type": "long"
}
}
},
"packets": {
"type": "long"
},
"port": {
"type": "long"
},
"registered_domain": {
"type": "wildcard"
},
"subdomain": {
"ignore_above": 1024,
"type": "keyword"
},
"top_level_domain": {
"ignore_above": 1024,
"type": "keyword"
},
"user": {
"properties": {
"domain": {
"ignore_above": 1024,
"type": "keyword"
},
"email": {
"type": "wildcard"
},
"full_name": {
"fields": {
"text": {
"norms": false,
"type": "text"
}
},
"type": "wildcard"
},
"group": {
"properties": {
"domain": {
"ignore_above": 1024,
"type": "keyword"
},
"id": {
"ignore_above": 1024,
"type": "keyword"
},
"name": {
"ignore_above": 1024,
"type": "keyword"
}
}
},
"hash": {
"ignore_above": 1024,
"type": "keyword"
},
"id": {
"ignore_above": 1024,
"type": "keyword"
},
"name": {
"fields": {
"text": {
"norms": false,
"type": "text"
}
},
"type": "wildcard"
},
"roles": {
"ignore_above": 1024,
"type": "keyword"
}
}
}
}
}
}
}
}
}
72 changes: 72 additions & 0 deletions experimental/generated/elasticsearch/component/cloud.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
{
"_meta": {
"documentation": "https://www.elastic.co/guide/en/ecs/current/ecs-cloud.html",
"ecs_version": "1.7.0+exp"
},
"template": {
"mappings": {
"properties": {
"cloud": {
"properties": {
"account": {
"properties": {
"id": {
"ignore_above": 1024,
"type": "keyword"
},
"name": {
"ignore_above": 1024,
"type": "keyword"
}
}
},
"availability_zone": {
"ignore_above": 1024,
"type": "keyword"
},
"instance": {
"properties": {
"id": {
"ignore_above": 1024,
"type": "keyword"
},
"name": {
"ignore_above": 1024,
"type": "keyword"
}
}
},
"machine": {
"properties": {
"type": {
"ignore_above": 1024,
"type": "keyword"
}
}
},
"project": {
"properties": {
"id": {
"ignore_above": 1024,
"type": "keyword"
},
"name": {
"ignore_above": 1024,
"type": "keyword"
}
}
},
"provider": {
"ignore_above": 1024,
"type": "keyword"
},
"region": {
"ignore_above": 1024,
"type": "keyword"
}
}
}
}
}
}
}
43 changes: 43 additions & 0 deletions experimental/generated/elasticsearch/component/container.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"_meta": {
"documentation": "https://www.elastic.co/guide/en/ecs/current/ecs-container.html",
"ecs_version": "1.7.0+exp"
},
"template": {
"mappings": {
"properties": {
"container": {
"properties": {
"id": {
"ignore_above": 1024,
"type": "keyword"
},
"image": {
"properties": {
"name": {
"ignore_above": 1024,
"type": "keyword"
},
"tag": {
"ignore_above": 1024,
"type": "keyword"
}
}
},
"labels": {
"type": "object"
},
"name": {
"ignore_above": 1024,
"type": "keyword"
},
"runtime": {
"ignore_above": 1024,
"type": "keyword"
}
}
}
}
}
}
}
Loading

0 comments on commit 2000924

Please sign in to comment.