Skip to content
DevOps · Terminal

NATS

Publish, subscribe and JetStream from the nats CLI.
  • 20 Dcoins / hour
  • standard machine
  • ready in about 10 seconds
  • devops
  • development
  • cloud-computing

About NATS

NATS is a small, fast messaging system for connecting services: publish a message on a subject and every subscriber listening on that subject receives it. This lab runs NATS Server 2.15 with JetStream switched on, and gives you a browser terminal on the same machine with the official nats command-line client already pointed at it.

Open the page in two tabs and you have both ends of a conversation. Subscribe to a wildcard subject in one and publish in the other, then try request and reply, and queue groups that share work between subscribers. With JetStream you create a stream, publish into it and replay messages through consumers that remember where they stopped. The server's monitoring endpoints, such as /varz and /connz, show connections and subscriptions as they happen.

Streams are kept on your volume. It suits distributed systems and cloud-native courses, and makes a light contrast with the Kafka and Redpanda labs.

What is installed

  • NATS server with JetStream
  • nats CLI in a browser terminal
  • HTTP monitoring endpoints
  • Streams kept on your volume

What it is good for

  • Publish / subscribe basics
  • Request-reply and queue groups
  • JetStream streams and consumers
  • Lighter alternative to Kafka

What it costs

20 Dcoins an hour while it runs (a standard machine), billed by the minute. Included on Pro and Power. Every new account starts with free Dcoins.

From Start to a working NATS takes about 10 seconds, measured on our lab server. If the server is asleep, waking it first adds a minute or two.

Courses that practise this

Similar labs