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

NullPointerException in MongoDB connector

XMLWordPrintable

    • False
    • None
    • False
    • Moderate

      Bug report

      For bug reports, provide this information, please:

      What Debezium connector do you use and what version?

      Mongodb, using latest commit on Debezium and Debezium Server main branches

      What is the connector configuration?

      Using the following with Debezium Server:

      debezium.sink.type=http
      debezium.sink.http.url=http://memphis-rest-gateway:4444/stations/todo-cdc-events/produce/single
      debezium.sink.http.time-out.ms=500
      debezium.sink.http.retries=3
      debezium.sink.http.authentication.type=jwt
      debezium.sink.http.authentication.jwt.username=todocdcservice
      debezium.sink.http.authentication.jwt.password=todocdcservice
      debezium.sink.http.authentication.jwt.url=http://memphis-rest-gateway:4444/
      debezium.source.connector.class=io.debezium.connector.mongodb.MongoDbConnector
      debezium.source.mongodb.connection.string=mongodb://db:27017/
      debezium.source.mongodb.user=root
      debezium.source.monogdb.password=mongodb
      debezium.source.offset.storage.file.filename=data/offsets.dat
      debezium.source.offset.flush.interval.ms=0
      debezium.source.topic.prefix=tutorial
      debezium.format.key=json
      debezium.format.value=json
      quarkus.log.console.json=false

      What is the captured database version and mode of depoyment?

      MongoDB 6.0.5 running in a local Docker container

      What behaviour do you expect?

      No NullPointerException .  I misspelled "debezium.source.mongodb.password" as "debezium.source.monogdb.password", so the password was never set.  It's likely that the configuration check isn't robust enough to handle cases where one of the user / password fields is set but not all of them.

      What behaviour do you see?

      A NullPointerException on ConnectionContext.java#L63

      Do you see the same behaviour using the latest relesead Debezium version?

      Yes – using most current commit on main

      Do you have the connector logs, ideally from start till finish?

       

      How to reproduce the issue using our tutorial deployment?

       

              anmohant Anisha Mohanty
              rnowling-memphis RJ Nowling (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: