talira

Watermill

Build event-driven applications the easy way in Go

open sourceMITfree

Watermill is a Go library for building event-driven applications. You publish and handle events as plain Go structs, and it takes care of routing, serialization and the low-level details, with a router API like an HTTP router that supports middleware (recovery, correlation IDs, timeouts) and CQRS helpers. The same API works over Kafka, RabbitMQ, PostgreSQL, Redis, AWS SNS and other Pub/Subs, so you can switch providers without changing application code. It is MIT licensed, from Three Dots Labs.

Problems it solves

  • build an event-driven service in Go without tying it to one message broker
  • switch my Go app from RabbitMQ to Kafka without rewriting the handlers
  • process events asynchronously in Go with retries and middleware

Features

  • publish and handle events as Go structs
  • router with middleware
  • CQRS event and command handlers
  • one API over Kafka, RabbitMQ, PostgreSQL, Redis and more