Closed Bug 1400012 Opened 5 years ago Closed 5 years ago

Make an easier developer patch to test worker type changes

Categories

(Firefox Build System :: Task Configuration, task)

task
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: Callek, Assigned: Callek)

Details

Attachments

(2 files, 4 obsolete files)

So, in IRC today, I saw :grenade's largish patch to do worker type testing for taskcluster. I created a patch that utilizes the task morph's instead, to avoid the need to do this all via a lot of different kind.yml's and transforms.
Attachment #8908427 - Flags: feedback?(rthijssen)
Comment on attachment 8908427 [details] [diff] [review]
morph version of patch

Review of attachment 8908427 [details] [diff] [review]:
-----------------------------------------------------------------

i would propose the following slight modification:

            if task.task["workerType"] == worker:
                if task.task["workerType"].endswith('-gpu'):
                    task.task["workerType"] = "{}-b".format(worker)
                else:
                    task.task["workerType"] = "{}-beta".format(worker)

required because gpu beta workers are suffixed with "-b" rather than "-beta" due to workertype name length limitations
Attachment #8908427 - Flags: feedback?(rthijssen) → feedback+
Callek,

Maybe just an explicit mapping?

{
  "gecko-t-win7-32":      "gecko-t-win7-32-beta",
  "gecko-t-win7-32-gpu":  "gecko-t-win7-32-gpu-b",
  "gecko-t-win10-64":     "gecko-t-win10-64-beta",
  "gecko-t-win10-64-gpu": "gecko-t-win10-64-gpu-b",
  "gecko-1-b-win2012":    "gecko-1-b-win2012-beta",
}

Note, in a try push, we don't need to (probably shouldn't) convert level 2/3 worker type names.
... also makes it easy to comment out a line for each worker type you don't want to include in the transformation (often we want beta testers, but the regular win2012 builder) ...
Pete, Rob, by all means adjust this -- I mainly wrote it as a place to store a temporary patch you could use on any try push you wanted to, in order to validate a worker, without having constant bitrot from the various places we specify workers :-).

I'm going to leave a n-i for you both here, and close it, since I consider the Proof Of Concept delivered ;-)
Status: NEW → RESOLVED
Closed: 5 years ago
Flags: needinfo?(rthijssen)
Flags: needinfo?(pmoore)
Resolution: --- → FIXED
Thanks.
Flags: needinfo?(pmoore)
Cheers!
Flags: needinfo?(rthijssen)
This is an alternative implementation using a regular transform.
Same as last version, with a flake8 (linting) fix.
Attachment #8933682 - Attachment is obsolete: true
There was a minor bug in the last version - the transform has to be performed after `taskgraph.transforms.task:transforms` since the task transform replaces `{level}` in worker type name. Therefore the last patch updated tests, but not builds...

Fixed in this version.
Attachment #8935752 - Attachment is obsolete: true
Whoops, I should have tested that previous patch first! xD
Attachment #8948441 - Attachment is obsolete: true
Product: TaskCluster → Firefox Build System
Added OS X staging worker type to transformation:

  "releng-hardware/gecko-t-osx-1010" => "releng-hardware/gecko-t-osx-1010-beta"

See bug 1452095 for details:
  https://bugzilla.mozilla.org/show_bug.cgi?id=1452095#c42
Attachment #8948627 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.