<!--
Copyright 2020 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 Simple 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>

<histogram name="SimpleGeolocation.Provider.ClientId"
    enum="SimpleGeolocationClientId" expires_after="2027-02-07">
  <owner>alvinji@chromium.org</owner>
  <owner>deviceapi-team@google.com</owner>
  <summary>
    Records which client requested geolocation from the
    `SystemLocationProvider`. This helps track the usage of the geolocation
    provider across different parts of the system.
  </summary>
</histogram>

<histogram
    name="SimpleGeolocation.Provider.GeolocationControllerRequestInterval"
    units="hours" expires_after="2027-02-02">
  <owner>alvinji@chromium.org</owner>
  <owner>deviceapi-team@google.com</owner>
  <summary>
    Measures the frequency of geolocation requests from the
    GeolocationController by recording the interval between each request in
    hour-sized buckets, up to a maximum of 24 hours.
  </summary>
</histogram>

<histogram
    name="SimpleGeolocation.Provider.QueryGeolocationCommandRequestInterval"
    units="hours" expires_after="2026-12-07">
  <owner>poromov@chromium.org</owner>
  <owner>alvinji@chromium.org</owner>
  <owner>deviceapi-team@google.com</owner>
  <summary>
    Measures the frequency of geolocation requests from the QueryGeolocation
    remote command by recording the interval between each request in hour-sized
    buckets, up to a maximum of 24 hours. The first request after startup is not
    recorded. We don't remember time intervals across restart cycles.
  </summary>
</histogram>

<histogram name="SimpleGeolocation.Provider.TimezoneResolverRequestInterval"
    units="hours" expires_after="2027-02-14">
  <owner>alvinji@chromium.org</owner>
  <owner>deviceapi-team@google.com</owner>
  <summary>
    Measures the frequency of geolocation requests from the TimezoneResolver by
    recording the interval between each request in hour-sized buckets, up to a
    maximum of 24 hours.
  </summary>
</histogram>

<histogram name="SimpleGeolocation.Provider.WizardControllerRequestInterval"
    units="hours" expires_after="2026-11-24">
  <owner>alvinji@chromium.org</owner>
  <owner>deviceapi-team@google.com</owner>
  <summary>
    Measures the frequency of geolocation requests from the WizardController by
    recording the interval between each request in hour-sized buckets, up to a
    maximum of 24 hours.
  </summary>
</histogram>

<histogram name="SimpleGeolocation.Request.Event"
    enum="SimpleGeolocationRequestEvent" expires_after="never">
<!-- expires-never: This reports external location provider health status and
should be kept until we use this API.  -->

  <owner>alemate@chromium.org</owner>
  <owner>michaelpg@chromium.org</owner>
  <summary>Events in reqests processing of IP-based SimpleGeolocation.</summary>
</histogram>

<histogram name="SimpleGeolocation.Request.HasCellTowers"
    enum="SimpleGeolocationRequestHasCellTowers" expires_after="never">
<!-- expires-never: This reports external location provider health status and
should be kept until we use this API.  -->

  <owner>alemate@chromium.org</owner>
  <owner>michaelpg@chromium.org</owner>
  <owner>skylarc@chromium.org</owner>
  <summary>
    This boolean histogram counts SimpleGeolocationRequests carrying a nonzero
    number of cell towers.
  </summary>
</histogram>

<histogram name="SimpleGeolocation.Request.HasWiFiAccessPoints"
    enum="SimpleGeolocationRequestHasWiFiAccessPoints" expires_after="never">
<!-- expires-never: This reports external location provider health status and
should be kept until we use this API.  -->

  <owner>alemate@chromium.org</owner>
  <owner>michaelpg@chromium.org</owner>
  <summary>
    This boolean histogram counts SimpleGeolocationRequests carrying nonzero
    number of WiFi access points.
  </summary>
</histogram>

<histogram name="SimpleGeolocation.Request.ResponseCode"
    enum="HttpResponseCode" expires_after="never">
<!-- expires-never: This reports external location provider health status and
should be kept until we use this API.  -->

  <owner>alemate@chromium.org</owner>
  <owner>michaelpg@chromium.org</owner>
  <summary>Http response codes in IP-based SimpleGeolocation.</summary>
</histogram>

<histogram name="SimpleGeolocation.Request.ResponseFailureTime" units="ms"
    expires_after="never">
<!-- expires-never: This reports external location provider health status and
should be kept until we use this API.  -->

  <owner>alemate@chromium.org</owner>
  <owner>michaelpg@chromium.org</owner>
  <summary>
    The time elapsed between the sending of the first API request and the time
    the final (failed) response was recorded. Includes all retries.
  </summary>
</histogram>

<histogram name="SimpleGeolocation.Request.ResponseSuccessTime" units="ms"
    expires_after="never">
<!-- expires-never: This reports external location provider health status and
should be kept until we use this API.  -->

  <owner>alemate@chromium.org</owner>
  <owner>michaelpg@chromium.org</owner>
  <summary>
    The time elapsed between the sending of the first API request and the time
    the final (successfull) response was recorded. Includes all retries.
  </summary>
</histogram>

<histogram name="SimpleGeolocation.Request.Result"
    enum="SimpleGeolocationRequestResult" expires_after="never">
<!-- expires-never: This reports external location provider health status and
should be kept until we use this API.  -->

  <owner>alemate@chromium.org</owner>
  <owner>michaelpg@chromium.org</owner>
  <summary>Result of SimpleGeolocationRequest.</summary>
</histogram>

<histogram name="SimpleGeolocation.Request.Retries" units="units"
    expires_after="never">
<!-- expires-never: This reports external location provider health status and
should be kept until we use this API.  -->

  <owner>alemate@chromium.org</owner>
  <owner>michaelpg@chromium.org</owner>
  <summary>Number of retries until the final response was recorded.</summary>
</histogram>

</histograms>

</histogram-configuration>
