Method: AMQP::Exchange#delete
- Defined in:
- lib/amqp/exchange.rb
#delete(opts = {}, &block) ⇒ NilClass
This method deletes an exchange. When an exchange is deleted all queue bindings on the exchange are deleted, too. Further attempts to publish messages to a deleted exchange will result in a channel-level exception.
562 563 564 565 566 567 568 569 |
# File 'lib/amqp/exchange.rb', line 562 def delete(opts = {}, &block) @channel.once_open do exchange_delete(opts.fetch(:if_unused, false), opts.fetch(:nowait, false), &block) end # backwards compatibility nil end |