feat: implement webhook delivery service with retry and signature verification (closes #111)#209
Merged
elizabetheonoja-art merged 1 commit intoJul 21, 2026
Conversation
…ification Closes Utility-Protocol#111 - Restructure src/webhooks.rs into src/webhooks/ module: - mod.rs: shared types, RetryPolicy with configurable delays, WebhookTransport trait - signer.rs: HMAC-SHA256 signing and verification functions - dispatcher.rs: WebhookDeliveryService with 10s timeout, per-endpoint rate limiting (100/min), and exponential backoff retry (10s, 30s, 2min, 10min, 30min) - dead_letter.rs: DeadLetterQueue trait + PostgresDlq implementation - Retry policy: fixed delays per spec (10s, 30s, 2min, 10min, 30min), max 5 retries - Permanent failures (non-retryable 4xx) returned immediately without DLQ - Transient failures retried with backoff, enqueued to DLQ after exhaustion - Rate limiting: 100 webhooks/min per endpoint via fixed-window counter - 10-second timeout per delivery attempt - Add webhook management API endpoints: - GET/POST /api/v1/webhooks/endpoints - DELETE /api/v1/webhooks/endpoints/:id - POST /api/v1/webhooks/endpoints/:id/test - GET /api/v1/webhooks/dead-letter - POST /api/v1/webhooks/dead-letter/:id/retry - Add DB migration for webhook_endpoints and dead_letter_webhooks tables - Add Prometheus metrics for webhook deliveries, latency, and retries - Update webhook tests to use new module structure and mock DLQ
elizabetheonoja-art
merged commit Jul 21, 2026
a08584a
into
Utility-Protocol:main
2 of 4 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements Issue #111 - Webhook Delivery Service with Retry and Signature Verification.
Changes
closes Webhook Delivery Service with Retry and Signature Verification #111