cancel
Showing results for 
Search instead for 
Did you mean: 
intapiuser
Community Team Member
Community Team Member

How to enable it?

Run the following script:
for i in 0 1 ; do echo sisense-rabbitmq-ha-$i " "; kubectl -n sisense exec -it sisense-rabbitmq-ha-$i -c rabbitmq-ha -- bash -c "apk update;apk add python;wget http://127.0.0.1:15672/cli/rabbitmqadmin;chmod a+x rabbitmqadmin" ; done
This will install the CLI in all Pods.
If you only have one Pod (single node deployment), you will probably see the following error:
sisense-rabbitmq-ha-1
Error from server (NotFound): pods "sisense-rabbitmq-ha-1" not found
You can ignore it.

(Optional) Enable bash auto-completion for the CLI

After you've successfully installed rabbitmqadmin, you can enable the tab-enabled auto-completion by running:
source $(./rabbitmqadmin --bash-completion)
 
./rabbitmqadmin [PRESS TAB + TAB]:
--depth
--host
--sort
--vhost
delete
help
publish
--format
--password
--sort-reverse
close
export
import
purge
--help
--port
--username
declare
get
list
show
How to print the number of messages and consumers per queue?
./rabbitmqadmin list queues name consumers messages
+------------------------------------------------------------------------------------------+-----------+----------+
|                                           name                                           | consumers | messages |
+------------------------------------------------------------------------------------------+-----------+----------+
| activities/addDirectActivity_v1                                                          | 1         | 0        |
| alerts/updateAlertsForDeletedGroups_v1                                                   | 1         | 0        |
| alerts/updateAlertsForDeletedUsers_v1                                                    | 1         | 0        |
...
More info about the commands can be found here.
Rate this article:
Version history
Last update:
‎03-02-2023 09:26 AM
Updated by:
Contributors