Start a flow
Poll for changes
Checks a system regularly and starts a run only for records that are new or changed.
- Good for
- Change data capture without webhooks
- Role
- Starts a flow
- Find it in
- Nodes › Triggers
When to use it
- The system cannot send webhooks, but you can read from it.
- You need inserts, updates and deletes from a database table.
- Checks that find nothing new should not start a run.
Reach for something else when
Example
Watch the orders table with a change detection key on id, keep only the deletions and record them in a data table for auditing.
How it works
The poll trigger checks a system on a schedule and passes on only what is new. The first poll sets a baseline and fires nothing.
- Choose the Connector. For databases type the query in SQL / command (for example
SELECT id, name, amount, updated_at FROM orders) or pick a saved operation; for apps choose an Event or Fetch operation. - Choose how new records are recognized:
- Cursor field (default
updated_at): passes on records whose cursor is newer than last time. - Change detection key (CDC): enter the field(s) that identify a record, such as
id(comma-separated for a composite key). The platform remembers a fingerprint of every record and reports inserts, updates and deletes.
- Choose the Connection and Poll every, save and set the flow Active.
With a change detection key each change arrives as one record with _change (insert, update or delete) and _key. Route on _change with conditional edges. A record is delivered only when its content really changes, and an empty poll starts no run.
Pause when trigger deduplication is unavailable makes the trigger wait rather than risk a duplicate if its memory of past records cannot be checked.
Native log CDC (write-ahead log)
Turn on Native log CDC to read the database's own change log instead of querying tables: true inserts, updates and deletes in commit order, no polling load on the source, and resume exactly where it left off. PostgreSQL is generally available; the others are marked Experimental in the product.
| Source | What to enable or provide |
|---|---|
| PostgreSQL | Logical replication. |
| SQL Server | Change data capture and the Tracked table. |
| MySQL / MariaDB | The binary log in row format. |
| MongoDB | Change streams. |
| Oracle | Flashback access and the tracked table. |
| CouchDB | The _changes feed. |
| Databricks | Delta Change Data Feed. |
| Snowflake | Change tracking. |
| Neo4j | CDC. |
| Google BigQuery | Append history. |
| DynamoDB | DynamoDB Streams. |
Add it to a flow
- Open the flow from Build › Workflows.
- Open Nodes and find Poll for changes under Triggers. Drag it onto the canvas as the first step.
- Connect it to the next step and open its settings with ✎ Edit.
- Save and test with Run, then set the flow Active so it starts on its own.