Closed bripkens closed 7 years ago
PerformanceServerTiming inherits from PerformanceEntry, which is the base for all the metrics we expose via PerformanceTimeline. So, yes, it has to be a DOMHighResTimestamp.
That said, you don't have to provide the duration and can focus on name+description. See example here: http://wicg.github.io/server-timing/#examples
Okay, so it is called duration
for compatibility reasons. Thanks for explaining @igrigorik!
Is it intended that all metric values have to be timestamps? I am confused right now about the scope of this specification as the header is described as defining generic metric key/value pairs. The
PerformanceServerTiming
interface, on the other hand, is limiting values to explicitly beDOMHighResTimeStamp
s (which basically meansdouble
s, which should be fine). Additionally, the field is called duration.I'd expect the
duration
field to be calledvalue
and for it to be typeddouble
to make it clearer that this is about any type of metric.