|
1 | 1 | ## 《分布式消息队列XXL-MQ》
|
2 | 2 |
|
3 |
| -[](https://travis-ci.org/xuxueli/xxl-mq) |
4 |
| -[](https://hub.docker.com/r/xuxueli/xxl-mq-admin/) |
5 |
| -[](https://maven-badges.herokuapp.com/maven-central/com.xuxueli/xxl-mq/) |
| 3 | +[](https://github.com/xuxueli/xxl-mq/actions) |
| 4 | +[](https://maven-badges.herokuapp.com/maven-central/com.xuxueli/xxl-mq-client/) |
6 | 5 | [](https://github.com/xuxueli/xxl-mq/releases)
|
| 6 | +[](https://github.com/xuxueli/xxl-mq/) |
| 7 | +[](https://hub.docker.com/r/xuxueli/xxl-mq-admin/) |
7 | 8 | [](http://www.gnu.org/licenses/gpl-3.0.html)
|
8 | 9 | [](https://www.xuxueli.com/page/donate.html)
|
9 | 10 |
|
@@ -630,6 +631,41 @@ transaction | 事务开关,开启消息事务性保证只会成功执行一次
|
630 | 631 | - 7、升级xxl-rpc、xxl-registry至较新版本,Broker注册发现服务做适配性优化;
|
631 | 632 |
|
632 | 633 |
|
| 634 | +### Tmp |
| 635 | + |
| 636 | +1、模型说明: |
| 637 | + - AppName:服务应用,一个应用包含多个 Consumer; |
| 638 | + - instance:uuid; |
| 639 | + - Topic:消息主题,逻辑消息队列; |
| 640 | + - Message:消息队列,物理消息队列;msgid + msgbody + topic + group + shardingId + status + retryCount + effectTime; |
| 641 | + - topic:关联 消息主题; |
| 642 | + - group: |
| 643 | + - shardingId:消费分片ID,限制0-1000之内;结合Consumer在线列表,匹配消费分片范围,实现并行分片消费消息; |
| 644 | +2、模块组成: |
| 645 | + - Broker: |
| 646 | + - Manage:提供 AccessToken、Topic、Message 管理能力; |
| 647 | + - Registry:提供 Consumer 注册、动态发现能力;消息分片消费时使用; |
| 648 | + - Broker Server:提供消息存储、读写能力; |
| 649 | + - OpenAPI:生产、批量查询、锁定、消费消息;(http+gson;借助 xxl-tool 实现通用 http-rpc 能力;) |
| 650 | + - Producer: |
| 651 | + - 功能:直连Broker;发起消息生产; |
| 652 | + - 性能:内存queue,批量异步推送;异常,写本地磁盘;(xxl-tool) |
| 653 | + - 要点: |
| 654 | + - 普通消息:指定 topic + group,生产单条消息,借助 shardingid 分片消费; |
| 655 | + - 广播消息:指定 topic,根据在线 group 列表生产多条消息; |
| 656 | + - Consumer: |
| 657 | + - 功能:查询消息,消费消息,回调消息; |
| 658 | + - 性能:批量查询、批量回调; |
| 659 | + - 要点: |
| 660 | + - 注册: |
| 661 | + - 写:instanceUUID : topic + group + shardingId |
| 662 | + - 读:instanceIndex / instanceNum; |
| 663 | + - 查询:分片查询:topic + group + 注册分片计算->消息分片范围; |
| 664 | + - 属性: |
| 665 | + - topic:绑定 Topic,只消费该topic的消息; |
| 666 | + - group:绑定 Topic Group,group 维度隔离,只消费该group下消息;同一 topic 支持绑定多group,可借助 group 实效消息广播; |
| 667 | + |
| 668 | + |
633 | 669 | ### TODO
|
634 | 670 | - 会考虑移除 mysql 强依赖的,迁移 jpa 进一步提升通用型。
|
635 | 671 | - producer消息,推送broker失败,先缓存本次文件;
|
|
0 commit comments