Sha256: bae8d8a53e79a57838d8e8c6429d5fef523a1840452cd33dd9d40ebdf7ec436f

Contents?: true

Size: 527 Bytes

Versions: 1

Compression:

Stored size: 527 Bytes

Contents

module Lambdakiq
  module Worker
    extend ActiveSupport::Concern

    included do
      class_attribute :lambdakiq_options_hash,
                      instance_predicate: false,
                      default: Hash.new
    end

    class_methods do

      def lambdakiq_options(options = {})
        self.lambdakiq_options_hash = options.symbolize_keys
      end

    end

    def lambdakiq_retry
      lambdakiq_options_hash[:retry]
    end

    def lambdakiq_async?
      !!lambdakiq_options_hash[:async]
    end

  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
lambdakiq-1.0.1 lib/lambdakiq/worker.rb