Sha256: ab73abe8c600b94c8ca61b1c560cfda2c82f7b1d068b4e06006c43e4d341dcf0
Contents?: true
Size: 552 Bytes
Versions: 6
Compression:
Stored size: 552 Bytes
Contents
require 'evrone/common/amqp' module Evrone module CI module Worker class JobsConsumer include Evrone::Common::AMQP::Consumer exchange 'ci.jobs' queue 'ci.worker.jobs.generic' ack true model Message::PerformJob def perform(message) job = Job.new message number = Thread.current[:consumer_id] || 0 path_prefix = "/tmp/.test/job.#{number}" Worker.perform(job, path_prefix) ack! end end end end end
Version data entries
6 entries across 6 versions & 1 rubygems