Contents

Four days ago I posted the pitch for grappa-irc — an IRC BNC with a REST API and a PWA that only speaks HTTP. README-driven, pre-alpha, no code. Four days later, first update: work has started, and we picked the stack.

Stack: Elixir on BEAM

First take was Rust + tokio + axum + sqlx. Solid on memory safety and per-core performance, IRC parser ready in the irc crate, walking-skeleton plan already drafted.

Then I stepped back and looked at the problem again. What does grappa actually do?

  • Long-lived TCP connections, one per user.
  • Per-user persistent state: channels, scrollback, modes.
  • Crash isolation: if a user’s upstream connection dies, no one else notices.
  • Hot code reload: ship updates without dropping sessions.
  • Massive IO-bound concurrency: every user is a process sleeping until a PRIVMSG arrives.

That list is the original Erlang brief. Telecom in the ’80s = millions of concurrent calls, long-running, isolated, hot-upgradable. It’s exactly the shape of an IRC bouncer multiplied by N users — a fit so clean I felt slow for not seeing it sooner.

And on top sits Phoenix: mature web framework, native REST + Channels (WebSocket), with client-side (phoenix.js) already battle-tested at Discord scale. I don’t have to reinvent the transport between grappa and cicchetto: it’s there, proven, designed for exactly the pattern of stateful per-user server pushing events to the browser.

Pattern matching on tuples and binaries collapses an IRC parser into three lines. Supervision trees replace “one tokio task per user” with a declarative model: a DynamicSupervisor spawns one GenServer per user, and if one crashes it restarts on its own, no neighbors disturbed. Hot reload comes free from the runtime. Mnesia or Ecto + sqlite for scrollback.

WhatsApp has run on BEAM forever — not nostalgia: the model fits. Pattern proven at scales grappa will never see.

Rust is still one of my favorite languages. For grappa, though, BEAM is the fit.

Next

  • README finalized.
  • Walking-skeleton rewritten in Elixir/Phoenix (the Rust plan is archived, not trashed — the walking-skeleton structure stands regardless of language).
  • Phase 1.

Open repo: github.com/vjt/grappa-irc. Issues welcome. On #grappa via Azzurra webchat you’ll find vjt-claude (the AI I handed the project context to) or me, when I’m around.