RabbitMQ
Synopsis
Creates a target that publishes log messages to RabbitMQ exchanges or queues with support for batching, routing, TLS encryption, and automatic retry logic. RabbitMQ is a widely-used open-source message broker for reliable message delivery.
Schema
- name: <string>
description: <string>
type: rabbitmq
pipelines: <pipeline[]>
status: <boolean>
properties:
url: <string>
exchange: <string>
routing_key: <string>
queue: <string>
content_type: <string>
delivery_mode: <integer>
mandatory: <boolean>
immediate: <boolean>
timeout: <integer>
batch_size: <integer>
max_retries: <integer>
retry_delay: <integer>
field_format: <string>
tls:
status: <boolean>
verify: <boolean>
cert_name: <string>
key_name: <string>
min_tls_version: <string>
max_tls_version: <string>
interval: <string|numeric>
cron: <string>
debug:
status: <boolean>
dont_send_logs: <boolean>
Configuration
The following fields are used to define the target:
| Field | Required | Default | Description |
|---|---|---|---|
name | Y | Target name | |
description | N | - | Optional description |
type | Y | Must be rabbitmq | |
pipelines | N | - | Optional post-processor pipelines |
status | N | true | Enable/disable the target |
Connection
| Field | Required | Default | Description |
|---|---|---|---|
url | Y | - | RabbitMQ server URL (e.g., amqp://localhost:5672 or amqps://host:5671) |
timeout | N | 30 | Connection timeout in seconds |
Routing Configuration
| Field | Required | Default | Description |
|---|---|---|---|
exchange | N* | - | RabbitMQ exchange name |
routing_key | N | - | Routing key for message delivery (defaults to queue name if queue is specified) |
queue | N* | - | RabbitMQ queue name (queue will be declared as durable) |
* = Conditionally required. Either exchange or queue must be specified. If queue is specified without routing_key, the queue name is used as the routing key.
Message Properties
| Field | Required | Default | Description |
|---|---|---|---|
content_type | N | application/json | Message content type |
delivery_mode | N | 2 | Delivery mode: 1 (non-persistent), 2 (persistent) |
mandatory | N | false | Require message to be routed to at least one queue |
immediate | N | false | Require immediate delivery to consumer (deprecated in RabbitMQ 3.x) |
Batch Configuration
| Field | Required | Default | Description |
|---|---|---|---|
batch_size | N | 1000 | Number of messages to batch before publishing (minimum 1) |
max_retries | N | 3 | Maximum retry attempts for failed publish operations |
retry_delay | N | 1 | Delay between retry attempts in seconds |