Commit f0e8263
committed
Exclude archived stacks from the scheduler loops
Stack.schedule_continuous_delivery and Stack.refresh_deployed_revisions
run every minute from the host application's scheduler, but neither
scope excluded archived stacks. Archiving locks a stack, so the jobs
were guaranteed no-ops: ContinuousDeliveryJob bails on the lock and
FetchDeployedRevisionJob refreshes state nobody can see.
At Shopify's scale that was ~1300 archived stacks enqueuing ~2000
no-op ContinuousDeliveryJobs per minute, plus full git clones from
FetchDeployedRevisionJob for archived stacks with fetch steps, all on
the same worker pool as deploys.
Unarchiving already triggers a GithubSyncJob via
sync_github_if_necessary, so a revived stack re-enters both loops
naturally.1 parent 635a50d commit f0e8263
2 files changed
Lines changed: 32 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
117 | 117 | | |
118 | 118 | | |
119 | 119 | | |
120 | | - | |
| 120 | + | |
121 | 121 | | |
122 | 122 | | |
123 | 123 | | |
124 | | - | |
| 124 | + | |
125 | 125 | | |
126 | 126 | | |
127 | 127 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
14 | 44 | | |
15 | 45 | | |
16 | 46 | | |
| |||
0 commit comments