当前位置:网站首页>maxwell concept
maxwell concept
2022-08-11 07:26:00 【Eating too much sugar will not gain weight】
maxwell concept
maxwell definition
maxwell is a real-time capture MYSQL software written in java. It reads the MYSQL binary log Binlog in real time and generates JSON format, which is used as a producer to send to Kafka, Redis and other applications.
The Principle of Maxwell
Disguise yourself as a MYSQL salve, and then copy data from the master as a salve.
Mysql master-slave replication process
The master main library change record is written to the binary log file.
salve sends the dump protocol from the library I/O thread to the mysql master, and copies the binary log events of the master master library to the relay log of the slave library.
salve has a sql thread that will read the relay log,The sql events in this log are executed sequentially to be consistent with the main library.
binary log classification
binary log has three formats: statement, row, mixed
statement
At the statement level, binlog records the statement of the write operation each time, which saves space, but may produce different results, such as update test set create_date=now(). If you use binlog to reply to the log, the execution time will also be different., the resulting data is different.
row
Row level, binlog records the changes of each row of records after each operation, advantages: maintain data consistency, because no matter what operation is performed, it only records the effect after execution.Disadvantage: takes up a lot of space
mixed
Mixed level, the upgraded version of statement, the default is statement, but when the function contains UUID(); when the table containing the AUTO_INCREMENT field is updated; when the INSERT DELAYED statement is executed; when using UDF; it will be processed in the way of ROW.Advantages: It saves space and also takes into account a certain consistency.Disadvantages: There are also individual cases that can cause inconsistencies.
binlog format chosen by maxwell
Maxwell needs to monitor and analyze, and it is more suitable to choose the row format, which has strong consistency.
maxwell and canal comparison
Language: All written in java
Data format: canal format is free, maxwell can only send json messages
Data collection mode: canal only supports incremental collection, maxwell supports full and incremental
Data landing: Canal needs to be customized, maxwell supports kafka and other platforms
ha: all support
边栏推荐
- JD.com product details API call example explanation
- HCIP OSPF dynamic routing protocol
- Cobbleland 博览会 基础系列 1
- 《Show and Tell: A Neural Image Caption Generator》论文解读
- Daily SQL - find each of the students school gpa minimum (window)
- Amazon API interface Daquan
- Redis + lua implements distributed interface current limiting implementation scheme
- 每日sql-找到每个学校gpa最低的同学(开窗)
- 快速了解集成学习
- MySQL之CRUD
猜你喜欢
随机推荐
快速了解集成学习
实现通用的、高性能排序和快排优化
强烈推荐一款好用的API接口
JVM学习——3——数据一致性
torch.cat()使用方法
那些事情是用Unity开发项目应该一开始规划好的?如何避免后期酿成巨坑?
opencv实现数据增强(图片+标签)平移,翻转,缩放,旋转
软件测试基本流程有哪些?北京专业第三方软件检测机构安利
详解BLEU的原理和计算
radix-4 FFT 原理和C语言代码实现
Implement general-purpose, high-performance sorting and quicksort optimizations
Trill keyword search goods - API
Monte Carlo
exness:黄金1800关口遇阻,静待美国CPI出炉
每日sql - 判断+聚合
自定义MVC增删改查
MySQL使用GROUP BY 分组查询时,SELECT 查询字段包含非分组字段
OA Project Pending Meeting & History Meeting & All Meetings
姿态解算-陀螺仪+欧拉法
京东商品详情API调用实例讲解