Sha256: c80e46ee638d45328ec041705cac485e16316a0309ff60320fe1b90cdb3e54e2
Contents?: true
Size: 609 Bytes
Versions: 3
Compression:
Stored size: 609 Bytes
Contents
# frozen_string_literal: true module Wayfarer class Task include Stringify attr_reader :url, :batch, :metadata stringify :url, :batch def initialize(url, batch) @url = url @batch = batch @metadata = OpenStruct.new end def ==(other) [url, batch] == [other.url, other.batch] end def barrier @barrier ||= Wayfarer::Redis::Barrier.new(batch) end def counter @counter ||= Wayfarer::Redis::Counter.new(batch) end def gc @gc ||= Wayfarer::GC.new(self) end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
wayfarer-0.4.6 | lib/wayfarer/task.rb |
wayfarer-0.4.5 | lib/wayfarer/task.rb |
wayfarer-0.4.4 | lib/wayfarer/task.rb |