Available for work
Distributed systems · Real-time/2026/Live

Votecast

A polling system where a vote is never lost, even mid-crash.

Votecast preview
Overview

An event-driven, fault-tolerant polling engine. Votes queue durably through Kafka, persist to Postgres, and stream back to every client in real time. Built to survive a server going down without dropping a single ballot.

Stack
  • Node.js
  • TypeScript
  • Kafka
  • Zookeeper
  • PostgreSQL
  • Prisma
  • WebSockets
  • Docker
How it works
  1. 01

    Architected an event-driven pipeline where each vote is published to a Kafka topic, consumed by a worker, and persisted to Postgres, guaranteeing zero loss even under server failure.

  2. 02

    Made vote processing idempotent with producer-stamped UUIDs and a unique constraint, so Kafka's at-least-once delivery never turns into a double vote.

  3. 03

    Built a WebSocket broadcast layer that pushes live counts to every connected client within about 50ms of a commit, with per-poll rooms to avoid needless fan-out.

  4. 04

    Containerised the whole stack (Kafka, Zookeeper, Postgres) with health checks and ordered startup for a one-command dev environment.

Menu00%