You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kafka.apache.org by rh...@apache.org on 2021/02/14 03:35:08 UTC
[kafka] 02/02: KAFKA-12326: Corrected regresion in MirrorMaker 2
executable introduced with KAFKA-10021 (#10122)
This is an automated email from the ASF dual-hosted git repository.
rhauch pushed a commit to branch 2.8
in repository https://gitbox.apache.org/repos/asf/kafka.git
commit 7a3e5f7cfe0db8f382f3423d3434d8c6a21ba087
Author: Randall Hauch <rh...@gmail.com>
AuthorDate: Fri Feb 12 16:53:29 2021 -0600
KAFKA-12326: Corrected regresion in MirrorMaker 2 executable introduced with KAFKA-10021 (#10122)
Fixes the recent change to the `MirrorMaker` class (used only in the MirrorMaker 2 executable) that uses a `SharedTopicAdmin` client as part of Connect, so that the correct properties into the `SharedTopicAdmin`.
Author: Randall Hauch <rh...@gmail.com>
Reviewer: Konstantine Karantasis <ko...@confluent.io>
---
.../src/main/java/org/apache/kafka/connect/mirror/MirrorMaker.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/connect/mirror/src/main/java/org/apache/kafka/connect/mirror/MirrorMaker.java b/connect/mirror/src/main/java/org/apache/kafka/connect/mirror/MirrorMaker.java
index e13873e..7ac6831 100644
--- a/connect/mirror/src/main/java/org/apache/kafka/connect/mirror/MirrorMaker.java
+++ b/connect/mirror/src/main/java/org/apache/kafka/connect/mirror/MirrorMaker.java
@@ -235,7 +235,7 @@ public class MirrorMaker {
DistributedConfig distributedConfig = new DistributedConfig(workerProps);
String kafkaClusterId = ConnectUtils.lookupKafkaClusterId(distributedConfig);
// Create the admin client to be shared by all backing stores for this herder
- Map<String, Object> adminProps = new HashMap<>(config.originals());
+ Map<String, Object> adminProps = new HashMap<>(distributedConfig.originals());
ConnectUtils.addMetricsContextProperties(adminProps, distributedConfig, kafkaClusterId);
SharedTopicAdmin sharedAdmin = new SharedTopicAdmin(adminProps);
KafkaOffsetBackingStore offsetBackingStore = new KafkaOffsetBackingStore(sharedAdmin);