example.conf
[rabbitmq]
# The url used to connect with RabbitMQ.
#
# If the consumer is started with the option --url or the environment variable
# AMQP_URL set, then this value set in the config file will be ignored.
amqpurl = amqp://guest:guest@localhost:5672/myvhost
# The hostname of the RabbitMQ service.
#
# Will be ignored of amqpurl is set.
host = localhost
# The username used to authenticate with RabbitMq.
#
# Will be ignored of amqpurl is set.
username = guest
# The password used to authenticate with RabbitMq.
#
# Will be ignored of amqpurl is set.
password = guest
# The vhost used when connecting with RabbitMq.
#
# Will be ignored of amqpurl is set.
vhost = /myvhost
# The port of the RabbitMQ service.
#
# Will be ignored of amqpurl is set.
port = 5672
# The queue to consume messages from.
#
# If the consumer is started with the --queue option set, this value will be
# ignored.
queue = mail
# Whether or not to compress the message passed to the script.
#
# Defaults to Off.
compression = On
# Define the acknowledgment method used when the executable exits with an error
# and the --strict-exit-code option is not set.
#
# Defaults to 6.
onfailure = 3
# It's possible to configure the prefetch count and if you want set it as
# global.
[prefetch]
# Sets the prefetch count
#
# Defaults to 3.
count = 3
# Makes the prefetch count global.
# Defaults to Off.
global = On
# It's also possible to configure the exchange and its options. When left out
# in the configuration file, the default exchange will be used.
[exchange]
# The name of the exchange
name = mail
# The exchange type.
#
# Common types are "direct", "fanout", "topic" and "headers".
# Defaults to "direct".
type = direct
# Mark the exchange to be auto deleted.
#
# Defaults to Off
autodelete = On
# Mark the exchange to be durable.
#
# Defaults to Off.
durable = On
# Settings used to bind the queue with the exchange and other queue related
# settings.
[queuesettings]
# The routing key used to determine if a message send to the above configured
# exchange will be routed to the queue. Multiple routing keys can be configured.
routingkey = somekey
routingkey = anotherkey
# The default TTL of a message in the queue.
#
# If not set, the messages will never expire.
messagettl = 30000
# Exchange where message are sent when rejected and or the TTL expires.
deadLetterExchange = someexchange
# The routing key used when sending a message to the dead letter exchange.
deadLetterroutingkey = someroutingkey
# The priority range for this queue.
priority = 10
# Prevents the queue from being declared. If set to true, the queue must have been configured previous to starting the
# consumer. If the queue is not defined, the consumer can not connect and quits.
nodeclare = false
# Should the queue be declared as durable. If set to true, the queue will survive server restarts.
# Defaults to true.
durable = true
# Should the queue be declared as exclusive. If set to true, the queue will be removed when consumer disconnects.
# Defaults to false.
exclusive = false
# Should the queue be declared as autodelete. If set to true and is durable, the queue will survive server restarts
# but will be removed when there are no remaining consumers or bindings.
# Defaults to false
autodelete = false
# Should the queue be declared as noWait. When noWait is true, the queue will assume to be declared on the server.
# A channel exception will arrive if the conditions are met for existing queues
# or attempting to modify an existing queue from a different connection.
# Defaults to false
nowait = false
[logs]
# Path to the log file where informational output is written to
# When providing the --verbose, -V option, this section becomes optional.
# The --verbose option will result in the logs written to STDOUT and STDERR
# #
# If not set, no log file will be written. Use the --verbose option to capture
# the output from the parent process.
info = /tmp/info.log
# Path to the log file where error output is written to
# #
# If not set, no log file will be written. Use the --verbose option to capture
# the output from the parent process.
error = /tmp/error.log