- Notifications
You must be signed in to change notification settings - Fork1k
Commit8b66a5a
authored
chore(codersdk/workspacesdk): make dialer fail fast for authnz errors (#19173)
Closes#18599.The linked issue was created due to me assuming the dialer didn't fail fast at all. In reality, it does fail fast, but only for a select few status codes. Auth[n|z] errors aren't any of those status codes, despite being 'permanent' in the same way a `400` is.This PR makes 401* and 403 'permanent' errors, meaning the dialer will give up immediately after receiving them from coderd.*One reason to receive a 401 is when the supplied resume_token is invalid. These are not permanent errors, and when we encounter those the dialer will retain the existing behaviour of unsetting the resume token and retrying.1 parent7eb4119 commit8b66a5a
2 files changed
+70
-8
lines changedOriginal file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
24 | 24 |
| |
25 | 25 |
| |
26 | 26 |
| |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
27 | 31 |
| |
28 | 32 |
| |
29 | 33 |
| |
| |||
39 | 43 |
| |
40 | 44 |
| |
41 | 45 |
| |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
42 | 64 |
| |
43 | 65 |
| |
44 | 66 |
| |
| |||
82 | 104 |
| |
83 | 105 |
| |
84 | 106 |
| |
85 |
| - | |
86 | 107 |
| |
87 | 108 |
| |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
88 | 115 |
| |
89 | 116 |
| |
90 | 117 |
| |
| |||
107 | 134 |
| |
108 | 135 |
| |
109 | 136 |
| |
110 |
| - | |
111 |
| - | |
112 |
| - | |
113 |
| - | |
114 |
| - | |
115 |
| - | |
116 |
| - | |
| 137 | + | |
| 138 | + | |
117 | 139 |
| |
118 | 140 |
| |
119 | 141 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
270 | 270 |
| |
271 | 271 |
| |
272 | 272 |
| |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
273 | 313 |
| |
274 | 314 |
| |
275 | 315 |
| |
|
0 commit comments
Comments
(0)