def destroy!
      unsubscribe  # first thing, make sure we don't get any callbacks related to this
      children = @zk.children(full_queue_path)
      locks = []
      children.each do |path|
        lock = @zk.locker("#{full_queue_path}/#{path}")
        lock.lock!    # XXX(slyphon): should this be a blocking lock?
        locks << lock
      end
      children.each do |path|
        begin
          @zk.delete("#{full_queue_path}/#{path}") 
        rescue ZK::Exceptions::NoNode
        end
      end

      begin
        @zk.delete(full_queue_path) 
      rescue ZK::Exceptions::NoNode
      end

      locks.each do |lock|
        lock.unlock!
      end
    end
def destroy!
      unsubscribe  # first thing, make sure we don't get any callbacks related to this
      children = @zk.children(full_queue_path)
      locks = []
      children.each do |path|
        lock = @zk.locker("#{full_queue_path}/#{path}")
        lock.lock!    # XXX(slyphon): should this be a blocking lock?
        locks << lock
      end
      children.each do |path|
        begin
          @zk.delete("#{full_queue_path}/#{path}") 
        rescue ZK::Exceptions::NoNode
        end
      end

      begin
        @zk.delete(full_queue_path) 
      rescue ZK::Exceptions::NoNode
      end

      locks.each do |lock|
        lock.unlock!
      end
    end
def destroy! unsubscribe # first thing, make sure we don't get any callbacks related to this children = @zk . children ( full_queue_path ) locks = [ ] children . each do | path | lock = @zk . locker ( "#{full_queue_path}/#{path}" ) lock . lock! # XXX(slyphon): should this be a blocking lock? locks << lock end children . each do | path | begin @zk . delete ( "#{full_queue_path}/#{path}" ) rescue ZK :: Exceptions :: NoNode end end begin @zk . delete ( full_queue_path ) rescue ZK :: Exceptions :: NoNode end locks . each do | lock | lock . unlock! end end
highly destructive method!
 WARNING! Will delete the queue and all messages in it
highly destructive method! WARNING! Will delete the queue and all messages in it