Skip to content

Instantly share code, notes, and snippets.

@flopezluis
Created August 4, 2012 08:21

Revisions

  1. flopezluis revised this gist Aug 4, 2012. 1 changed file with 2 additions and 1 deletion.
    3 changes: 2 additions & 1 deletion gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,5 @@
    //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
    //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 (http://www.rabbitmq.com/management.html)
    javascript:
    vhost="%252f";
  2. flopezluis revised this gist Aug 4, 2012. 1 changed file with 3 additions and 2 deletions.
    5 changes: 3 additions & 2 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -4,10 +4,10 @@ javascript:
    vhost="%252f";
    var delete_queues = function(name) {
    $.ajax({
    url:'api/queues/%2F/' + name,
    url:'api/queues/' +vhost+ '/' + name,
    type: 'DELETE',
    success:function(data) {
    console.log(name + " purged");
    console.log(name + " Delete");
    }
    });
    };
    @@ -18,5 +18,6 @@ $.ajax({
    queue_name = data[queue].name;
    delete_queues(queue_name);
    }
    window.location.reload(); # The plugin reloads every 5 seconds if you enable it
    }
    });
  3. flopezluis created this gist Aug 4, 2012.
    22 changes: 22 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,22 @@
    //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 (http://www.rabbitmq.com/management.html)
    javascript:
    vhost="%252f";
    var delete_queues = function(name) {
    $.ajax({
    url:'api/queues/%2F/' + name,
    type: 'DELETE',
    success:function(data) {
    console.log(name + " purged");
    }
    });
    };
    $.ajax({
    url: '/api/queues/' + vhost,
    success: function(data) {
    for (queue in data) {
    queue_name = data[queue].name;
    delete_queues(queue_name);
    }
    }
    });