OpenStack services use advanced message queuing protocol (AMQP), an open standard for messaging middleware. This messaging middleware enables the OpenStack services that run on multiple servers to talk to each other. OpenStack Oslo RPC supports two implementations of AMQP: RabbitMQ and ZeroMQ.
Use these options to configure the RPC messaging driver.
Configuration option = Default value | Description |
---|---|
[DEFAULT] | |
control_exchange = openstack |
(String) The default exchange under which topics are scoped. May be overridden by an exchange name specified in the transport_url option. |
default_publisher_id = None |
(String) Default publisher_id for outgoing notifications |
transport_url = None |
(String) A URL representing the messaging driver to use and its full configuration. If not set, we fall back to the rpc_backend option and driver specific configuration. |
Configuration option = Default value | Description |
---|---|
[DEFAULT] | |
notification_format = both |
(String) Specifies which notification format shall be used by nova. |
rpc_backend = rabbit |
(String) The messaging driver to use, defaults to rabbit. Other drivers include amqp and zmq. |
rpc_cast_timeout = -1 |
(Integer) Seconds to wait before a cast expires (TTL). The default value of -1 specifies an infinite linger period. The value of 0 specifies no linger period. Pending messages shall be discarded immediately when the socket is closed. Only supported by impl_zmq. |
rpc_conn_pool_size = 30 |
(Integer) Size of RPC connection pool. |
rpc_poll_timeout = 1 |
(Integer) The default number of seconds that poll should wait. Poll raises timeout exception when timeout expired. |
rpc_response_timeout = 60 |
(Integer) Seconds to wait for a response from a call. |
[cells] | |
rpc_driver_queue_base = cells.intercell |
(String) RPC driver queue base When sending a message to another cell by JSON-ifying the message and making an RPC cast to ‘process_message’, a base queue is used. This option defines the base queue name to be used when communicating between cells. Various topics by message type will be appended to this. Possible values: * The base queue name to be used when communicating between cells. Services which consume this: * nova-cells Related options: * None |
[oslo_concurrency] | |
disable_process_locking = False |
(Boolean) Enables or disables inter-process locks. |
lock_path = None |
(String) Directory to use for lock files. For security, the specified directory should only be writable by the user running the processes that need locking. Defaults to environment variable OSLO_LOCK_PATH. If external locks are used, a lock path must be set. |
[oslo_messaging] | |
event_stream_topic = neutron_lbaas_event |
(String) topic name for receiving events from a queue |
[oslo_messaging_amqp] | |
allow_insecure_clients = False |
(Boolean) Accept clients using either SSL or plain TCP |
broadcast_prefix = broadcast |
(String) address prefix used when broadcasting to all servers |
container_name = None |
(String) Name for the AMQP container |
group_request_prefix = unicast |
(String) address prefix when sending to any server in group |
idle_timeout = 0 |
(Integer) Timeout for inactive connections (in seconds) |
password = |
(String) Password for message broker authentication |
sasl_config_dir = |
(String) Path to directory that contains the SASL configuration |
sasl_config_name = |
(String) Name of configuration file (without .conf suffix) |
sasl_mechanisms = |
(String) Space separated list of acceptable SASL mechanisms |
server_request_prefix = exclusive |
(String) address prefix used when sending to a specific server |
ssl_ca_file = |
(String) CA certificate PEM file to verify server certificate |
ssl_cert_file = |
(String) Identifying certificate PEM file to present to clients |
ssl_key_file = |
(String) Private key PEM file used to sign cert_file certificate |
ssl_key_password = None |
(String) Password for decrypting ssl_key_file (if encrypted) |
trace = False |
(Boolean) Debug: dump AMQP frames to stdout |
username = |
(String) User name for message broker authentication |
[oslo_messaging_notifications] | |
driver = [] |
(Multi-valued) The Drivers(s) to handle sending notifications. Possible values are messaging, messagingv2, routing, log, test, noop |
topics = notifications |
(List) AMQP topic used for OpenStack notifications. |
transport_url = None |
(String) A URL representing the messaging driver to use for notifications. If not set, we fall back to the same configuration used for RPC. |
[upgrade_levels] | |
baseapi = None |
(String) Set a version cap for messages sent to the base api in any service |
OpenStack Oslo RPC uses RabbitMQ
by default.
The rpc_backend
option is not required as long as RabbitMQ
is the default messaging system. However, if it is included
in the configuration, you must set it to rabbit
:
rpc_backend = rabbit
You can configure messaging communication for different installation
scenarios, tune retries for RabbitMQ, and define the size of the RPC
thread pool. To monitor notifications through RabbitMQ
,
you must set the notification_driver
option to
nova.openstack.common.notifier.rpc_notifier
.
The default value for sending usage data is sixty seconds plus
a random number of seconds from zero to sixty.
Use the options described in the table below to configure the
RabbitMQ
message system.
Configuration option = Default value | Description |
---|---|
[oslo_messaging_rabbit] | |
amqp_auto_delete = False |
(Boolean) Auto-delete queues in AMQP. |
amqp_durable_queues = False |
(Boolean) Use durable queues in AMQP. |
channel_max = None |
(Integer) Maximum number of channels to allow |
default_notification_exchange = ${control_exchange}_notification |
(String) Exchange name for for sending notifications |
default_notification_retry_attempts = -1 |
(Integer) Reconnecting retry count in case of connectivity problem during sending notification, -1 means infinite retry. |
default_rpc_exchange = ${control_exchange}_rpc |
(String) Exchange name for sending RPC messages |
default_rpc_retry_attempts = -1 |
(Integer) Reconnecting retry count in case of connectivity problem during sending RPC message, -1 means infinite retry. If actual retry attempts in not 0 the rpc request could be processed more then one time |
fake_rabbit = False |
(Boolean) Deprecated, use rpc_backend=kombu+memory or rpc_backend=fake |
frame_max = None |
(Integer) The maximum byte size for an AMQP frame |
heartbeat_interval = 1 |
(Integer) How often to send heartbeats for consumer’s connections |
heartbeat_rate = 2 |
(Integer) How often times during the heartbeat_timeout_threshold we check the heartbeat. |
heartbeat_timeout_threshold = 60 |
(Integer) Number of seconds after which the Rabbit broker is considered down if heartbeat’s keep-alive fails (0 disable the heartbeat). EXPERIMENTAL |
host_connection_reconnect_delay = 0.25 |
(Floating point) Set delay for reconnection to some host which has connection error |
kombu_compression = None |
(String) EXPERIMENTAL: Possible values are: gzip, bz2. If not set compression will not be used. This option may notbe available in future versions. |
kombu_failover_strategy = round-robin |
(String) Determines how the next RabbitMQ node is chosen in case the one we are currently connected to becomes unavailable. Takes effect only if more than one RabbitMQ node is provided in config. |
kombu_missing_consumer_retry_timeout = 60 |
(Integer) How long to wait a missing client before abandoning to send it its replies. This value should not be longer than rpc_response_timeout. |
kombu_reconnect_delay = 1.0 |
(Floating point) How long to wait before reconnecting in response to an AMQP consumer cancel notification. |
kombu_ssl_ca_certs = |
(String) SSL certification authority file (valid only if SSL enabled). |
kombu_ssl_certfile = |
(String) SSL cert file (valid only if SSL enabled). |
kombu_ssl_keyfile = |
(String) SSL key file (valid only if SSL enabled). |
kombu_ssl_version = |
(String) SSL version to use (valid only if SSL enabled). Valid values are TLSv1 and SSLv23. SSLv2, SSLv3, TLSv1_1, and TLSv1_2 may be available on some distributions. |
notification_listener_prefetch_count = 100 |
(Integer) Max number of not acknowledged message which RabbitMQ can send to notification listener. |
notification_persistence = False |
(Boolean) Persist notification messages. |
notification_retry_delay = 0.25 |
(Floating point) Reconnecting retry delay in case of connectivity problem during sending notification message |
pool_max_overflow = 0 |
(Integer) Maximum number of connections to create above pool_max_size. |
pool_max_size = 10 |
(Integer) Maximum number of connections to keep queued. |
pool_recycle = 600 |
(Integer) Lifetime of a connection (since creation) in seconds or None for no recycling. Expired connections are closed on acquire. |
pool_stale = 60 |
(Integer) Threshold at which inactive (since release) connections are considered stale in seconds or None for no staleness. Stale connections are closed on acquire. |
pool_timeout = 30 |
(Integer) Default number of seconds to wait for a connections to available |
rabbit_ha_queues = False |
(Boolean) Try to use HA queues in RabbitMQ (x-ha-policy: all). If you change this option, you must wipe the RabbitMQ database. In RabbitMQ 3.0, queue mirroring is no longer controlled by the x-ha-policy argument when declaring a queue. If you just want to make sure that all queues (except those with auto-generated names) are mirrored across all nodes, run: “rabbitmqctl set_policy HA ‘^(?!amq.).*’ ‘{“ha-mode”: “all”}’ “ |
rabbit_host = localhost |
(String) The RabbitMQ broker address where a single node is used. |
rabbit_hosts = $rabbit_host:$rabbit_port |
(List) RabbitMQ HA cluster host:port pairs. |
rabbit_interval_max = 30 |
(Integer) Maximum interval of RabbitMQ connection retries. Default is 30 seconds. |
rabbit_login_method = AMQPLAIN |
(String) The RabbitMQ login method. |
rabbit_max_retries = 0 |
(Integer) Maximum number of RabbitMQ connection retries. Default is 0 (infinite retry count). |
rabbit_password = guest |
(String) The RabbitMQ password. |
rabbit_port = 5672 |
(Port number) The RabbitMQ broker port where a single node is used. |
rabbit_qos_prefetch_count = 0 |
(Integer) Specifies the number of messages to prefetch. Setting to zero allows unlimited messages. |
rabbit_retry_backoff = 2 |
(Integer) How long to backoff for between retries when connecting to RabbitMQ. |
rabbit_retry_interval = 1 |
(Integer) How frequently to retry connecting with RabbitMQ. |
rabbit_transient_queues_ttl = 1800 |
(Integer) Positive integer representing duration in seconds for queue TTL (x-expires). Queues which are unused for the duration of the TTL are automatically deleted. The parameter affects only reply and fanout queues. |
rabbit_use_ssl = False |
(Boolean) Connect over SSL for RabbitMQ. |
rabbit_userid = guest |
(String) The RabbitMQ userid. |
rabbit_virtual_host = / |
(String) The RabbitMQ virtual host. |
rpc_listener_prefetch_count = 100 |
(Integer) Max number of not acknowledged message which RabbitMQ can send to rpc listener. |
rpc_queue_expiration = 60 |
(Integer) Time to live for rpc queues without consumers in seconds. |
rpc_reply_exchange = ${control_exchange}_rpc_reply |
(String) Exchange name for receiving RPC replies |
rpc_reply_listener_prefetch_count = 100 |
(Integer) Max number of not acknowledged message which RabbitMQ can send to rpc reply listener. |
rpc_reply_retry_attempts = -1 |
(Integer) Reconnecting retry count in case of connectivity problem during sending reply. -1 means infinite retry during rpc_timeout |
rpc_reply_retry_delay = 0.25 |
(Floating point) Reconnecting retry delay in case of connectivity problem during sending reply. |
rpc_retry_delay = 0.25 |
(Floating point) Reconnecting retry delay in case of connectivity problem during sending RPC message |
socket_timeout = 0.25 |
(Floating point) Set socket timeout in seconds for connection’s socket |
ssl = None |
(Boolean) Enable SSL |
ssl_options = None |
(Dict) Arguments passed to ssl.wrap_socket |
tcp_user_timeout = 0.25 |
(Floating point) Set TCP_USER_TIMEOUT in seconds for connection’s socket |
Use these options to configure the ZeroMQ
messaging system for OpenStack
Oslo RPC. ZeroMQ
is not the default messaging system, so you must enable
it by setting the rpc_backend
option.
Configuration option = Default value | Description |
---|---|
[DEFAULT] | |
rpc_zmq_bind_address = * |
(String) ZeroMQ bind address. Should be a wildcard (*), an ethernet interface, or IP. The “host” option should point or resolve to this address. |
rpc_zmq_bind_port_retries = 100 |
(Integer) Number of retries to find free port number before fail with ZMQBindError. |
rpc_zmq_concurrency = eventlet |
(String) Type of concurrency used. Either “native” or “eventlet” |
rpc_zmq_contexts = 1 |
(Integer) Number of ZeroMQ contexts, defaults to 1. |
rpc_zmq_host = localhost |
(String) Name of this node. Must be a valid hostname, FQDN, or IP address. Must match “host” option, if running Nova. |
rpc_zmq_ipc_dir = /var/run/openstack |
(String) Directory for holding IPC sockets. |
rpc_zmq_matchmaker = redis |
(String) MatchMaker driver. |
rpc_zmq_max_port = 65536 |
(Integer) Maximal port number for random ports range. |
rpc_zmq_min_port = 49152 |
(Port number) Minimal port number for random ports range. |
rpc_zmq_topic_backlog = None |
(Integer) Maximum number of ingress messages to locally buffer per topic. Default is unlimited. |
use_pub_sub = True |
(Boolean) Use PUB/SUB pattern for fanout methods. PUB/SUB always uses proxy. |
zmq_target_expire = 120 |
(Integer) Expiration timeout in seconds of a name service record about existing target ( < 0 means no timeout). |
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.