Skip to content

siarzh/mm2-rename-policy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MirrorMaker v2 replication policy to rename target topics

Implements custom ReplicationPolicy that allows you to set renaming mapping for required topics.

Setup

In order to use this policy, please build the project with Maven:

mvn package

or take the .jar file directly from the repo ./dist folder.

Prerequisites

To start using this policy you should first put the .jar to Kafka libs directory to all the other JARs used by Kafka services eg.

/opt/kafka/libs

or include the .jar file in your classpath:

export CLASSPATH=<path_to_jar_folder>/mm2-rename-policy-1.0.jar

Usage

Then you can add these two extra replication policy params for the required topics in your MirrorMaker v2 standalone or Kafka Connect config:

{
    "topics": "A,B,C,D"
    ...
    "replication.policy.class": "com.mirrormaker.RenameReplicationPolicy",
    "replication.policy.topics.mapping": "B,B_on_target;C,brand_new_C"
    ...
}

Specify only those topics you need to rename, for all the rest the default replication policy will be used.

About

MirrorMaker v2 replication policy to rename target topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages