Module: Nanite::AMQPHelper

Included in:
Agent, Mapper
Defined in:
lib/nanite/amqp.rb

Instance Method Summary collapse

Instance Method Details

#start_amqp(options) ⇒ Object



41
42
43
44
45
# File 'lib/nanite/amqp.rb', line 41

def start_amqp(options)
  connection = AMQP.connect(:user => options[:user], :pass => options[:pass], :vhost => options[:vhost],
    :host => options[:host], :port => (options[:port] || ::AMQP::PORT).to_i, :insist => options[:insist] || false)
  MQ.new(connection)
end