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

NO_DATA snapshot mode validation throw DebeziumException on restarts if snapshot is not completed

XMLWordPrintable

      When using a snapshot mode that will not snapshot data, if the connector stops without finishing the snapshot it will wrongly thrown 

      2024-04-16 17:12:58 [main] ERROR io.debezium.embedded.EmbeddedEngine - Unable to initialize and start connector's task class 'io.debezium.connector.sqlserver.SqlServerConnectorTask' with config: {connector.class=io.debezium.connector.sqlserver.SqlServerConnector, tasks.max=5, transforms=unwrap, schema.history.internal.file.filename=/tmp/schemahistory.dat, topic.prefix=local, offset.storage.file.filename=/tmp/offsets.dat, transforms.unwrap.type=io.debezium.transforms.ExtractNewRecordState, errors.retry.delay.initial.ms=300, value.converter=org.apache.kafka.connect.json.JsonConverter, key.converter=org.apache.kafka.connect.json.JsonConverter, database.user=*******, database.names=*****, offset.storage=org.apache.kafka.connect.storage.FileOffsetBackingStore, offset.flush.timeout.ms=5000, errors.retry.delay.max.ms=10000, snapshot.isolation.mode=read_committed, database.port=1433, offset.flush.interval.ms=60000, key.converter.schemas.enable=false, schema.history.internal=io.debezium.storage.file.history.FileSchemaHistory, errors.max.retries=-1, database.hostname=**********-dev.database.windows.net, database.password=********, value.converter.schemas.enable=false, name=sqlserver-connector, task.id=0, snapshot.mode=recovery}
      io.debezium.DebeziumException: The connector previously stopped while taking a snapshot, but now the connector is configured to never allow snapshots. Reconfigure the connector to use snapshots initially or when needed.
          at io.debezium.connector.common.BaseSourceTask.validateAndLoadSchemaHistory(BaseSourceTask.java:97)
          at io.debezium.connector.sqlserver.SqlServerConnectorTask.start(SqlServerConnectorTask.java:108)
          at io.debezium.connector.common.BaseSourceTask.start(BaseSourceTask.java:240)
          at io.debezium.embedded.EmbeddedEngine.startSourceTask(EmbeddedEngine.java:636)
          at io.debezium.embedded.EmbeddedEngine.run(EmbeddedEngine.java:448)
          at io.debezium.embedded.ConvertingEngineBuilder$1.run(ConvertingEngineBuilder.java:163)
          at com.onetrust.poc.debezium.Connector.main(Connector.java:52) 

              rh-ee-mvitale Mario Fiore Vitale
              rh-ee-mvitale Mario Fiore Vitale
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: