Commit graph

46 commits

Author SHA1 Message Date
Tom Prince
1206a0cc12 Bug 1477706: [test-verify] Only look at locally changed files on try and in try-select; r=ahal
The taskgraph code for test-verify currently looks at locally changed files to
determine how many chunks should be run. This code exists so that
`mach try fuzzy` show the same chunks that would be run on a try push.

This changes it, so that local commts are only considered on try and when
called from try-select. This makes generating the taskgraph locally faster,
when not using `mach try`. It also makes test-verfiy not consider too many
files, if the try push happens to contain commits that have landed but havent
been pushed to try yet (i.e. the first push to try after a merge, or beta try
pushes).

Differential Revision: https://phabricator.services.mozilla.com/D2698

--HG--
extra : rebase_source : 68b1ea583730ff3086949aa6c7b6a1046b406d23
extra : histedit_source : 68bbc7ca2062c7f425353e6caf6b8959786dc42d
2018-08-03 10:26:17 -06:00
Joel Maher
28e3660b54 Bug 1400895 - Better try support for test-verify. r=ahal 2018-05-23 10:00:03 -04:00
Chris AtLee
9472cb160b Bug 1450029: Remove buildbot/buildbot-bridge references from taskcluster r=aki,tomprince
MozReview-Commit-ID: Hu9ju4XVQpA

--HG--
extra : rebase_source : dba8ba385a86ef24a031bca58f01c6ec553d1459
2018-05-01 16:07:19 -04:00
Mike Hommey
1b6bd8290a Bug 1405570 - Never remove tasks with an index-search optimization. r=dustin
--HG--
extra : rebase_source : 9553827bdbf68f2c664e8a1a1481fc2b8222d9da
2017-10-05 10:36:32 +09:00
Dustin J. Mitchell
0448e8d8a4 Bug 1383880: handle keyError from find_task_id; r=gps
MozReview-Commit-ID: F3mVgKcqZwA

--HG--
extra : rebase_source : ff3b24ff42caf9a8770e196d7ee80edb25ff0ead
2017-09-21 12:02:44 +00:00
Dustin J. Mitchell
bdd0ccb0a8 Bug 1383880: use a vcs-compatible reader in decision tasks; r=gps
This continues to use a file-based reader when run locally.

MozReview-Commit-ID: CJuYKDj2E3n

--HG--
extra : rebase_source : ceb56f3eb5b56fca90f19736ab710696fde86bd1
2017-09-07 18:28:22 +00:00
Dustin J. Mitchell
fab36ce789 Bug 1383880: add only-if-dependencies-run optimization for follow-ons; r=ahal
MozReview-Commit-ID: JuhwyQIx3Mh

--HG--
extra : rebase_source : 9255e352377800998fa8913282e1d5aed1851949
extra : source : 4b3fa9587e88431cc28331d129dd7ef4d1a793c2
2017-08-25 21:18:13 +00:00
Dustin J. Mitchell
7bddde4cb2 Bug 1383880: add support for optimizing tasks based on SCHEDULES; r=ahal
This adds some new optimization strategies.  For tests, we use Either(SETA,
SkipUnlessSchedules), thereby giving both mechanisms a chance to skip tasks. On
try, SETA is omitted.

MozReview-Commit-ID: GL4tlwyeBa6

--HG--
extra : rebase_source : f208e4960cf76a9dfe77634b87f0058f676e9fa9
extra : source : 046d705929f7a41e977eec19c8503afccdec7592
2017-08-23 16:21:06 +00:00
Dustin J. Mitchell
400f6f88ad Bug 1383880: optimize in three phases; r=ahal
In preparation for much more thorough optimization of task-graphs, this
makes a few changes:

 * optimization is split into thre phases, with task removal in one phase
   (following dependency links) and task replacement in the next (in the
   reverse order).
 * optimization uses class instances instead of functions for optimizations;
   this allows different functions for different phases, and also leaves open
   the possibility of composing optimizations.
 * the replacement phase can also support removal; this is when utility tasks
   like symbol uploads can be optimized away iff their parent task is
   optimized.

MozReview-Commit-ID: C5QznNpwqXn

--HG--
extra : rebase_source : cf1654036041a64398a2cd38e35e8de4f3596ff9
extra : source : c25af2c111a5be4e3381d0b002641691d15fe4e8
2017-08-20 20:00:17 +00:00
Dustin J. Mitchell
e8c05596d8 Bug 1383880: allow only one optimization per task; r=ahal,glandium
It is not at *all* clear how multiple optimizations for a single task should
interact. No simple logical operation is right in all cases, and in fact in
most imaginable cases the desired behavior turns out to be independent of all
but one of the optimizations. For example, given both `seta` and
`skip-unless-files-changed` optimizations, if SETA says to skip a test, it is
low value and should be skipped regardless of what files have changed. But if
SETA says to run a test, then it has likely been skipped in previous pushes, so
it should be run regardless of what has changed in this push.

This also adds a bit more output about optimization, that may be useful for
anyone wondering why a particular job didn't run.

MozReview-Commit-ID: 3OsvRnWjai4

--HG--
extra : rebase_source : ba0aa536e8c474b36c63d1447c83ed9885f1e3e6
extra : source : a3b7bdfdb116300daa3f49e0dfc96177e1369440
2017-08-01 20:02:59 +00:00
Phil Ringnalda
aad01e0dc2 Backed out 12 changesets (bug 1383880) for decision task bustage
CLOSED TREE

Backed out changeset fd3615e7e0a3 (bug 1383880)
Backed out changeset 8cceb6a82bfb (bug 1383880)
Backed out changeset 571a6c9054a5 (bug 1383880)
Backed out changeset ec2b8ba5a949 (bug 1383880)
Backed out changeset 8e5847d9acda (bug 1383880)
Backed out changeset b354fdf6e233 (bug 1383880)
Backed out changeset ebdd6ccbcfca (bug 1383880)
Backed out changeset ebcc9d20981a (bug 1383880)
Backed out changeset 97eedc84d6e8 (bug 1383880)
Backed out changeset a3116da52b4e (bug 1383880)
Backed out changeset b3eb0c939720 (bug 1383880)
Backed out changeset 7c07cb798530 (bug 1383880)

MozReview-Commit-ID: EPDuQHr7w2y
2017-09-20 19:57:39 -07:00
Dustin J. Mitchell
4c7134dced Bug 1383880: use a vcs-compatible reader in decision tasks; r=gps
This continues to use a file-based reader when run locally.

MozReview-Commit-ID: CJuYKDj2E3n

--HG--
extra : rebase_source : 8532c2cd8bff035b6b7f497947356383713944d7
2017-09-07 18:28:22 +00:00
Dustin J. Mitchell
157dffcb8e Bug 1383880: add only-if-dependencies-run optimization for follow-ons; r=ahal
MozReview-Commit-ID: JuhwyQIx3Mh

--HG--
extra : rebase_source : 553eabc3ac408710bd8c0124232985cc4b01e705
extra : source : 4b3fa9587e88431cc28331d129dd7ef4d1a793c2
2017-08-25 21:18:13 +00:00
Dustin J. Mitchell
0ad6fa01b1 Bug 1383880: add support for optimizing tasks based on SCHEDULES; r=ahal
This adds some new optimization strategies.  For tests, we use Either(SETA,
SkipUnlessSchedules), thereby giving both mechanisms a chance to skip tasks. On
try, SETA is omitted.

MozReview-Commit-ID: GL4tlwyeBa6

--HG--
extra : rebase_source : 4cf3efc9c57bb14d2f44147c8881d0a0a18703d6
extra : source : 046d705929f7a41e977eec19c8503afccdec7592
2017-08-23 16:21:06 +00:00
Dustin J. Mitchell
8009d846d4 Bug 1383880: optimize in three phases; r=ahal
In preparation for much more thorough optimization of task-graphs, this
makes a few changes:

 * optimization is split into thre phases, with task removal in one phase
   (following dependency links) and task replacement in the next (in the
   reverse order).
 * optimization uses class instances instead of functions for optimizations;
   this allows different functions for different phases, and also leaves open
   the possibility of composing optimizations.
 * the replacement phase can also support removal; this is when utility tasks
   like symbol uploads can be optimized away iff their parent task is
   optimized.

MozReview-Commit-ID: C5QznNpwqXn

--HG--
extra : rebase_source : c6e2ff90316d43cd93826de5c30a1936f19c01ca
extra : source : c25af2c111a5be4e3381d0b002641691d15fe4e8
2017-08-20 20:00:17 +00:00
Dustin J. Mitchell
938bafc956 Bug 1383880: allow only one optimization per task; r=ahal,glandium
It is not at *all* clear how multiple optimizations for a single task should
interact. No simple logical operation is right in all cases, and in fact in
most imaginable cases the desired behavior turns out to be independent of all
but one of the optimizations. For example, given both `seta` and
`skip-unless-files-changed` optimizations, if SETA says to skip a test, it is
low value and should be skipped regardless of what files have changed. But if
SETA says to run a test, then it has likely been skipped in previous pushes, so
it should be run regardless of what has changed in this push.

This also adds a bit more output about optimization, that may be useful for
anyone wondering why a particular job didn't run.

MozReview-Commit-ID: 3OsvRnWjai4

--HG--
extra : rebase_source : d5bce42fc0ea24616d885eed62e5e5a42b4fce24
extra : source : a3b7bdfdb116300daa3f49e0dfc96177e1369440
2017-08-01 20:02:59 +00:00
Ryan VanderMeulen
1a86da24ad Backed out 9 changesets (bug 1383880) for decision task bustage.
Backed out changeset 53f5d47a7cb0 (bug 1383880)
Backed out changeset a0abda41172a (bug 1383880)
Backed out changeset 729a7e2091e8 (bug 1383880)
Backed out changeset a33f5a14a471 (bug 1383880)
Backed out changeset 5b10d321cfee (bug 1383880)
Backed out changeset 8056488d8aed (bug 1383880)
Backed out changeset e62c90e3c1e8 (bug 1383880)
Backed out changeset 91f116ce6c2a (bug 1383880)
Backed out changeset 045498bc36c4 (bug 1383880)
2017-09-01 15:37:08 -04:00
Dustin J. Mitchell
cb543f8ecc Bug 1383880: add only-if-dependencies-run optimization for follow-ons; r=ahal
MozReview-Commit-ID: JuhwyQIx3Mh

--HG--
extra : rebase_source : ea02aed4d2f716315c3e51553c3a0d19d40d7679
2017-08-25 21:18:13 +00:00
Dustin J. Mitchell
671dda0818 Bug 1383880: add support for optimizing tasks based on SCHEDULES; r=ahal
This adds some new optimization strategies.  For tests, we use Either(SETA,
SkipUnlessSchedules), thereby giving both mechanisms a chance to skip tasks. On
try, SETA is omitted.

MozReview-Commit-ID: GL4tlwyeBa6

--HG--
extra : rebase_source : 0c1ce762afc7a691788379d4f4206df106f6df63
2017-08-23 16:21:06 +00:00
Dustin J. Mitchell
7b7bcad347 Bug 1383880: optimize in three phases; r=ahal
In preparation for much more thorough optimization of task-graphs, this
makes a few changes:

 * optimization is split into thre phases, with task removal in one phase
   (following dependency links) and task replacement in the next (in the
   reverse order).
 * optimization uses class instances instead of functions for optimizations;
   this allows different functions for different phases, and also leaves open
   the possibility of composing optimizations.
 * the replacement phase can also support removal; this is when utility tasks
   like symbol uploads can be optimized away iff their parent task is
   optimized.

MozReview-Commit-ID: C5QznNpwqXn

--HG--
extra : rebase_source : f8e65ee3ebb9fb584b00ee0db518b790a9c1b233
2017-08-20 20:00:17 +00:00
Dustin J. Mitchell
7e084ff0ae Bug 1383880: allow only one optimization per task; r=ahal
It is not at *all* clear how multiple optimizations for a single task should
interact. No simple logical operation is right in all cases, and in fact in
most imaginable cases the desired behavior turns out to be independent of all
but one of the optimizations. For example, given both `seta` and
`skip-unless-files-changed` optimizations, if SETA says to skip a test, it is
low value and should be skipped regardless of what files have changed. But if
SETA says to run a test, then it has likely been skipped in previous pushes, so
it should be run regardless of what has changed in this push.

This also adds a bit more output about optimization, that may be useful for
anyone wondering why a particular job didn't run.

MozReview-Commit-ID: 3OsvRnWjai4

--HG--
extra : rebase_source : 4ac6a5cc592f4210918c73e667f3b5dd50230894
2017-08-01 20:02:59 +00:00
Dustin J. Mitchell
6efc822329 Bug 1379163: make parameterization functions into utilities; r=bstack
These both have a similar form, recursing over a nested JSON structure, and are
useful outside of the modules in which they are defined.

MozReview-Commit-ID: 1bsRtlaQol7

--HG--
extra : rebase_source : 21b641e927c5004a1cc9778cbd909e4dc40ec47f
2017-07-20 19:24:50 +00:00
Ryan VanderMeulen
25cb66b774 Merge m-c to autoland on a CLOSED TREE. a=merge 2017-05-26 15:45:41 -04:00
Joel Maher
207a896ca0 Bug 1364421 - renable seta for BBB jobs. r=dustin
MozReview-Commit-ID: CLkKUKRMtWE
2017-05-26 12:09:20 -04:00
Dustin J. Mitchell
8e0e299dc8 Bug 1359942: rename optimization to skip-unless-changed; r=glandium
MozReview-Commit-ID: 4d4zoDDJYnz

