Commit 0b69fe9
committed
fix: close pipe readers before join() to prevent conformance test hang (#259)
assertMatchesParquetOracle streams the vortex-java CSV export and the
parquet oracle through a PipedWriter/PipedReader pair on two virtual
threads, compared line-by-line by the main thread. If assertFilesMatch
stops reading early (oracle abort, line mismatch), nobody drains the
pipe anymore — a producer still writing blocks forever once its 128KB
buffer fills, and the unconditional join() right after hangs forever.
Never surfaced before #257 because every prior repeated/list column
consumer failed fast (VortexException thrown immediately). #257 is
the first case where the Java side succeeds and outruns an
early-exiting reader (confirmed via jstack: main thread parked on
Thread.join() for 18+ minutes, ~4s CPU time).
Close both readers before join() so a producer parked on a full
buffer gets an IOException instead of blocking; the artificial
"Pipe closed" error ranks below the real captured errors in the
existing priority order, so behavior is unchanged on every other path.1 parent 776843a commit 0b69fe9
1 file changed
Lines changed: 21 additions & 0 deletions
File tree
- integration/src/test/java/io/github/dfa1/vortex/integration
Lines changed: 21 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| 21 | + | |
21 | 22 | | |
22 | 23 | | |
23 | 24 | | |
| |||
122 | 123 | | |
123 | 124 | | |
124 | 125 | | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
125 | 134 | | |
126 | 135 | | |
127 | 136 | | |
| |||
173 | 182 | | |
174 | 183 | | |
175 | 184 | | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
176 | 197 | | |
177 | 198 | | |
178 | 199 | | |
| |||
0 commit comments