camellia
camellia copied to clipboard
camellia-redis-proxy CamelliaDelayQueueServer源码中eventMap的作用
Module: camellia-delay-queue Version: v1.2.16 Content: 请教一下作者,CamelliaDelayQueueServer源码中发布有消息ready的通知是先放到eventMap中,再使用一个singleThread轮询去调用redis的publish,为什么不直接publish,如果是为了减少redis远程调用耗时,在将消息放入eventMap之前也有redis的操作。
如果100ms内发了1000条delay-msg,就得publish 1000次,但是现在定时publish就只需要publish 1次
哦这样,明白了,谢谢