Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change event.name attribute into top-level event name field #4320

Merged
merged 11 commits into from
Dec 6, 2024
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ release.

### Events

- Change `event.name` attribute into top-level event name field.
trask marked this conversation as resolved.
Show resolved Hide resolved
([#4320](https://github.com/open-telemetry/opentelemetry-specification/pull/4320))

### Baggage

### Resource
Expand Down
3 changes: 1 addition & 2 deletions specification/logs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -173,8 +173,7 @@ formatted as an [event](./data-model.md#events).

**Parameters:**

* The [`Name`](https://github.com/open-telemetry/semantic-conventions/blob/main/docs/general/events.md)
of the Event.
* [Event Name](./data-model.md#event-name) (required)
trask marked this conversation as resolved.
Show resolved Hide resolved
* [Timestamp](./data-model.md#field-timestamp) (optional)
* [Observed Timestamp](./data-model.md#field-observedtimestamp) (optional). If unspecified
the implementation SHOULD set it equal to the current time.
Expand Down
9 changes: 9 additions & 0 deletions specification/logs/data-model.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
+ [Type `map`](#type-mapstring-any)
* [Field Kinds](#field-kinds)
- [Log and Event Record Definition](#log-and-event-record-definition)
* [Field: `EventName`](#field-eventname)
* [Field: `Timestamp`](#field-timestamp)
* [Field: `ObservedTimestamp`](#field-observedtimestamp)
* [Trace Context Fields](#trace-context-fields)
Expand Down Expand Up @@ -197,6 +198,7 @@ Here is the list of fields in a log record:

Field Name |Description
---------------|--------------------------------------------
EventName |Name that identifies the class / type of event.
trask marked this conversation as resolved.
Show resolved Hide resolved
Timestamp |Time when the event occurred.
ObservedTimestamp|Time when the event was observed.
TraceId |Request trace id.
Expand All @@ -211,6 +213,13 @@ Attributes |Additional information about the event.

Below is the detailed description of each field.

### Field: `EventName`
trask marked this conversation as resolved.
Show resolved Hide resolved

lmolkova marked this conversation as resolved.
Show resolved Hide resolved
Type: string.

Description: Name that identifies the class / type of event.
trask marked this conversation as resolved.
Show resolved Hide resolved
This name SHOULD uniquely identify the event structure (both attributes and body).

### Field: `Timestamp`

Type: Timestamp, uint64 nanoseconds since Unix epoch.
Expand Down
2 changes: 1 addition & 1 deletion specification/versioning-and-stability.md
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ Semantic Conventions defines the set of fields in the OTLP data model:
of well-known values.
- For log records that are [Log Events](logs/event-api.md)
- The following data provided to [emit event](logs/event-api.md#emit-event):
- The event name (the value of the `event.name` attribute)
- The event name

Things not listed in the above are not expected to remain stable via semantic
convention and are allowed (or expected) to change. A few examples:
Expand Down
Loading