bug 1319824 - Announce signing jobs to funsize with a new pulse route. r=Callek
authorSimon Fraser <sfraser@mozilla.com>
Wed, 21 Dec 2016 18:23:03 +0000
changeset 326835 a331041b33dab6eceaafd29e4666042d9a5def37
parent 326834 4ae5601ea396b1f79a2a4a5f9166905b2ff70b23
child 326939 4e9a4e331b006d5572400fa1fbf8a36d097845ce
push id120
push userCallek@gmail.com
push dateWed, 21 Dec 2016 20:24:23 +0000
reviewersCallek
bugs1319824
milestone53.0a1
bug 1319824 - Announce signing jobs to funsize with a new pulse route. r=Callek MozReview-Commit-ID: A9L6ZEYWQTh
taskcluster/taskgraph/transforms/build_signing.py
taskcluster/taskgraph/transforms/nightly_l10n_signing.py
taskcluster/taskgraph/transforms/signing.py
--- a/taskcluster/taskgraph/transforms/build_signing.py
+++ b/taskcluster/taskgraph/transforms/build_signing.py
@@ -55,9 +55,14 @@ def make_signing_description(config, job
         job['label'] = label
 
         symbol = 'Ns'
         group = 'tc'
 
         job['treeherder'] = {
             'symbol': join_symbol(group, symbol),
         }
+
+        # Announce job status on funsize specific routes, so that it can
+        # start the partial generation for nightlies only.
+        job['use_funsize_route'] = True
+
         yield job
--- a/taskcluster/taskgraph/transforms/nightly_l10n_signing.py
+++ b/taskcluster/taskgraph/transforms/nightly_l10n_signing.py
@@ -63,9 +63,14 @@ def make_signing_description(config, job
 
         # add the chunk number to the TH symbol
         symbol = 'Ns{}'.format(dep_job.attributes.get('l10n_chunk'))
         group = 'tc-L10n'
 
         job['treeherder'] = {
             'symbol': join_symbol(group, symbol),
         }
+
+        # Announce job status on funsize specific routes, so that it can
+        # start the partial generation for nightlies only.
+        job['use_funsize_route'] = True
+
         yield job
--- a/taskcluster/taskgraph/transforms/signing.py
+++ b/taskcluster/taskgraph/transforms/signing.py
@@ -57,16 +57,20 @@ signing_description_schema = Schema({
 
     # unique label to describe this signing task, defaults to {dep.label}-signing
     Optional('label'): basestring,
 
     # treeherder is allowed here to override any defaults we use for signing.  See
     # taskcluster/taskgraph/transforms/task.py for the schema details, and the
     # below transforms for defaults of various values.
     Optional('treeherder'): task_description_schema['treeherder'],
+
+    # If True, adds a route which funsize uses to schedule generation of partial mar
+    # files for updates. Expected to be added on nightly builds only.
+    Optional('use_funsize_route'): bool,
 })
 
 
 @transforms.add
 def validate(config, jobs):
     for job in jobs:
         label = job.get('dependent-task', object).__dict__.get('label', '?no-label?')
         yield validate_schema(
@@ -112,9 +116,13 @@ def make_task_description(config, jobs):
                        'max-run-time': 3600},
             'scopes': ["project:releng:signing:cert:nightly-signing"] + signing_format_scopes,
             'dependencies': {job['depname']: dep_job.label},
             'attributes': attributes,
             'run-on-projects': dep_job.attributes.get('run_on_projects'),
             'treeherder': treeherder,
         }
 
+        if job.get('use_funsize_route', False):
+            task['routes'] = ["project.releng.funsize.{project}.level-{level}".format(
+                project=config.params['project'], level=config.params['level'])]
+
         yield task