Commit 84f94ad
Fix port collision with ephemeral range in broker.test
generate_port previously produced ports in [49152, 65535), which
overlaps ~72% of the Linux default ephemeral port range (32768-60999).
Under CI load the generated port could already be in use, causing
bind() to fail with EADDRINUSE and the broker to exit silently.
Dual-port tests (10a/10b/10c) needed two simultaneous free ports,
doubling the exposure.
Changes:
- generate_port: use od -tu2 (unsigned decimal) and range [15000,32000)
which is safely below both Linux and macOS ephemeral ranges
- check_broker: emit a WARNING when the broker does not become ready
within the timeout, so failures are visible rather than silent
- start_broker / start_broker_dual: redirect broker output to a named
log file in TMP_DIR so the CI "Show logs on failure" step captures
the broker's error messages
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent a1639db commit 84f94ad
1 file changed
Lines changed: 18 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
42 | 47 | | |
43 | | - | |
| 48 | + | |
44 | 49 | | |
45 | | - | |
| 50 | + | |
46 | 51 | | |
47 | 52 | | |
| 53 | + | |
48 | 54 | | |
| 55 | + | |
49 | 56 | | |
50 | 57 | | |
51 | 58 | | |
52 | 59 | | |
53 | | - | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
54 | 65 | | |
55 | 66 | | |
56 | 67 | | |
| |||
89 | 100 | | |
90 | 101 | | |
91 | 102 | | |
92 | | - | |
| 103 | + | |
| 104 | + | |
93 | 105 | | |
94 | 106 | | |
95 | 107 | | |
| |||
107 | 119 | | |
108 | 120 | | |
109 | 121 | | |
110 | | - | |
| 122 | + | |
| 123 | + | |
111 | 124 | | |
112 | 125 | | |
113 | 126 | | |
| |||
0 commit comments