项目开源主页:https://github.com/alibaba/RocketMQ
I
目录
1 前言 .................................................................................................................................................................................... 1
2 客户端使用指南 ................................................................................................................................................................ 1
2.1 客户端如何寻址 .................................................................................................................................................... 1
2.2 自定义客户端行为 ............................................................................................................................................... 2
2.2.1 客户端 API 形式 ....................................................................................................................................... 2
2.2.2 客户端的公共配置 ................................................................................................................................... 2
2.2.3 Producer 配置 ............................................................................................................................................... 2
2.2.4 PushConsumer 配置 ..................................................................................................................................... 3
2.2.5 PullConsumer 配置 ....................................................................................................................................... 4
2.3 Message 数据结构 ............................................................................................................................................... 4
2.3.1 针对 Producer ........................................................................................................................................... 4
2.3.2 针对 Consumer ......................................................................................................................................... 5
2.4 收发消息例子 ....................................................................................................................................................... 6
2.5 发送顺序消息 ....................................................................................................................................................... 6
2.6 顺序消费与乱序消费 ........................................................................................................................................... 6
2.7 集群消费与广播消费 ........................................................................................................................................... 6
2.8 消息发送失败重试 ............................................................................................................................................... 6
2.9 消息消费失败重试 ............................................................................................................................................... 6
2.10 主动 Pull 方式消费 ............................................................................................................................................... 6
3 Broker 使用指南 ............................................................................................................................................................. 6
3.1 Broker 配置参数 ................................................................................................................................................... 6
3.2 Broker 集群搭建 ................................................................................................................................................... 8
3.3 Broker 重启对客户端的影响 .............................................................................................................................. 10