Postgres CDC Source V2 (Debezium) connector permission denied error


I’m currently using the Postgres CDC Source V2 (Debezium) connector to connect to an AWS Aurora PostgreSQL database and getting permission denied error.

I have enabled the rds.logical_replication=1 setting on the server, and the wal_level parameter is set to logical. When I select ‘Snapshot mode’ = ‘initial_only’ in the connector settings under Configuration, I can see messages being generated in the topics. However, when I change the ‘Snapshot mode’ value to ‘initial’ or ‘never’, the connection fails and I receive a ‘Permission denied for database confluentcloud. Please make sure the database user has the required permissions.’ error.

I have already completed the prerequisites mentioned in the PostgreSQL CDC Source V2 (Debezium) Connector for Confluent Cloud page for connecting to PostgreSQL on Amazon RDS:

  1. I have set rds.logical_replication to 1.
  2. I have verified that the wal_level parameter is set to logical.
  3. I did not need to explicitly set the Debezium parameter to pgoutput as I am using PostgreSQL version 15, where the default output parameter is already set to pgoutput.
  4. I have executed the GRANT rds_replication to my_user command using pgadmin and not aws master user(and i am not sure if this is the issue), which is used for the Confluent Cloud connection to PostgreSQL.

Has anyone else encountered a similar error before or any recommendations on fixing it.