栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 前沿技术 > 大数据 > 大数据系统

Python kafka

Python kafka

安装
pip3 install kafka-python
参考

Kafka Python client
https://github.com/dpkp/kafka-python

Python 连接 Kafka 简单实现
https://www.jianshu.com/p/2ae9b2608ae1

kafka使用_kafka-python基本使用
https://blog.csdn.net/weixin_39963534/article/details/110802374

MessageSizeTooLargeException

Consumer side:fetch.message.max.bytes - this will determine the largest size of a message that can be fetched by the consumer.Broker side: replica.fetch.max.bytes - this will allow for the replicas in the brokers to send messages within the cluster and make sure the messages are replicated correctly. If this is too small, then the message will never be replicated, and therefore, the consumer will never see the message because the message will never be committed (fully replicated).Broker side: message.max.bytes - this is the largest size of the message that can be received by the broker from a producer.Broker side (per topic): max.message.bytes - this is the largest size of the message the broker will allow to be appended to the topic. This size is validated pre-compression. (Defaults to broker’s message.max.bytes.)

如果主题已经创建,修改主题参数

查看参数

bin/kafka-configs.sh --all --describe --topic test-video  --bootstrap-server localhost:9092

max.message.bytes=1048588 sensitive=false synonyms={DEFAULT_CONFIG:message.max.bytes=1048588}

修改参数 改为大小约10M

bin/kafka-configs.sh   --alter --topic test-video  --add-config max.message.bytes=10485880  --bootstrap-server localhost:9092
转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/730582.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号