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

First stab at documenting the art of defining semantic conventions #1707

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

lmolkova
Copy link
Contributor

@lmolkova lmolkova commented Dec 20, 2024

A lot of todos, which I'd like to tackle in follow up PRs (hopefully with the help of others)

Merge requirement checklist

@lmolkova lmolkova requested review from a team as code owners December 20, 2024 22:27
@lmolkova lmolkova requested a review from Copilot December 20, 2024 22:28
@lmolkova lmolkova added the Skip Changelog Label to skip the changelog check label Dec 20, 2024
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

Comments suppressed due to low confidence (1)

docs/general/how-to-define-semantic-conventions.md:69

  • The phrase 'are involved into instrumentation efforts' should be 'are involved in instrumentation efforts'.
are involved into instrumentation efforts, and are committed to be the point of contact for

docs/general/how-to-define-semantic-conventions.md Outdated Show resolved Hide resolved
Copy link
Member

@joaopgrassi joaopgrassi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a great start!

<!-- tocstop -->

This document describes requirements, recommendations, and best practices on how to define conventions
for the new areas or make substantial changes to the existing ones.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
for the new areas or make substantial changes to the existing ones.
for new areas or make substantial changes to the existing ones.


- New conventions MUST have a group of codeowners. See [project management](https://github.com/open-telemetry/community/blob/main/project-management.md) for more details.
<!-- TODO: add CI check for CODEOWNERS file (when a new area is added) -->
- New conventions SHOULD be defined in YAML files. See [YAML Model for Semantic Conventions](/model/README.md) for the details.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With this SHOULD I assume your intention is that things should be added to yaml files where possible, but also it's OK to add conventions as just text in markdown files? For example how to record span names?

If this is right, maybe we can say something like this, to make it more clear?

  • New conventions MUST be defined in YAML files. Conventions that cannot be recorded as part of the YAML model MAY be added in the corresponding markdown file (e.g., conventions for span name)

check out [common attributes](/docs/general/attributes.md).
Semantic conventions authors are encouraged to use attributes from different namespaces.

Introduce new attributes when there is a clear use-case for them. Consider adding
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess we can make this shorter with just:

Suggested change
Introduce new attributes when there is a clear use-case for them. Consider adding
Consider adding new attributes when the following apply:

them if most of the following apply:

- They provide a clear benefit to end users by enhancing telemetry.
- You plan to use the attribute in spans, metrics, events, resources, or other telemetry signals.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- You plan to use the attribute in spans, metrics, events, resources, or other telemetry signals.
- There is a clear plan to use the attribute in spans, metrics, events, resources, or other telemetry signals.

I'm never sure if we should avoid using "you" in conventions 🤔


- They provide a clear benefit to end users by enhancing telemetry.
- You plan to use the attribute in spans, metrics, events, resources, or other telemetry signals.
- The attribute will be utilized in instrumentations.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- The attribute will be utilized in instrumentations.
- The attribute will be utilized in instrumentations.

If the above is true, isn't this already somewhat implicit? (that they are used in spans/metrics/logs etc?

I think what we have been trying to push when folks want to add new things, is that we'd like to see implementations of them, so maybe we can also say:

  • There is a clear plan on how these attributes will be used by instrumentations

- You plan to use the attribute in spans, metrics, events, resources, or other telemetry signals.
- The attribute will be utilized in instrumentations.

Postpone adding new attributes if their benefit to telemetry is not yet clear.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe here we can say something like this instead?

Semantic convention mantainers may reject the addition of new attributes if their benefit/usecase is not yet clear.

Copy link
Contributor

@braydonk braydonk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor grammar feedback

### Suggesting conventions for a new areas

Defining semantic conventions involves a group of people who are familiar with the domain,
are involved into instrumentation efforts, and are committed to be the point of contact for
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
are involved into instrumentation efforts, and are committed to be the point of contact for
are involved with instrumentation efforts, and are committed to be the point of contact for

Check out [project management](https://github.com/open-telemetry/community/blob/main/project-management.md)
for the details on how to start.

Refer to the [How to define new conventions](/docs/general/how-to-define-semantic-conventions.md) for
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Refer to the [How to define new conventions](/docs/general/how-to-define-semantic-conventions.md) for
Refer to the [How to define new conventions](/docs/general/how-to-define-semantic-conventions.md) document for

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Skip Changelog Label to skip the changelog check
Projects
Development

Successfully merging this pull request may close these issues.

3 participants