proxes 0.4.2 → 0.4.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9fece98d3fa989bac3fb44675cbe761fb44741c6
4
- data.tar.gz: 88f4671b2439c3bf9720ad6c346e14ab38ef6969
3
+ metadata.gz: 39914b3404c6fb1f55236a2c339acf423f0e2ddf
4
+ data.tar.gz: 208aa9c4a994aec8a1683217ddad8ae540865bd7
5
5
  SHA512:
6
- metadata.gz: a0698864d6cbb71f6c18fc1b37a368cbd1d11413269a7dc40a7a35820f18dde69515ff2f644799edbbf322211782bb74c4a08661f42cb900338bbb7ad58326df
7
- data.tar.gz: 5007833d868c816cff5875d8fb1a5dce44f6fb4f688f8263b4516a90bbb4c6f549765546212fa4c439b59e1ff3ec622ae133430208bae2965a5514f5cdb89666
6
+ metadata.gz: 80557eb6329e4c06b04406fffa23f5f404f4d99bb7fc6a78c36eb102e9c3d9389549a3357309ead09b1e64cdd141f8e0c388ff4dd00553d4296af76e741c5713
7
+ data.tar.gz: dce018fe1f91137dabf3e36e42ae8535f945dc5414e8abc29421c232c2381bbc70cfa4bb8206f5696657abdb48844d215fda7e5eca95788b4508db02fe5966a4
@@ -8,7 +8,9 @@ require 'proxes/helpers/views'
8
8
  require 'proxes/helpers/pundit'
9
9
  require 'proxes/helpers/wisper'
10
10
  require 'proxes/helpers/authentication'
11
+ require 'proxes/services/logger'
11
12
  require 'rack/contrib'
13
+ require 'elasticsearch'
12
14
 
13
15
  module ProxES
14
16
  class Application < Sinatra::Base
@@ -20,10 +22,11 @@ module ProxES
20
22
  helpers do
21
23
  def cluster_health
22
24
  @health ||= begin
23
- client = Elasticsearch::Client.new
25
+ client = ::Elasticsearch::Client.new host: ENV['ELASTICSEARCH_URL']
24
26
  client.cluster.health
25
27
  end
26
- rescue
28
+ rescue => e
29
+ ::ProxES::Services::Logger.instance.warn "Could not connect to ES Cluster: #{e.message}"
27
30
  nil
28
31
  end
29
32
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ProxES
4
- VERSION = '0.4.2'.freeze
4
+ VERSION = '0.4.3'.freeze
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: proxes
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.2
4
+ version: 0.4.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jurgens du Toit
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-05-16 00:00:00.000000000 Z
11
+ date: 2017-05-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler