You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2022/03/28 12:58:08 UTC

[camel] branch main updated: [CAMEL-17839] camel-kafka: fix health checks and failing KafkaConsumerHealthCheckIT (#7276)

This is an automated email from the ASF dual-hosted git repository.

davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/main by this push:
     new 69ab928  [CAMEL-17839] camel-kafka: fix health checks and failing KafkaConsumerHealthCheckIT (#7276)
69ab928 is described below

commit 69ab92809e2359268afdf568388bed7e7ebc5206
Author: John Poth <po...@gmail.com>
AuthorDate: Mon Mar 28 14:57:27 2022 +0200

    [CAMEL-17839] camel-kafka: fix health checks and failing KafkaConsumerHealthCheckIT (#7276)
---
 .../java/org/apache/camel/component/kafka/KafkaConsumerHealthCheck.java | 1 +
 .../java/org/apache/camel/component/kafka/KafkaProducerHealthCheck.java | 2 ++
 2 files changed, 3 insertions(+)

diff --git a/components/camel-kafka/src/main/java/org/apache/camel/component/kafka/KafkaConsumerHealthCheck.java b/components/camel-kafka/src/main/java/org/apache/camel/component/kafka/KafkaConsumerHealthCheck.java
index e759191..2429156 100644
--- a/components/camel-kafka/src/main/java/org/apache/camel/component/kafka/KafkaConsumerHealthCheck.java
+++ b/components/camel-kafka/src/main/java/org/apache/camel/component/kafka/KafkaConsumerHealthCheck.java
@@ -82,5 +82,6 @@ public class KafkaConsumerHealthCheck extends AbstractHealthCheck {
                 return; // break on first DOWN
             }
         }
+        builder.up();
     }
 }
diff --git a/components/camel-kafka/src/main/java/org/apache/camel/component/kafka/KafkaProducerHealthCheck.java b/components/camel-kafka/src/main/java/org/apache/camel/component/kafka/KafkaProducerHealthCheck.java
index 34fde2a..8be0c2a 100644
--- a/components/camel-kafka/src/main/java/org/apache/camel/component/kafka/KafkaProducerHealthCheck.java
+++ b/components/camel-kafka/src/main/java/org/apache/camel/component/kafka/KafkaProducerHealthCheck.java
@@ -59,6 +59,8 @@ public class KafkaProducerHealthCheck extends AbstractHealthCheck {
                 builder.detail("group.id", gid);
             }
             builder.detail("topic", cfg.getTopic());
+        } else {
+            builder.up();
         }
     }
 }