--HG--
extra : rebase_source : c458cdbe898755f33eb207f2af2c5f4efb7a4702
2017-05-23 10:22:53 -04:00
ayodeji.oyewole
a0fee45dbc Bug 1351010 - Return a single value from optimize functions; r=bstack,TheNavigat
This simplifies the return value of optimize functions:
 * False -- don't optimize
 * True -- optimize away
 * <taskId> -- replace with this task

Original patch by ayodeji.oyewole, with test updates by dustin.

MozReview-Commit-ID: HKoWcINVSnV

--HG--
extra : rebase_source : 1d22d61030eb2bf95d4b9d0803a40e0be96c8830
extra : source : ae32a34822c40dbf7f9129edd701b945f6c95b3a
2017-05-16 18:03:05 +00:00
Dustin J. Mitchell
0344e1f70e Bug 1364421: actually disable SETA, instead of never running talos; r=bstack a=infra-fix
MozReview-Commit-ID: ABtOy6FqKKT

--HG--
extra : amend_source : c55830b73dd4afa51aa163cd537513734e09f5f3
extra : transplant_source : %85Gzz%8E%1A%95o%D0%1A%CB%E3%9A%B0%9AZ%5Cb%5Ew
2017-05-13 19:15:35 +00:00
Joel Maher
d8e63e2177 Bug 1364421 - fix flake8 errors. r=me a=CLOSED TREE 2017-05-12 15:14:10 -04:00
Joel Maher
769411ae57 Bug 1364421 - temporarily disable SETA for BBB only. r=bstack, a=CLOSED TREE 2017-05-12 14:55:42 -04:00
Joel Maher
5d7cb32492 Bug 1364421 - temporarily disable SETA. r=bstack, a=CLOSED TREE
MozReview-Commit-ID: KEoiYhR6bXs
2017-05-12 14:41:52 -04:00
Sebastian Hengst
8cb6dfec68 Backed out changeset e5073b47f5c8 (bug 1351010) for failing taskcluster/taskgraph/test/test_optimize.py. r=backout 2017-04-26 16:19:19 +02:00
Ayodeji Oyewole
dea9b3f094 Bug 1351010 - Fix return statements in optimize.py; r=dustin
MozReview-Commit-ID: ctgm1fw0Fo
***
Bug 1351010 - Completely fixed; r?dustin

MozReview-Commit-ID: HKoWcINVSnV

--HG--
extra : rebase_source : 8ee85a34a6dfb6bc8fe40c4768d2713fffe4a67c
2017-04-01 15:59:36 -04:00
Joel Maher
4b7908e0dd Bug 1349667 - do not used files-changed to conditionally exclude tasks when run from a cron job. r=dustin
MozReview-Commit-ID: 9SOjTxPprMV
2017-03-24 14:02:08 -04:00
Dustin J. Mitchell
8bf935c9ee Bug 1333255: only apply seta optimizations for tests; r=jonasfj
MozReview-Commit-ID: FoIlgwBe4Gd

--HG--
extra : rebase_source : 93a206dc9df029c23514f11d75e349d897dd44bf
2017-03-09 14:45:12 -05:00
Dustin J. Mitchell
bf33dfcabd Bug 1333255: implement optimizations as named functions; r=jonasfj
MozReview-Commit-ID: 9xkHny7IYfA

--HG--
extra : rebase_source : 201cf73414aee4bab407c67cb95e08fd2b794ba5
2017-03-10 18:17:43 +00:00
Dustin J. Mitchell
365aa86d4d Bug 1277579: use 'name' in dependency error message; r=kmoir
MozReview-Commit-ID: GXX5KNQOGve

--HG--
extra : rebase_source : cf0704a52559ec313008db6507244aaf852bb9fa
2016-09-16 20:25:29 +00:00
Dustin J. Mitchell
2fb0796e2b Bug 1286075: add support for optimizing based on files changed in the push; r=gps
MozReview-Commit-ID: 5di7TuL9X2P

