[KAFKA-340] How to add multiple collections in the mongodb source config ? Created: 15/Nov/22  Updated: 15/Nov/22  Resolved: 15/Nov/22

Status: Closed
Project: Kafka Connector
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Question Priority: Minor - P4
Reporter: Ross Carvalho Assignee: Ross Lawley
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

So I am using Mongo kafka connector as a source and here is my configĀ 

{
  "name": "MONGO_SO",
  "config": {
    "connector.class": "com.mongodb.kafka.connect.MongoSourceConnector",
    "errors.log.include.messages": "true",
    "publish.full.document.only": "false",
    "tasks.max": "1",
    "change.stream.full.document": "updateLookup",
    "collection": "coupon",
    "key.converter.schemas.enable": "false",
    "topic.prefix": "",
    "database": "",
    "poll.await.time.ms": "5000",
    "connection.uri": "",
    "name": "MONGO_SOU",
    "value.converter.schemas.enable": "false",
    "copy.existing": "true",
    "value.converter": "org.apache.kafka.connect.json.JsonConverter",
    "errors.log.enable": "true",
    "key.converter": "org.apache.kafka.connect.json.JsonConverter",
    "poll.max.batch.size": "1000"
  }
} 

I want my multiple collections to migrate. According to logs it looks like only one collection is supported.Any way to include more than one collection in the config? Any thing to change in config to achieve thisĀ  ?



 Comments   
Comment by Ross Lawley [ 15/Nov/22 ]

Hi rosscarvalho@gofynd.com,

Thank you for reaching out. Jira is really for feature requests or bug reported and I wanted to give you some resources to get questions answered in the future:

  • Our MongoDB support portal, located at support.mongodb.com
  • Our MongoDB community portal, located here
  • If you are an Atlas customer, there is free support offered 24/7 in the lower right hand corner of the UI

In this case see the documentation it has exactly what you are looking for.

All the best,

Ross

Generated at Thu Feb 08 09:06:09 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.