-
Notifications
You must be signed in to change notification settings - Fork 183
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This PR is a follow up to the OTEP [Events and Logs API](https://github.com/open-telemetry/oteps/blob/main/text/0202-events-and-logs-api.md). It describes the specification for an Events and Logs API and also defines semantic conventions for attributes to be used for Events that are represented using Log Records. For non-trivial changes, follow the [change proposal process](../CONTRIBUTING.md#proposing-a-change) and link to the related issue(s) and/or [OTEP(s)](https://github.com/open-telemetry/oteps), update the [`CHANGELOG.md`](../CHANGELOG.md), and also be sure to update [`spec-compliance-matrix.md`](../spec-compliance-matrix.md) if necessary. Related [OTEP(s)](https://github.com/open-telemetry/oteps) # [Events and Logs API](https://github.com/open-telemetry/oteps/blob/main/text/0202-events-and-logs-api.md)
- Loading branch information
Showing
3 changed files
with
63 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
groups: | ||
- id: event | ||
prefix: event | ||
brief: > | ||
This document defines attributes for Events represented using Log Records. | ||
attributes: | ||
- id: name | ||
type: string | ||
requirement_level: required | ||
brief: > | ||
The name identifies the event. | ||
examples: ['click', 'exception'] | ||
- id: domain | ||
brief: > | ||
The domain identifies the context in which an event happened. An event name is unique only within a domain. | ||
type: | ||
allow_custom_values: true | ||
members: | ||
- id: browser | ||
value: 'browser' | ||
brief: 'Events from browser apps' | ||
- id: device | ||
value: 'device' | ||
brief: 'Events from mobile apps' | ||
- id: k8s | ||
value: 'k8s' | ||
brief: 'Events from Kubernetes' | ||
requirement_level: required | ||
note: | | ||
An `event.name` is supposed to be unique only in the context of an | ||
`event.domain`, so this allows for two events in different domains to | ||
have same `event.name`, yet be unrelated events. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# Semantic Convention for event attributes | ||
|
||
**Status**: [Experimental](../../document-status.md) | ||
|
||
This document describes the attributes of standalone Events that are represented | ||
by `LogRecord`s. All standalone Events have a name and a domain. The Event domain | ||
is a namespace for event names and is used as a mechanism to avoid conflicts of | ||
event names. | ||
|
||
<!-- semconv event --> | ||
| Attribute | Type | Description | Examples | Requirement Level | | ||
|---|---|---|---|---| | ||
| `event.name` | string | The name identifies the event. | `click`; `exception` | Required | | ||
| `event.domain` | string | The domain identifies the context in which an event happened. An event name is unique only within a domain. [1] | `browser` | Required | | ||
|
||
**[1]:** An `event.name` is supposed to be unique only in the context of an | ||
`event.domain`, so this allows for two events in different domains to | ||
have same `event.name`, yet be unrelated events. | ||
|
||
`event.domain` has the following list of well-known values. If one of them applies, then the respective value MUST be used, otherwise a custom value MAY be used. | ||
|
||
| Value | Description | | ||
|---|---| | ||
| `browser` | Events from browser apps | | ||
| `device` | Events from mobile apps | | ||
| `k8s` | Events from Kubernetes | | ||
<!-- endsemconv --> |