Error on mongoDB connector with Amazon MSK

17 views
Skip to first unread message

Diwakar Mishra

unread,
Mar 17, 2023, 3:17:34 AM3/17/23
to debezium
Hi
I'm trying to use Amazon MSK connector to create CDC pipeline for mongoDB
I have create a user with these permissions:

{
"_id" : "admin.cdc_user",
"userId" : UUID("f...."),
"user" : "cdc_user",
"db" : "admin",
"roles" : [
{
"role" : "read",
"db" : "admin"
},
{
"role" : "listDatabases",
"db" : "admin"
},
{
"role" : "read",
"db" : "dbs"
},
{
"role" : "read",
"db" : "config"
},
{
"role" : "readChangeStream",
"db" : "admin"
},
{
"role" : "read",
"db" : "local"
}
],
"mechanisms" : [
"SCRAM-SHA-1",
"SCRAM-SHA-256"
]
}


and with this connector configuration:

connector.class=io.debezium.connector.mongodb.MongoDbConnector
collection.include.list=
mongodb.password=
tasks.max=1
mongodb.user=cdc_user
tombstones.on.delete=false
topic.prefix=mongo-db
database.history.store.only.captured.tables.ddl=true
value.converter=org.apache.kafka.connect.json.JsonConverter
mongodb.hosts=rs1/ip1:27017,ip2:27017,ip3:27017
key.converter=org.apache.kafka.connect.json.JsonConverter
snapshot.mode=never


I'm getting this error after creating the connector:

[Worker-0dc3e6a956b1d478d] [2023-03-17 07:01:24,221] ERROR [mongo-connector|worker] Error while trying to get information about the replica sets (io.debezium.connector.mongodb.ReplicaSetMonitorThread:89)
[Worker-0dc3e6a956b1d478d] com.mongodb.MongoTimeoutException: Timed out after 30000 ms while waiting to connect. Client view of cluster state is {type=UNKNOWN, servers=[{address=ip1:27017, type=UNKNOWN, state=CONNECTING, exception={com.mongodb.MongoSocketOpenException: Exception opening socket}, caused by {java.net.SocketTimeoutException: connect timed out}}]

Can anyone help me to identify what I'm doing wrong here?

Thanks



Reply all
Reply to author
Forward
0 new messages