Sha256: 86ff9d509fec0c45909d1894f83ec880c4d6a49e62c3abf98b77e2881add2cb0

Contents?: true

Size: 530 Bytes

Versions: 2

Compression:

Stored size: 530 Bytes

Contents

require 'evrone/common/amqp'

module Evrone
  module CI
    class Router
      class BuildsConsumer

        include Evrone::Common::AMQP::Consumer
        include Helper::Logger

        exchange 'ci.builds'
        queue    'ci.worker.builds'
        ack      true

        model Message::PerformBuild

        def perform(message)
          logger.tagged self.class.consumer_id do
            build = Build.new message
            Router.new(build).perform
          end
          ack!
        end

      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
evrone-ci-router-0.2.0.pre8 lib/evrone/ci/router/consumers/builds_consumer.rb
evrone-ci-router-0.2.0.pre7 lib/evrone/ci/router/consumers/builds_consumer.rb