Most of the GET requests you can issue to the HTTP API return JSON objects with a large number of keys. While a few of these keys represent things you set yourself in a PUT request or AMQP command (e.g. queue durability or arguments), most of them represent statistics to do with the object in question. This page attempts to document them.
It should be read in conjunction with the manual page
for rabbitmqctl
(see your installation if on Unix / Linux,
or the
RabbitMQ website for the latest version). Any field which can
be returned by a command of the form rabbitmqctl
list_something
will also be returned in the
equivalent part of the HTTP API, so all those keys are not
documented here. However, the HTTP API also adds a lot of extra
fields which are not available in rabbitmqctl
.
Many fields represent a count of some kind: queue length,
messages acknowledged, bytes received and so on. Such absolute
counts returned by the HTTP API will often have a
corresponding _details
object which offers
information on how this count has changed. So for example, from
a queue:
"messages": 123619, "messages_details": { "avg": 41206.333333333336, "avg_rate": 1030.1583333333333, "rate": 24723.8, "samples": [ { "sample": 123619, "timestamp": 1400680560000 }, { "sample": 0, "timestamp": 1400680500000 }, { "sample": 0, "timestamp": 1400680440000 } ] }
Here we have a messages
count (the total messages
in the queue), with some additional data:
avg |
The average value for the requested time period (see below). |
avg_rate |
The average rate for the requested time period. |
rate |
How much the count has changed per second in the most recent sampling interval. |
samples |
Snapshots showing how the value has changed over the requested time period. |
avg
, avg_rate
and samples
will only appear if you request a specific time period by
appending query parameters to the URL. To do this you need to
set an age and an increment for the samples you want. The end of
the range returned will always correspond to the present.
Use msg_rates_age
and msg_rates_incr
to return samples for messages
sent and received, data_rates_age
and data_rates_incr
to return samples for bytes
sent and received, and lengths_age
and lengths_incr
to return samples for queue
lengths. For example,
appending ?lengths_age=3600&lengths_incr=60
will
return the last hour's data on queue lengths, with a sample for
every minute.
Many objects (including queues, exchanges and channels) will
return counts of messages passing through them. These are
included in a message_stats
object (which in turn
will contain _details
objects for each count, as
described above).
These can contain:
publish |
Count of messages published. |
publish_in |
Count of messages published "in" to an exchange, i.e. not taking account of routing. |
publish_out |
Count of messages published "out" of an exchange, i.e. taking account of routing. |
confirm |
Count of messages confirmed. |
deliver |
Count of messages delivered in acknowledgement mode to consumers. |
deliver_noack |
Count of messages delivered in no-acknowledgement mode to consumers. |
get |
Count of messages delivered in acknowledgement mode in response to basic.get. |
get_noack |
Count of messages delivered in no-acknowledgement mode in response to basic.get. |
deliver_get |
Sum of all four of the above. |
redeliver |
Count of subset of messages in deliver_get
which had the redelivered flag set.
|
return |
Count of messages returned to publisher as unroutable. |
Only fields for which some activity has taken place will appear.
In addition, queues, exchanges and channels will return a breakdown of message stats for each of their neighbours (i.e. adjacent objects in the chain: channel -> exchange -> queue -> channel).
As this possibly constitutes a large quantity of data, it is only returned when querying a single channel, queue or exchange rather than a list. Note also that the default sample retention policy means that these detailed message stats do not retain historical data for more than a few seconds.
The detailed message stats objects have different names
depending on where they are (documented below). Each set of
detailed stats consists of a list of objects with two fields,
one identifying the partner object and one stats
which is a message_stats object as described above.
For example, from a queue:
"incoming": [ { "stats": { "publish": 352593, "publish_details": { "rate": 100.2 } }, "exchange": { "name": "my-exchange", "vhost": "/" } } { "stats": { "publish": 543784, "publish_details": { "rate": 54.6 } }, "exchange": { "name": "amq.topic", "vhost": "/" } } ],
This queue is currently receiving messages from two exchanges: 100.2 msg/s from "my-exchange" and 54.6 msg/s from "amq.topic".
This has the following fields:
cluster_name |
The name of the entire cluster, as set with rabbitmqctl
set_cluster_name .
|
erlang_full_version |
A string with extended detail about the Erlang VM and how it was compiled, for the node connected to. |
erlang_version |
A string with the Erlang version of the node connected to. As clusters should all run the same version this can be taken as representing the cluster. |
exchange_types |
A list of all exchange types available. |
listeners |
All (non-HTTP) network listeners for all nodes in the
cluster. (See contexts
in /api/nodes for HTTP).
|
management_version |
Version of the management plugin in use. |
message_stats |
A message_stats object for everything the user can see - for
all vhosts regardless of permissions in the case
of monitoring and administrator
users, and for all vhosts the user has access to for other
users.
|
node |
The name of the cluster node this management plugin instance is running on. |
object_totals |
An object containing global counts of all connections,
channels, exchanges, queues and consumers, subject to the
same visibility rules as for message_stats .
|
queue_totals |
An object containing sums of
the messages , messages_ready
and messages_unacknowledged fields for all
queues, again subject to the same visibility rules as
for message_stats .
|
rabbitmq_version |
Version of RabbitMQ on the node which processed this request. |
statistics_db_node |
Name of the cluster node hosting the management statistics database. |
statistics_level |
Whether the node is running fine or coarse statistics. |
This has the following fields:
applications |
List of all Erlang applications running on the node. |
auth_mechanisms |
List of all SASL authentication mechanisms installed on the node. |
contexts |
List of all HTTP listeners on the node. |
disk_free |
Disk free space in bytes. |
disk_free_alarm |
Whether the disk alarm has gone off. |
disk_free_limit |
Point at which the disk alarm will go off. |
exchange_types |
Exchange types available on the node. |
fd_total |
File descriptors available. |
fd_used |
Used file descriptors. |
mem_used |
Memory used in bytes. |
mem_alarm |
Whether the memory alarm has gone off. |
mem_limit |
Point at which the memory alarm will go off. |
name |
Node name. |
os_pid |
Process identifier for the Operating System under which this node is running. |
partitions |
List of network partitions this node is seeing. |
proc_total |
Maximum number of Erlang processes. |
proc_used |
Number of Erlang processes in use. |
processors |
Number of cores detected and usable by Erlang. |
run_queue |
Average number of Erlang processes waiting to run. |
running |
Boolean for whether this node is up. Obviously if this is false, most other stats will be missing. |
sockets_total |
File descriptors available for use as sockets. |
sockets_used |
File descriptors used as sockets. |
statistics_level |
'fine' or 'coarse'. |
type |
'disc' or 'ram'. |
uptime |
Time since the Erlang VM started, in milliseconds. |
All of the above, plus:
memory |
Detailed memory use statistics. Only appears
if ?memory=true is appended to the URL.
|
See documentation for rabbitmqctl
list_connections
. No additional fields,
although pid
is replaced by node
.
Note also that while non-AMQP connections will appear in this
list (unlike rabbitmqctl list_connections
), they
will omit many of the connection-level statistics.
See documentation for rabbitmqctl list_channels
,
with pid
replaced by node
, plus:
connection_details |
Some basic details about the owning connection. |
message_stats |
See the section on message_stats above. |
All the above, plus
publishes |
Detailed message stats (see section above) for publishes to exchanges. |
deliveries |
Detailed message stats for deliveries from queues. |
consumer_details |
List of consumers on this channel, with some details on each. |
See documentation for rabbitmqctl list_exchanges
, plus:
message_stats |
See the section on message_stats above. |
All the above, plus:
incoming |
Detailed message stats (see section above) for publishes from channels into this exchange. |
outgoing |
Detailed message stats for publishes from this exchange into queues. |
See documentation for rabbitmqctl list_queues
, with
all references to pid
s replaced by node
s
plus:
message_stats |
See the section on message_stats above. |
All the above, plus:
incoming |
Detailed message stats (see section above) for publishes from exchanges into this queue. |
deliveries |
Detailed message stats for deliveries from this queue into channels. |
consumer_details |
List of consumers on this channel, with some details on each. |
All the fields from rabbitmqctl list_vhosts
(i.e. name
and tracing
) plus:
message_stats |
Global message_stats for this vhost. Note that activity for
other users in this vhost is shown, even for users
without the monitoring tag.
|
messages messages_ready messages_acknowledged |
Sum of these fields for all queues in the vhost. |
recv_oct send_oct |
Sum of these fields for all connections to the vhost. |