Skip to content

Commit

Permalink
feat: store well defined metrics as times-series data streams
Browse files Browse the repository at this point in the history
Remove index.sort.field for internal metrics:
illegal_argument_exception: [illegal_argument_exception] Reason: [index.mode=time_series]
is incompatible with [index.sort.field]
  • Loading branch information
kruskall committed Dec 15, 2022
1 parent 9dab672 commit e070f52
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 2 additions & 0 deletions apmpackage/apm/data_stream/internal_metrics/fields/ecs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
name: cloud.service.name
- external: ecs
name: container.id
dimension: true
- external: ecs
name: destination.address
- external: ecs
Expand All @@ -74,6 +75,7 @@
name: host.ip
- external: ecs
name: host.name
dimension: true
- external: ecs
name: host.os.platform
index: false
Expand Down
5 changes: 1 addition & 4 deletions apmpackage/apm/data_stream/internal_metrics/manifest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ type: metrics
dataset: apm.internal
ilm_policy: metrics-apm.internal_metrics-default_policy
elasticsearch:
index_mode: "time_series"
index_template:
mappings:
# Internal metrics should have all fields strictly mapped;
Expand All @@ -29,7 +30,3 @@ elasticsearch:
type: aggregate_metric_double
metrics: [sum, value_count]
default_metric: sum
settings:
index:
sort.field: "@timestamp"
sort.order: desc

0 comments on commit e070f52

Please sign in to comment.