Closed Bug 1214867 Opened 4 years ago Closed 4 years ago

Expose HeapSnapshots' creation timestamp to JS

Categories

(DevTools :: Memory, defect)

defect
Not set

Tracking

(firefox44 fixed)

RESOLVED FIXED
Firefox 44
Tracking Status
firefox44 --- fixed

People

(Reporter: fitzgen, Assigned: fitzgen)

References

(Blocks 1 open bug)

Details

Attachments

(1 file, 3 obsolete files)

We serialize, deserialize, and store the heap snapshot's creation timestamp, but don't expose it to JS. Just a small oversight.
Attachment #8674591 - Flags: review?(bobbyholley)
Comment on attachment 8674591 [details] [diff] [review]
Add HeapSnapshot.prototype.creationTimeStamp

Review of attachment 8674591 [details] [diff] [review]:
-----------------------------------------------------------------

::: dom/webidl/HeapSnapshot.webidl
@@ +11,5 @@
>  interface HeapSnapshot {
>    /**
> +   * A time stamp of when the heap snapshot was taken, if available.
> +   */
> +  readonly attribute Date? creationTimeStamp;

I'd call this creationTime.
Attachment #8674591 - Flags: review?(bobbyholley) → review+
As per https://www.w3.org/Bugs/Public/show_bug.cgi?id=22824 and https://groups.google.com/d/msg/mozilla.dev.platform/TiE00xh6Ihg/CnCIJFS8BAAJ, I'm going to return the microseconds (not milliseconds) since the epoch directly rather than a Date object.

Let me know if you feel strongly otherwise, Bobby, or if you feel strongly that we should return milliseconds rather than microseconds.
Attachment #8674591 - Attachment is obsolete: true
backedout for test failures like https://treeherder.mozilla.org/logviewer.html#?job_id=5195817&repo=fx-team
Flags: needinfo?(nfitzgerald)
Attachment #8674928 - Attachment is obsolete: true
Attachment #8675804 - Attachment is obsolete: true
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/64404fe72e3b
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 44
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.