文章摘要
苏玉钊,孙恩昌,杨睿哲,李萌,张延华,司鹏搏,张卉.面向Kafka共识消息传输的负载均衡算法[J].高技术通讯(中文),2023,33(1):42~49
面向Kafka共识消息传输的负载均衡算法
Load balancing algorithm for Kafka consensus message transmission
  
DOI:10. 3772/ j. issn. 1002-0470. 2023. 01. 004
中文关键词: Kafka; 负载均衡; 区块链; 消费者; 优化
英文关键词: Kafka, load balancing, blockchain, consumer, optimization
基金项目:
作者单位
苏玉钊 (北京工业大学信息学部北京 100124) 
孙恩昌 (北京工业大学信息学部北京 100124) 
杨睿哲 (北京工业大学信息学部北京 100124) 
李萌 (北京工业大学信息学部北京 100124) 
张延华 (北京工业大学信息学部北京 100124) 
司鹏搏 (北京工业大学信息学部北京 100124) 
张卉 (北京工业大学信息学部北京 100124) 
摘要点击次数: 712
全文下载次数: 533
中文摘要:
      Kafka是一种高吞吐量消息中间件,但该算法存在负载均衡导致消费者消息处理效率下降的问题。本文提出一种改进的Kafka负载均衡算法,其中协调者基于消费者和分区的对应关系,根据不同的负载均衡场景优化调整消费者数目,按照业务负载倒序的方式更新消费者和分区的对应关系,优先处理负载较大的业务分区,提高消息传输效率,并且搭建Fabric联盟链验证分析算法的性能。实验结果表明,本算法在中央处理器(CPU)资源消耗比其他算法低5%的情况下,共识速度提升了2%~7%,并且在6个Kafka节点中3个宕机的情况下仍然能共识上链,提升了Kafka负载均衡算法的效率和稳定性。
英文摘要:
      Kafka is a kind of message middleware with high throughput. However, this algorithm has the problem that load balancing can reduce the efficiency of consumer message processing. The coordinator in this algorithm optimizes and adjusts the number of consumers based on the correspondence between consumers and partitions according to different load balancing scenarios, and then updates the correspondence between consumers and partitions in a reverse order of business load. This algorithm prioritizes the business partitions with heavy load and improves the efficiency of message transmission. And build the Fabric consortium chain to verify the performance of the algorithm. Experimental results show that the proposed algorithm improves the consensus speed by 2%-7% when the central processing unit (CPU) resource consumption is 5% lower than that of other algorithm, and the consensus link can still be available even when three out of six Kafka nodes are out of service, which improves the efficiency and stability of the Kafka load balancing algorithm.
查看全文   查看/发表评论  下载PDF阅读器
关闭

分享按钮