Bug 1730186 - Remove about:telemetry's 'Captured Stacks' section r=janerik
authorChris H-C <chutten@mozilla.com>
Fri, 14 Jan 2022 18:54:11 +0000
changeset 604596 b560976e8b048275474f78f50163348bca737689
parent 604595 1b4bb9f435b1378837566ab92461b72df7796486
child 604597 51c111ad6373a87ac962e02bf1f0084c60db04a9
push id39152
push userabutkovits@mozilla.com
push dateSat, 15 Jan 2022 09:45:36 +0000
treeherdermozilla-central@60998033086a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjanerik
bugs1730186
milestone98.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1730186 - Remove about:telemetry's 'Captured Stacks' section r=janerik Captured Stacks were removed, oh, ages ago. Also, while we're here, point at the new symbolication server. Differential Revision: https://phabricator.services.mozilla.com/D135741
toolkit/content/aboutTelemetry.js
toolkit/content/aboutTelemetry.xhtml
toolkit/locales/en-US/toolkit/about/aboutTelemetry.ftl
--- a/toolkit/content/aboutTelemetry.js
+++ b/toolkit/content/aboutTelemetry.js
@@ -42,17 +42,18 @@ const brandBundle = Services.strings.cre
 
 // Maximum height of a histogram bar (in em for html, in chars for text)
 const MAX_BAR_HEIGHT = 8;
 const MAX_BAR_CHARS = 25;
 const PREF_TELEMETRY_SERVER_OWNER = "toolkit.telemetry.server_owner";
 const PREF_TELEMETRY_ENABLED = "toolkit.telemetry.enabled";
 const PREF_DEBUG_SLOW_SQL = "toolkit.telemetry.debugSlowSql";
 const PREF_SYMBOL_SERVER_URI = "profiler.symbolicationUrl";
-const DEFAULT_SYMBOL_SERVER_URI = "https://symbols.mozilla.org/symbolicate/v4";
+const DEFAULT_SYMBOL_SERVER_URI =
+  "https://symbolication.services.mozilla.com/symbolicate/v4";
 const PREF_FHR_UPLOAD_ENABLED = "datareporting.healthreport.uploadEnabled";
 
 // ms idle before applying the filter (allow uninterrupted typing)
 const FILTER_IDLE_TIMEOUT = 500;
 
 const isWindows = Services.appinfo.OS == "WINNT";
 const EOL = isWindows ? "\r\n" : "\n";
 
@@ -1054,51 +1055,16 @@ SymbolicationRequest.prototype.fetchSymb
   this.symbolRequest.open("POST", symbolServerURI, true);
   this.symbolRequest.setRequestHeader("Content-type", "application/json");
   this.symbolRequest.setRequestHeader("Content-length", requestJSON.length);
   this.symbolRequest.setRequestHeader("Connection", "close");
   this.symbolRequest.onreadystatechange = this.handleSymbolResponse.bind(this);
   this.symbolRequest.send(requestJSON);
 };
 
