0

The initial synchronization worked as expected, but when I insert or update data into the table, the connection with postgres closes.The connector is still marked as active and running.This issue only occurs when the logical decoding plugin used is decoderbufs, and it runs normally when using pgoutput.

Datebase:Database: Postgresql-12

connector config:

{
  "name": "postgres-connector",
  "config": {
    "connector.class": "io.debezium.connector.postgresql.PostgresConnector",
    "database.hostname": "",
    "database.port": "5432",
    "database.user": "postgres",
    "database.password": "123456",
    "database.dbname" : "postgres",
    "topic.prefix": "postgres_service",
    "table.include.list": "debezium.index_example,debezium.stock_example",
    "decimal.handling.mode": "string"
  }
}

Log-Errors:

[2024-07-10 11:04:34,804] INFO [postgres-connector|task-0] Obtained valid replication slot ReplicationSlot [active=false, latestFlushedLsn=LSN{0/175A408}, catalogXmin=534] (io.debezium.connector.postgresql.connection.PostgresConnection:325)
[2024-07-10 11:04:34,806] INFO [postgres-connector|task-0] Found previous offset PostgresOffsetContext [sourceInfoSchema=Schema{io.debezium.connector.postgresql.Source:STRUCT}, sourceInfo=source_info[server='postgres_service'db='postgres', lsn=LSN{0/295A0A8}, txId=565, timestamp=2024-07-10T02:58:18.929445Z, snapshot=FALSE, schema=, table=], lastSnapshotRecord=true, lastCompletelyProcessedLsn=null, lastCommitLsn=null, streamingStoppingLsn=null, transactionContext=TransactionContext [currentTransactionId=null, perTableEventCount={}, totalEventCount=0], incrementalSnapshotContext=IncrementalSnapshotContext [windowOpened=false, chunkEndPosition=null, dataCollectionsToSnapshot=[], lastEventKeySent=null, maximumKey=null]] (io.debezium.connector.postgresql.PostgresConnectorTask:148)
[2024-07-10 11:04:34,806] INFO [postgres-connector|task-0] Requested thread factory for connector PostgresConnector, id = postgres_service named = SignalProcessor (io.debezium.util.Threads:271)
[2024-07-10 11:04:34,807] INFO [postgres-connector|task-0] Requested thread factory for connector PostgresConnector, id = postgres_service named = change-event-source-coordinator (io.debezium.util.Threads:271)
[2024-07-10 11:04:34,807] INFO [postgres-connector|task-0] Requested thread factory for connector PostgresConnector, id = postgres_service named = blocking-snapshot (io.debezium.util.Threads:271)
[2024-07-10 11:04:34,807] INFO [postgres-connector|task-0] Creating thread debezium-postgresconnector-postgres_service-change-event-source-coordinator (io.debezium.util.Threads:288)
[2024-07-10 11:04:34,807] INFO [postgres-connector|task-0] Metrics registered (io.debezium.pipeline.ChangeEventSourceCoordinator:131)
[2024-07-10 11:04:34,807] INFO [postgres-connector|task-0] Context created (io.debezium.pipeline.ChangeEventSourceCoordinator:134)
[2024-07-10 11:04:34,807] INFO [postgres-connector|task-0] Previous snapshot has completed successfully, streaming logical changes from last known position (io.debezium.connector.postgresql.snapshot.InitialSnapshotter:42)
[2024-07-10 11:04:34,807] INFO [postgres-connector|task-0] According to the connector configuration no snapshot will be executed (io.debezium.connector.postgresql.PostgresSnapshotChangeEventSource:79)
[2024-07-10 11:04:34,807] INFO [postgres-connector|task-0] Snapshot ended with SnapshotResult [status=SKIPPED, offset=PostgresOffsetContext [sourceInfoSchema=Schema{io.debezium.connector.postgresql.Source:STRUCT}, sourceInfo=source_info[server='postgres_service'db='postgres', lsn=LSN{0/295A0A8}, txId=565, timestamp=2024-07-10T02:58:18.929445Z, snapshot=FALSE, schema=, table=], lastSnapshotRecord=true, lastCompletelyProcessedLsn=null, lastCommitLsn=null, streamingStoppingLsn=null, transactionContext=TransactionContext [currentTransactionId=null, perTableEventCount={}, totalEventCount=0], incrementalSnapshotContext=IncrementalSnapshotContext [windowOpened=false, chunkEndPosition=null, dataCollectionsToSnapshot=[], lastEventKeySent=null, maximumKey=null]]] (io.debezium.pipeline.ChangeEventSourceCoordinator:254)
[2024-07-10 11:04:34,808] INFO [postgres-connector|task-0] Connected metrics set to 'true' (io.debezium.pipeline.ChangeEventSourceCoordinator:425)
[2024-07-10 11:04:34,808] INFO [postgres-connector|task-0] SignalProcessor started. Scheduling it every 5000ms (io.debezium.pipeline.signal.SignalProcessor:105)
[2024-07-10 11:04:34,808] INFO [postgres-connector|task-0] Creating thread debezium-postgresconnector-postgres_service-SignalProcessor (io.debezium.util.Threads:288)
[2024-07-10 11:04:34,808] INFO [postgres-connector|task-0] Successfully restarted task (io.debezium.connector.common.BaseSourceTask:252)
[2024-07-10 11:04:34,818] INFO [postgres-connector|task-0] REPLICA IDENTITY for 'debezium.stock_example' is 'DEFAULT'; UPDATE and DELETE events will contain previous values only for PK columns (io.debezium.connector.postgresql.PostgresSchema:100)
[2024-07-10 11:04:34,830] INFO [postgres-connector|task-0] REPLICA IDENTITY for 'debezium.index_example' is 'DEFAULT'; UPDATE and DELETE events will contain previous values only for PK columns (io.debezium.connector.postgresql.PostgresSchema:100)
[2024-07-10 11:04:34,831] INFO [postgres-connector|task-0] Starting streaming (io.debezium.pipeline.ChangeEventSourceCoordinator:271)
[2024-07-10 11:04:34,831] INFO [postgres-connector|task-0] Retrieved latest position from stored offset 'LSN{0/295A0A8}' (io.debezium.connector.postgresql.PostgresStreamingChangeEventSource:141)
[2024-07-10 11:04:34,832] INFO [postgres-connector|task-0] Looking for WAL restart position for last commit LSN 'null' and last change LSN 'LSN{0/295A0A8}' (io.debezium.connector.postgresql.connection.WalPositionLocator:48)
[2024-07-10 11:04:34,842] INFO [postgres-connector|task-0] Obtained valid replication slot ReplicationSlot [active=false, latestFlushedLsn=LSN{0/175A408}, catalogXmin=534] (io.debezium.connector.postgresql.connection.PostgresConnection:325)
[2024-07-10 11:04:34,842] INFO [postgres-connector|task-0] Connection gracefully closed (io.debezium.jdbc.JdbcConnection:949)
[2024-07-10 11:04:34,861] INFO [postgres-connector|task-0] Requested thread factory for connector PostgresConnector, id = postgres_service named = keep-alive (io.debezium.util.Threads:271)
[2024-07-10 11:04:34,861] INFO [postgres-connector|task-0] Creating thread debezium-postgresconnector-postgres_service-keep-alive (io.debezium.util.Threads:288)
[2024-07-10 11:04:34,876] INFO [postgres-connector|task-0] REPLICA IDENTITY for 'debezium.stock_example' is 'DEFAULT'; UPDATE and DELETE events will contain previous values only for PK columns (io.debezium.connector.postgresql.PostgresSchema:100)
[2024-07-10 11:04:34,877] INFO [postgres-connector|task-0] REPLICA IDENTITY for 'debezium.index_example' is 'DEFAULT'; UPDATE and DELETE events will contain previous values only for PK columns (io.debezium.connector.postgresql.PostgresSchema:100)
[2024-07-10 11:04:34,878] INFO [postgres-connector|task-0] Searching for WAL resume position (io.debezium.connector.postgresql.PostgresStreamingChangeEventSource:342)
[2024-07-10 11:04:35,389] INFO [postgres-connector|task-0] First LSN 'LSN{0/295A1F0}' received (io.debezium.connector.postgresql.connection.WalPositionLocator:71)
[2024-07-10 11:04:35,389] INFO [postgres-connector|task-0] WAL resume position 'LSN{0/295A1F0}' discovered (io.debezium.connector.postgresql.PostgresStreamingChangeEventSource:364)
[2024-07-10 11:04:35,390] INFO [postgres-connector|task-0] Connection gracefully closed (io.debezium.jdbc.JdbcConnection:949)
[2024-07-10 11:04:35,394] ERROR [postgres-connector|task-0] Producer failure (io.debezium.pipeline.ErrorHandler:52)
org.postgresql.util.PSQLException: FATAL: the database system is in recovery mode

Any thoughts about what the problem could be?

0