Skip to main content
The playground includes a RabbitMQ instance that demonstrates KrakenD’s async agent capabilities. This allows KrakenD to consume messages from queues and deliver them to backend services asynchronously.

Overview

RabbitMQ provides:
  • AMQP message delivery - Reliable message queuing and routing
  • Management UI - Web interface for queue administration
  • Async agent integration - KrakenD consumes messages and forwards them
  • Message persistence - Queue durability and message storage

Access

  • Management UI: http://localhost:15672
  • Port: 15672 (management interface)
  • AMQP Port: 5672 (default, internal)
  • Default Credentials: guest / guest

The krakend Queue

The playground uses a queue named krakend that the async agent monitors for incoming messages.

Accessing the Queue

Direct link to the queue in RabbitMQ management:
http://localhost:15672/#/queues/%2F/krakend
The %2F in the URL represents the default virtual host / in RabbitMQ.

How It Works

  1. Messages arrive in the krakend queue (via AMQP publish)
  2. KrakenD’s async agent picks up messages from the queue
  3. Agent delivers messages to configured backend endpoints
  4. Backend processes the message payload

Message Flow

Producer → RabbitMQ Queue → KrakenD Async Agent → Backend Service

Sending Messages

You can manually publish messages through the RabbitMQ management UI:
  1. Open http://localhost:15672
  2. Login with guest / guest
  3. Navigate to Queues tab
  4. Click on the krakend queue
  5. Expand Publish message section
  6. Enter your message payload
  7. Click Publish message

Example Message Payload

{
  "message": "Hello from RabbitMQ",
  "timestamp": "2026-03-03T10:00:00Z",
  "data": {
    "key": "value"
  }
}
Watch the async agent in KrakenD logs to see messages being picked up and delivered.

Async Agent Configuration

KrakenD’s async agent is configured to:
  • Connect to RabbitMQ on the internal Docker network
  • Monitor the krakend queue
  • Forward messages to designated backend endpoints
  • Handle message acknowledgment and error scenarios

Management UI Features

The RabbitMQ management interface provides:
  • Queue monitoring - Message counts, rates, and states
  • Message publishing - Manual message injection for testing
  • Exchange configuration - Routing and binding management
  • Connection tracking - Active consumers and publishers
  • Performance metrics - Throughput and resource usage

Viewing Messages

In the management UI, you can:
  1. See messages waiting in the queue
  2. Get messages without removing them (peek)
  3. View message details and headers
  4. Requeue or delete messages

Use Cases

Async messaging is useful for:
  • Event-driven architectures - Decouple message production from consumption
  • Background processing - Offload time-consuming tasks
  • Batch operations - Queue up work for later processing
  • Rate limiting - Control backend load through queue consumption rates

Monitoring

Watch the async agent activity:
make logs
Look for log entries showing:
  • Queue connection status
  • Message consumption
  • Delivery to backends
  • Errors or retries
Messages published to the queue will be consumed by the async agent. Make sure your backend services are ready to handle incoming messages.

Additional Resources

Build docs developers (and LLMs) love