We didn't have explicit test coverage of this before, surprisingly.
MozReview-Commit-ID: 32ZnxZYLXDg
--HG--
extra : rebase_source : 07110ed90b69c5b0fb73fda8264db2eb755ca6a4
A run_test() calling run_next_test() is optional in xpcshell tests as
of a9738e5f636a (bug 982852).
MozReview-Commit-ID: DT3sfm6JcAG
--HG--
extra : rebase_source : f3c7c19df8b283e6360fd6975c421a004d26c8ef
This allows us to track how often EME CDMs are used, rather than just created.
The telemetry I added in bug 1304207 is reports whenever a CDM is created, but
some sites, such as the Shaka Player demo site, create CDMs without using them,
so that telemetry isn't a great measure in helping us detect when CDMs aren't
being used. Whereas the telemetry added here will report when the CDMs are used
to negotiate a license, i.e. when the CDMs are actually being used.
MozReview-Commit-ID: ExMIcIIBvS1
--HG--
extra : rebase_source : 61c3e965dbc3a59714231e9f454f2aa7518db7f2
We've now seen an OOM trying to grow the accumulations array during a test
suite. The g*Accumulations arrays do grow unboundedly in size waiting for the
IPC timer to fire, so we should put a size bound as well as a time bound to
trigger the batch send.
The current size bound is 5K elements. This was chosen out of a hat.
MozReview-Commit-ID: 5HeWdbLfN03
We're seeing occasional failures of the isValid assert on the parent side where
the ID we're being asked to accumulate on is invalid.
Check the IDs on both sides to ensure that they're valid heading in.
MozReview-Commit-ID: 4gLG54Tx64s
nsTimer fires on the thread that created the timer. An nsTimer instance should
only be manipulated on its target thread (it isn't threadsafe). IPC using
PContent must be on the main thread.
Thus, everything to do with the gIPCTimer must be on the main thread.
This also takes care of bug 1299312.
MozReview-Commit-ID: IcVRYsoX2R9
Throw some process selectors in the Histograms and Keyed Histograms sections
to allow users to choose which process type's histograms they'd like to see.
Rewrite the categorical histogram accumulation code to use the common path.
This way it gets remote accumulation for cheap.
MozReview-Commit-ID: 3q6gdSvBix
I saw a one-off crash on try in internal_GetHistogramByEnumId. Not reproducible
but maybe possible if we're trying to accumulate using an invalid ID. So let's
guard against that.
MozReview-Commit-ID: Ei6eTlV91mJ
On content process shutdown we send a content process ping to ensure we have
up-to-date data from the content process before it goes away. Now we need to
also flush the batched telemetry accumulations to the parent so that it can be
present in the ping.
No attempt is made to synchronize access to IPCTimerFired. It is safe to
re-enter.
No attempt is made to cancel the timer as its firing is benign.
MozReview-Commit-ID: 1gjNH9IPhKf