[ 
https://issues.apache.org/jira/browse/CAMEL-17489?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17480674#comment-17480674
 ] 

Otavio Rodolfo Piske commented on CAMEL-17489:
----------------------------------------------

[~davsclaus] no, we are done w/ this one. I also back-ported it to 3.14.x.

> camel-kafka - Unsubscribing fails due to already closed consumer
> ----------------------------------------------------------------
>
>                 Key: CAMEL-17489
>                 URL: https://issues.apache.org/jira/browse/CAMEL-17489
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-kafka
>    Affects Versions: 3.14.0
>            Reporter: Rafał Gała
>            Priority: Minor
>             Fix For: 3.14.2, 3.15.0
>
>
> In {*}KafkaFetchRecords{*}, when an exception occurs inside *startPolling* 
> method, the consumer is closed in finally block:
> {code:java}
> finally {
>     lock.unlock();
>     // only close if not retry
>     if (!isRetrying()) {
>         LOG.debug("Closing consumer {}", threadId);
>         IOHelper.close(consumer);
>     }
> } {code}
>  and then unsubscribing in *run* method fails with "This consumer has already 
> been closed"
> {code:java}
> LOG.info("Terminating KafkaConsumer thread: {} receiving from topic: {}", 
> threadId, topicName);
> safeUnsubscribe();
> IOHelper.close(consumer); {code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to