Kafka客户端性能参数调优

调优方向:吞吐量

Producer:

• batch.size: increase to 100000--200000 (default 16384)

linger.ms: increase to 10--100 (default 0)

• compression.type=lz4 (default none, i.e., no compression)

• acks=1 (default 1)

• buffer.memory: increase if there are a lot of partitions (default 33554432)

Consumer:

• fetch.min.bytes: increase to ~100000 (default 1)
调优方向:低延迟

Producer:

• linger.ms=0 (default 0)

• compression.type=none (default none, i.e., no compression)

• acks=1 (default 1)

Consumer:

• fetch.min.bytes=1 (default 1)
调优方向:持久性(消息不丢失

replication.factor=3

• acks=all (default 1)

• enable.idempotence=true (default false), to prevent duplicate messages and out-of-order

messages

• max.in.flight.requests.per.connection=1 (default 5), to prevent out of order messages

when not using an idempotent producer

Consumer:

• enable.auto.commit=false (default true)

• isolation.level=read_committed (when using EOS transactions)

调优方向:可用性

Consumer:

session.timeout.ms: increase (default 10000)

max.poll.records减少

相关推荐
云和数据.ChenGuang7 小时前
OpenEuler系统下RabbitMQ安装与基础配置教程
服务器·分布式·rabbitmq·ruby·数据库运维工程师·运维教程
大千AI助手11 小时前
程序合约:形式化验证中的规范与实现框架
分布式·区块链·软件开发·形式化验证·大千ai助手·程序合约·contracts
云和数据.ChenGuang12 小时前
Deepseek适配场景:OpenEuler系统下RabbitMQ安装与基础配置教程
分布式·rabbitmq·ruby
时光追逐者12 小时前
一个基于 .NET 开源、功能强大的分布式微服务开发框架
分布式·微服务·开源·c#·.net·.net core
2501_9401986913 小时前
【前瞻创想】Kurator·云原生实战派:打造下一代分布式云原生基础设施
分布式·云原生
太阳伞下的阿呆13 小时前
kafka高吞吐持久化方案(2)
分布式·kafka·高并发·重入锁
永亮同学15 小时前
【探索实战】告别繁琐,一栈统一:Kurator 从0到1落地分布式云原生应用管理平台!
分布式·云原生
十五年专注C++开发15 小时前
ZeroMQ: 一款高性能、异步、轻量级的消息传输库
网络·c++·分布式·zeroqm
张人玉16 小时前
LiveCharts WPF MVVM 图表开发笔记
大数据·分布式·wpf·livecharts
不惑_16 小时前
Kurator 分布式云原生平台从入门到实战教程
分布式·云原生