Bug 790732 - Components shim telemetry. r=mrbkap

This commit is contained in:
Bobby Holley 2013-03-27 18:27:27 -07:00
parent 939fedeaee
commit f29e69ac81
2 changed files with 7 additions and 0 deletions

View File

@ -5183,6 +5183,9 @@ const InterfaceShimEntry kInterfaceShimMap[] =
static nsresult
DefineComponentsShim(JSContext *cx, JS::HandleObject global)
{
// Keep track of how often this happens.
Telemetry::Accumulate(Telemetry::COMPONENTS_SHIM_ACCESSED_BY_CONTENT, true);
// Create a fake Components object.
JSObject *components = JS_NewObject(cx, nullptr, nullptr, global);
NS_ENSURE_TRUE(components, NS_ERROR_OUT_OF_MEMORY);

View File

@ -2906,6 +2906,10 @@
"kind": "flag",
"description": "Whether content ever accesed Components.interfaces in this session"
},
"COMPONENTS_SHIM_ACCESSED_BY_CONTENT": {
"kind": "flag",
"description": "Whether content ever accesed the Components shim in this session"
},
"CHECK_ADDONS_MODIFIED_MS": {
"kind": "exponential",
"high": "5000",