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

showuon pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/kafka.git


The following commit(s) were added to refs/heads/trunk by this push:
     new 7779a632a95 KAFKA-20163: Missing MM2 default exclude configs (#21443)
7779a632a95 is described below

commit 7779a632a9552b677b9fa96596363db62d35f65c
Author: Federico Valeri <[email protected]>
AuthorDate: Tue Feb 24 10:24:37 2026 +0100

    KAFKA-20163: Missing MM2 default exclude configs (#21443)
    
    This patch adds the following missing configuration in MM2 exclude
    defaults that were introduced in KIP-937:
    
    - log.message.timestamp.before.max.ms
    - log.message.timestamp.after.max.ms
    
    Reviewers: Luke Chen <[email protected]>
    
    Signed-off-by: Federico Valeri <[email protected]>
---
 .../kafka/connect/mirror/DefaultConfigPropertyFilter.java | 14 ++++++++------
 .../kafka/connect/mirror/MirrorSourceConnectorTest.java   | 15 ++++++++-------
 2 files changed, 16 insertions(+), 13 deletions(-)

diff --git 
a/connect/mirror/src/main/java/org/apache/kafka/connect/mirror/DefaultConfigPropertyFilter.java
 
b/connect/mirror/src/main/java/org/apache/kafka/connect/mirror/DefaultConfigPropertyFilter.java
index 2dd99ad0cb7..2dbca8ce5e9 100644
--- 
a/connect/mirror/src/main/java/org/apache/kafka/connect/mirror/DefaultConfigPropertyFilter.java
+++ 
b/connect/mirror/src/main/java/org/apache/kafka/connect/mirror/DefaultConfigPropertyFilter.java
@@ -35,12 +35,14 @@ public class DefaultConfigPropertyFilter implements 
ConfigPropertyFilter {
 
     private static final String CONFIG_PROPERTIES_EXCLUDE_DOC = "List of topic 
configuration properties and/or regexes "
                                                                 + "that should 
not be replicated.";
-    public static final String CONFIG_PROPERTIES_EXCLUDE_DEFAULT = 
"follower\\.replication\\.throttled\\.replicas, "
-                                                                   + 
"leader\\.replication\\.throttled\\.replicas, "
-                                                                   + 
"message\\.timestamp\\.difference\\.max\\.ms, "
-                                                                   + 
"message\\.timestamp\\.type, "
-                                                                   + 
"unclean\\.leader\\.election\\.enable, "
-                                                                   + 
"min\\.insync\\.replicas";
+    public static final String CONFIG_PROPERTIES_EXCLUDE_DEFAULT = 
"follower.replication.throttled.replicas, "
+                                                                   + 
"leader.replication.throttled.replicas, "
+                                                                   + 
"message.timestamp.difference.max.ms, "
+                                                                   + 
"log.message.timestamp.before.max.ms, "
+                                                                   + 
"log.message.timestamp.after.max.ms, "
+                                                                   + 
"message.timestamp.type, "
+                                                                   + 
"unclean.leader.election.enable, "
+                                                                   + 
"min.insync.replicas";
     private Pattern excludePattern = 
MirrorUtils.compilePatternList(CONFIG_PROPERTIES_EXCLUDE_DEFAULT);
     private String useDefaultsFrom = USE_DEFAULTS_FROM_DEFAULT;
 
diff --git 
a/connect/mirror/src/test/java/org/apache/kafka/connect/mirror/MirrorSourceConnectorTest.java
 
b/connect/mirror/src/test/java/org/apache/kafka/connect/mirror/MirrorSourceConnectorTest.java
index 1d106d6deaa..8d17e2ac9ae 100644
--- 
a/connect/mirror/src/test/java/org/apache/kafka/connect/mirror/MirrorSourceConnectorTest.java
+++ 
b/connect/mirror/src/test/java/org/apache/kafka/connect/mirror/MirrorSourceConnectorTest.java
@@ -337,12 +337,14 @@ public class MirrorSourceConnectorTest {
     @Test
     public void testNewTopicConfigs() throws Exception {
         Map<String, Object> filterConfig = new HashMap<>();
-        
filterConfig.put(DefaultConfigPropertyFilter.CONFIG_PROPERTIES_EXCLUDE_CONFIG, 
"follower\\.replication\\.throttled\\.replicas, "
-                + "leader\\.replication\\.throttled\\.replicas, "
-                + "message\\.timestamp\\.difference\\.max\\.ms, "
-                + "message\\.timestamp\\.type, "
-                + "unclean\\.leader\\.election\\.enable, "
-                + "min\\.insync\\.replicas,"
+        
filterConfig.put(DefaultConfigPropertyFilter.CONFIG_PROPERTIES_EXCLUDE_CONFIG, 
"follower.replication.throttled.replicas, "
+                + "leader.replication.throttled.replicas, "
+                + "message.timestamp.difference.max.ms, "
+                + "log.message.timestamp.before.max.ms, "
+                + "log.message.timestamp.after.max.ms, "
+                + "message.timestamp.type, "
+                + "unclean.leader.election.enable, "
+                + "min.insync.replicas,"
                 + "exclude_param.*");
         DefaultConfigPropertyFilter filter = new DefaultConfigPropertyFilter();
         filter.configure(filterConfig);
@@ -377,7 +379,6 @@ public class MirrorSourceConnectorTest {
         verify(connector).createNewTopics(any(), any());
     }
 
-
     @Test
     public void testMirrorSourceConnectorTaskConfig() {
         List<TopicPartition> knownSourceTopicPartitions = new ArrayList<>();

Reply via email to