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

NPE when setting schema.history.internal.store.only.captured.tables.ddl=true

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 2.2.0.Beta1
    • 2.1.1.Final, 2.1.2.Final
    • oracle-connector
    • None
    • False
    • None
    • False
    • Moderate

      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.1.2.Finalhttps://issues.redhat.com/browse/DBZ-6072?filter=12358727#

      What is the connector configuration?

      {   "connector.class": "io.debezium.connector.oracle.OracleConnector",   "database.connection.adapter": "logminer",   "database.dbname": "svidbs",   "database.password": "******",   "database.url": "jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=svidbs007.local)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=kafka_srv)))",   "database.user": "dbzuser",   "decimal.handling.mode": "double",   "event.processing.failure.handling.mode": "fail",   "heartbeat.action.query": "UPDATE dbzuser.cdc_heartbeat SET beat_time=LOCALTIMESTAMP WHERE id=0",   "heartbeat.interval.ms": 180000,   "key.converter": "io.confluent.connect.avro.AvroConverter",   "key.converter.schema.registry.url": "http://localhost:28080/apis/ccompat/v7",   "log.mining.batch.size.default": 100000,   "log.mining.session.max.ms": 3600000,   "log.mining.strategy": "online_catalog",   "sanitize.field.names": true,   "schema.history.internal.kafka.bootstrap.servers": "localhost:9092",   "schema.history.internal.kafka.topic": "__schema-changes.testdbz02",   "schema.history.internal.store.only.captured.tables.ddl": true,   "schema.include.list": "testdbz02",   "schema.name.adjustment.mode": "avro",   "signal.data.collection": "svidbs007.dbzuser.cdc_signal",   "snapshot.locking.mode": "none",   "snapshot.mode": "initial",   "table.include.list": "testdbz02.info_login",   "tasks.max": 1,   "time.precision.mode": "connect",   "topic.creation.default.cleanup.policy": "compact",   "topic.creation.default.delete.retention.ms": 3600000,   "topic.creation.default.partitions": -1,   "topic.creation.default.replication.factor": -1,   "topic.creation.default.retention.bytes": -1,   "topic.creation.default.segment.ms": 86400000,   "topic.prefix": "cdc",   "value.converter": "io.confluent.connect.avro.AvroConverter",   "value.converter.schema.registry.url": "http://localhost:28080/apis/ccompat/v7" }

      What is the captured database version and mode of depoyment?

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

      On-premise Oracle RAC 12.2.0.1.0

      What behaviour do you expect?

      Without setting the property schema.history.internal.store.only.captured.tables.ddl=true the connector works so I would expect to continue functioning after setting the property.

      What behaviour do you see?

      The connector stops after a NullPointerException

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

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

      I tested it only with stable versions. The connector failed in version 2.1.1.Final also.

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

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

      [2023-02-03 09:16:16,307] ERROR [oracle-cer02c|task-0] Producer failure (io.debezium.pipeline.ErrorHandler:38)
      io.debezium.DebeziumException: java.lang.NullPointerException
          at io.debezium.pipeline.source.AbstractSnapshotChangeEventSource.execute(AbstractSnapshotChangeEventSource.java:85)
          at io.debezium.pipeline.ChangeEventSourceCoordinator.doSnapshot(ChangeEventSourceCoordinator.java:155)
          at io.debezium.pipeline.ChangeEventSourceCoordinator.executeChangeEventSources(ChangeEventSourceCoordinator.java:137)
          at io.debezium.pipeline.ChangeEventSourceCoordinator.lambda$start$0(ChangeEventSourceCoordinator.java:109)
          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: java.lang.NullPointerException
          at io.debezium.connector.oracle.OracleSnapshotChangeEventSource.createSchemaChangeEventsForTables(OracleSnapshotChangeEventSource.java:220)
          at io.debezium.relational.RelationalSnapshotChangeEventSource.doExecute(RelationalSnapshotChangeEventSource.java:122)
          at io.debezium.pipeline.source.AbstractSnapshotChangeEventSource.execute(AbstractSnapshotChangeEventSource.java:76)
          ... 8 more
      [2023-02-03 09:16:16,308] INFO [oracle-cer02c|task-0] Connected metrics set to 'false' (io.debezium.pipeline.ChangeEventSourceCoordinator:236)
      [2023-02-03 09:16:16,485] ERROR [oracle-cer02c|task-0] WorkerSourceTask{id=oracle-cer02c-0} Task threw an uncaught and unrecoverable exception. Task is being killed and will not recover until manually restarted (org.apache.kafka.connect.runtime.WorkerTask:196)
      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:53)
          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: io.debezium.DebeziumException: java.lang.NullPointerException
          at io.debezium.pipeline.source.AbstractSnapshotChangeEventSource.execute(AbstractSnapshotChangeEventSource.java:85)
          at io.debezium.pipeline.ChangeEventSourceCoordinator.doSnapshot(ChangeEventSourceCoordinator.java:155)
          at io.debezium.pipeline.ChangeEventSourceCoordinator.executeChangeEventSources(ChangeEventSourceCoordinator.java:137)
          at io.debezium.pipeline.ChangeEventSourceCoordinator.lambda$start$0(ChangeEventSourceCoordinator.java:109)
          ... 5 more
      Caused by: java.lang.NullPointerException
          at io.debezium.connector.oracle.OracleSnapshotChangeEventSource.createSchemaChangeEventsForTables(OracleSnapshotChangeEventSource.java:220)
          at io.debezium.relational.RelationalSnapshotChangeEventSource.doExecute(RelationalSnapshotChangeEventSource.java:122)
          at io.debezium.pipeline.source.AbstractSnapshotChangeEventSource.execute(AbstractSnapshotChangeEventSource.java:76)
          ... 8 more
      [2023-02-03 09:16:16,486] INFO [oracle-cer02c|task-0] Stopping down connector (io.debezium.connector.common.BaseSourceTask:265)

      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>

            ywyuewei Harvey Yue
            c.oancea@informatica.aci.it CIPRIAN OANCEA (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: