Commit Graph

969 Commits

Author SHA1 Message Date
Christian Neumüller 9d54f2f42b Fix absolute links to spec (#1192)
* Remove absolute links where possible.

* Work around semantic conventions.

* Docfx.

* Fix YAML.

* More docfx.
2023-11-16 12:50:59 -05:00
Armin Ruech 906beb96fc Define `null` as an invalid value for attributes and declare attempts to set `null` as undefined behavior (#992) 2023-11-16 12:50:59 -05:00
Tigran Najaryan a15b95dafa Require that names and namespaces are one global space across all semantic convention areas (#832)
* Require that names and namespaces are one global space across all semantic convention areas

We have semantic conventions for Resources, Spans and Metrics (in the future also Logs are expected).
It was not clear if the attribute names across all convention areas should be globally unique.

This commit asserts that conventions are one space, they are not independent spaces with
their own namespaces each.

We prohibit using the same Span or Resource attribute name or metric label name but give them
slightly different meanings or value sets.

Resolves: https://github.com/open-telemetry/opentelemetry-specification/issues/815

* Address PR comments

Co-authored-by: Bogdan Drutu <bogdandrutu@gmail.com>
2023-11-16 12:50:59 -05:00
Bogdan Drutu 15097436c7 Fix lint check in makefile, fix errors (#837)
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2023-11-16 12:50:59 -05:00
Tigran Najaryan 3fb086c80f Extend attribute naming rules to metric labels (#821)
* Extend attribute naming rules to metric labels

We earlier defined naming rules for attributes, however we do not have
similar rules for metric labels. This commit extends the exact same
set of rules to metric labels.

This was brought up in this comment https://github.com/open-telemetry/opentelemetry-specification/pull/807#discussion_r471550053

* Address PR comments
2023-11-16 12:50:59 -05:00
Tigran Najaryan 7a01501836 Add conventions for attribute names (#807)
* Add conventions for attribute names

Resolves: https://github.com/open-telemetry/opentelemetry-specification/issues/726

* Address PR comments

* Re-word company/application specific attribute recommendations
2023-11-16 12:50:59 -05:00
Giovanni Liva 46b79ae1e7 Consistency between Span and Resource attributes (#777)
* Consistency between Span and Resource attributes

* Address feedback

* Wording
2023-11-16 12:50:59 -05:00
Reiley Yang 4a2a4ef946 DocFX sanity check (#742) 2023-11-16 12:50:59 -05:00
Bogdan Drutu 4f5831ca5f Centralize attributes definition (#722)
* Centralize attributes definition

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>

* Update specification/common/common.md

Co-authored-by: Christian Neumüller <christian+github@neumueller.me>

* Update specification/common/common.md

Co-authored-by: Christian Neumüller <christian+github@neumueller.me>

* Update specification/common/common.md

Co-authored-by: Christian Neumüller <christian+github@neumueller.me>

* Update specification/common/common.md

Co-authored-by: Christian Neumüller <christian+github@neumueller.me>

* Update specification/common/common.md

Co-authored-by: Christian Neumüller <christian+github@neumueller.me>

* Update specification/common/common.md

Co-authored-by: Christian Neumüller <christian+github@neumueller.me>

* Update specification/overview.md

Co-authored-by: Christian Neumüller <christian+github@neumueller.me>

Co-authored-by: Christian Neumüller <christian+github@neumueller.me>
2023-11-16 12:50:59 -05:00
Jack Berg b85a0db524 Update spec references to point to local files 2023-11-16 12:50:59 -05:00
Jack Berg 1dc1e04ab6 Point to 1.26.0 of specification 2023-11-16 12:50:59 -05:00
Jack Berg f183527bf7 Fix more links 2023-11-16 12:50:59 -05:00
Jack Berg 84cd08ef20 Change to relative links 2023-11-16 12:50:59 -05:00
Jack Berg d445ea5eec Move attribute documents 2023-11-16 12:50:59 -05:00
Jack Berg eece45b83c Remove files to keep 2023-11-16 12:50:59 -05:00
Trask Stalnaker e56432cc1d Rename/replace `(client|server).socket.(address|port)` attributes with `network.(peer|local).(address|port)`. (#3713)
Co-authored-by: Armin Ruech <armin.ruech@dynatrace.com>
2023-11-16 12:50:59 -05:00
Carlos Alberto Cortez 7ee67a7192 Add a new AddLink() operation to Span. (#3678)
Fixes #454

Related to #3337

As the Messaging SIG merged its last OTEP 222, we will be adding operations
that require Links after Span creation, taking a direct route with `AddLink()`,
albeit without any of the new members suggested in #3337, e.g. `timestamp` (to be
discussed in a separate issue).

```
AddLink(spanContext, attributes /* optional */)
```
2023-11-16 12:50:59 -05:00
Josh Suereth e3352d43bc Remove local stubs of semantic conventions. (#3711) 2023-11-16 12:50:59 -05:00
Patrice Chalin 9d7cdb9292 Hugo front-matter fixes for aliases and linkTitle (#3592)
- Followup changes for
https://github.com/open-telemetry/opentelemetry.io/issues/2793
- There are only changes to Hugo front matter
- Adds `likeTitle`s for "Compatibility" pages
- Adds aliases for pages that have moved or were renamed
- Related:
https://github.com/open-telemetry/opentelemetry.io/issues/3013 -- the
`compatibility/openmetrics` spec page is in the list because it was
renamed

/cc @svrnm @cartermp
2023-11-16 12:50:59 -05:00
Tigran Najaryan bd2b51a249 Explain why custom attributes are not recommended to be placed in Otel namespaces (#3507)
The @open-telemetry/technical-committee discussed and decided to keep the
existing recommendations but clarify them and explain the purpose.
2023-11-16 12:50:59 -05:00
Liudmila Molkova cc85702f85 BREAKING: Introduce common `url.*` attributes, and improve use of namespacing under `http.*` (#3355) 2023-11-16 12:50:59 -05:00
Trask Stalnaker d6f3da6f11 BREAKING: Rename remaining network attributes from `net.*` to `network.*` and align definitions with ECS (#3426) 2023-11-16 12:50:59 -05:00
Liudmila Molkova 1b01442218 BREAKING: Replace `net.peer.*`/`net.host.*` with `client.*`/`server.*` (and `source.*`/`destination.*`) (#3402) 2023-11-16 12:50:59 -05:00
Patrice Chalin f4f8be2cce Use path, not external URL, for link into glossary (#3375)
- Contributes to
https://github.com/open-telemetry/opentelemetry.io/issues/2429
- This is part of an effort to normalize links, for improved link
checking on the OTel website
2023-11-16 12:50:59 -05:00
Trask Stalnaker e182ff311d Mark attribute requirement levels as stable (#3368) 2023-11-16 12:50:59 -05:00
Trask Stalnaker 4adbc387e9 Clarify that attribute requirement levels apply to instrumentation libraries (#3289)
Based on discussion in semconv stability WG

Closes #3283

## Changes

Clarifies that attribute requirement levels apply to instrumentation.
And that, because users can transform their telemetry in a number of
ways (e.g. metric views, span processors, and collector
transformations), these requirement levels cannot be relied on by
telemetry consumers.

---------

Co-authored-by: Liudmila Molkova <limolkova@microsoft.com>
Co-authored-by: Bogdan Drutu <bogdandrutu@gmail.com>
2023-11-16 12:50:59 -05:00
Trask Stalnaker c717ab4f4c Attribute requirement level follow-up edits (#3293) 2023-11-16 12:50:59 -05:00
Trask Stalnaker 8b0bccd2de Proofread of attribute requirement levels in preparation for stability (#3270) 2023-11-16 12:50:59 -05:00
Trask Stalnaker b8e3c86a2b Rename Optional attribute requirement level to Opt-In (#3228) 2023-11-16 12:50:59 -05:00
Josh Suereth 6b6cba749a Mark Attribute naming conventions as stable. (#3220) 2023-11-16 12:50:59 -05:00
Alan West 6fb1c444ab Add log attribute limit configuration (#2861)
Fixes #2860

Adds log attribute limit configuration.

These new environment variables bring more consistency between spans and logs.
2023-11-16 12:50:59 -05:00
Bogdan Drutu fac9ea093c Define semantic conventions yaml for non-otlp conventions (#2850)
* Define semantic conventions yaml for non-otlp conventions

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>

* Update semantic_conventions/trace/exporter/exporter.yaml

Co-authored-by: Christian Neumüller <christian+github@neumueller.me>

* Update semantic_conventions/scope/exporter/exporter.yaml

Co-authored-by: Joao Grassi <joao@joaograssi.com>

* Rename otel to otel_span

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
Co-authored-by: Christian Neumüller <christian+github@neumueller.me>
Co-authored-by: Joao Grassi <joao@joaograssi.com>
2023-11-16 12:50:59 -05:00
jack-berg 8267eacc84 Align log sdk naming with api (#2768)
Resolves #2752.

This aligns log SDK and API concepts which have diverged after the merged of #2676. This PR brings alignment to the log API and SDK, and in brings the log signal into alignment with tracing and metrics where there is conceptual overlap. There shouldn't be any new concepts introduced here.

- Rename `../logs/logging-library-sdk.md` to `../logs/sdk.md`
- Remove wording from SDK that implies that an API doesn't exist, like [this](https://github.com/open-telemetry/opentelemetry-specification/blame/main/specification/logs/logging-library-sdk.md#L60-L62).
- Move [How to Create Log4j Style Appender](https://github.com/open-telemetry/opentelemetry-specification/blame/main/specification/logs/logging-library-sdk.md#L219) to `api.md` since it describes an API use case.
- Move [Implicit / Explicit Context Injection](https://github.com/open-telemetry/opentelemetry-specification/blame/main/specification/logs/logging-library-sdk.md#L270-L288) sections to `api.md` since they describe API level considerations.
- Rename Logger [create](https://github.com/open-telemetry/opentelemetry-specification/blame/main/specification/logs/api.md#L133) method to be emit, to align with SDK concept of `LogRecordProcessor#onEmit(..)`.
- Rename `LogProcessor`, `LogExporter` to `LogRecordProcessor`, `LogRecordExporter`.
- Fill in various SDK level TODOs related to shutdown and flushing. The language from these was taken directly from the metrics / tracing SDK - no new concepts were introduced.
2023-11-16 12:50:59 -05:00
Liudmila Molkova a181cc323e Define net.sock attributes and clarify logical net.peer|host.name attributes (#2614) 2023-11-16 12:50:59 -05:00
Patrice Chalin fe3cf1830c Add note to Hugo front matter (#2651) 2023-11-16 12:50:59 -05:00
Tigran Najaryan aafd53c129 Use consistent file name for data-model.md (#2586) 2023-11-16 12:50:59 -05:00
Tigran Najaryan b0047edbc3 Introduce Instrumentation Scope Attributes (#2579) 2023-11-16 12:50:59 -05:00
Tigran Najaryan fb860bc667 Move non-otlp.md to common directory (#2587) 2023-11-16 12:50:59 -05:00
Patrice Chalin a1f9af0259 Add missing READMEs to section (#2559) 2023-11-16 12:50:59 -05:00
Liudmila Molkova b8926d2db9 Define attribute requirement levels (#2522)
* nits

* review comments

* No exceptions for Required attributes, clarifications on performance

* Conditional clarifications

* nits

* Conditional -> required conditionally and minor fixes

* Align requirement levels with RFC levels better

* Clarify Note on required attributes

* Update specification/common/attribute-requirement-level.md

Co-authored-by: Tigran Najaryan <4194920+tigrannajaryan@users.noreply.github.com>

* Clarify Note on required attributes

* Remove performance from conditionally required attributes

* Clarify Conditionally Required case when condition is false

* Apply suggestions from code review

Co-authored-by: Tigran Najaryan <4194920+tigrannajaryan@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Christian Neumüller <christian+github@neumueller.me>

* headings for levels and moving things around

* nits: formatting

Co-authored-by: Tigran Najaryan <4194920+tigrannajaryan@users.noreply.github.com>
Co-authored-by: Christian Neumüller <christian+github@neumueller.me>
Co-authored-by: Reiley Yang <reyang@microsoft.com>
2023-11-16 12:50:59 -05:00
Patrice Chalin 7a55bf2c53 Ensure common section has a README (#2479) 2023-11-16 12:50:59 -05:00
Tigran Najaryan b1abb50dd6 Implement OTEP 0178: Mapping external data to AnyValue (#2385)
OTEP 0178 [0] proposed this mapping. This PR merges the proposal into specification.
The content of this PR is mostly copy/paste of the text of the OTEP minus the
irrelevant sections such as "Alternates", etc.

0 - https://github.com/open-telemetry/oteps/blob/main/text/0178-mapping-to-otlp-anyvalue.md
2023-11-16 12:50:59 -05:00
Reiley Yang d1296366cf Fix links (#2426) 2023-11-16 12:50:59 -05:00
David Ashpole 5bf1bbed5b Describe how to convert non-string primitives for protocols which only support strings (#2343)
* Describe how to handle converting non-string primitives for protocols that only support strings

* update wording to make clear that only non-string values are converted to strings

* unify language

* Update specification/common/common.md

Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>

Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
Co-authored-by: Bogdan Drutu <bogdandrutu@gmail.com>
2023-11-16 12:50:59 -05:00
Tigran Najaryan 1637677327 Clarify that Trace/Meter are associated with Instrumentation Scope (#2276)
* Clarify that Trace/Meter are associated with Instrumentation Scope

This is a slightly different take on https://github.com/open-telemetry/opentelemetry-specification/issues/2203

Instead of renaming instrumentation library to instrumentation scope everywhere
this PR suggests targetted editing of wording of the Trace/Meter obtaining API
to allow not just instrumentation library but other instrumentation scopes to be
used as a parameter.

This change does not force renaming of API parameters and is not a breaking change.
We consider it a clarification of usage to match the intent that we had for the "name"
field.

If this PR is accepted there will be a follow up PR that will suggest to rename
InstrumentationLibrary* messages in OTLP proto to InstrumentationScope* message.
Such a change will not be a breaking change for the OTLP wire format and is acceptable.

If this PR is accepted we will also close https://github.com/open-telemetry/opentelemetry-specification/pull/1236
since it will be no longer necessary. The logger name will be recorded as the
instrumentation scope. This clarification will be a follow up PR that clarifies the
behavior in https://github.com/open-telemetry/oteps/blob/main/text/logs/0150-logging-library-sdk.md
2023-11-16 12:50:59 -05:00
Tigran Najaryan a2667a2dec Clarify that attribute keys are unique in collections (#2248)
Attributes keys must be unique. The key/value pair collections in the specification
was always intended to model a map.

There was a recent confusion about this. This change clarifies the spec.

Resolves https://github.com/open-telemetry/opentelemetry-specification/issues/2245
2023-11-16 12:50:59 -05:00
Tigran Najaryan 14280a41ae Prohibit usage of retired names in semantic conventions (#2191)
* Prohibit usage of retired names in semantic conventions

This change adds a prohibition clause that requires that no old
metric or attribute name is used for a new attribute.

This is important to ensure reversibility of schema transformation
(converting from a new version to an old version of schema).

Without this restriction the following is possible:

Schema version 1. Attribute A exists.
Schema version 2. Attribute A is renamed to B. Appropriate schema file is created.
Schema version 3. Attribute A is introduced (a completely different new attribute).

Now attempting to go from Version 3 to version 1 is impossible since it requires
renaming B to A (for the change in version 2), but a different attribute A already exists.

* Fix based on comments

* Add changelog entry

Co-authored-by: Carlos Alberto Cortez <calberto.cortez@gmail.com>
2023-11-16 12:50:59 -05:00
Patrice Chalin 537b07fcd6 Ensure all ToCs are generated using markdown-toc (#2146) 2023-11-16 12:50:59 -05:00
Patrice Chalin 5c85918533 Provide a normative definition of Attribute (singular) rather than Attributes (plural) (#2123)
* Provide a normative definition of Attribute (singular)

- Providing a normative definition of **attribute** (singular)
- Other copyedits

/cc @austinlparker @tedsuo

* Move anchor to make markdown checker happy
2023-11-16 12:50:59 -05:00
Owais Lone 8d35d0c0fd Exempt resources from attribute limits (#1892)
Resources are not susceptible to scenarios where excessive attributes
can be recorded unlike Spans. Resources are also immutable and it can be
hard for some SDKs to apply the limits at source at the time the
attributes are added to a resource. Furthermore, limits and Resources
both are generally defined and passed on to a TracerProvider which
forces a TracerProvider to either mutate the resource or generate a new
one with duplicate attributes in order to apply the limits to it.

Co-authored-by: Tigran Najaryan <4194920+tigrannajaryan@users.noreply.github.com>
2023-11-16 12:50:59 -05:00