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

Is there an index for all available schema? #3256

Closed
MrAlias opened this issue Sep 11, 2023 · 8 comments · Fixed by #3475
Closed

Is there an index for all available schema? #3256

MrAlias opened this issue Sep 11, 2023 · 8 comments · Fixed by #3475
Labels
enhancement New feature or request sig:spec

Comments

@MrAlias
Copy link
Contributor

MrAlias commented Sep 11, 2023

I am writing code that uses these schema and would like to create automation that checks all published schema are supported. To do this I need to be able to dynamically get a list of all published schema.

Ideally, I would be able to make a request to the opentelemetry.io website and get an index of all published schema and their URLs.

Does this already exist, or is it something that would need to be added?

@svrnm
Copy link
Member

svrnm commented Sep 12, 2023

That's something that would need to be added. Question is, if this should be done via the opentelemetry website or if it should come from https://github.com/open-telemetry/semantic-conventions/, because as of today the schemas are loaded via a submodule from there

Any suggestions, @chalin ?

@svrnm svrnm added sig:spec enhancement New feature or request labels Sep 12, 2023
@chalin
Copy link
Contributor

chalin commented Oct 17, 2023

Hi @MrAlias, I'm back from vacation now.

I'd like to better understand your needs and what you are trying to achieve. First a question ...

would like to create automation that checks all published schema are supported

Wasn't there such a check in the OTel spec repo at one point? Is it that check that you are trying to rework?

@MrAlias
Copy link
Contributor Author

MrAlias commented Oct 17, 2023

I'm writing a translation utility for resource attributes based on OTel schema. My needs have changed slightly as it has been developed, and now I need to ensure that I have the latest schema published. It would be ideal if there was some query I can make to get the "latest" schema.

@svrnm
Copy link
Member

svrnm commented Oct 17, 2023

@MrAlias would it help if https://opentelemetry.io/schemas/latest points to the latest schema via a redirect? So you hit that URL and it gives a 302 and a Location?

@MrAlias
Copy link
Contributor Author

MrAlias commented Oct 17, 2023

Yeah, that would be great!

@svrnm
Copy link
Member

svrnm commented Oct 18, 2023

@chalin is this something we can do with hugo easily?

@chalin
Copy link
Contributor

chalin commented Oct 19, 2023

@open-telemetry/specs-semconv-maintainers @jsuereth: can we safely assume that the latest release of semconv (https://github.com/open-telemetry/semantic-conventions/releases/latest) for tag X.Y.Z can generally be assumed to mean that X.Y.Z is the latest schema? (I'm asking because, at some point in the recent past, we published schema 1.21.0 on the website when we shouldn't have.)

If so then yes, @svrnm and @MrAlias, I can add something to the auto-version update process to also create a redirect rule for https://opentelemetry.io/schemas/latest to be mapped to X.Y.Z, the latest semconv release.

Thoughts?

@chalin
Copy link
Contributor

chalin commented Nov 1, 2023

Actually, used another strategy, see:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request sig:spec
Projects
None yet
3 participants