'Debezium Postgres Connector Error Getting before data as always null for DELETE/ UPDATE operation
While using the Debezium Postgres connector for capturing the change data on Aurora Postgres, we saw for all the INSERT operations we are getting the captured data correctly. But for the UPDATE operation, we are seeing that we do not have any before/old data just the getting the after/new data. Also for DELETE operation, we are getting the primary key value filled in just, and the rest of the fields are set to null.
Our configuration for debezium connector in apache camel is as below:
String uri = "debezium-postgres:dbz-test-1?" +
"databaseHostName=" + host +
"&databaseUser=" + username +
"&databasePassword=" + password +
"&databasePort=" + port +
"&databaseDbname=" + dbName +
"&slotName=" + dbName +
"&databaseSslMode=require" +
"&databaseServerName=my-server1" +
"&offsetStorageFileName=offset-file-1.dat" +
"&snapshotMode=initial" +
"&pluginName=pgoutput" +
"&eventProcessingFailureHandlingMode=warn" +
"&tombstonesOnDelete=false" +
"&databaseHistoryFileFilename=history-file-1.dat";
2 things that we basically tried:
- Setting the
tombstonesOnDeleteto false explicitly... but it did not help much. - Set the REPLICA_IDENTITY for a specific table to value FULL. But after setting this value, the UPDATES are leading to replication status getting set to down. Basically, the PG logical replication goes down.
Could anyone please help? My requirement is to get all of the before/old data during UPDATE and DELETE operation.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
