Commit dd0c547
committed
docs(qwp): fix load-bearing concurrency comments that contradict the code
Five doc sites documented behavior the code deliberately does not have;
each invited a future 'fix' that would reintroduce the hazard the
quiescence work eliminated. Comment-only change.
- CursorSendEngine.closeCompleted field doc: carve the failed-flock-
release case out of the retry sentence. A retried close() exits at the
consumed terminalCleanupClaimed CAS and never calls SlotLock.release()
again — deliberate, pinned by
testUnconfirmedFlockReleaseKeepsCloseIncomplete.
- CursorSendEngine.finishClose javadoc: 'must hold the engine monitor'
was false for completeDeferredClose (deliberately monitor-free to
avoid the join livelock). State the real contract: monitor (close
path) OR worker exit path; in all cases the CAS must be won.
- CursorSendEngine.isCloseCompleted javadoc: admit the third,
unrecoverable state — failed flock release never flips; only process
exit frees the flock.
- SegmentManager.isWorkerReaped javadoc: the fall-through reap nulls
workerThread while the thread may still be running deferred engine
cleanups; the engine-side CAS, not this predicate, is the exclusion.
- SegmentManager.serviceRing0 trim comment: narrow 'stale snapshots' to
mid-pass-deregistered entries — the claim gate makes the trim block
unreachable for pre-pass-deregistered entries.
- SenderPool reclaimSlot/retireLease: 'retired permanently' contradicted
retiredSlots.add + reprobeRetiredSlots recovery three lines down.
- QwpWebSocketSender post-guard comment: the incomplete-close branch is
not only the owned-manager handoff; document the no-handoff cases
(shared manager, failed handoff registration, failed flock release)
where the re-probe never flips.1 parent 79e0847 commit dd0c547
4 files changed
Lines changed: 61 additions & 25 deletions
File tree
- core/src/main/java/io/questdb/client
- cutlass/qwp/client
- sf/cursor
- impl
Lines changed: 15 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1272 | 1272 | | |
1273 | 1273 | | |
1274 | 1274 | | |
1275 | | - | |
1276 | | - | |
1277 | | - | |
1278 | | - | |
1279 | | - | |
1280 | | - | |
1281 | | - | |
| 1275 | + | |
| 1276 | + | |
| 1277 | + | |
| 1278 | + | |
| 1279 | + | |
| 1280 | + | |
| 1281 | + | |
| 1282 | + | |
| 1283 | + | |
| 1284 | + | |
| 1285 | + | |
| 1286 | + | |
| 1287 | + | |
| 1288 | + | |
| 1289 | + | |
1282 | 1290 | | |
1283 | 1291 | | |
1284 | 1292 | | |
| |||
Lines changed: 22 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
124 | 124 | | |
125 | 125 | | |
126 | 126 | | |
127 | | - | |
128 | | - | |
129 | | - | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
130 | 137 | | |
131 | 138 | | |
132 | 139 | | |
| |||
674 | 681 | | |
675 | 682 | | |
676 | 683 | | |
677 | | - | |
| 684 | + | |
| 685 | + | |
| 686 | + | |
| 687 | + | |
678 | 688 | | |
679 | 689 | | |
680 | 690 | | |
| |||
796 | 806 | | |
797 | 807 | | |
798 | 808 | | |
799 | | - | |
800 | | - | |
801 | | - | |
802 | | - | |
803 | | - | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
| 816 | + | |
804 | 817 | | |
805 | 818 | | |
806 | 819 | | |
| |||
Lines changed: 14 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
376 | 376 | | |
377 | 377 | | |
378 | 378 | | |
379 | | - | |
380 | | - | |
381 | | - | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
382 | 389 | | |
383 | 390 | | |
384 | 391 | | |
| |||
742 | 749 | | |
743 | 750 | | |
744 | 751 | | |
745 | | - | |
| 752 | + | |
| 753 | + | |
| 754 | + | |
| 755 | + | |
746 | 756 | | |
747 | 757 | | |
748 | 758 | | |
| |||
Lines changed: 10 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1062 | 1062 | | |
1063 | 1063 | | |
1064 | 1064 | | |
1065 | | - | |
| 1065 | + | |
| 1066 | + | |
| 1067 | + | |
1066 | 1068 | | |
1067 | 1069 | | |
1068 | 1070 | | |
| |||
1350 | 1352 | | |
1351 | 1353 | | |
1352 | 1354 | | |
1353 | | - | |
1354 | | - | |
1355 | | - | |
1356 | | - | |
| 1355 | + | |
| 1356 | + | |
| 1357 | + | |
| 1358 | + | |
| 1359 | + | |
| 1360 | + | |
| 1361 | + | |
1357 | 1362 | | |
1358 | 1363 | | |
1359 | 1364 | | |
| |||
0 commit comments