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

MongoDB connector still attempting to get oplog position for AWS DocumentDB

    XMLWordPrintable

Details

    • Bug
    • Resolution: Not a Bug
    • Major
    • None
    • 2.0.0.Beta1
    • mongodb-connector
    • None
    • False
    • None
    • False

    Description

      In order to make your issue reports as actionable as possible, please provide the following information, depending on the issue type.

      Bug report

      For bug reports, provide this information, please:

      What Debezium connector do you use and what version?

      2.0.0.Beta1

      What is the connector configuration?

       

      connector.class=io.debezium.connector.mongodb.MongoDbConnector
      errors.log.include.messages=false
      max.queue.size=8192
      mongodb.password=<removed>
      tasks.max=2
      query.fetch.size=0
      retriable.restart.connector.wait.ms=10000
      capture.mode=change_streams_update_full
      initial.sync.max.threads=1
      snapshot.delay.ms=0
      provide.transaction.metadata=false
      mongodb.ssl.enabled=true
      tombstones.on.delete=true
      mongodb.poll.interval.sec=30
      mongodb.members.auto.discover=true
      mongodb.server.selection.timeout.ms=30000
      poll.interval.ms=500
      mongodb.authsource=<admin>
      heartbeat.topics.prefix=__debezium-heartbeat
      config.action.reload=restart
      errors.log.enable=false
      mongodb.connect.timeout.ms=10000
      mongodb.hosts=rs0/<removed>.us-east-1.docdb.amazonaws.com:27017
      connect.backoff.initial.delay.ms=1000
      mongodb.poll.interval.ms=30000
      errors.retry.timeout=0
      sanitize.field.names=false
      connect.max.attempts=16
      max.queue.size.in.bytes=0
      transaction.topic=${database.server.name}.transaction
      mongodb.user=<removed>
      errors.retry.delay.max.ms=60000
      mongodb.socket.timeout.ms=0
      event.processing.failure.handling.mode=fail
      source.struct.version=v2
      heartbeat.interval.ms=0
      mongodb.name=<removed>
      snapshot.max.threads=2
      connect.backoff.max.delay.ms=120000
      schema.name.adjustment.mode=avro
      errors.tolerance=none
      mongodb.ssl.invalid.hostname.allowed=true
      max.batch.size=2048
      snapshot.mode=never 

       

       

      What is the captured database version and mode of depoyment?

      (E.g. on-premises, with a specific cloud provider, etc.)

      AWS DocumentDB

      What behaviour do you expect?

      Should not be crashed

      What behaviour do you see?

      org.apache.kafka.connect.errors.ConnectException: An exception occurred in the change event producer. This connector will be stopped.
      	at io.debezium.pipeline.ErrorHandler.setProducerThrowable(ErrorHandler.java:50)
      	at io.debezium.pipeline.ChangeEventSourceCoordinator.lambda$start$0(ChangeEventSourceCoordinator.java:116)
      	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
      	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
      	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
      	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
      	at java.base/java.lang.Thread.run(Thread.java:829)
      Caused by: org.apache.kafka.connect.errors.ConnectException: Error while attempting to get oplog position
      	at io.debezium.connector.mongodb.MongoDbStreamingChangeEventSource.lambda$establishConnectionToPrimary$3(MongoDbStreamingChangeEventSource.java:170)
      	at io.debezium.connector.mongodb.ConnectionContext$MongoPrimary.execute(ConnectionContext.java:286)
      	at io.debezium.connector.mongodb.MongoDbStreamingChangeEventSource.lambda$initializeOffsets$5(MongoDbStreamingChangeEventSource.java:303)
      	at java.base/java.util.HashMap$Values.forEach(HashMap.java:977)
      	at io.debezium.connector.mongodb.ReplicaSets.onEachReplicaSet(ReplicaSets.java:115)
      	at io.debezium.connector.mongodb.MongoDbStreamingChangeEventSource.initializeOffsets(MongoDbStreamingChangeEventSource.java:298)
      	at io.debezium.connector.mongodb.MongoDbStreamingChangeEventSource.execute(MongoDbStreamingChangeEventSource.java:90)
      	at io.debezium.connector.mongodb.MongoDbStreamingChangeEventSource.execute(MongoDbStreamingChangeEventSource.java:52)
      	at io.debezium.pipeline.ChangeEventSourceCoordinator.streamEvents(ChangeEventSourceCoordinator.java:174)
      	at io.debezium.pipeline.ChangeEventSourceCoordinator.executeChangeEventSources(ChangeEventSourceCoordinator.java:141)
      	at io.debezium.pipeline.ChangeEventSourceCoordinator.lambda$start$0(ChangeEventSourceCoordinator.java:109)
      	... 5 more
      Caused by: com.mongodb.MongoQueryException: Query failed with error code 303 with name '' and error message '{$natural: -1} is not supported' on server <removed>.us-east-1.docdb.amazonaws.com:27017
      	at com.mongodb.internal.operation.FindOperation.lambda$execute$1(FindOperation.java:699)
      	at com.mongodb.internal.operation.OperationHelper.lambda$withSourceAndConnection$2(OperationHelper.java:575)
      	at com.mongodb.internal.operation.OperationHelper.withSuppliedResource(OperationHelper.java:600)
      	at com.mongodb.internal.operation.OperationHelper.lambda$withSourceAndConnection$3(OperationHelper.java:574)
      	at com.mongodb.internal.operation.OperationHelper.withSuppliedResource(OperationHelper.java:600)
      	at com.mongodb.internal.operation.OperationHelper.withSourceAndConnection(OperationHelper.java:573)
      	at com.mongodb.internal.operation.FindOperation.lambda$execute$2(FindOperation.java:690)
      	at com.mongodb.internal.async.function.RetryingSyncSupplier.get(RetryingSyncSupplier.java:65)
      	at com.mongodb.internal.operation.FindOperation.execute(FindOperation.java:722)
      	at com.mongodb.internal.operation.FindOperation.execute(FindOperation.java:86)
      	at com.mongodb.client.internal.MongoClientDelegate$DelegateOperationExecutor.execute(MongoClientDelegate.java:191)
      	at com.mongodb.client.internal.FindIterableImpl.first(FindIterableImpl.java:213)
      	at io.debezium.connector.mongodb.MongoDbStreamingChangeEventSource.lambda$initializeOffsets$4(MongoDbStreamingChangeEventSource.java:305)
      	at io.debezium.connector.mongodb.ConnectionContext$MongoPrimary.execute(ConnectionContext.java:282)
      	... 14 more
       

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

      (Ideally, also verify with latest Alpha/Beta/CR version)

      <Your answer>

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

      (You might be asked later to provide DEBUG/TRACE level log)

      <Your answer>

      How to reproduce the issue using our tutorial deployment?

      <Your answer>

      Feature request or enhancement

      For feature requests or enhancements, provide this information, please:

      Which use case/requirement will be addressed by the proposed feature?

      <Your answer>

      Implementation ideas (optional)

      <Your answer>
       

      Attachments

        Activity

          People

            Unassigned Unassigned
            me-189 Van-Duyet Le (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: