By adding extra metrics, we found that the time cost is between the ringbuffer.publish() and the onEvent method of handler. That is to say, there are objects stayed in the ringbuffer for an unexpected long time. Furthermore, the extra metrics also confirmed that the ringbuffer is not full when the queue time glitching happened.
We used to think the glitching may result from the WaitStrategy. But it didn't work when we changed the WaitStrategy from BlockingWaitStrategy to YieldingWaitStrategy.
Could you please give us some suggestions about how to solve this?
Our running env is:
- OS: CentOS Linux 7 (Core)
- Disruptor Version: 3.4.2
- Java Version: 17.0.2
- WaitStrategy: BlockingWaitStrategy