Emails 0.1.16: Brevo polling picks up where it left off
Emails 0.1.16 makes Brevo event polling remember how far it got, so each cycle reads only new events instead of the same two days again.
Each Brevo account now keeps a saved position, a day and an offset, and a cycle continues from there. A busy sender with more events than one cycle covers now catches up over the next cycles instead of never reaching its newest events. A short re-check of the previous day catches events that Brevo indexed late. Saved positions of accounts that were deleted or excluded from polling are cleared. A bug that made the offset for today stand still on a short page, so the same events were read every cycle, is fixed as well.
The release also takes the SQS client to beamlab_ex_aws_sqs 5.0, declared as ex_aws_sqs, matching PhoenixKit core. Its API is unchanged.
Full release notes: Emails 0.1.16
0.1.16 · 20 July 2026
Changed
BrevoPollingJobno longer re-fetches the fixed[yesterday, today]window from offset 0 every cycle. Each integration’s progress is now a persisted%{date, offset}watermark (stored viaPhoenixKit.Settings’ JSON-by-prefix helpers), so a cycle queries a single day at its last-known offset instead of re-paying the re-fetch + dedup-lookup cost for every already-processed event, and a sender producing more events than one cycle’s page cap covers can still reach its newest events over successive cycles instead of never catching up. A trailing one-day re-check (its own small page budget, independent of the forward walk’s) guards against Brevo’s ~30-60s indexing lag and undocumentedstartDate/endDatetimezone. Watermarks for integrations no longer active (deleted or excluded from polling) are pruned each cycle. (#20)
Fixed
- The above watermark’s offset for today specifically never advanced past a non-empty short page — every cycle re-fetched and re-processed the same tail of today’s events for as long as today’s total stayed under the page limit, which is the common case at normal volumes. Now advances by the number of events actually returned. (#20)
Emails 0.1.16. Install or update: {:phoenix_kit_emails, "~> 0.1"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.