Skip to content

Ameliob18/wirevault

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

⚡ WireVault — The Webhook Ledger

WireVault Dashboard

"Every packet of data deserves a delivery guarantee."

WireVault is a zero-loss webhook delivery engine built for developers who refuse to let events disappear into the void. Inspired by the philosophy of Redis — minimal, fast, indestructible — WireVault gives you a persistent, observable, and replayable layer in front of your webhook endpoints.

Think of it as tail -f for your integrations, with automatic retries baked in.


Why WireVault?

When Stripe fires a payment.succeeded event and your server is down, that event is gone. When a PayPal IPN hits during a deploy, it's gone. WireVault catches everything, stores it durably, retries with exponential backoff, and lets you replay any event at any time.

Stripe → POST /v1/ingest/my-vault → [202 in <5ms] → PostgreSQL → Dispatcher → Your Server
                                                                        ↓
                                                              Retry: 1m → 5m → 15m → 1h → 6h → 12h

Features

  • Zero-loss ingestion — 202 Accepted in under 5ms, persistence is async
  • Exponential backoff — 6 retry stages before marking as permanently failed
  • Virtual Threads — Java 21 Project Loom for massive concurrency, tiny footprint
  • GIN-indexed JSONB — Google-style search inside webhook payloads
  • Live dashboard — WebSocket-powered terminal UI, tail -f style
  • REPLAY command — Re-send any webhook on demand, instantly
  • Prometheus metrics — Throughput counter out of the box
  • Native-ready — GraalVM native compilation for <50ms startup

Stack

Layer Technology
Runtime Java 21 + Virtual Threads (Project Loom)
Framework Quarkus 3.x (GraalVM native-ready)
Database PostgreSQL 16 + GIN indexes on JSONB
Cache/Queue Redis 7
API REST (ingest + ledger) + WebSocket (dashboard)
Metrics Micrometer + Prometheus
Migrations Flyway

Quick Start

Docker Compose (recommended)

git clone https://github.com/YOUR_USERNAME/wirevault
cd wirevault
docker-compose up -d

WireVault is available at http://localhost:8080

Local Dev

Requirements: Java 21+, Maven 3.9+, PostgreSQL 16, Redis 7

# Start dependencies
docker-compose up -d postgres redis

# Run in dev mode (hot reload)
./mvnw quarkus:dev

API Reference

Register a Vault

curl -X POST http://localhost:8080/v1/ledger/vaults \
  -H "Content-Type: application/json" \
  -d '{
    "vaultKey": "my-stripe-vault",
    "targetUrl": "https://myapp.com/webhooks/stripe",
    "signingSecret": "whsec_..."
  }'

Ingest a Webhook

Point your external provider (Stripe, PayPal, GitHub, etc.) to:

POST http://localhost:8080/v1/ingest/{vault_key}

WireVault returns 202 Accepted in under 5ms. Your provider never waits.

# Simulate an incoming webhook
curl -X POST http://localhost:8080/v1/ingest/my-stripe-vault \
  -H "Content-Type: application/json" \
  -d '{"type":"payment_intent.succeeded","data":{"object":{"amount":9900}}}'

# → {"id":"550e8400-...","status":"ACCEPTED","vault_key":"my-stripe-vault"}

LIST — Recent webhooks

curl http://localhost:8080/v1/ledger/my-stripe-vault?limit=20

INSPECT — Full payload + delivery history

curl http://localhost:8080/v1/ledger/my-stripe-vault/inspect/{id}

REPLAY — Force immediate re-delivery

curl -X POST http://localhost:8080/v1/ledger/my-stripe-vault/replay/{id}

SEARCH — GIN-powered JSON search

# Find all payment_intent.succeeded events
curl "http://localhost:8080/v1/ledger/my-stripe-vault/search?q=%7B%22type%22%3A%22payment_intent.succeeded%22%7D"

Dashboard

Open http://localhost:8080 for the live terminal dashboard:

  • Real-time feed (WebSocket) — new webhooks appear instantly as they're ingested
  • Click any row to inspect the full payload and delivery attempt history
  • REPLAY button on every row
  • SEARCH bar for instant JSONB querying

Retry Schedule

Attempt Delay
1 1 minute
2 5 minutes
3 15 minutes
4 1 hour
5 6 hours
6 12 hours
FAILED (permanent)

Metrics

Prometheus metrics are available at /metrics:

wirevault_webhooks_ingested_total    — events received
wirevault_webhooks_delivered_total   — events successfully delivered
wirevault_webhooks_failed_total      — events permanently failed

Health check: GET /health


Native Build (GraalVM)

./mvnw package -Pnative
./target/wirevault-runner

Expected startup time: < 50ms. RAM usage: ~30MB.


Smoke Test

chmod +x test.sh
./test.sh http://localhost:8080

Roadmap

  • mTLS support for enterprise deployments
  • Webhook signature verification (HMAC-SHA256)
  • Multi-tenant vault isolation
  • gRPC internal transport
  • Retention policies (30 / 90 days)
  • WireVault Cloud SaaS offering

License

MIT — Use it, fork it, sell it. Ship good software.


Built with Java 21 + Quarkus + ☕

About

Zero-loss webhook delivery engine. Catch, store, retry and replay webhooks — Java 21 Virtual Threads + Quarkus.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors