health-monitor-rails 7.5.1 → 8.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: fda7b28c9eeeca8a1761bb5e079549b6d2c76f6a
4
- data.tar.gz: a545a3926b032419213962b4dd578e6b7470005f
3
+ metadata.gz: b38a2b9e13d993baffbcd7fd4358b2084f6a927f
4
+ data.tar.gz: 3c9dee471042f9b3283c57c7d09772cda865f807
5
5
  SHA512:
6
- metadata.gz: 11c34f554f6387d47770221c66f18d118008ab2f11e1a136406d390d1d900e0bdb3c5b0dffb4d606c72c327128bbc2d4e3b8817e4682e3e91e69fc9fa3f435cb
7
- data.tar.gz: 7f412ec0b18426d239ef5ad1c0670ffbff09ff612f55c08451f7bc887d5de900af70391760457ac241f3001da1c51f6f9d9ce156801d52c434f8c532c7e8edab
6
+ metadata.gz: 27c5fee038403947e282f928de6a0a1b282936ffd2961f185cde15bae6c6fe09134c893c5aa9503f76bbd4a28273170230e3fa0cd70942c67de8a8b45a82ff16
7
+ data.tar.gz: b1cde4837738edbeaedb5bbf30ebe0e1af1523b5f45ac4d0d5610f2cc58f77a4eb871dbc7f379897713b3aea669a2c17e2ff29a9e0bc08e77497a2eeb98111ee
data/README.md CHANGED
@@ -1,9 +1,9 @@
1
1
  # health-monitor-rails
2
2
 
3
- [![Gem Version](https://badge.fury.io/rb/health-monitor-rails.png)](http://badge.fury.io/rb/health-monitor-rails)
4
- [![Build Status](https://travis-ci.org/lbeder/health-monitor-rails.png)](https://travis-ci.org/lbeder/health-monitor-rails)
5
- [![Dependency Status](https://gemnasium.com/lbeder/health-monitor-rails.png)](https://gemnasium.com/lbeder/health-monitor-rails)
6
- [![Coverage Status](https://coveralls.io/repos/lbeder/health-monitor-rails/badge.png)](https://coveralls.io/r/lbeder/health-monitor-rails)
3
+ [![Gem Version](https://badge.fury.io/rb/health-monitor-rails.svg)](http://badge.fury.io/rb/health-monitor-rails)
4
+ [![Build Status](https://travis-ci.org/lbeder/health-monitor-rails.svg)](https://travis-ci.org/lbeder/health-monitor-rails)
5
+ [![Dependency Status](https://gemnasium.com/lbeder/health-monitor-rails.svg)](https://gemnasium.com/lbeder/health-monitor-rails)
6
+ [![Coverage Status](https://coveralls.io/repos/lbeder/health-monitor-rails/badge.svg)](https://coveralls.io/r/lbeder/health-monitor-rails)
7
7
 
8
8
  This is a health monitoring Rails mountable plug-in, which checks various services (db, cache, sidekiq, redis, etc.).
9
9
 
@@ -14,10 +14,10 @@ module HealthMonitor
14
14
  respond_to do |format|
15
15
  format.html
16
16
  format.json do
17
- render json: statuses.to_json
17
+ render json: statuses.to_json, status: statuses[:status]
18
18
  end
19
19
  format.xml do
20
- render xml: statuses.to_xml
20
+ render xml: statuses.to_xml, status: statuses[:status]
21
21
  end
22
22
  end
23
23
  end
@@ -21,7 +21,7 @@ module HealthMonitor
21
21
 
22
22
  {
23
23
  results: results,
24
- status: results.all? { |res| res[:status] == STATUSES[:ok] } ? :ok : :service_unavailable,
24
+ status: results.any? { |res| res[:status] != STATUSES[:ok] } ? :service_unavailable : :ok,
25
25
  timestamp: Time.now.to_s(:rfc2822)
26
26
  }
27
27
  end
@@ -5,7 +5,7 @@ module HealthMonitor
5
5
  attr_accessor :configuration
6
6
 
7
7
  def self.provider_name
8
- @name ||= name.demodulize
8
+ @provider_name ||= name.demodulize
9
9
  end
10
10
 
11
11
  def self.configure
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module HealthMonitor
4
- VERSION = '7.5.1'.freeze
4
+ VERSION = '8.0.0'.freeze
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: health-monitor-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.5.1
4
+ version: 8.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Leonid Beder
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-01-09 00:00:00.000000000 Z
11
+ date: 2018-03-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails