lib/amqp/channel.rb in amqp-0.8.4 vs lib/amqp/channel.rb in amqp-0.9.0.pre1

- old
+ new

@@ -263,11 +263,11 @@ self.open do @channel_is_open_deferrable.succeed # exchanges must be recovered first because queue recovery includes recovery of bindings. MK. - @exchanges.each { |name, e| e.auto_recover } + @exchanges.each { |name, e| puts("Recovering ex #{name}"); e.auto_recover } @queues.each { |name, q| q.auto_recover } end end # auto_recover # Can be used to recover channels from channel-level exceptions. Allocates a new channel id and reopens @@ -421,10 +421,10 @@ # @see http://bit.ly/hw2ELX AMQP 0.9.1 specification (Section 2.1.2.4) # # @return [Exchange] # @api public def default_exchange - Exchange.default(self) + @default_exchange ||= Exchange.default(self) end # Defines, intializes and returns a fanout Exchange instance. # # Learn more about fanout exchanges in {Exchange Exchange class documentation}.