910e62b5创建于 1月15日历史提交
<!--
Copyright 2024 The Chromium Authors
Use of this source code is governed by a BSD-style license that can be
found in the LICENSE file.
-->

<!--
This file is used to generate a comprehensive list of magic stack histograms
along with a detailed description for each histogram.

For best practices on writing histogram descriptions, see
https://chromium.googlesource.com/chromium/src.git/+/HEAD/tools/metrics/histograms/README.md

Please follow the instructions in the OWNERS file in this directory to find a
reviewer. If no OWNERS file exists, please consider signing up at
go/reviewing-metrics (Googlers only), as all subdirectories are expected to
have an OWNERS file. As a last resort you can send the CL to
chromium-metrics-reviews@google.com.
-->

<histogram-configuration>

<histograms>

<variants name="HostSurfaceState">
  <variant name="Regular"/>
  <variant name="Startup"/>
</variants>

<variants name="ModuleType">
  <variant name="AuxiliarySearch"/>
  <variant name="DefaultBrowserPromo"/>
  <variant name="HistorySyncPromo"/>
  <variant name="PriceChange"/>
  <variant name="QuickDeletePromo"/>
  <variant name="SafetyHub"/>
  <variant name="SingleTab"/>
  <variant name="TabGroupPromo"/>
  <variant name="TabGroupSyncPromo"/>
  <variant name="TabResumption"/>
  <variant name="TipsNotificationsPromo"/>
</variants>

<variants name="ScrollState">
  <variant name="NotScrolled"/>
  <variant name="Scrolled"/>
</variants>

<variants name="ToggleState">
  <variant name="TurnOffModule"/>
  <variant name="TurnOnModule"/>
</variants>

<histogram name="MagicStack.Clank.NewTabPage.ContextMenu.OpenCustomizeSettings"
    enum="ModuleType" expires_after="2026-03-29">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Record the total count that the context menu item to open customize settings
    is clicked. The histogram is logged on a NewTabPage and is logged
    Android-only.
  </summary>
</histogram>

<histogram name="MagicStack.Clank.NewTabPage.ContextMenu.RemoveModuleV2"
    enum="ModuleType" expires_after="2026-03-29">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Record the total count that the context menu item to remove a module is
    clicked. The histogram is logged on a NewTabPage and is logged Android-only.
  </summary>
</histogram>

<histogram name="MagicStack.Clank.NewTabPage.ContextMenu.ShownV2"
    enum="ModuleType" expires_after="2026-03-29">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Record the total count of times that the context menu of a module is shown
    on the magic stack of a NewTabPage. The histogram is logged on Android-only.
  </summary>
</histogram>

<histogram name="MagicStack.Clank.NewTabPage.Module.Click" enum="ModuleType"
    expires_after="2026-03-29">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Record the total count of clicks on different modules of the magic stack on
    the NewTabPage. The histogram is logged every time when a module is clicked,
    Android-only.
  </summary>
</histogram>

<histogram
    name="MagicStack.Clank.NewTabPage.Module.FetchDataDurationMs.{ModuleType}"
    units="ms" expires_after="2026-03-29">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the duration from building a module to the time when the module
    returns a successful fetching data response. The histogram is logged when
    showing the magic stack on NewTabPage, Android-only.
  </summary>
  <token key="ModuleType" variants="ModuleType"/>
</histogram>

<histogram
    name="MagicStack.Clank.NewTabPage.Module.FetchDataFailedDurationMs.{ModuleType}"
    units="ms" expires_after="2026-05-26">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the duration from building a module to the time when the module
    returns a response of no data to show. The histogram is logged when showing
    the magic stack on NewTabPage, Android-only.
  </summary>
  <token key="ModuleType" variants="ModuleType"/>
</histogram>

<histogram
    name="MagicStack.Clank.NewTabPage.Module.FetchDataTimeoutDurationMs.{ModuleType}"
    units="ms" expires_after="2026-05-26">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the duration from building a module to the time when it returns a
    response after timeout. The histogram is logged when showing the magic stack
    on NewTabPage, Android-only.
  </summary>
  <token key="ModuleType" variants="ModuleType"/>
</histogram>

<histogram name="MagicStack.Clank.NewTabPage.Module.FetchDataTimeoutTypeV2"
    enum="ModuleType" expires_after="2026-05-26">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the types of modules which didn't respond before the timer timeout.
    The histogram is logged when showing the magic stack on NewTabPage,
    Android-only.
  </summary>
</histogram>

<histogram name="MagicStack.Clank.NewTabPage.Module.FirstModuleShownDurationMs"
    units="ms" expires_after="2026-04-12">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the duration from building the first module to the time when the
    recyclerview becomes visible, i.e., the first highest ranking module returns
    valid data. The histogram is logged when showing the magic stack on
    NewTabPage, Android-only.
  </summary>
</histogram>

