当前位置:网站首页>Reliability and repeatability of messages
Reliability and repeatability of messages
2022-07-22 19:47:00 【Blizzard 2008】
Reliability and repetition of messages
The reliability of the message
Production and consumption process
We often use message queues , Here we briefly introduce the reliability of messages , The author takes kafka Message queue is the background . Let's take a look at the whole process of news from generation to consumption :
Here's the picture :
The producer sends a message to Broker,Broker After receiving the message , Store it in memory , Persist to cluster storage ( Confirm according to the reliability , It can be adjusted : For example, if there is no need to ensure that messages are not lost , After receiving the message , Return confirmation without persistence ), Send confirmation to Producer, Send complete .
consumer , It adopts the method of pulling , After pulling , Consumption is ( Generally, it is the business logic of processing consumption ), Send confirmation to Broker.
detailed , The author combed the guide map :
Duplicate message
Through the reliability of the message, we know , In the realization of reliability , The network jitter 、 The system handles busy and other unstable situations
In the sending phase : Send confirmation timeout , A message resend occurs .
Consumption stage : Over time consumption , Send a message and resend ; Consumption confirmation timeout , There will also be message resending .
here , We need to respond to repeated messages , Usually on the consumer side , Doing idempotent processing is to do idempotent design for the business logic of consumption messages .
The general business idempotency design is shown in the following diagram :
边栏推荐
- SVN服务端与客户端安装(汉化包)以及简单使用
- 发现mariadb数据库时间晚了12个小时,xxljob定时任务调度异常
- 安装Mariadb columnStore(10.3版本)
- ES6新特性分享(四)
- maxscale的causal_reads参数
- Definition of derived classes
- CV520国产替代CI520非接触式读写器读卡芯片
- NIOBuffer(缓冲器)
- How maxscale handles the state of event after MariaDB master-slave switch -handle_ events
- Ci24r1 low-cost 2.4G wireless transceiver chip replaces xn297 compact si24r1
猜你喜欢
向量vector
zabbix实现钉钉监控告警
ZABBIX server downtime report "\u zbx\u mem\u malloc(): out of memory (requested 96 bytes)"
[learn C and fly] Chapter 3 branch structure (exercise 3.1 simple guessing game)
DP4361国产六通道立体声D/A音频转换器芯片替代CS4361
中国最幸运极客:二十出头身家过亿,三次创业全身而退
How can ZABBIX customize MySQL monitoring items and trigger alarms
多重继承
warning: [mariadbmon] The current master server ‘srv-cls01-02‘ is no longer valid because it is in r
安装mariadb 10.5.7(tar包安装)
随机推荐
Operator overloading
Jackson 解析 JSON 详细教程
Wanxing PDF expert v8.3.8.1253 Professional Edition
oracle怎样将字符串转为多行
派生类的定义
NIOFiles工具类
管理的艺术-通过领导力驱动软件研发效能提升
How Oracle escapes single quotation marks
The luckiest geek in China: in his early twenties, he was worth more than 100 million, and retired after three startups
Neo4j 示例:三国志人物关系图谱
CV520国产替代CI520非接触式读写器读卡芯片
NIO字符集和Charset
mysql数据库
mysql进阶(十七)Cannot Connect to Database Server问题分析
MySQL converts milliseconds into time string
Last change time of MySQL view table structure
SQLite UDF/UDAF 的 PHP 实现
MariaDB audit plug-in
Initial experience of MariaDB spider sharding engine
YII2 composer 报错解决 requires bower-asset 问题