Menu

rabbitmq-streams(8)

rabbitmq-streams
RabbitMQ stream management tools

rabbitmq-streams [
-q
] [
-s
] [
-l
] [
-n node
] [
-t timeout
] command [
command_options
]

rabbitmq-streams is a command line tool that provides commands used to manage streams, for example, add or delete stream replicas. See the RabbitMQ streams overview.

node
Default node is "rabbit@target-hostname", where target-hostname is the local host. On a host named "myserver.example.com", the node name will usually be "rabbit@myserver" (unless RABBITMQ_NODENAME has been overridden). The output of "hostname -s" is usually the correct suffix to use after the "@" sign. See rabbitmq-server(8) for details of configuring a RabbitMQ node.
, --quiet
Quiet output mode is selected. Informational messages are reduced when quiet mode is in effect.
, --silent
Silent output mode is selected. Informational messages are reduced and table headers are suppressed when silent mode is in effect.
timeout, --timeout timeout
Operation timeout in seconds. Not all commands support timeouts. Default is infinity.
, --longnames
Must be specified when the cluster is configured to use long (FQDN) node names. To learn more, see the RabbitMQ Clustering guide
cookie
Shared secret to use to authenticate to the target node. Prefer using a local file or the RABBITMQ_ERLANG_COOKIE environment variable instead of specifying this option on the command line. To learn more, see the RabbitMQ CLI Tools guide

Displays general help and commands supported by rabbitmq-streams.

queue node --vhost virtual-host
Adds a stream replica on the given node.
Example:
rabbitmq-streams add_replica --vhost "a-vhost" "a-queue" "rabbit@new-node"
queue node --vhost virtual-host
Removes a stream replica on the given node.
Example:
rabbitmq-streams delete_replica --vhost "a-vhost" "a-queue" "rabbit@decomissioned-node"

stream --vhost virtual-host
Displays the status of a stream.
Example:
rabbitmq-streams stream_status --vhost "a-vhost" "a-stream"

stream policy --vhost virtual-host
Set the retention policy of a stream.
Example:
rabbitmq-streams set_stream_retention_policy --vhost "a-vhost" "a-stream" "a-policy"

[
connectioninfoitem ...
]
Returns stream protocol connection statistics.
The connectioninfoitem parameter is used to indicate which connection information items to include in the results. The column order in the results will match the order of the parameters. connectioninfoitem can take any value from the list that follows:
SASL authentication mechanism used, such as "PLAIN".
Informational properties transmitted by the client during connection establishment.
Readable name for the connection.
Date and time this connection was established, as timestamp.
Connection state; one of:
  • running
  • blocked
Maximum frame size (bytes).
Negotiated heartbeat interval, in seconds.
Server hostname obtained via reverse DNS, or its IP address if reverse DNS failed or was disabled.
The issuer of the peer's SSL certificate, in RFC4514 form.
The subject of the peer's SSL certificate, in RFC4514 form.
The period for which the peer's SSL certificate is valid.
Peer hostname obtained via reverse DNS, or its IP address if reverse DNS failed or was not enabled.
Peer port.
Server port.
Boolean indicating whether the connection is secured with SSL.
SSL cipher algorithm (e.g. "aes_256_cbc").
SSL hash function (e.g. "sha").
SSL key exchange algorithm (e.g. "rsa").
SSL protocol (e.g. "tlsv1").
Number of subscriptions (consumers) on the connection.
Username associated with the connection.
Virtual host name with non-ASCII characters escaped as in C.
If no connectioninfoitem are specified then only conn_name is displayed.
For example, this command displays the connection name and user for each connection:
rabbitmq-streams list_stream_connections conn_name user
[
-p vhost
] [
consumerinfoitem ...
]
Returns consumers attached to a stream.
The consumerinfoitem parameter is used to indicate which consumer information items to include in the results. The column order in the results will match the order of the parameters. consumerinfoitem can take any value from the list that follows:
connection_pid
Id of the Erlang process associated with the consumer connection.
credits
Available credits for the consumer.
messages_consumed
Number of messages the consumer consumed.
offset
The offset (location in the stream) the consumer is at.
offset_lag
The difference between the last stored offset and the last dispatched offset for the consumer.
properties
The properties of the consumer subscription.
stream
The stream the consumer is attached to.
subscription_id
The connection-scoped ID of the consumer.
If no consumerinfoitem are specified then connection_pid, subscription_id, stream, messages_consumed, offset, offset_lag, credits, properties are displayed.
For example, this command displays the connection PID, subscription ID and stream for each consumer:
rabbitmq-streams list_stream_consumers connection_pid subscription_id stream
[
-p vhost
] [
publisherinfoitem ...
]
Returns registered publishers.
The publisherinfoitem parameter is used to indicate which publisher information items to include in the results. The column order in the results will match the order of the parameters. publisherinfoitem can take any value from the list that follows:
connection_pid
Id of the Erlang process associated with the consumer connection.
messages_confirmed
The number of confirmed messages for the publisher.
messages_errored
The number of errored messages for the publisher.
messages_published
The overall number of messages the publisher published.
publisher_id
The connection-scoped ID of the publisher.
reference
The deduplication reference of the publisher.
stream
The stream the publisher publishes to.
If no publisherinfoitem are specified then connection_pid, publisher_id, stream, reference, messages_published, messages_confirmed, and messages_errored are displayed.
For example, this command displays the connection PID, publisher ID and stream for each producer:
rabbitmq-streams list_stream_publishers connection_pid publisher_id stream

rabbitmqctl(8), rabbitmq-diagnostics(8), rabbitmq-server(8), rabbitmq-queues(8), rabbitmq-upgrade(8), rabbitmq-service(8), rabbitmq-env.conf(5), rabbitmq-echopid(8)

The RabbitMQ Team <info@rabbitmq.com>

Getting Help and Providing Feedback

If you have questions about the contents of this guide or any other topic related to RabbitMQ, don't hesitate to ask them on the RabbitMQ mailing list.

Help Us Improve the Docs <3

If you'd like to contribute an improvement to the site, its source is available on GitHub. Simply fork the repository and submit a pull request. Thank you!