Bug 1433761 - ensure that max-run-time is working from taskcluster -> talos. r=dustin
authorJoel Maher <jmaher@mozilla.com>
Fri, 09 Feb 2018 10:08:44 -0500
changeset 461410 00fc5ded3b48de4beba1597465d6d9a59e733556
parent 461409 c922cfb6504d6376cbe5427fc75145341cbb525b
child 461411 9922610d010eb3c579c7f893f67c6f186affc2a8
push id1683
push usersfraser@mozilla.com
push dateThu, 26 Apr 2018 16:43:40 +0000
treeherdermozilla-release@5af6cb21869d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdustin
bugs1433761
milestone60.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1433761 - ensure that max-run-time is working from taskcluster -> talos. r=dustin
taskcluster/taskgraph/transforms/job/mozharness_test.py
taskcluster/taskgraph/transforms/task.py
--- a/taskcluster/taskgraph/transforms/job/mozharness_test.py
+++ b/taskcluster/taskgraph/transforms/job/mozharness_test.py
@@ -363,16 +363,19 @@ def mozharness_test_on_native_engine(con
         ("public/logs/", "workspace/build/upload/logs/"),
         ("public/test", "artifacts/"),
         ("public/test_info/", "workspace/build/blobber_upload_dir/"),
     ]]
 
     if test['reboot']:
         worker['reboot'] = test['reboot']
 
+    if test['max-run-time']:
+        worker['max-run-time'] = test['max-run-time']
+
     worker['env'] = env = {
         'GECKO_HEAD_REPOSITORY': config.params['head_repository'],
         'GECKO_HEAD_REV': config.params['head_rev'],
         'MOZHARNESS_CONFIG': ' '.join(mozharness['config']),
         'MOZHARNESS_SCRIPT': mozharness['script'],
         'MOZHARNESS_URL': {'task-reference': mozharness_url},
         'MOZILLA_BUILD_URL': {'task-reference': installer_url},
         "MOZ_NO_REMOTE": '1',
--- a/taskcluster/taskgraph/transforms/task.py
+++ b/taskcluster/taskgraph/transforms/task.py
@@ -444,16 +444,19 @@ task_description_schema = Schema({
             Optional('tuxedo_server_url'): optionally_keyed_by('project', basestring),
             Optional('release_eta'): basestring,
             Extra: taskref_or_string,  # additional properties are allowed
         },
     }, {
         Required('implementation'): 'native-engine',
         Required('os'): Any('macosx', 'linux'),
 
+        # the maximum time to run, in seconds
+        Required('max-run-time'): int,
+
         # A link for an executable to download
         Optional('context'): basestring,
 
         # Tells the worker whether machine should reboot
         # after the task is finished.
         Optional('reboot'):
             Any('always', 'on-exception', 'on-failure'),
 
@@ -1216,16 +1219,17 @@ def build_macosx_engine_payload(config, 
         'expires': task_def['expires'],
     }, worker.get('artifacts', []))
 
     task_def['payload'] = {
         'context': worker['context'],
         'command': worker['command'],
         'env': worker['env'],
         'artifacts': artifacts,
+        'maxRunTime': worker['max-run-time'],
     }
     if worker.get('reboot'):
         task_def['payload'] = worker['reboot']
 
     if task.get('needs-sccache'):
         raise Exception('needs-sccache not supported in native-engine')