Initial release
[websub-hub] / src / db / postgres / sql / subscription-delivery-claim-by-id.sql
1 --
2 INSERT INTO subscription_delivery_in_progress (id, claimant, claimed, claim_expires)
3 VALUES ($(subscriptionId), $(claimant), now(), now() + $(claimTimeoutSeconds)::text::interval)
4 ON CONFLICT (id) DO UPDATE
5 SET
6 claimant = $(claimant),
7 claimed = now(),
8 claim_expires = now() + $(claimTimeoutSeconds)::text::interval
9 RETURNING id