beam-telemetry / telemetry

Dynamic dispatching library for metrics and instrumentations.
https://hexdocs.pm/telemetry
Apache License 2.0
872 stars 66 forks source link

Update documentation for span/3 #101

Closed stefanchrobot closed 2 years ago

stefanchrobot commented 2 years ago

It wasn't really clear to me how SpanFunction works.

stefanchrobot commented 2 years ago
%% When providing `StartMetadata' and `StopMetadata', these values will be sent independently to `start' and
%% `stop' events. If an exception occurs, exception metadata will be merged onto the `StartMetadata'. In general,
%% `StopMetadata' should only provide values that are additive to `StartMetadata' so that handlers, such as those
%% used for metrics, can rely entirely on the `stop' event.

This section is unclear to me. Can this be reworded into "stop metadata should be a superset of start metadata"?

stefanchrobot commented 2 years ago

@josevalim sorry for the trouble, pushed a minor reword.

stefanchrobot commented 2 years ago

@josevalim can you please have another look?

josevalim commented 2 years ago

:green_heart: :blue_heart: :purple_heart: :yellow_heart: :heart: