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

Clarify warning & fix line number #109

Merged
merged 2 commits into from
Jul 27, 2022

Conversation

CleanCut
Copy link
Contributor

#107 established that this warning is intended to advise users to set the type for a group. This PR is to:

  • Clarify the message, including a link to the documentation for the type.
  • Fix the line number (previously the line number was always 5)

From syntax.md...

  • type, optional enum, defaults to span (with a warning if not present).

I would love to add some language to this ☝🏻 section of the syntax.md document, further explaining what a group's type field means. Unfortunately, I don't know what it means. Could anyone suggest some further explanation?

@CleanCut
Copy link
Contributor Author

CleanCut commented Jul 25, 2022

Before:

Using default SPAN type for semantic convention 'browser' @ line 5
Using default SPAN type for semantic convention 'cloud' @ line 5
Using default SPAN type for semantic convention 'aws.ecs' @ line 5
Using default SPAN type for semantic convention 'aws.eks' @ line 5
Using default SPAN type for semantic convention 'aws.log' @ line 5
Using default SPAN type for semantic convention 'container' @ line 5
Using default SPAN type for semantic convention 'deployment' @ line 5
Using default SPAN type for semantic convention 'device' @ line 5
Using default SPAN type for semantic convention 'faas_resource' @ line 5
Using default SPAN type for semantic convention 'host' @ line 5
Using default SPAN type for semantic convention 'k8s.cluster' @ line 5
Using default SPAN type for semantic convention 'k8s.node' @ line 5
Using default SPAN type for semantic convention 'k8s.namespace' @ line 5
Using default SPAN type for semantic convention 'k8s.pod' @ line 5
Using default SPAN type for semantic convention 'k8s.container' @ line 5
Using default SPAN type for semantic convention 'k8s.replicaset' @ line 5
Using default SPAN type for semantic convention 'k8s.deployment' @ line 5
Using default SPAN type for semantic convention 'k8s.statefulset' @ line 5
Using default SPAN type for semantic convention 'k8s.daemonset' @ line 5
Using default SPAN type for semantic convention 'k8s.job' @ line 5
Using default SPAN type for semantic convention 'k8s.cronjob' @ line 5
Using default SPAN type for semantic convention 'os' @ line 5
Using default SPAN type for semantic convention 'process' @ line 5
Using default SPAN type for semantic convention 'process.runtime' @ line 5
Using default SPAN type for semantic convention 'service' @ line 5
Using default SPAN type for semantic convention 'telemetry' @ line 5
Using default SPAN type for semantic convention 'webengine_resource' @ line 5

After:

Please set the type for group 'browser' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'cloud' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'aws.ecs' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'aws.eks' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'aws.log' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'container' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'deployment' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'device' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'faas_resource' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'host' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.cluster' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.node' on line 13 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.namespace' on line 29 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.pod' on line 40 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.container' on line 56 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.replicaset' on line 76 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.deployment' on line 92 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.statefulset' on line 108 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.daemonset' on line 124 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.job' on line 140 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'k8s.cronjob' on line 156 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'os' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'process' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'process.runtime' on line 73 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'service' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'telemetry' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups
Please set the type for group 'webengine_resource' on line 2 - defaulting to type 'span'. See https://github.com/open-telemetry/build-tools/blob/main/semantic-conventions/syntax.md#groups

Copy link
Member

@Oberon00 Oberon00 left a comment

Choose a reason for hiding this comment

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

I think you know the meaning of the type, since you suggested the correct types in the semantic conventions.
There are also some technical consequences since certain fields can only be set for certain types, e.g. name can only be set for type: event.

@arminru arminru merged commit 850a2b0 into open-telemetry:main Jul 27, 2022
@arminru arminru mentioned this pull request Jul 27, 2022
@CleanCut CleanCut deleted the clarify-warning branch July 27, 2022 17:29
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.

3 participants