随笔分类 -  Mq

Mq
摘要:1.指定Stop接口 public interface IStop { void close(); } 2.指定Consumer接口 public interface IConsumer extends IStop{ void init(); void start() throws Exceptio 阅读全文
posted @ 2022-11-11 17:02 SpecialSpeculator 阅读(40) 评论(0) 推荐(0) 编辑
摘要:本地延迟队列 DelayQueue是无界的 特殊注意: 放入DelayQueue队列中的数据必须实现Delay接口,可以通过指定方法获取到是否到执行时间及比较运算逻辑 1.定义本地延迟队列 @Slf4j @Component public class NotificationHisRetryQueu 阅读全文
posted @ 2022-11-02 13:49 SpecialSpeculator 阅读(69) 评论(0) 推荐(0) 编辑
摘要:1.异步发送API接口 public void send(final Message message, final AsyncSendCallback callback) 2.实现类分析 public void send(final Message message, final AsyncSendC 阅读全文
posted @ 2022-10-28 18:22 SpecialSpeculator 阅读(91) 评论(0) 推荐(0) 编辑
摘要:1.消息的发送流程 一条消息从生产到被消费,将会经历3个阶段 生产阶段,Producer 新建消息,然后通过网络将消息投递给MQ Broker 存储阶段,消息将会存储在Broker端磁盘中 消费阶段,Consumer将会从Broker拉取消息 以上3个阶段,都有可能会丢失消息,只要找到这3个阶段丢失 阅读全文
posted @ 2021-06-01 14:29 SpecialSpeculator 阅读(431) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示