-
Notifications
You must be signed in to change notification settings - Fork 8
Description
The specification doesn't specify which Documents/frames in a crashed process actually send reports. Specifically, nothing is said about how many or which frames belonging to a particular origin actually send crash reports, if there are multiple same-origin frames in the crashing process.
There are various options available to us here:
- Send reports for literally every Document hosted in the crashed process
- Send reports for main frames and any iframe that is cross-origin with its parent
- For
A->B->A
nesting cases, this would send two reports for origin A: one for each frame in the crashing process - This could conceivably be valuable if the grandparent
A
and grandchildA
were intentionally served with two different reporting endpoints
- For
- Send reports for only the highest-level frame in the tree for a particular origin. In the
A->B->A
case, we'd only send one report for origin A: the main frame's report.
As of right now, there's not very much context data attached to each crash report, so whether we send a single report or multiple ones doesn't really matter, since the report data itself doesn't change very much.
But as crash reports get more and more context data, the issue of scoping/coalescing/sending matters more and more. This is particularly relevant in light of:
is_top_level
: Additional signal: is_top_level #20, Addis_top_level
andpage_visibility
bits #23visibility_state
: Adding support for additional context / dimensions in the crash report #14 (comment)- A new key-value storage API to associate arbitrary data with crash reports: Expose a JS API to programmatically add additional client context #15
As all of the above proposals get incubated, context data that might be relevant to a specific document can make its way into a crash report, so tightening things up in the specification will help with developer predictability so they know which frames are actually responsible for sending their state along with crash reports.
Proposal
Regarding the three options I enumerated above, my vote would be for option #3, which seems like a good tradeoff for predictability and lack of redundancy. Chromium is kind of documented to do #2, but actually does #3 in practice, which I think seems reasonable. But discussing this more regardless makes sense.