-var CapturedStacks = {
-  symbolRequest: null,
-
-  render: function CapturedStacks_render(payload) {
-    // Retrieve captured stacks from telemetry payload.
-    let capturedStacks =
-      "processes" in payload && "parent" in payload.processes
-        ? payload.processes.parent.capturedStacks
-        : false;
-    let hasData =
-      capturedStacks && capturedStacks.stacks && !!capturedStacks.stacks.length;
-    setHasData("captured-stacks-section", hasData);
-    if (!hasData) {
-      return;
-    }
-
-    let stacks = capturedStacks.stacks;
-    let memoryMap = capturedStacks.memoryMap;
-    let captures = capturedStacks.captures;
-
-    StackRenderer.renderStacks("captured-stacks", stacks, memoryMap, index =>
-      this.renderCaptureHeader(index, captures)
-    );
-  },
-
-  renderCaptureHeader: function CaptureStacks_renderCaptureHeader(
-    index,
-    captures
-  ) {
-    let key = captures[index][0];
-    let cardinality = captures[index][2];
-    StackRenderer.renderHeader("captured-stacks", [key, cardinality]);
-  },
-};
-
 var Histogram = {
   /**
    * Renders a single Telemetry histogram
    *
    * @param aParent Parent element
    * @param aName Histogram name
    * @param aHgram Histogram information
    * @param aOptions Object with render options
@@ -2260,41 +2226,16 @@ function setupListeners() {
       show(e.target);
     }
   });
 
   let search = document.getElementById("search");
   search.addEventListener("input", Search.searchHandler);
 
   document
-    .getElementById("captured-stacks-fetch-symbols")
-    .addEventListener("click", function() {
-      if (!gPingData) {
-        return;
-      }
-      let capturedStacks = gPingData.payload.processes.parent.capturedStacks;
-      let req = new SymbolicationRequest(
-        "captured-stacks",
-        CapturedStacks.renderCaptureHeader,
-        capturedStacks.memoryMap,
-        capturedStacks.stacks,
-        capturedStacks.captures
-      );
-      req.fetchSymbols();
-    });
-
-  document
-    .getElementById("captured-stacks-hide-symbols")
-    .addEventListener("click", function() {
-      if (gPingData) {
-        CapturedStacks.render(gPingData.payload);
-      }
-    });
-
-  document
     .getElementById("late-writes-fetch-symbols")
     .addEventListener("click", function() {
       if (!gPingData) {
         return;
       }
 
       let lateWrites = gPingData.payload.lateWrites;
       let req = new SymbolicationRequest(
@@ -2696,19 +2637,16 @@ function displayRichPingData(ping, updat
   HistogramSection.render(payload);
 
   // Show keyed histogram data
   KeyedHistogramSection.render(payload);
 
   // Show event data.
   Events.render(payload);
 
-  // Show captured stacks.
-  CapturedStacks.render(payload);
-
   LateWritesSingleton.renderLateWrites(payload.lateWrites);
 
   // Show origin telemetry.
   Origins.render(payload.origins);
 
   // Show simple measurements
   SimpleMeasurements.render(payload);
 }
--- a/toolkit/content/aboutTelemetry.xhtml
+++ b/toolkit/content/aboutTelemetry.xhtml
@@ -61,19 +61,16 @@
         <span class="category-name" data-l10n-id="about-telemetry-simple-measurements-section"></span>
       </div>
       <div class="category category-no-icon" value="slow-sql-section">
         <span class="category-name" data-l10n-id="about-telemetry-slow-sql-section"></span>
       </div>
       <div class="category category-no-icon" value="addon-details-section">
         <span class="category-name" data-l10n-id="about-telemetry-addon-details-section"></span>
       </div>
-      <div class="category category-no-icon" value="captured-stacks-section">
-        <span class="category-name" data-l10n-id="about-telemetry-captured-stacks-section"></span>
-      </div>
       <div class="category category-no-icon" value="late-writes-section">
         <span class="category-name" data-l10n-id="about-telemetry-late-writes-section"></span>
       </div>
       <div class="category category-no-icon" value="origin-telemetry-section">
         <span class="category-name" data-l10n-id="about-telemetry-origin-section"></span>
       </div>
       <div class="category category-no-icon has-data" value="raw-payload-section">
         <span class="category-name" data-l10n-id="about-telemetry-raw-payload-section"></span>
@@ -205,19 +202,13 @@
           <a data-l10n-name="prio-blog-link" href="https://hacks.mozilla.org/2018/10/testing-privacy-preserving-telemetry-with-prio/"></a>
         </div>
         <div id="origins" class="data"></div>
       </section>
 
       <section id="addon-details-section">
         <div id="addon-details" class="data"></div>
       </section>
-
-      <section id="captured-stacks-section">
-        <a id="captured-stacks-fetch-symbols" href="" data-l10n-id="about-telemetry-fetch-stack-symbols"></a>
-        <a id="captured-stacks-hide-symbols" href="" data-l10n-id="about-telemetry-hide-stack-symbols"></a>
-        <div id="captured-stacks" class="data"></div>
-      </section>
     </div>
 
   </body>
 
 </html>
--- a/toolkit/locales/en-US/toolkit/about/aboutTelemetry.ftl
+++ b/toolkit/locales/en-US/toolkit/about/aboutTelemetry.ftl
@@ -29,17 +29,16 @@ about-telemetry-session-info-section = S
 about-telemetry-scalar-section = Scalars
 about-telemetry-keyed-scalar-section = Keyed Scalars
 about-telemetry-histograms-section = Histograms
 about-telemetry-keyed-histogram-section = Keyed Histograms
 about-telemetry-events-section = Events
 about-telemetry-simple-measurements-section = Simple Measurements
 about-telemetry-slow-sql-section = Slow SQL Statements
 about-telemetry-addon-details-section = Add-on Details
-about-telemetry-captured-stacks-section = Captured Stacks
 about-telemetry-late-writes-section = Late Writes
 about-telemetry-raw-payload-section = Raw Payload
 about-telemetry-raw = Raw JSON
 about-telemetry-full-sql-warning = NOTE: Slow SQL debugging is enabled. Full SQL strings may be displayed below but they will not be submitted to Telemetry.
 about-telemetry-fetch-stack-symbols = Fetch function names for stacks
 about-telemetry-hide-stack-symbols = Show raw stack data
 # Selects the correct release version
 # Variables:
@@ -117,20 +116,16 @@ about-telemetry-addon-table-id = Add-on 
 about-telemetry-addon-table-details = Details
 # Variables:
 #   $addonProvider (String): the name of an Add-on Provider (e.g. “XPI”, “Plugin”)
 about-telemetry-addon-provider = { $addonProvider } Provider
 about-telemetry-keys-header = Property
 about-telemetry-names-header = Name
 about-telemetry-values-header = Value
 # Variables:
-#   $stackKey (String): the string key for this stack
-#   $capturedStacksCount (Integer):  the number of times this stack was captured
-about-telemetry-captured-stacks-title = { $stackKey } (capture count: { $capturedStacksCount })
-# Variables:
 #   $lateWriteCount (Integer): the number of the late writes
 about-telemetry-late-writes-title = Late Write #{ $lateWriteCount }
 about-telemetry-stack-title = Stack:
 about-telemetry-memory-map-title = Memory map:
 about-telemetry-error-fetching-symbols = An error occurred while fetching symbols. Check that you are connected to the Internet and try again.
 about-telemetry-time-stamp-header = timestamp
 about-telemetry-category-header = category
 about-telemetry-method-header = method