check / check (push) Canceled after 0s
The AS, peer and prefix handlers wrote their batch to the database while holding the mutex HandleMessage needs, and HandleMessage wrote a full batch itself. For as long as a write took, the handler took nothing off its queue, and the streamer dropped updates once the queue was half full. Now only the flush goroutine writes: it takes the batch under the mutex, releases it, then writes. A full batch wakes the flush goroutine instead. While a write runs, the next batch grows to at most ten batch sizes; at that size HandleMessage waits until the flush goroutine takes it (README "Memory"). Stop still writes what the handler holds. Model: opus-5-5