DevTools Logo

Distributed Systems & Network Topology Simulator

About this tool

The Distributed Systems & Network Topology Simulator runs a tick-based, pure-TypeScript simulation of request traffic flowing through a topology you assemble from clients, load balancers, API gateways, microservices, message queues, distributed databases and caches — entirely in your browser, with no real network calls.

Each tick, client nodes originate requests that are routed through the graph: load balancers pick a downstream target (round robin, weighted, or least connections), API gateways and microservices gate traffic through a Hystrix/Resilience4j-style circuit breaker, queues buffer and drain messages at a configured rate, caches serve a TTL-decaying hit ratio, and databases model master-replica, quorum or Raft consensus topologies.

Chaos actions let you kill a node, partition it from the network, add packet loss (5-50%), inject a latency spike (500ms+), or force a circuit breaker open — then watch per-node status, latency and error-rate metrics react live on the graph and in the metrics tables below it.

Raft-backed databases expose a genuine split-brain lesson: quorumSize configured as a true majority of replicaCount makes split-brain structurally impossible even under a partition, while a misconfigured quorumSize lets two partition groups both elect a leader — the exact failure mode real Raft deployments are built to prevent.

Once you're happy with a topology, the Export tab generates a Docker Compose file, Kubernetes Deployment/Service manifests, and Mermaid or PlantUML architecture diagram code — starter scaffolding to sketch the shape of a real system, not a deploy-ready stack.

How to use

  1. Load a topology

    Pick a preset — three-tier web app, event-driven pipeline, or Raft cluster — from the dropdown.

  2. Run the simulation

    Press Run to advance the simulation continuously, or Step to advance one tick at a time.

  3. Select a node

    Click any node on the graph to target it with chaos actions in the side panel.

  4. Inject chaos

    Kill or partition a node, add packet loss or a latency spike, or trip a circuit breaker, then watch the graph and metrics tables react.

  5. Read the metrics

    The Metrics tab lists per-node status, latency, error rate, plus circuit breaker phase and Raft leader/split-brain state.

  6. Export the topology

    Copy or download Docker Compose, Kubernetes manifests, Mermaid or PlantUML from the Export tab.

Use cases

Teaching quorum and split-brain risk

Show why quorumSize must be a strict majority of replicaCount, by contrasting a safe and an unsafe configuration side by side.

Explaining circuit breaker behavior

Demonstrate the closed → open → half-open → closed state machine without spinning up Hystrix or Resilience4j.

Sketching a topology before building it

Rough out a load balancer / gateway / service / cache / database shape and export a starter Docker Compose or Kubernetes manifest to iterate on.

Chaos engineering intuition

Explore how packet loss, latency spikes and node kills propagate through a request graph before running a real chaos experiment.

Common mistakes

Mistake:Treating the simulation as a real infrastructure test.

Fix:It's a client-side, educational model — see the warning banner. No real services, network calls or infrastructure are involved; use it to build intuition, not to validate a production design.

Mistake:Assuming any quorumSize prevents split-brain.

Fix:Only a quorumSize that is a strict majority of replicaCount (> replicaCount / 2) guarantees a partition can't elect two leaders — a quorumSize of half or less can split-brain.

Mistake:Expecting the exported manifests to be deploy-ready.

Fix:Docker Compose and Kubernetes exports are scaffolding with placeholder images and no resource limits, probes or secrets — a starting point to edit, not a finished deployment.

Frequently asked questions

.htaccess Generator

Build an Apache .htaccess — HTTPS redirects, rewrites, error pages, security headers, and basic auth

2D Fluid Dynamics & Particle Physics Sandbox

A physics playground with two engines sharing one canvas. The fluid mode runs a real Eulerian Navier-Stokes solver — semi-Lagrangian advection, explicit diffusion, Jacobi pressure projection and vorticity confinement — that you paint with dye and velocity using mouse or touch. The particle mode is a damped Verlet N-body engine with gravity wells, Coulomb attractors and repulsors, spring links, wall restitution and elastic circle collisions. Particle counts adapt to the device (100k target on WebGL2 desktop, 2k-5k on CPU fallback), and every configuration exports as runnable code: a Matter.js world, a PixiJS ticker setup, or a standalone vanilla Canvas engine.

Algorithm Arena & Data Structure Visualizer

Interactive arena for algorithms and data structures: eight sorting algorithms racing on one seeded input, six pathfinding algorithms walking generated mazes, and BST, AVL, Red-Black, B-tree, heap and trie operations replayed step by step with rotations highlighted. Every run shows the Big-O table and the phase-highlighted reference implementation in four languages, and compared values can be played as pitch (sonification) through the shared audio engine. Everything runs client-side; inputs never leave the browser.

Ansible Playbook Generator

Build an Ansible playbook — hosts, vars, and tasks with modules — as YAML

Apache Config Generator

Build an Apache 2.4 VirtualHost — ServerName, DocumentRoot, Directory, aliases, and optional SSL

AWS Architecture Diagram

Drag-and-drop AWS service blocks, connect edges and export architecture diagrams as SVG