From 9afa07b4ef104d952cb7adc296f79402728c54fa Mon Sep 17 00:00:00 2001 From: Sean Feng Date: Tue, 10 Mar 2020 15:39:34 +0000 Subject: [PATCH] Bug 1620669 - Separate CONTAINS_REMOTE_SUBFRAMES to its own label in BFCACHE_COMBO telemetry r=nika Differential Revision: https://phabricator.services.mozilla.com/D65792 --HG-- extra : moz-landing-system : lando --- docshell/base/nsDocShell.cpp | 4 ++++ docshell/base/nsDocShell.h | 1 + toolkit/components/telemetry/Histograms.json | 1 + 3 files changed, 6 insertions(+) diff --git a/docshell/base/nsDocShell.cpp b/docshell/base/nsDocShell.cpp index 22a486ce3bfb..616dc006f203 100644 --- a/docshell/base/nsDocShell.cpp +++ b/docshell/base/nsDocShell.cpp @@ -6770,6 +6770,10 @@ void nsDocShell::ReportBFCacheComboTelemetry(uint16_t aCombo) { Telemetry::AccumulateCategorical( Telemetry::LABELS_BFCACHE_COMBO::SPD_Unload_Req_Peer); break; + case REMOTE_SUBFRAMES: + Telemetry::AccumulateCategorical( + Telemetry::LABELS_BFCACHE_COMBO::Remote_Subframes); + break; default: Telemetry::AccumulateCategorical(Telemetry::LABELS_BFCACHE_COMBO::Other); break; diff --git a/docshell/base/nsDocShell.h b/docshell/base/nsDocShell.h index 92498fe20d02..baa1acc2f388 100644 --- a/docshell/base/nsDocShell.h +++ b/docshell/base/nsDocShell.h @@ -907,6 +907,7 @@ class nsDocShell final : public nsDocLoader, mozilla::dom::BFCacheStatus::UNLOAD_LISTENER | mozilla::dom::BFCacheStatus::REQUEST | mozilla::dom::BFCacheStatus::ACTIVE_PEER_CONNECTION, + REMOTE_SUBFRAMES = mozilla::dom::BFCacheStatus::CONTAINS_REMOTE_SUBFRAMES }; void ReportBFCacheComboTelemetry(uint16_t aCombo); diff --git a/toolkit/components/telemetry/Histograms.json b/toolkit/components/telemetry/Histograms.json index 77a48da92462..2ac3337d9be3 100644 --- a/toolkit/components/telemetry/Histograms.json +++ b/toolkit/components/telemetry/Histograms.json @@ -14535,6 +14535,7 @@ "Unload_Req_Peer_MSE", "Unload_Req_MSE", "SPD_Unload_Req_Peer", + "Remote_Subframes", "Other" ], "description": "The common combinations of BFCacheStatus when we determine whether the page can be BFCached or not; If it's BFCached, we record BFCache_Success; Success_Not_Toplevel represents the number of not the only top level document in BrowsingContextGroup's documents that are BFCached, and BFCache_Success includes Success_Not_Toplevel; If it's not and it falls under common failure reasons combinations, we record the corresponding combination; Otherwise, we record Other to indicate this is not a common failure"