apache/seatunnel · error · ConnectException
Value <column> in the pg_replication_slots table for slot =
Error message
Value <column> in the pg_replication_slots table for slot = '<slotName>', plugin = '<pluginName>', database = '<database>' is not valid. This is an abnormal situation and the database status should be checked.
What it means
tryParseLsn converts the string value of a column (confirmed_flush_lsn or restart_lsn) from pg_replication_slots into a Debezium Lsn via Lsn.valueOf. If the string cannot be parsed, it throws this ConnectException indicating the slot row holds a corrupt/unsupported LSN value and the database state should be inspected.
Source
Thrown at seatunnel-connectors-v2/connector-cdc/connector-cdc-opengauss/src/main/java/io/debezium/connector/postgresql/connection/PostgresConnection.java:421
throw new ConnectException("restart_lsn could be found");
}
return restartLsn;
}
private Lsn tryParseLsn(
String slotName, String pluginName, String database, ResultSet rs, String column)
throws ConnectException, SQLException {
Lsn lsn = null;
String lsnStr = rs.getString(column);
if (lsnStr == null) {
return null;
}
try {
lsn = Lsn.valueOf(lsnStr);
} catch (Exception e) {
throw new ConnectException(
"Value "
+ column
+ " in the pg_replication_slots table for slot = '"
+ slotName
+ "', plugin = '"
+ pluginName
+ "', database = '"
+ database
+ "' is not valid. This is an abnormal situation and the database status should be checked.");
}
if (!lsn.isValid()) {
throw new ConnectException("Invalid LSN returned from database");
}
return lsn;
}
/**
* Drops a replication slot that was created on the DBView on GitHub (pinned to cf67b549a7)
Solutions
- Inspect the raw value: SELECT slot_name, plugin, database, confirmed_flush_lsn, restart_lsn FROM pg_replication_slots WHERE slot_name = '<slot>';
- Drop and recreate the corrupted slot: SELECT pg_drop_replication_slot('<slot>'); then pg_create_logical_replication_slot(...).
- Verify the connector variant matches the database flavor (use the OpenGauss-appropriate Debezium connector, not vanilla Postgres, if LSN formats differ).
- Check database logs for catalog corruption and consider a restart of the database instance.
Example fix
-- before: corrupted slot value aborts startup
SELECT slot_name, restart_lsn FROM pg_replication_slots; -- shows invalid value
-- after: recreate the slot
SELECT pg_drop_replication_slot('seatunnel_slot');
SELECT pg_create_logical_replication_slot('seatunnel_slot', 'pgoutput'); Defensive patterns
Strategy: validation
Validate before calling
SELECT confirmed_flush_lsn, restart_lsn FROM pg_replication_slots WHERE slot_name = 'slot'; -- values must match PostgreSQL LSN format, e.g. 0/1A2B3C4
Try / catch
try {
connection.getReplicationSlotState(slotName, pluginName);
} catch (ConnectException e) {
// drop and recreate the slot, then restart the connector
} Prevention
- Use the connector variant that matches the database flavor (OpenGauss vs PostgreSQL).
- Check slot LSNs after any database crash before restarting connectors.
- Avoid manual edits to replication slot catalog entries.
When it happens
Trigger: Lsn.valueOf(lsnStr) throws for the value of the given column for slot '<slotName>', plugin '<pluginName>', database '<database>' — e.g. an empty/placeholder value, a format produced by an OpenGauss fork that differs from PostgreSQL's XXX/XXXXXXX hex LSN format.
Common situations: Using the opengauss CDC connector against a server whose pg_replication_slots LSN rendering differs from vanilla PostgreSQL; corrupted catalog entries after a crash; manually tampered slot metadata.
Understand the failure class
Background: "Invalid ... format", "must be in format X", "does not look like a ..." — invalid argument format errors across CLI tools and libraries — this error's family across 17 libraries.
Related errors
- Neither confirmed_flush_lsn nor restart_lsn could be found
- restart_lsn could be found
- Invalid LSN returned from database
- Error getting current Lsn/txId ${e.getMessage()}
- Read the binlog offset error
AI-assisted analysis of apache/seatunnel@cf67b549a7 (2026-09-10).
Data as JSON: /api/errors/e29497a80c6e11b8.
Report an issue: GitHub.