Uploaded image for project: 'Debezium'
  1. Debezium
  2. DBZ-167

mongodb connector throws NPE when discovering replica set on a sharded cluster

    Details

      Description

      Settings,

      mongodb.hosts=<shard cluster config server ip>:27019
      mongodb.user=admin
      mongodb.password=<password>
      

      Command to run

      $ /usr/bin/connect-standalone /etc/kafka/connect-standalone.properties /opt/debezium-connector-mongodb/config/mongodb-kafka-connect.properties
      

      Connector throws out NPE when setting up tasks

      [2016-12-15 15:44:09,042] ERROR Task patientstore-connector-0 threw an uncaught and unrecoverable exception (org.apache.kafka.connect.runtime.WorkerTask:142)
      java.lang.NullPointerException
      	at java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1645)
      	at io.debezium.connector.mongodb.SourceInfo.partition(SourceInfo.java:172)
      	at io.debezium.connector.mongodb.MongoDbConnectorTask.lambda$start$1(MongoDbConnectorTask.java:119)
      	at java.util.ArrayList.forEach(ArrayList.java:1249)
      	at io.debezium.connector.mongodb.ReplicaSets.onEachReplicaSet(ReplicaSets.java:103)
      	at io.debezium.connector.mongodb.MongoDbConnectorTask.start(MongoDbConnectorTask.java:117)
      	at org.apache.kafka.connect.runtime.WorkerSourceTask.execute(WorkerSourceTask.java:137)
      	at org.apache.kafka.connect.runtime.WorkerTask.doRun(WorkerTask.java:140)
      	at org.apache.kafka.connect.runtime.WorkerTask.run(WorkerTask.java:175)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      	at java.lang.Thread.run(Thread.java:745)
      

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                rhauch Randall Hauch
                Reporter:
                sean171 Dongjun Sun
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: