You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "Willian Dallastella (Jira)" <ji...@apache.org> on 2022/01/17 12:04:00 UTC
[jira] [Updated] (KAFKA-13597) Memory leak with kafka-clients 3.0.0
[ https://issues.apache.org/jira/browse/KAFKA-13597?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Willian Dallastella updated KAFKA-13597:
----------------------------------------
Description:
I'm having this issue reported here: [https://github.com/spring-projects/spring-kafka/issues/2056]
It is a Spring Boot 2.5.7 application that started failing (out of memory) when updated to Spring Boot 2.6.1.
This updated *kafka-clients {color:#00875a}2.7.1{color}* to *{color:#ff0000}3.0.0{color}* and started causing the memory leak.
The service is using a standard spring *katkaTemplate* to send messages.
{code:java}
kafkaTemplate.send(
topic,
id,
data
).addCallback(kafkaLoggerCallback) {code}
This producer is quite heavy (2-2k messages/s)
*Downgrading* just the lib *kafka-clients* to *{color:#00875a}2.7.1{color}* solves the issue.
h2. Memory leak sample
* The green line around 16:40 is the service using kafka-clients 2.7.1
* The pink line around 16:55 is without downgrading, that means kafka-clients 3.0.0
!image-2022-01-17-12-59-43-411.png|width=1379,height=411!
h2. Profiling sample
!image-2022-01-17-13-01-43-418.png!
was:
I'm having this issue reported here: [https://github.com/spring-projects/spring-kafka/issues/2056]
It is a Spring Boot 2.5.7 application that started failing when updated to Spring Boot 2.6.1.
This updated *kafka-clients {color:#00875a}2.7.1{color}* to *{color:#FF0000}3.0.0{color}* and started causing the memory leak.
The service is using a standard spring *katkaTemplate* to send messages.
{code:java}
kafkaTemplate.send(
topic,
id,
data
).addCallback(kafkaLoggerCallback) {code}
This producer is quite heavy (2-2k messages/s)
*Downgrading* just the lib *kafka-clients* to *{color:#00875a}2.7.1{color}* solves the issue.
h2. Memory leak sample
* The green line around 16:40 is the service using kafka-clients 2.7.1
* The pink line around 16:55 is without downgrading, that means kafka-clients 3.0.0
!image-2022-01-17-12-59-43-411.png|width=1379,height=411!
h2. Profiling sample
!image-2022-01-17-13-01-43-418.png!
> Memory leak with kafka-clients 3.0.0
> ------------------------------------
>
> Key: KAFKA-13597
> URL: https://issues.apache.org/jira/browse/KAFKA-13597
> Project: Kafka
> Issue Type: Bug
> Components: clients
> Affects Versions: 3.0.0
> Reporter: Willian Dallastella
> Priority: Major
> Attachments: image-2022-01-17-12-59-43-411.png, image-2022-01-17-13-01-43-418.png
>
>
> I'm having this issue reported here: [https://github.com/spring-projects/spring-kafka/issues/2056]
>
> It is a Spring Boot 2.5.7 application that started failing (out of memory) when updated to Spring Boot 2.6.1.
> This updated *kafka-clients {color:#00875a}2.7.1{color}* to *{color:#ff0000}3.0.0{color}* and started causing the memory leak.
>
> The service is using a standard spring *katkaTemplate* to send messages.
> {code:java}
> kafkaTemplate.send(
> topic,
> id,
> data
> ).addCallback(kafkaLoggerCallback) {code}
> This producer is quite heavy (2-2k messages/s)
>
> *Downgrading* just the lib *kafka-clients* to *{color:#00875a}2.7.1{color}* solves the issue.
> h2. Memory leak sample
> * The green line around 16:40 is the service using kafka-clients 2.7.1
> * The pink line around 16:55 is without downgrading, that means kafka-clients 3.0.0
> !image-2022-01-17-12-59-43-411.png|width=1379,height=411!
>
> h2. Profiling sample
>
> !image-2022-01-17-13-01-43-418.png!
--
This message was sent by Atlassian Jira
(v8.20.1#820001)