Sync Multiple databases using kafka connector

What configuration is needed in Sink connector to listen to multiple database changes? In source connector i can use pipeline filter to select databases and collections name and make database field empty, but in sink connector database field is mandatory. How can we sync changes in multiple databases(more than 4k count) to the respective database in another cluster?? It is impossible to add seperate connectors for each databases. As per the documentation sink connector can listen to multiple topics, but how it will write to different databases.?

Hi,

@Robert_Walters How to listen change streams in multiple database in Sink connector. I have databases like
DB1_CA , DB1_DC , DB2_CA , DB2_DC . Databases DB1_CA and DB2_CA have collections with same name. Same will apply for DB1_DC and DB2_DC . I was able create topics dynamically for these database changes. But I am stuck with Sink Connector configurations. I know Sink connector can listen to multiple topics by configuring topics.regex or topics. But where it will write to?? Database field is mandatory and cannot able to accept list of regex. Please direct me to solve this particular case.

Regards,

Check out

more info:

Thank you @Robert_Walters . I just extended the NamespaceMapper Interface according to my requirements and it worked.

@Suraj_Santhosh1 Can you give an overview of how the file turned out?