Skip to content

Proposal: Define namespaces in yaml - #867

Open
thompson-tomo wants to merge 3 commits into
open-telemetry:mainfrom
thompson-tomo:proposal/#802_NamespaceDefs
Open

Proposal: Define namespaces in yaml#867
thompson-tomo wants to merge 3 commits into
open-telemetry:mainfrom
thompson-tomo:proposal/#802_NamespaceDefs

Conversation

@thompson-tomo

Copy link
Copy Markdown
Contributor

Progresses #802 and unblocks #849

This provides as a proposal to introducing namespace definitions alongside metrics, attributes etc,

Namespaces are a way in which definitions can be grouped together as well as a method to define & eventually generate additional useful data about that namespace. Such as examples would be revision history & migration guides.

Comment on lines +35 to +39
#### Fallback linking

If neither of the 2 previous methods are satisifed,
a namespace is created by weaver which corresponds to the first path segment.
This namespace will use the default values for a namespace.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I like the idea of defining namespaces explicitly. Within Weaver right now there is no concept of namespace whatsoever by design. Hence your proposal.

(I took a wrong turn when developing live-check, I had namespace checking with the . separator built into rust code. This was removed and rewritten in rego policies.)

So,

  1. What if I don't want namespaces at all?
  2. What if I want namespaces but a different separator? Or, just CamelCase (I've seen examples of this in the wild)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

So my thought would be that there should be a default namespace "default" which items are assigned to if the namespace can not be determined via either of the methods. I think that would handle the scenario of not wanting to use namespaces.

In an effort to keep it simple I would stick with the dot convention being the namespace seperator however if an author is using another convention they should use the explicit option. We could always extend later.

Comment on lines +18 to +22
#### Explicit linking

This is where the author explicitly states the namespace which this telemetry signal should be associated with.
This is to help with the when the namespace of an attribute changes.
For instance `az` has become `azure`.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We used to have prefix - I wonder what the reasoning was behind its removal?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

My understanding was prefix was added to the attribute keys etc whereas this explicit namespace can be thought of as aliasing.

Comment thread docs/proposals/namespaces.md Outdated
Comment on lines +37 to +39
If neither of the 2 previous methods are satisifed,
a namespace is created by weaver which corresponds to the first path segment.
This namespace will use the default values for a namespace.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Should we have a configuration option to use the folder as fall back source?

Comment on lines +18 to +22
#### Explicit linking

This is where the author explicitly states the namespace which this telemetry signal should be associated with.
This is to help with the when the namespace of an attribute changes.
For instance `az` has become `azure`.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

My understanding was prefix was added to the attribute keys etc whereas this explicit namespace can be thought of as aliasing.

@thompson-tomo thompson-tomo changed the title Define namespaces in yaml Proposal: Define namespaces in yaml Aug 7, 2025
@opentelemetry-pr-dashboard

opentelemetry-pr-dashboard Bot commented Jul 18, 2026

Copy link
Copy Markdown

Pull request dashboard status

Waiting on reviewers · refreshed 2026-08-04 14:25 UTC

Review the latest changes.

Status above doesn't look right?
  • Just replied or pushed? Anything around or after the refresh time above may not be picked up yet — give it a few minutes.
  • Anything look wrong? Report it with what you expected; it helps us improve the dashboard.

@codecov

codecov Bot commented Jul 19, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 81.1%. Comparing base (967b53e) to head (caf70fc).

Additional details and impacted files
@@           Coverage Diff           @@
##            main    #867     +/-   ##
=======================================
- Coverage   81.2%   81.1%   -0.1%     
=======================================
  Files        130     130             
  Lines      11463   11463             
=======================================
- Hits        9309    9307      -2     
- Misses      2154    2156      +2     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants