From fadc4779e8d88b6430316c52c1bd0db9d42d2dbb Mon Sep 17 00:00:00 2001 From: Duncan Doyle Date: Tue, 13 Apr 2021 16:06:00 +0200 Subject: [PATCH] Fix case of Kafka ServiceBinging properties Fixes #16477 --- .../quarkus/kafka/client/runtime/KafkaBindingConverter.java | 6 +++--- .../some-kafka/{bootstrapservers => bootstrapServers} | 0 2 files changed, 3 insertions(+), 3 deletions(-) rename integration-tests/kafka-snappy/src/test/resources/k8s-sb/some-kafka/{bootstrapservers => bootstrapServers} (100%) diff --git a/extensions/kafka-client/runtime/src/main/java/io/quarkus/kafka/client/runtime/KafkaBindingConverter.java b/extensions/kafka-client/runtime/src/main/java/io/quarkus/kafka/client/runtime/KafkaBindingConverter.java index f99a5b6a71082..46e769e876ba9 100644 --- a/extensions/kafka-client/runtime/src/main/java/io/quarkus/kafka/client/runtime/KafkaBindingConverter.java +++ b/extensions/kafka-client/runtime/src/main/java/io/quarkus/kafka/client/runtime/KafkaBindingConverter.java @@ -21,7 +21,7 @@ public Optional convert(List service Map properties = new HashMap<>(); ServiceBinding binding = matchingByType.get(); - String bootstrapServers = binding.getProperties().get("bootstrapservers"); + String bootstrapServers = binding.getProperties().get("bootstrapServers"); if (bootstrapServers == null) { bootstrapServers = binding.getProperties().get("bootstrap-servers"); } @@ -29,12 +29,12 @@ public Optional convert(List service properties.put("kafka.bootstrap.servers", bootstrapServers); } - String securityProtocol = binding.getProperties().get("securityprotocol"); + String securityProtocol = binding.getProperties().get("securityProtocol"); if (securityProtocol != null) { properties.put("kafka.security.protocol", securityProtocol); } - String saslMechanism = binding.getProperties().get("saslmechanism"); + String saslMechanism = binding.getProperties().get("saslMechanism"); if (saslMechanism != null) { properties.put("kafka.sasl.mechanism", saslMechanism); } diff --git a/integration-tests/kafka-snappy/src/test/resources/k8s-sb/some-kafka/bootstrapservers b/integration-tests/kafka-snappy/src/test/resources/k8s-sb/some-kafka/bootstrapServers similarity index 100% rename from integration-tests/kafka-snappy/src/test/resources/k8s-sb/some-kafka/bootstrapservers rename to integration-tests/kafka-snappy/src/test/resources/k8s-sb/some-kafka/bootstrapServers