---
title: "Welcome to the Wonderful World of Clusters"
description: "Replit split its infrastructure into multiple independent clusters (failure domains) after two load-related site-wide outages, moving paid Hacker users into their own cluster so future incidents affect only a subset of users."
url: "https://swe.quest/articles/welcome-to-the-wonderful-world-of-clusters-52a29e1c3fc463f3"
canonical: "https://replit.com/blog/welcome-to-the-wonderful-world-of-clusters"
source: "Replit"
published: "2021-03-26"
difficulty: "medium"
kind: "Case study"
reading_minutes: 5
tags: ["system-design","dns","resilience","distributed-systems","cloud"]
---

# Welcome to the Wonderful World of Clusters

A post on [Replit](https://swe.quest/sources/replit.md), published 2021-03-26, 5 min read, Case study. Original: [https://replit.com/blog/welcome-to-the-wonderful-world-of-clusters](https://replit.com/blog/welcome-to-the-wonderful-world-of-clusters)

## Summary

Replit split its infrastructure into multiple independent clusters (failure domains) after two load-related site-wide outages, moving paid Hacker users into their own cluster so future incidents affect only a subset of users. A cluster resolution service exposed as an external DNS server maps repls to clusters for both the web server and \`.repl.co\` hosting, adding no extra lookup latency. Because DNS answers are cached, users moved between clusters leave tombstones in the old cluster that transparently proxy connections to the new one until the record's TTL expires. The new cluster also became a tool for shedding load during incidents and lets Replit run Hacker repls on beefier machines.

Written by swe.quest, not by the author.

**Difficulty:** Medium: assumes a working developer; shows how it is built or done

## Topics

- [System design](https://swe.quest/tags/system-design.md) (Architecture & design)
- [DNS](https://swe.quest/tags/dns.md) (Infrastructure)
- [Resilience](https://swe.quest/tags/resilience.md) (Distributed systems)
- [Distributed systems](https://swe.quest/tags/distributed-systems.md) (Distributed systems)
- [Cloud platforms](https://swe.quest/tags/cloud.md) (Infrastructure)

## Prerequisites

- DNS basics ([easy posts on DNS](https://swe.quest/tags/dns.md?difficulty=easy))
- eventual consistency ([easy posts on Consistency models](https://swe.quest/tags/consistency.md?difficulty=easy))

## Keywords

Replit, Google Compute Engine, Managed Instance Groups, repl.co

## Related posts

- [Why We Built Our Own DNS Infrastructure](https://swe.quest/articles/why-we-built-our-own-dns-infrastructure-b1c8975cd0ea6aa3.md): Replit · 2021-04-29 · Medium · 4 min read · DNS, Load balancing, Distributed systems, Go
  Replit made its repl hosting cluster-aware by running its own authoritative DNS server for \*.repl.co, which resolves each repl's domain to the proxy load balancer in the cluster hosting that repl.
- [Sharding Infrastructure: The Regional Goval Project](https://swe.quest/articles/sharding-infrastructure-the-regional-goval-project-86db1e97083bbccb.md): Replit · 2024-02-14 · Medium · 7 min read · Infrastructure as code, Distributed systems, Cloud platforms, Resilience, Deployment
  Replit re-sharded the infrastructure that runs Repls (Goval) from a few unbalanced, multi-region clusters partitioned by user membership into uniformly sized, single-region clusters with Repls distributed by consistent hashing, shrinking failure domains and removing cross-region traffic.
- [Data Loss: a sad tale with a happy ending](https://swe.quest/articles/data-loss-a-sad-tale-with-a-happy-ending-94994cb503d66c03.md): Replit · 2021-09-10 · Medium · 4 min read · Incidents & postmortems, Storage systems, Go, Debugging, Linux
  Replit silently lost or corrupted user repl data for months.
- [More Reliable Connections to Your Repls](https://swe.quest/articles/more-reliable-connections-to-your-repls-07578bd14f5efb1d.md): Replit · 2024-03-18 · Medium · 5 min read · Load balancing, System design, Resilience, SRE, Real-time systems
  Replit split reverse WebSocket proxying out of Conman, its container manager on GCE VMs, into a dedicated service called Eval that sits between clients and Conman VMs.
- [Keep the monolith, but split the workloads](https://swe.quest/articles/keep-the-monolith-but-split-the-workloads-a46b5ee6a5f1e352.md): incident.io · 2023-04-12 · Medium · 9 min read · Resilience, System design, PostgreSQL, Go, Microservices
  A Go monolith can get much of the reliability isolation of microservices by splitting workloads into separate deployments of the same binary, instead of breaking it into services.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
