Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 :-) -->

#### Bugfixes

* `tracing` fields should be at root of Beats `fields.ecs.yml` artifacts. #1164

#### Added

* Added ability to supply free-form usage documentation per fieldset. #988
Expand Down
65 changes: 26 additions & 39 deletions experimental/generated/beats/fields.ecs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5212,47 +5212,34 @@
description: Normalized lowercase protocol name parsed from original string.
example: tls
default_field: false
- name: tracing
title: Tracing
group: 2
description: 'Distributed tracing makes it possible to analyze performance throughout
a microservice architecture all in one view. This is accomplished by tracing
all of the requests - from the initial web request in the front-end service
- to queries made through multiple back-end services.

Unlike most field sets in ECS, the tracing fields are *not* nested under the
field set name. In other words, the correct field name is `trace.id`, not `tracing.trace.id`,
and so on.'
type: group
fields:
- name: span.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the span within the scope of its trace.

A span represents an operation within a transaction, such as a request to
another service, or a database query.'
example: 3ff9a8981b7ccd5a
default_field: false
- name: trace.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the trace.
- name: span.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the span within the scope of its trace.

A span represents an operation within a transaction, such as a request to another
service, or a database query.'
example: 3ff9a8981b7ccd5a
default_field: false
- name: trace.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the trace.

A trace groups multiple events like transactions that belong together. For
example, a user request handled by multiple inter-connected services.'
example: 4bf92f3577b34da6a3ce929d0e0e4736
- name: transaction.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the transaction within the scope of its trace.
A trace groups multiple events like transactions that belong together. For example,
a user request handled by multiple inter-connected services.'
example: 4bf92f3577b34da6a3ce929d0e0e4736
- name: transaction.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the transaction within the scope of its trace.

A transaction is the highest level of work measured within a service, such
as a request to a server.'
example: 00f067aa0ba902b7
A transaction is the highest level of work measured within a service, such as
a request to a server.'
example: 00f067aa0ba902b7
- name: url
title: URL
group: 2
Expand Down
65 changes: 26 additions & 39 deletions generated/beats/fields.ecs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5299,47 +5299,34 @@
description: Normalized lowercase protocol name parsed from original string.
example: tls
default_field: false
- name: tracing
title: Tracing
group: 2
description: 'Distributed tracing makes it possible to analyze performance throughout
a microservice architecture all in one view. This is accomplished by tracing
all of the requests - from the initial web request in the front-end service
- to queries made through multiple back-end services.

Unlike most field sets in ECS, the tracing fields are *not* nested under the
field set name. In other words, the correct field name is `trace.id`, not `tracing.trace.id`,
and so on.'
type: group
fields:
- name: span.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the span within the scope of its trace.

A span represents an operation within a transaction, such as a request to
another service, or a database query.'
example: 3ff9a8981b7ccd5a
default_field: false
- name: trace.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the trace.
- name: span.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the span within the scope of its trace.

A span represents an operation within a transaction, such as a request to another
service, or a database query.'
example: 3ff9a8981b7ccd5a
default_field: false
- name: trace.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the trace.

A trace groups multiple events like transactions that belong together. For
example, a user request handled by multiple inter-connected services.'
example: 4bf92f3577b34da6a3ce929d0e0e4736
- name: transaction.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the transaction within the scope of its trace.
A trace groups multiple events like transactions that belong together. For example,
a user request handled by multiple inter-connected services.'
example: 4bf92f3577b34da6a3ce929d0e0e4736
- name: transaction.id
level: extended
type: keyword
ignore_above: 1024
description: 'Unique identifier of the transaction within the scope of its trace.

A transaction is the highest level of work measured within a service, such
as a request to a server.'
example: 00f067aa0ba902b7
A transaction is the highest level of work measured within a service, such as
a request to a server.'
example: 00f067aa0ba902b7
- name: url
title: URL
group: 2
Expand Down
5 changes: 5 additions & 0 deletions scripts/generators/beats.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@ def generate(ecs_nested, ecs_version, out_dir):
continue
fieldset = ecs_nested[fieldset_name]

# Handle when `root:true`
if fieldset.get('root', False):
beats_fields.extend(fieldset_field_array(fieldset['fields'], df_whitelist, fieldset['prefix']))
continue

beats_field = ecs_helpers.dict_copy_keys_ordered(fieldset, allowed_fieldset_keys)
beats_field['fields'] = fieldset_field_array(fieldset['fields'], df_whitelist, fieldset['prefix'])
beats_fields.append(beats_field)
Expand Down