- Notifications
You must be signed in to change notification settings - Fork928
Commitd94a2e5
feat: add API/SDK support for autostop extension (#1778)
* Adds deadline column to workspace_builds, associated DB/API plumbing* database: Upon inserting a row into workspace_builds, deadline will initially be zero.* autobuild: Executor now checks the Deadline field of the workspace_build for the purpose of autostop logic.* coderd: Adds a new route /api/v2/workspaces/:workspace/extend which allows updating the deadline of the currently active workspace build. The new deadline must be after the existing deadline, and not the zero time.* provisionerd: updates workspace_build.deadline upon successful workspace build completion (equal to now plus workspace TTL, if it exists).1 parent9f55f16 commitd94a2e5
File tree
18 files changed
+306
-34
lines changed- coderd
- autobuild/executor
- database
- databasefake
- migrations
- queries
- codersdk
- site/src
- api
- testHelpers
18 files changed
+306
-34
lines changedLines changed: 17 additions & 8 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
50 | 50 |
| |
51 | 51 |
| |
52 | 52 |
| |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
53 | 65 |
| |
54 | 66 |
| |
55 | 67 |
| |
| |||
88 | 100 |
| |
89 | 101 |
| |
90 | 102 |
| |
91 |
| - | |
92 |
| - | |
| 103 | + | |
| 104 | + | |
93 | 105 |
| |
94 |
| - | |
| 106 | + | |
95 | 107 |
| |
96 | 108 |
| |
97 | 109 |
| |
98 |
| - | |
99 |
| - | |
100 |
| - | |
101 |
| - | |
102 |
| - | |
| 110 | + | |
| 111 | + | |
103 | 112 |
| |
104 | 113 |
| |
105 | 114 |
| |
|
Lines changed: 88 additions & 8 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
190 | 190 |
| |
191 | 191 |
| |
192 | 192 |
| |
193 |
| - | |
194 | 193 |
| |
195 | 194 |
| |
196 | 195 |
| |
| 196 | + | |
197 | 197 |
| |
198 |
| - | |
| 198 | + | |
199 | 199 |
| |
200 |
| - | |
| 200 | + | |
201 | 201 |
| |
202 | 202 |
| |
203 | 203 |
| |
| |||
209 | 209 |
| |
210 | 210 |
| |
211 | 211 |
| |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
212 | 261 |
| |
213 | 262 |
| |
214 | 263 |
| |
| |||
222 | 271 |
| |
223 | 272 |
| |
224 | 273 |
| |
225 |
| - | |
226 | 274 |
| |
227 | 275 |
| |
228 | 276 |
| |
229 | 277 |
| |
230 | 278 |
| |
231 | 279 |
| |
232 | 280 |
| |
233 |
| - | |
| 281 | + | |
234 | 282 |
| |
235 | 283 |
| |
236 | 284 |
| |
| |||
264 | 312 |
| |
265 | 313 |
| |
266 | 314 |
| |
267 |
| - | |
| 315 | + | |
268 | 316 |
| |
269 | 317 |
| |
270 | 318 |
| |
| |||
352 | 400 |
| |
353 | 401 |
| |
354 | 402 |
| |
355 |
| - | |
| 403 | + | |
356 | 404 |
| |
357 | 405 |
| |
358 | 406 |
| |
| |||
367 | 415 |
| |
368 | 416 |
| |
369 | 417 |
| |
370 |
| - | |
| 418 | + | |
371 | 419 |
| |
372 | 420 |
| |
373 | 421 |
| |
| |||
378 | 426 |
| |
379 | 427 |
| |
380 | 428 |
| |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
381 | 461 |
| |
382 | 462 |
| |
383 | 463 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
315 | 315 |
| |
316 | 316 |
| |
317 | 317 |
| |
| 318 | + | |
318 | 319 |
| |
319 | 320 |
| |
320 | 321 |
| |
|
Lines changed: 2 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1485 | 1485 |
| |
1486 | 1486 |
| |
1487 | 1487 |
| |
| 1488 | + | |
1488 | 1489 |
| |
1489 | 1490 |
| |
1490 | 1491 |
| |
| |||
1693 | 1694 |
| |
1694 | 1695 |
| |
1695 | 1696 |
| |
| 1697 | + | |
1696 | 1698 |
| |
1697 | 1699 |
| |
1698 | 1700 |
| |
|
Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
| 1 | + |
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
| 1 | + |
Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.
0 commit comments
Comments
(0)