Bug 1382911 - Add schedulerId to task draft
authorHassan Ali <helfi92@gmail.com>
Fri, 21 Jul 2017 08:36:01 -0400
changeset 613084 5783a3ea1a2e1cea66443765085a0c129e72e3cc
parent 613083 064ce241ea2d9beaf31d7afe2b36882ed399fb1b
child 613085 cfc5fab71116a51a4c5de836a098ec4cfdcb7488
push id69723
push userbmo:helfi92@gmail.com
push dateFri, 21 Jul 2017 14:57:00 +0000
bugs1382911
milestone56.0a1
Bug 1382911 - Add schedulerId to task MozReview-Commit-ID: JoK1hC9MRuR
taskcluster/actions/add-new-jobs.py
--- a/taskcluster/actions/add-new-jobs.py
+++ b/taskcluster/actions/add-new-jobs.py
@@ -40,16 +40,17 @@ def add_new_jobs_action(parameters, inpu
     for elem in input['tasks']:
         if elem in task_graph:
             new_task_definition = copy.copy(task_graph[elem]['task'])
 
             # set new created, deadline, and expiry fields
             new_task_definition['created'] = current_json_time()
             new_task_definition['deadline'] = json_time_from_now('1d')
             new_task_definition['expires'] = json_time_from_now('30d')
+            new_task_definition['schedulerId'] = 'gecko-level-{}'.format(parameters['level'])
 
             logging.info("New full task definition: %s", new_task_definition)
 
             # actually create the new task
             new_task_id = slugid()
             logger.info("Retriggering task with id %s", new_task_id)
             
             create_task(session, new_task_id, 'task-retrigger', new_task_definition)