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

Add InstrumentationScope/Logger Name to log data model #2359

Merged
merged 2 commits into from
Feb 24, 2022
Merged
Changes from 1 commit
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
16 changes: 16 additions & 0 deletions specification/logs/data-model.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
+ [Comparing Severity](#comparing-severity)
* [Field: `Body`](#field-body)
* [Field: `Resource`](#field-resource)
* [Field: `InstrumentationScope`](#field-instrumentationscope)
* [Field: `Attributes`](#field-attributes)
+ [Errors and Exceptions](#errors-and-exceptions)
- [Example Log Records](#example-log-records)
Expand Down Expand Up @@ -194,6 +195,7 @@ SeverityText |The severity text (also known as log level).
SeverityNumber |Numerical value of the severity.
Body |The body of the log record.
Resource |Describes the source of the log.
InstrumentationScope|Describes the scope that emitted the log.
Attributes |Additional information about the event.

Below is the detailed description of each field.
Expand Down Expand Up @@ -436,6 +438,20 @@ from the same source. SHOULD follow OpenTelemetry
[semantic conventions for Resources](../resource/semantic_conventions/README.md).
This field is optional.

### Field: `InstrumentationScope`

Type: (Name,Version) tuple of strings.

Description: the [instrumentation scope](../glossary.md#instrumentation-scope).
Multiple occurrences of events coming from the same scope can happen across time and
they all have the same value of `InstrumentationScope`. For log sources which define
a logger name (e.g. Java
[Logger Name](https://docs.oracle.com/javase/7/docs/api/java/util/logging/Logger.html#getLogger(java.lang.String)))
the Logger Name SHOULD be recorded as the Instrumentation Scope name.

Version is optional. Name SHOULD be specified if version is specified, otherwise Name
is optional.
bogdandrutu marked this conversation as resolved.
Show resolved Hide resolved

### Field: `Attributes`

Type: `map<string, any>`.
Expand Down