The current spec for adding events to a Span specifies that "Events have a time associated with the moment when they are added to the Span."
However, in order support tracing use cases in the browser, I would like to modify this to say something like "Events have a time associated with when they occurred. By default this is the moment they were added to the span, but implementations may allow an optional argument for the time when the event occurred."
The use case for web tracing is that there are some events that are measure by the browser and accessible in the Performance Timing API, and so we would like to be able to make those events become timed events on a span, but with the time stamp of when the event actually occurred as measured by the browser rather than the time when the event is being attached to the span (which for the initial page load could be a long time after). See https://github.com/census-instrumentation/opencensus-web#span-annotations-for-dom-and-network-events
This is along the lines of the RFC by @bg451 to remove SpanData in favor of allowing time stamps to be specified when starting/ending a span
The current spec for adding events to a Span specifies that "Events have a time associated with the moment when they are added to the Span."
However, in order support tracing use cases in the browser, I would like to modify this to say something like "Events have a time associated with when they occurred. By default this is the moment they were added to the span, but implementations may allow an optional argument for the time when the event occurred."
The use case for web tracing is that there are some events that are measure by the browser and accessible in the Performance Timing API, and so we would like to be able to make those events become timed events on a span, but with the time stamp of when the event actually occurred as measured by the browser rather than the time when the event is being attached to the span (which for the initial page load could be a long time after). See https://github.com/census-instrumentation/opencensus-web#span-annotations-for-dom-and-network-events
This is along the lines of the RFC by @bg451 to remove SpanData in favor of allowing time stamps to be specified when starting/ending a span