Repository navigation
Commit e8ac6aa
refactor(server): CloudLink fails with its own errors; the connect routes map them to HTTP
CloudLink now constructs domain errors (invalid relay config or origin,
account mismatch, rejected or replayed proofs, an unavailable tunnel, and
an internal error naming the failed operation with its cause), and relay
responses become a RelayRequestError that says whether the relay refused
the request. The connect routes map these to the same HTTP errors and
messages as before. Startup, recovery and shutdown no longer receive
HTTP-shaped errors, and retries key off the domain errors.
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>1 parent 5573d02 commit e8ac6aa
8 files changed
Lines changed: 577 additions & 337 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
45 | 45 | | |
46 | 46 | | |
47 | 47 | | |
48 | | - | |
49 | 48 | | |
50 | 49 | | |
51 | 50 | | |
| |||
109 | 108 | | |
110 | 109 | | |
111 | 110 | | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
| 111 | + | |
116 | 112 | | |
117 | 113 | | |
118 | 114 | | |
| |||
689 | 685 | | |
690 | 686 | | |
691 | 687 | | |
692 | | - | |
| 688 | + | |
693 | 689 | | |
694 | 690 | | |
695 | 691 | | |
| |||
1051 | 1047 | | |
1052 | 1048 | | |
1053 | 1049 | | |
1054 | | - | |
1055 | | - | |
1056 | | - | |
1057 | | - | |
| 1050 | + | |
| 1051 | + | |
| 1052 | + | |
| 1053 | + | |
1058 | 1054 | | |
1059 | 1055 | | |
1060 | 1056 | | |
| |||
1068 | 1064 | | |
1069 | 1065 | | |
1070 | 1066 | | |
1071 | | - | |
| 1067 | + | |
| 1068 | + | |
1072 | 1069 | | |
1073 | 1070 | | |
1074 | 1071 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
137 | 137 | | |
138 | 138 | | |
139 | 139 | | |
140 | | - | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
141 | 144 | | |
142 | 145 | | |
143 | 146 | | |
| |||
153 | 156 | | |
154 | 157 | | |
155 | 158 | | |
156 | | - | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
157 | 163 | | |
158 | 164 | | |
159 | 165 | | |
| |||
184 | 190 | | |
185 | 191 | | |
186 | 192 | | |
187 | | - | |
| 193 | + | |
188 | 194 | | |
189 | 195 | | |
190 | 196 | | |
| |||
231 | 237 | | |
232 | 238 | | |
233 | 239 | | |
234 | | - | |
| 240 | + | |
235 | 241 | | |
236 | 242 | | |
237 | 243 | | |
| |||
0 commit comments