Sha256: ad0970ae330e8e9e440a56f908feb0ae45d29973412949948c529cd79d88f3e3

Contents?: true

Size: 379 Bytes

Versions: 41

Compression:

Stored size: 379 Bytes

Contents

require 'asir'
require 'time'

module DelayedService
  include ASIR::Client
  def self.do_it(t0)
    dt = Time.now - t0
    result = 5 <= dt && dt <= 6 ? :ok : :not_delayed
    puts "DelayedService.do_it(#{t0.iso8601}) dt=#{dt.inspect} #{result.inspect}"
    $stderr.puts "DelayedService.do_it => #{result.inspect}"
    raise "Failed" unless result == :ok
    result 
  end
end

Version data entries

41 entries across 41 versions & 2 rubygems

Version Path
asir-1.2.11 example/delayed_service.rb
asir-1.2.10 example/delayed_service.rb
asir-1.2.9 example/delayed_service.rb
asir_beanstalk-1.2.8 example/delayed_service.rb
asir-1.2.8 example/delayed_service.rb
asir_beanstalk-1.2.7 example/delayed_service.rb
asir-1.2.7 example/delayed_service.rb
asir_beanstalk-1.2.6 example/delayed_service.rb
asir-1.2.6 example/delayed_service.rb
asir_beanstalk-1.2.5 example/delayed_service.rb
asir-1.2.5 example/delayed_service.rb
asir_beanstalk-1.2.3 example/delayed_service.rb
asir-1.2.3 example/delayed_service.rb
asir-1.2.2 example/delayed_service.rb
asir-1.2.1 example/delayed_service.rb
asir_beanstalk-1.2.0 example/delayed_service.rb
asir-1.2.0 example/delayed_service.rb
asir-1.1.12 example/delayed_service.rb
asir-1.1.11 example/delayed_service.rb
asir-1.1.10 example/delayed_service.rb