wolff icon indicating copy to clipboard operation
wolff copied to clipboard

feat: optimize disk buffer writes

Open zmstone opened this issue 5 months ago • 0 comments

Previously, the wolff_producer implementation is aggresive when try to enqueue newly received calls, even when max_linger_ms is set to non-zero because the linger was implemented from the popping end of the queue.

This change moves the linger timer to the pushing end of the queue, that is, the process will delay enqueue to allow a larger collection of concurrent calls so the write batch towards disk can be larger

This also means when max_linger_ms is not zero, the concurrent callers will get blocked while lingering.

zmstone avatar Sep 07 '24 11:09 zmstone