Skip to content
Theory · NATS: subjects and queue groups · lesson 1 of 8

Publish and subscribe in NATS

A dispatcher's microphone on the channel orders: two radios that are on hear it, the third, switched off, gets nothing, nothing is recorded

A currency service sends out the latest exchange rate once a second, and the shop front and the shipping calculator display it. If the shop front was restarting and missed one value, no harm done: the next one arrives a second later. There is no point in keeping such messages on disk, as Kafka or RabbitMQ would.

In this lesson

  • Subject and subscription
  • A message with no subscriber
  • Subscribing in Go
  • Slow consumer
  • Common mistake
  • Key points