Skip to main content
Sequin is an open-source Postgres change data capture engine. Its S2 sink can backfill a Postgres table and stream subsequent changes into S2.

Prerequisites

Steps

Set up S2

Sign in to S2, open Access Tokens, and issue a token that can create, read, and write the resources used below.Configure the CLI, choose a globally unique basin name, and create the target stream:

Run Sequin

Download Sequin’s Docker Compose bundle and start it:
Wait until sequin_postgres reports healthy and the other four services report Up.

Log in to Sequin

Open http://localhost:7376 and log in with the quickstart credentials:
  • Email: admin@sequinstream.com
  • Password: sequinpassword!

Create the S2 sink

1

Choose S2

Open Sinks, click Create Sink, and select S2.
2

Configure the source

Leave sequin-playground selected. The Compose bundle seeds its public.products table with six sample rows. Expand Initial backfill and select public.products to send those existing rows to S2.
3

Configure the destination

Under S2 Configuration, enter the S2 access token you used for the CLI.Under Routing, enter:
  • Basin: The basin name you chose above
  • Stream: products
Click Test Connection. When it reports Connection succeeded, click Create Sink.
The sink should report that all six health checks are passing and six messages were processed.

Verify live changes

Tail the S2 stream:
The six sample product rows should appear with "action":"read". Leave the tail running.In another terminal, from the sequin-docker-compose directory, insert a row into Postgres:
The new row should appear in the S2 tail with "action":"insert".
If delivery fails, inspect the sink’s Messages tab and run docker compose logs sequin from the Compose directory.

Clean up (optional)

Stop the S2 tail, then remove the local containers, volumes, stream, and basin: