forked from mirrors/gecko-dev
Since the submetric deals with IPCPayload, the submetric needs to know its label. We could add that to CounterMetric::Child, but adding an optional label to the child variant of CounterMetric looked strange. So instead, I introduce the Labeled*Metric types. Well, LabeledStringMetric and LabeledBooleanMetric are just re-exports. But LabeledCounterMetric knows its label in non-parent processes. And in parent processes it just acts like a normal CounterMetric, thanks to the metric traits. To figure out how to handle all these types it encouraged me to remove lambdas from the MLA FFI and solve it with hygienic identifier capture instead. Bonus. Here's hoping I don't regret this additional level of abstraction later. Differential Revision: https://phabricator.services.mozilla.com/D107667 |
||
|---|---|---|
| .. | ||
| api | ||
| bindings | ||
| build_scripts/glean_parser_ext | ||
| docs | ||
| gtest | ||
| ipc | ||
| pytest | ||
| sphinx | ||
| src | ||
| xpcom | ||
| xpcshell | ||
| Cargo.toml | ||
| cbindgen.toml | ||
| metrics.yaml | ||
| metrics_index.py | ||
| moz.build | ||
| pings.yaml | ||
| test_metrics.yaml | ||
| test_pings.yaml | ||