Class: NtqTools::Monitors::Redis

Inherits:
Base
  • Object
show all
Defined in:
lib/ntq_tools/monitors/redis.rb

Class Method Summary collapse

Class Method Details

.checkObject



15
16
17
18
19
# File 'lib/ntq_tools/monitors/redis.rb', line 15

def check
  ::Sidekiq.redis { |con| con.ping }.present?
rescue ::Redis::CannotConnectError
  false
end

.is_installed?Boolean

Returns:

  • (Boolean)


11
12
13
# File 'lib/ntq_tools/monitors/redis.rb', line 11

def is_installed?
  ::Gem.loaded_specs.has_key?("redis")
end

.nameObject



7
8
9
# File 'lib/ntq_tools/monitors/redis.rb', line 7

def name
  'redis'
end