Skip to main content
The Popsink Postgres target connector consolidates transactional and analytical data in a PostgreSQL database while honoring your organization’s security and governance requirements.

Compatible versions

PostgreSQL 12 still works but has reached end of life upstream and is no longer covered.

Prerequisites

  • Roles and permissions: a PostgreSQL role with CREATE, INSERT, UPDATE, DELETE, and ALTER rights on the target schema, plus permission to execute functions required for COPY or INSERT operations.
  • Infrastructure settings: outbound network access from Popsink to port 5432 (or your custom port) with TLS enabled and root certificates imported. See Compatible versions for the supported PostgreSQL releases.
  • Quotas and limits: provision disk capacity for at least 150% of the expected daily volume and verify concurrent connection limits (max_connections) to accommodate Popsink workers.
  • Monitoring and audits: enable pg_stat_statements and error logging to trace connector activity.

Configuration

1

Declare the destination

Provide the host, port, database, and target schema in Popsink. Attach a secret containing the user, password, and SSL string (sslmode=require) if needed.
2

Configure the write mode

Choose COPY for large volumes or INSERT for smaller datasets. Configure the maximum batch size (batch_size) and duplicate key handling (upsert_strategy).
3

Schedule loads

Define the sync cadence and retention rules for intermediate files. Ensure maintenance windows do not overlap with scheduled batches.

Data types

Popsink creates each table on its first record. Columns are typed from the Avro schema of the source record, read from the Schema Registry, never from the values. When a subscription applies its column mapping, an explicit cast in the mapping takes precedence. An existing table keeps the types it already has. A cast in the column mapping produces: int / long → bigint, float / double → double precision, bool → boolean, date → date, datetime → timestamp, time → time, decimal → numeric(p,s) from its format (numeric(38,9) when none is given), any other cast → text.
Timestamps without a time zone are written as UTC in timestamp columns; only a Debezium ZonedTimestamp keeps its offset, in timestamptz. PostgreSQL stores microseconds, so nanosecond values are truncated. JSON is written as text, not jsonb, and UUIDs as text unless the table already has a uuid column. Nested records and maps are not supported as columns: flatten them in the column mapping.

Schema evolution

  • New source columns are added with ALTER TABLE … ADD.
  • Type changes are applied with ALTER COLUMN … TYPE when the new type is wider. Decimals are widened, never narrowed. If PostgreSQL refuses the change, the subscription stops on that table instead of skipping data.
  • Dropped source columns are kept in the table, and stay NULL for new rows.
  • With schema evolution off on the subscription, any change that needs an ALTER stops the subscription.

Monitoring

  • Instrument a dashboard built on pg_stat_activity, lock durations (pg_locks), and Popsink metrics (throughput, latency, errors).
  • Enable job failure notifications in Popsink and forward PostgreSQL logs to your SIEM.
  • Configure disk quotas and WAL usage alerts to prevent replication stoppages.

Best practices

  • Normalize data types (UUID, JSONB, timestamp with time zone) to avoid expensive conversions.
  • Document target tables with SQL comments to streamline maintenance.
  • Orchestrate schema changes outside of loading windows.
Avoid setting synchronous_commit=off on the Popsink session: if a failure occurs, you may lose transactions that were confirmed on the source.

FAQ

Enable upsert mode with ON CONFLICT DO UPDATE and use a versioning column (updated_at) to resolve collisions.
Declare the parent table in Popsink and ensure the PostgreSQL partitioning strategy routes rows automatically via triggers or PARTITION BY.
Start with Popsink logs to identify the failing step, then correlate with postgresql.log and pg_stat_activity for SQL details.

Monitor targets

Understand metrics shared across all target connectors.

Alerting Popsink

Configure notifications and webhooks when incidents occur.

Start a pipeline

End-to-end example to validate your Postgres configuration.