--HG--
extra : rebase_source : 30b078178b028b22c0cd7b3d893aa12fd195cf26
2016-09-12 18:40:12 +00:00
Dustin J. Mitchell
d5b3c6a83c Bug 1286075: allow optimization of tasks whose dependencies have not been optimized; r=armenzg
MikeLing initially did this in bug 1287018.  The intent of this conditional was
to make optimization faster by not even checking most tasks, based on the
assumption that if the prerequisite to a task has changed (for example, a
docker image or a build), then naturally we will want to execute that task.
However, as we have developed actual optimization methods, this has proven not
to be the case: we might want to optimize a test out if its inputs have not
changed, even if a new installer has been built.  Similarly, SETA may optimize
tasks out even if their inputs have changed.

MozReview-Commit-ID: LgHET3Z84GB

--HG--
extra : rebase_source : efd297d37bd49dbe655266380641abc258dda725
2016-09-07 00:10:51 +00:00
Kalpesh Krishna
7eccb69c1c Bug 1281062 - Create Action Tasks to schedule new jobs. r=dustin
MozReview-Commit-ID: 5MvqLfGrlLC

--HG--
extra : rebase_source : dd954acce8ef9ed2f3b9aa7c5c2cbd916a82f1f1
2016-07-11 22:43:58 +05:30
Dustin J. Mitchell
c6a548be78 Bug 1280231: rename types.py to taskgraph.py; r=Callek
MozReview-Commit-ID: Jf6CVyFCGMI

--HG--
rename : taskcluster/taskgraph/types.py => taskcluster/taskgraph/taskgraph.py
extra : rebase_source : 12e30313eb1fd4062c0be9d869460644ae949019
extra : intermediate-source : 4b1d94901b4d09c13031982c28eec6a48f938c71
extra : source : e85765be39d61d7c0df9831e16930328effad554
2016-06-20 19:11:52 +00:00
Dustin J. Mitchell
49f6131a63 Bug 1280231: refactor task kinds to task classes; r=jonasfj
MozReview-Commit-ID: 1cNukxBgfey

--HG--
extra : rebase_source : 4f0fcce2bcea0fb78ba70e7c052638ca2c5b8a3d
extra : intermediate-source : ba5cbf4e06a550993e5216f816dcf0ccd3938b2e
extra : source : f744bd2fbcd3ae9b90851dcd12307c15d04f8bea
2016-06-27 22:57:44 +00:00
Wes Kocher
c9059e6a53 Backed out 3 changesets (bug 1280231) for decision task failures CLOSED TREE
Backed out changeset 4b1d94901b4d (bug 1280231)
Backed out changeset 7898d1ab1afc (bug 1280231)
Backed out changeset ba5cbf4e06a5 (bug 1280231)

--HG--
rename : taskcluster/taskgraph/taskgraph.py => taskcluster/taskgraph/types.py
2016-06-27 15:45:44 -07:00
Dustin J. Mitchell
1a1a14c19c Bug 1280231: rename types.py to taskgraph.py; r=Callek
MozReview-Commit-ID: Jf6CVyFCGMI

--HG--
rename : taskcluster/taskgraph/types.py => taskcluster/taskgraph/taskgraph.py
extra : source : e85765be39d61d7c0df9831e16930328effad554
extra : histedit_source : 732dc9a6b9206be1bb2a3e4f1d507d0001588f6c
2016-06-20 19:11:52 +00:00
Dustin J. Mitchell
4cfe2b182c Bug 1280231: refactor task kinds to task classes; r=jonasfj
MozReview-Commit-ID: 1cNukxBgfey

--HG--
extra : source : f744bd2fbcd3ae9b90851dcd12307c15d04f8bea
2016-06-20 20:45:15 +00:00
Justin Wood
15b23fced1 Bug 1280956 - Use in-tree linter job to flake8 test taskcluster directory. r=dustin
MozReview-Commit-ID: FsWmAnnycZ2

--HG--
extra : rebase_source : 04a32cea2de133cb75472092cffb8a215f7dc603
2016-06-20 21:06:55 -04:00
Dustin J. Mitchell
722b95f979 Bug 1274611: Implement task-graph optimization; r=gps
* Implement & document optimization (although legacy kind doesn't do much of it)
 * Introduce `optimize_target_tasks` parameter to control whether tasks in the
   target set can be optimized (no for try, yes for most other branches)
 * Refactor to include resolved taskIds in the optimized task graph
 * Include a `label-to-taskid.json` artifact.
 * Introduce {'task-reference': '... <dependency-name> ...'} for referring to
   parent tasks' taskId.

MozReview-Commit-ID: LWvlWNz49U5

--HG--
extra : rebase_source : 780e0e23d24b268ade33ecdcbccb5081f32aac48
2016-06-05 19:49:41 +00:00