# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

# If this file is changed, update the generated docs:
# https://firefox-source-docs.mozilla.org/mach/telemetry.html#updating-generated-metrics-docs

# Adding a new metric? We have docs for that!
# https://mozilla.github.io/glean/book/user/metrics/adding-new-metrics.html

---
$schema: moz://mozilla.org/schemas/glean/metrics/1-0-0

mozbuild:
  compiler:
    type: string
    description: The compiler type in use (CC_TYPE), such as "clang" or "gcc".
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053#c34
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  artifact:
    type: boolean
    description: True if `--enable-artifact-builds`.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053#c34
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  debug:
    type: boolean
    description: True if `--enable-debug`.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053#c34
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  opt:
    type: boolean
    description: True if `--enable-optimize`.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053#c34
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  ccache:
    type: boolean
    description: True if `--with-ccache`.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053#c34
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  sccache:
    type: boolean
    description: True if ccache in use is sccache.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1291053#c34
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  clobber:
    type: boolean
    description: True if the build was a clobber/full build.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1526072
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1526072#c15
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  project:
    type: string
    description: The project being built.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1654084
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1654084#c2
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  target:
    type: string
    description: The target architecture for the build, such as "x86_64-pc-mingw32".
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1887885
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1893740#c1
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  tier_artifact_duration:
    type: timespan
    description: How long it took for the artifact tier of the build to complete.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  tier_pre_export_duration:
    type: timespan
    description: How long it took for the pre-export tier of the build to complete.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  tier_export_duration:
    type: timespan
    description: How long it took for the export tier of the build to complete.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  tier_misc_duration:
    type: timespan
    description: How long it took for the misc tier of the build to complete.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  tier_libs_duration:
    type: timespan
    description: How long it took for the libs tier of the build to complete.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  tier_tools_duration:
    type: timespan
    description: How long it took for the tools tier of the build to complete.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  tier_configure_duration:
    type: timespan
    description: How long it took for the configure tier of the build to complete.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
  tier_compile_duration:
    type: timespan
    description: How long it took for the compile tier of the build to complete.
    lifetime: application
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1894153
    notification_emails:
      - build-telemetry@mozilla.com
      - ahochheiden@mozilla.com
    expires: never
    send_in_pings:
      - usage
