commit f76d4f31c37fcd66743323f0dafcbd896220dab4
Author: Greg Althaus <galthaus@austin.rr.com>
Date: Fri Aug 14 12:00:30 2020 -0500
fix(transact): fix possible channel miss on wake up and tighten read acquire
The channel semantics are annoying that you can miss wakeups because
of timing. So, close the channel instead of message passing to
ensure that we are unblocking the waiter. This is a better
semantic for this use.
Also, make the read acquire code a little tighter and clearer.
Add some debugging helper functions.
M transact/tx.go
commit 07b7a9ec94d3d9c80f7de1af5dc29733595b7d4b
Author: Greg Althaus <galthaus@austin.rr.com>
Date: Fri Aug 14 00:24:18 2020 -0500
fix(replication): fix some holes in sync and order of stream commits
The synchronizers variable on stack was not protected in all cases by
the spaceLock. Also, some races occur around the syncStream buf because
the atomic check for open could immediately close and generate a panic.
This moves the sychronizer notifications for commits into the flusher
to maintain order. This means that the flusher could be blocked if
a passive receiver runs slow, but it would slow down the system while
the system waited for the commit to complete. Not sure there is much
difference between the two places. We could up the queue depth on the
commit streaming queue.
M datastack/content.go
M datastack/streamingSyncActive.go
M datastack/wal.go
End of Note