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

Refine description of Instrumentation Scope for Logs #3855

Merged
merged 28 commits into from
Mar 15, 2024
Merged
Show file tree
Hide file tree
Changes from 12 commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
b3daf3c
Refine description of InstrumentationScope in Logs Bridge API and Log…
pellared Jan 31, 2024
a5535d4
Update glossary
pellared Jan 31, 2024
ccada15
Fix TOC
pellared Jan 31, 2024
592bb98
Update changelog
pellared Jan 31, 2024
a2a0eda
InstrumentationScope is required
pellared Jan 31, 2024
411e5d3
Update Attribute Collections
pellared Jan 31, 2024
e060b05
Merge branch 'main' into logs-scope-attrs
pellared Jan 31, 2024
9d26df5
Update specification/common/README.md
pellared Feb 1, 2024
368aa3a
Merge branch 'main' into logs-scope-attrs
pellared Feb 1, 2024
4a92d4d
Merge branch 'main' into logs-scope-attrs
pellared Feb 6, 2024
ea6d4ab
Merge branch 'main' into logs-scope-attrs
pellared Feb 6, 2024
73fdb42
Merge branch 'main' into logs-scope-attrs
pellared Feb 7, 2024
b638467
Merge branch 'main' into logs-scope-attrs
pellared Feb 19, 2024
658bdc4
Update CHANGELOG.md
pellared Feb 19, 2024
40494cb
Update bridge-api.md
pellared Feb 19, 2024
403f58a
Merge branch 'main' into logs-scope-attrs
pellared Feb 20, 2024
3d7b01a
Merge branch 'main' into logs-scope-attrs
pellared Feb 26, 2024
4832d66
Merge branch 'main' into logs-scope-attrs
pellared Feb 27, 2024
f136737
Update specification/logs/data-model.md
pellared Feb 27, 2024
9cb6fb5
Merge branch 'main' into logs-scope-attrs
pellared Mar 5, 2024
4efd076
Merge branch 'main' into logs-scope-attrs
pellared Mar 6, 2024
70c2650
Merge branch 'main' into logs-scope-attrs
pellared Mar 6, 2024
2be188b
Merge branch 'main' into logs-scope-attrs
pellared Mar 12, 2024
4c2a873
Merge branch 'main' into logs-scope-attrs
pellared Mar 12, 2024
a3d2f26
Update bridge-api.md
pellared Mar 13, 2024
84445a0
Merge branch 'main' into logs-scope-attrs
pellared Mar 13, 2024
c659d82
Merge branch 'main' into logs-scope-attrs
pellared Mar 14, 2024
df415a2
Merge branch 'main' into logs-scope-attrs
tigrannajaryan Mar 14, 2024
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.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ release.

- Fix `Resource` field type in Logs Data Model.
([#3826](https://github.com/open-telemetry/opentelemetry-specification/pull/3826))
- Refine description of Instrumentation Scope.
([#3855](https://github.com/open-telemetry/opentelemetry-specification/pull/3855))
- Remove confusing description from `Body` field in Logs Data Model to make it clear the Bridge API must support a structured body.
([#3827](https://github.com/open-telemetry/opentelemetry-specification/pull/3827))
- Deconstruct number scalar type to double and signed integer.
Expand Down
5 changes: 3 additions & 2 deletions specification/common/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,9 @@ at this time, as discussed in

## Attribute Collections

[Resources](../resource/sdk.md), Metrics
[data points](../metrics/data-model.md#metric-points),
[Resources](../resource/sdk.md),
[Instrumentation Scopes](../glossary.md#instrumentation-scope),
[Metric points](../metrics/data-model.md#metric-points),
[Spans](../trace/api.md#set-attributes), Span
[Events](../trace/api.md#add-events), Span
[Links](../trace/api.md#link) and
Expand Down
8 changes: 4 additions & 4 deletions specification/glossary.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Some other fundamental terms are documented in the [overview document](overview.
* [Instrumented Library](#instrumented-library)
* [Instrumentation Library](#instrumentation-library)
* [Instrumentation Scope](#instrumentation-scope)
* [Tracer Name / Meter Name](#tracer-name--meter-name)
* [Tracer Name / Meter Name / Logger Name](#tracer-name--meter-name--logger-name)
pellared marked this conversation as resolved.
Show resolved Hide resolved
* [Execution Unit](#execution-unit)
- [Logs](#logs)
* [Log Record](#log-record)
Expand Down Expand Up @@ -169,19 +169,19 @@ fully qualified name of the emitting code (e.g. fully qualified library name or
fully qualified class name).

The instrumentation scope is used to obtain a
[Tracer or Meter](#tracer-name--meter-name).
[Tracer, Meter, or Logger](#tracer-name--meter-name--logger-name).

The instrumentation scope may have zero or more additional attributes that provide
additional information about the scope. For example for a scope that specifies an
instrumentation library an additional attribute may be recorded to denote the URL of the
repository URL the library's source code is stored. Since the scope is a build-time
concept the attributes of the scope cannot change at runtime.

### Tracer Name / Meter Name
### Tracer Name / Meter Name / Logger Name

This refers to the `name` and (optional) `version` arguments specified when
creating a new `Tracer` or `Meter` (see
[Obtaining a Tracer](trace/api.md#tracerprovider)/[Obtaining a Meter](metrics/api.md#meterprovider)).
[Obtaining a Tracer](trace/api.md#tracerprovider)/[Obtaining a Meter](metrics/api.md#meterprovider))/[Obtaining a Logger](logs/bridge-api.md#loggerprovider).
The name/version pair identifies the
[Instrumentation Scope](#instrumentation-scope), for example the
[Instrumentation Library](#instrumentation-library) or another unit of
Expand Down
13 changes: 5 additions & 8 deletions specification/logs/bridge-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,16 +61,13 @@ The `LoggerProvider` MUST provide the following functions:

#### Get a Logger

This API MUST accept the following parameters:
This API MUST accept the following [instrumentation scope](data-model.md#field-instrumentationscope)
parameters:

* `name`: This name uniquely identifies the [instrumentation scope](../glossary.md#instrumentation-scope),
such as the [instrumentation library](../glossary.md#instrumentation-library)
(e.g. `io.opentelemetry.contrib.mongodb`), package, module or class name.
If an application or library has built-in OpenTelemetry instrumentation, both
[Instrumented library](../glossary.md#instrumented-library) and
[Instrumentation library](../glossary.md#instrumentation-library) may refer to
the same library. In that scenario, the `name` denotes a module name or component
name within that library or application.
pellared marked this conversation as resolved.
Show resolved Hide resolved
such as the bridge implementation name. 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.
jack-berg marked this conversation as resolved.
Show resolved Hide resolved

* `version` (optional): Specifies the version of the instrumentation scope if
the scope has a version (e.g. a library version). Example value: 1.0.0.
Expand Down
10 changes: 2 additions & 8 deletions specification/logs/data-model.md
Original file line number Diff line number Diff line change
Expand Up @@ -428,17 +428,11 @@ This field is optional.

### Field: `InstrumentationScope`

Type: (Name,Version) tuple of strings.
Type: [Instrumentation Scope](../glossary.md#instrumentation-scope).

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.
they all have the same value of `InstrumentationScope`. This field is required.
pellared marked this conversation as resolved.
Show resolved Hide resolved

### Field: `Attributes`

Expand Down
Loading