RE: [UserTiming] Spec review

Thanks for taking the time to provide feedback to this spec. I have responded to the issues you raised below.


> need links to and tests for general exceptions

WebIDL should cover the general cases.


> mark, measure method
> - why doesn't this return the timing information being stored, it might be of immediate interest?

To reduce confusion and for simplicity, we have one set of methods for profiling and another set of methods for retrieving the data.


> Why are we throwing syntax errors on measure if a calculation in the measure method is negative, or a value is 0? 

I agree that we should not be throwing syntax errors in either case. Just because a measure between two marks is negative, doesn't make that measure invalid. 

I have updated the spec to remove the two syntax errors raised by the measure() method when the duration is negative or the startMark or endMark argument's are zero valued.


> I am not convinced that throwing at all in those cases is optimal...
>Would a better way be to always store e.g. "-1" in those cases...

As the DOMHighResTimeStamp is a double, a "-1" value would indicate that the time value is 1 millisecond prior to the start of navigation of the page. Further, raising an error may help the developer catch this issue earlier rather than waiting to get "bad" data from analytics later on. Seeing that errors and exceptions were designed to catch these kinds of issues, I'm inclined to keep the current model.


> Privacy
> =======
> The text is hard to understand, and can do with a rewrite. Who is to ensure the information is only 
> available to the server, does this mean javascript cannot send it off to another server for analysis there? 

I have re-written the privacy and security section. Per conversation in last week's conference call, I have also introduced the Timing-Allow-Origin http response header concept in this specification. 


> Wording improvements
> ====================
> "If both the startMark and endMark arguments are not" => "If neither ...  nor ... is"

Fixed.


> Vendor prefixes and monotonic clock - uses slightly different language and markup than other specs.

Fixed.

Thanks,
Jatinder

Received on Wednesday, 28 March 2012 01:06:36 UTC