Skip to content

Consider using go module paths for scope name in demos #5412

Closed
open-telemetry/opentelemetry.io
#4831
@dashpole

Description

Problem Statement

I noticed the rolldice example has a single-word name for the meter and tracer:

const name = "rolldice"
var (
tracer = otel.Tracer(name)
meter = otel.Meter(name)
logger = otelslog.NewLogger(name)

I haven't checked other examples, but IMO we should consider doing this across all of them.

Proposed Solution

Since many users will use this as a starting point for their code, would it make more sense to use a "real" scope name? E.g. go.opentelemetry.io/otel/example/dice?

Alternatives

Keep simpler names for samples

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions