Skip to content

Message queue testing

A message queue decouples producers from consumers. That is its strength and the reason it needs its own load test: the backlog absorbs pressure, so producers keep reporting success while consumers quietly fall behind. By the time an HTTP-style test would notice, the queue is minutes deep. This section gives you a copy-paste Locust file for each of five common brokers, plus the rules for running them safely.

Every guide reports the same three numbers:

  • Send latency: how long a producer waits for the broker to accept a message.
  • Consume rate: how many messages per second the consumers keep up with.
  • End-to-end latency: time from send to receipt by a consumer. A value that climbs over the run means consumers are falling behind.

They appear in the run results as two labels per queue: <queue> send and <queue> end-to-end. For example, the Kafka guide reports kafka send and kafka end-to-end.

  • The tests run on the Locust executor. Upload the locustfile.py directly. No YAML is needed.
  • Each guide’s taurus.yml installs its client library when the test starts, with Taurus’s built-in pip-install service. Nothing is preinstalled on the runner.
  • Connection values (URL, bootstrap servers, credentials) come from workspace secrets bound to the test as SECRET_* environment variables. See Secrets and environments.
  • The broker must be reachable from the runners. Managed runners need a public endpoint. For a broker inside your network, use a private datacenter outpost.
  • Only load-test brokers, topics and queues you are authorised to load. Read Message queue testing: do and don’t first.
QueueClient libraryGuideBlog post
Apache Kafkaconfluent-kafkaLoad test Apache Kafka on MaxoPerfLoad testing Kafka
RabbitMQpikaLoad test RabbitMQ on MaxoPerfLoad testing RabbitMQ
Amazon SQSboto3Load test Amazon SQS on MaxoPerfLoad testing Amazon SQS
NATS JetStreamnats-pyLoad test NATS JetStream on MaxoPerfLoad testing NATS JetStream
Redis StreamsredisLoad test Redis Streams on MaxoPerfLoad testing Redis Streams

Testing IBM MQ instead? See MQ and messaging testing.

Last updated: