Sha256: 9e4d227dad9af5a12d613ebe9e0cd4fb54db6d3dae0b162ed2117ea8b22400d3

Contents?: true

Size: 433 Bytes

Versions: 3

Compression:

Stored size: 433 Bytes

Contents

require 'untied-consumer/worker'
require 'amqp'

namespace :untied do
  namespace :consumer do
    desc "Starts untied's worker"
    task :work do
      AMQP.start do |connection|
        channel  = AMQP::Channel.new(connection)
        exchange = channel.topic("untied", :auto_delete => true)
        worker = Untied::Consumer::Worker.new(:channel => channel, :exchange => exchange)
        worker.start
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
untied-consumer-0.0.3 lib/untied-consumer/tasks/untied.tasks
untied-consumer-0.0.2 lib/untied-consumer/tasks/untied.tasks
untied-consumer-0.0.1 lib/untied-consumer/tasks/untied.tasks