Sha256: de52d4c004a234d5ad08cfd60376a913e672177868a5c4778b850f9cf1609c62
Contents?: true
Size: 570 Bytes
Versions: 2
Compression:
Stored size: 570 Bytes
Contents
module Heartcheck module Checks class Resque < Base def validate services.each do |service| begin quantity = failures_counter if quantity > service[:failures_limit].to_i append_error("#{quantity} failures") end rescue => e append_error(e.message) end end end private def failures_counter ::Resque::Failure.count end def custom_error(msg) @errors << "Resque failed! #{msg}" end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
heartcheck-resque-0.0.2 | lib/heartcheck/checks/resque.rb |
heartcheck-resque-0.0.1 | lib/heartcheck/checks/resque.rb |