Closed Bug 1497638 Opened 6 years ago Closed 6 years ago

Collect telemetry for mach commands other than just build

Categories

(Firefox Build System :: General, enhancement)

enhancement
Not set
normal

Tracking

(firefox65 fixed)

RESOLVED FIXED
mozilla65
Tracking Status
firefox65 --- fixed

People

(Reporter: ted, Assigned: chmanchester)

References

Details

Attachments

(1 file)

I neglected to file this, but the telemetry I hooked up in bug 1237610 used the existing build system telemetry integration points which only wrapped `mach build`. We'd like to collect telemetry on other mach commands as well, so we'll need to shuffle things around a bit.

We currently gather the telemetry data at the end of `BuildDriver.build`:
https://dxr.mozilla.org/mozilla-central/rev/c291143e24019097d087f9307e59b49facaf90cb/python/mozbuild/mozbuild/controller/building.py#1290-1292

There is a generic `post_dispatch_handler` that gets called by mach here:
https://dxr.mozilla.org/mozilla-central/rev/c291143e24019097d087f9307e59b49facaf90cb/python/mach/mach/registrar.py#96

The callback for that is here, we currently use it to submit pending telemetry on a regular basis:
https://dxr.mozilla.org/mozilla-central/rev/c291143e24019097d087f9307e59b49facaf90cb/build/mach_bootstrap.py#231-254

We'd have to tweak the invocation of `post_dispatch_handler` to pass a few more bits down. We'd also need to replace the use of `monitor` with something more generic (it's only being used for `start_time` and `elapsed`). Getting the substs and topsrcdir/topobjdir might be a little fiddly outside of build-related mach commands, but I'm sure we can figure out something reasonable.
Keywords: in-triage
Assignee: nobody → ted
Keywords: in-triage
Assignee: ted → cmanchester
Pushed by cmanchester@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/b42fc1ea86f3
Gather telemetry for mach commands other than build. r=ted,firefox-build-system-reviewers,nalexander
https://hg.mozilla.org/mozilla-central/rev/b42fc1ea86f3
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla65
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: