Coffrify. Runtime. WebhookReplay. Redis
(Coffrify v0.9.0)
View Source
Redis-backed replay store. Atomic SET NX EX across nodes.
Example
{:ok, conn} = Redix.start_link("redis://localhost:6379")
store = Coffrify.Runtime.WebhookReplay.Redis.new(conn: conn)
if Coffrify.Runtime.WebhookReplay.seen?(store, event_id, 86_400_000) do
# already processed; ack and skip
else
handle(event)
end