Instantly share code, notes, and snippets.

What would you like to do?
Bookmark to purge all the queues in a vhost. RabbitMQ
//add this to your bookmarks. The default vhost in RabbitMq is "/",
// so you should have as virtualhost %2F, but due to chrome escape it, i used %252f
//i assume you're in the management site (
var purge = function(name) {
url:'api/queues/' + vhost + "/" + name + '/contents/',
type: 'DELETE',
success:function(data) {
console.log(name + " purged");
url: '/api/queues/' + vhost,
success: function(data) {
for (queue in data) {
queue_name = data[queue].name;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment