Bug 1370421 - Put base-toolchains builds into own perfherder bucket; r=mshal

Perfherder metrics are by default put in a bucket according to their
platform name. e.g. linux64/opt. Similar jobs emitting otherwise
identical metric names must differentiate the metrics by inserting
extra metadata.

Before this commit, we defined extra metadata in mozharness
sub-configs, as appropriate. As long as the sub-config remembers
to define the metadata, we're good.

However, some tasks don't use mozharness sub-configs. Instead, they
create variations in the taskgraph. The base toolchains builds
are an example. These share the same platform name (e.g. linux64/opt)
and the base mozharness config. Therefore there's no way to
distinguish these builds as being "base toolchains" from mozharness.

This commit teaches mozharness to look for an environment variable
defining extra perfherder keys to use to bucket results. We define
this variable in taskgraph for relevant tasks.

MozReview-Commit-ID: 8oGHGyx6Zn5

--HG--
extra : rebase_source : 5d7355c2e3118fcb893e699c248002d89c328483
This commit is contained in:
Gregory Szorc 2017-06-06 16:23:14 -07:00
parent 2ccb684d0c
commit 2deadc2bf6
2 changed files with 7 additions and 0 deletions

View File

@ -107,6 +107,7 @@ linux64-base-toolchains/opt:
worker:
max-run-time: 36000
env:
PERFHERDER_EXTRA_OPTIONS: base-toolchains
TOOLTOOL_MANIFEST: browser/config/tooltool-manifests/linux64/base-toolchains.manifest
run:
using: mozharness
@ -131,6 +132,7 @@ linux64-base-toolchains/debug:
worker:
max-run-time: 36000
env:
PERFHERDER_EXTRA_OPTIONS: base-toolchains
TOOLTOOL_MANIFEST: browser/config/tooltool-manifests/linux64/base-toolchains.manifest
run:
using: mozharness

View File

@ -2106,6 +2106,11 @@ or run without that action (ie: --no-{action})"
if opt not in suite.get('extraOptions', []):
suite.setdefault('extraOptions', []).append(opt)
for opt in os.environ.get('PERFHERDER_EXTRA_OPTIONS', '').split():
for suite in perfherder_data['suites']:
if opt not in suite.get('extraOptions', []):
suite.setdefault('extraOptions', []).append(opt)
if self.query_is_nightly():
for suite in perfherder_data['suites']:
suite.setdefault('extraOptions', []).insert(0, 'nightly')