From 17b8ce671a4bf4a4a1bc518e2674bf930442505c Mon Sep 17 00:00:00 2001 From: Clement Escoffier Date: Mon, 19 Jul 2021 19:01:43 +0200 Subject: [PATCH] Fix #18811 - Only add the consumer group id if the Kafka config is not empty (cherry picked from commit eef7581ec92b22d17abec76cf3f4e16ca643a095) --- .../kafka/client/runtime/KafkaRuntimeConfigProducer.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/kafka-client/runtime/src/main/java/io/quarkus/kafka/client/runtime/KafkaRuntimeConfigProducer.java b/extensions/kafka-client/runtime/src/main/java/io/quarkus/kafka/client/runtime/KafkaRuntimeConfigProducer.java index 61ddbfde3ce30..1bedf2d4dcc6b 100644 --- a/extensions/kafka-client/runtime/src/main/java/io/quarkus/kafka/client/runtime/KafkaRuntimeConfigProducer.java +++ b/extensions/kafka-client/runtime/src/main/java/io/quarkus/kafka/client/runtime/KafkaRuntimeConfigProducer.java @@ -38,7 +38,7 @@ public Map createKafkaRuntimeConfig(Config config, ApplicationCo result.put(effectivePropertyName, value); } - if (!result.containsKey(GROUP_ID) && app.name.isPresent()) { + if (!result.isEmpty() && !result.containsKey(GROUP_ID) && app.name.isPresent()) { result.put(GROUP_ID, app.name.get()); }