Sha256: a6e96372d894e6a958ec60b1351cc217e0198c4647609cb5d1071ebc14f82c97
Contents?: true
Size: 975 Bytes
Versions: 9
Compression:
Stored size: 975 Bytes
Contents
# Alias for AMQP::Channel. # # @note This class will be removed before 1.0 release. # @deprecated class MQ < AMQP::Channel; end class MQ # Alias for AMQP::Exchange. # # @note This class will be removed before 1.0 release. # @deprecated class Exchange < ::AMQP::Exchange; end # Alias for AMQP::Queue. # # @note This class will be removed before 1.0 release. # @deprecated class Queue < ::AMQP::Queue; end # # Backwards compatibility with 0.6.x # # unique identifier def MQ.id Thread.current[:mq_id] ||= "#{`hostname`.strip}-#{Process.pid}-#{Thread.current.object_id}" end # @private def MQ.default # TODO: clear this when connection is closed Thread.current[:mq] ||= MQ.new end # Allows for calls to all MQ instance methods. This implicitly calls # MQ.new so that a new channel is allocated for subsequent operations. def MQ.method_missing(meth, *args, &blk) MQ.default.__send__(meth, *args, &blk) end end
Version data entries
9 entries across 9 versions & 1 rubygems