Commit 6b299b6
committed
test: drive the concurrent install through the command boundary
The case that pins two callers not deciding each other's configuration
drove `Commands.install/5`, and the defect it names was a composition in
`Castle.install/1` - `materialise/3` and then the install, so both callers
configured the target before either reached the lock. Putting that
composition back therefore left the case green: it was asserting about a
function the defect was never in.
`Castle.install/1` now takes the releases directory, the handler, the peer
and the deployment as defaulted arguments, the way `Commands.install/5`
already did, and that one case runs two concurrent callers through the
boundary `bin/castle` actually reaches over `rpc`. `installer/3` takes
`through: :boundary` for it; the boundary prints what succeeded and raises
what failed, so `invoke/2` puts both back into the shape
`Commands.install/5` returns - `with_io/1` inside the task, because that is
whose group leader has to be swapped.
Verified by reintroducing the composition: the case fails on the second
caller's peer having been called and on the target holding its
configuration, which is exactly what it is for.
Every other concurrency case stays on `Commands.install/5`, which is the
right level for a claim about the serialised region itself. The arity-1
form is unchanged and nothing in a release passes the extra arguments, so
no caller chooses anything about the deployment.
Claude-Session: https://claude.ai/code/session_01C4oaMvbR1cbxrZBj8qwkqN1 parent f63f8df commit 6b299b6
4 files changed
Lines changed: 99 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
533 | 533 | | |
534 | 534 | | |
535 | 535 | | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
536 | 548 | | |
537 | 549 | | |
538 | 550 | | |
| |||
1154 | 1166 | | |
1155 | 1167 | | |
1156 | 1168 | | |
| 1169 | + | |
| 1170 | + | |
| 1171 | + | |
| 1172 | + | |
| 1173 | + | |
| 1174 | + | |
| 1175 | + | |
| 1176 | + | |
| 1177 | + | |
| 1178 | + | |
| 1179 | + | |
| 1180 | + | |
| 1181 | + | |
| 1182 | + | |
1157 | 1183 | | |
1158 | 1184 | | |
1159 | 1185 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
230 | 230 | | |
231 | 231 | | |
232 | 232 | | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
233 | 238 | | |
234 | 239 | | |
235 | 240 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
8 | 9 | | |
9 | 10 | | |
10 | 11 | | |
| |||
56 | 57 | | |
57 | 58 | | |
58 | 59 | | |
59 | | - | |
60 | | - | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
61 | 84 | | |
62 | 85 | | |
63 | 86 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
| 5 | + | |
4 | 6 | | |
5 | 7 | | |
6 | 8 | | |
| |||
796 | 798 | | |
797 | 799 | | |
798 | 800 | | |
| 801 | + | |
| 802 | + | |
| 803 | + | |
| 804 | + | |
| 805 | + | |
| 806 | + | |
| 807 | + | |
799 | 808 | | |
800 | 809 | | |
801 | 810 | | |
| |||
805 | 814 | | |
806 | 815 | | |
807 | 816 | | |
| 817 | + | |
808 | 818 | | |
809 | 819 | | |
810 | 820 | | |
| |||
814 | 824 | | |
815 | 825 | | |
816 | 826 | | |
| 827 | + | |
817 | 828 | | |
818 | 829 | | |
819 | 830 | | |
| |||
1239 | 1250 | | |
1240 | 1251 | | |
1241 | 1252 | | |
| 1253 | + | |
| 1254 | + | |
| 1255 | + | |
| 1256 | + | |
| 1257 | + | |
| 1258 | + | |
1242 | 1259 | | |
1243 | 1260 | | |
1244 | 1261 | | |
1245 | 1262 | | |
1246 | 1263 | | |
1247 | 1264 | | |
| 1265 | + | |
1248 | 1266 | | |
1249 | 1267 | | |
1250 | 1268 | | |
| |||
1253 | 1271 | | |
1254 | 1272 | | |
1255 | 1273 | | |
1256 | | - | |
1257 | | - | |
| 1274 | + | |
1258 | 1275 | | |
1259 | 1276 | | |
1260 | 1277 | | |
| 1278 | + | |
| 1279 | + | |
| 1280 | + | |
| 1281 | + | |
| 1282 | + | |
| 1283 | + | |
| 1284 | + | |
| 1285 | + | |
| 1286 | + | |
| 1287 | + | |
| 1288 | + | |
| 1289 | + | |
| 1290 | + | |
| 1291 | + | |
| 1292 | + | |
| 1293 | + | |
| 1294 | + | |
| 1295 | + | |
| 1296 | + | |
| 1297 | + | |
| 1298 | + | |
| 1299 | + | |
| 1300 | + | |
| 1301 | + | |
1261 | 1302 | | |
1262 | 1303 | | |
1263 | 1304 | | |
| |||
0 commit comments