<histogram name="MagicStack.Clank.NewTabPage.Module.ProfileReadyDelayMs"
    units="ms" expires_after="2026-05-26">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the time spent between triggering to show modules and fetch the
    module list when the profile is ready. The histogram is logged when showing
    the magic stack on NewTabPage, Android-only.
  </summary>
</histogram>

<histogram name="MagicStack.Clank.NewTabPage.Module.TopImpressionV2"
    enum="ModuleType" expires_after="2026-05-03">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Record the total count of times that a module is shown on the magic stack of
    a NewTabPage. The histogram is logged on Android-only.
  </summary>
</histogram>

<histogram name="MagicStack.Clank.NewTabPage.NotScrollable" units="count"
    expires_after="2026-05-26">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the total count of times that magic stack is not scrollable. The
    histogram is logged when showing the magic stack on NewTabPage,
    Android-only.
  </summary>
</histogram>

<histogram name="MagicStack.Clank.NewTabPage.Scrollable.{ScrollState}"
    units="count" expires_after="2026-05-26">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the total count of times that magic stack is scrollable and the
    number of times it has been scrolled or not. The histogram is logged when
    showing the magic stack on NewTabPage, Android-only.
  </summary>
  <token key="ScrollState" variants="ScrollState"/>
</histogram>

<histogram
    name="MagicStack.Clank.NewTabPage.Segmentation.FetchRankingResultsDurationMs"
    units="ms" expires_after="2026-04-26">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the duration from calling the segmentation API to fetch a ranking to
    the time when a response returns. The histogram is logged when showing the
    magic stack on NewTabPage, Android-only.
  </summary>
</histogram>

<histogram
    name="MagicStack.Clank.NewTabPage.{HostSurfaceState}.Module.{ModuleType}.Build"
    enum="ModulePosition" expires_after="2026-04-26">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the type and position of a module when it is added to the magic
    stack of a NewTabPage. {HostSurfaceState} indicates whether the histogram is
    logged at startup, or when the user opens a new Tab. Android-only.
  </summary>
  <token key="HostSurfaceState" variants="HostSurfaceState"/>
  <token key="ModuleType" variants="ModuleType"/>
</histogram>

<histogram
    name="MagicStack.Clank.NewTabPage.{HostSurfaceState}.Module.{ModuleType}.Click"
    enum="ModulePosition" expires_after="2026-04-26">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the type and position of a module when it is clicked by users on the
    magic stack of a NewTabPage. {HostSurfaceState} indicates whether the
    histogram is logged at startup, or when the user opens a new Tab.
    Android-only.
  </summary>
  <token key="HostSurfaceState" variants="HostSurfaceState"/>
  <token key="ModuleType" variants="ModuleType"/>
</histogram>

<histogram
    name="MagicStack.Clank.NewTabPage.{HostSurfaceState}.Module.{ModuleType}.Impression"
    enum="ModulePosition" expires_after="2026-04-12">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records the type and position of a module when it is visible to users on the
    magic stack of a NewTabPage. {HostSurfaceState} indicates whether the
    histogram is logged at startup, or when the user opens a new Tab. The
    histogram is logged on Android-only.
  </summary>
  <token key="HostSurfaceState" variants="HostSurfaceState"/>
  <token key="ModuleType" variants="ModuleType"/>
</histogram>

<histogram
    name="MagicStack.Clank.NewTabPage.{HostSurfaceState}.Module.{ModuleType}.ImpressionCountBeforeInteraction"
    units="count" expires_after="2026-04-12">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    This histogram is currently logged only for educational tip cards. It tracks
    the number of times a module has been shown before user interaction and is
    recorded when users interact with it on the magic stack of a NewTabPage.
    Once the user interacts with the card, the histogram is no longer logged.
    The {HostSurfaceState} specifies whether the histogram logs at startup or
    when a user opens a new tab. This histogram is exclusively logged on
    Android.
  </summary>
  <token key="HostSurfaceState" variants="HostSurfaceState"/>
  <token key="ModuleType" variants="ModuleType"/>
</histogram>

<histogram name="MagicStack.Clank.Settings.{ToggleState}" enum="ModuleType"
    expires_after="2026-03-01">
  <owner>hanxi@chromium.org</owner>
  <owner>xinyiji@chromium.org</owner>
  <summary>
    Records when a module is activated or deactivated in the configuration page
    of the magic stack. The resulting histogram, which is enumerated, tallies
    the total number of these actions across various module types. The histogram
    is logged whenever the state of a module is toggled in configuration page
    when the magic stack is customizable, Android-only.
  </summary>
  <token key="ToggleState" variants="ToggleState"/>
</histogram>

<histogram name="MagicStack.Clank.SingleTab.SeeMoreLinkClicked" enum="Boolean"
    expires_after="2026-05-26">
  <owner>hanxi@google.com</owner>
  <owner>huangs@google.com</owner>
  <summary>
    Records each time the Single Tab Card's &quot;See more&quot; link is
    clicked, Android-only.
  </summary>
</histogram>

</histograms>

</histogram-configuration>