New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 758782 link

Starred by 2 users

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Feature



Sign in to add a comment

Allow "pattern histograms" in histograms.xml

Project Member Reported by holte@chromium.org, Aug 25 2017

Issue description

We currently allow groups of histograms to be created using <histogram-suffixes> declarations, but the syntax for these is fairly inflexible, and doesn't match the kind of code people typically write to create these families.

We should probably have a syntax that declares a pattern of histograms, with seperate declarations of variants of families of histograms, e.g.:

<name-piece name="MyFeatureColor">
  <variant name="Red">
  <variant name="Green">
  <variant name="Blue">
</name-piece>

<name-piece name="MyFeatureSize">
  <variant name="Small">
  <variant name="Medium">
  <variant name="Large">
</name-piece>

<histogram-pattern name="MyFeature.{color}.{size}.Result" enum="BooleanSuccess">
  <owner>me@google.com</owner>
  <summary>The result of MyFeature operation for a color and size.</summary>
  <token key="color" variant="MyFeatureColor">
  <token key="size" variant="MyFeatureSize">
</histogram-pattern>

<histogram-pattern name="MyFeature.{color}.{size}.Time" units="ms">
  <owner>me@google.com</owner>
  <summary>How long MyFeature operation took for a color and size.</summary>
  <token key="color" variant="MyFeatureColor">
  <token key="size" variant="MyFeatureSize">
</histogram-pattern>

 
That does seem like a friendlier syntax than what we have now with histogram_suffixes.  IMO we could just allow all <histogram> elements to substitute in pattern pieces, and remove histogram_suffixes entirely, if we switch to this syntax.

Comment 2 by holte@chromium.org, Sep 1 2017

Components: Internals>Metrics>UMA
 Issue 808383  has been merged into this issue.
Components: -Internals>Metrics
Status: Available (was: Untriaged)
Labels: -Type-Bug Type-Feature

Sign in to add a comment