kubernetes-health 3.13.0 → 3.14.0

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
  SHA256:
3
- metadata.gz: 9c2c9b60a7289355e669d7ea209ff49a09dbd0cd143f8d394d3920173cebfa49
4
- data.tar.gz: cbfbb6a989ab515505601151c611400c4bda12f7dcbd62e2afba95a3b0ac119c
3
+ metadata.gz: e3575c8bb4c8e379dff9f4f91e1b5ebcc19b144438dc75a1fa1c387370361299
4
+ data.tar.gz: 30bb81065ee295ed152e43469bd88b5c992b79275ff672358a7684c7724dd12d
5
5
  SHA512:
6
- metadata.gz: 9805d34deec7b9bab3e8f6fa25c17f71e701d7972797c737358f72ee086a0a7748e1b9953e05584cc9b4df45bb021749d6adfc7930ab950c5765d7be853a4500
7
- data.tar.gz: 46c1e70a5bd9f613d4b523f4aa36e9663ae83d4967b61f870484a7b5c3c8bc2b4c595abea5f3bca84dffc9897955caa0c4a35dea2c120bf59ece5c4bff9a0621
6
+ metadata.gz: beb7dfc5ebe610fb016ed5fa0c7520ee1a2cf6ecdfb34e68632756a63fb78f4dc771bdb7a16c363e8daf80487b44eb2e7fcd9c94bd3619902a7b010b0c812b4b
7
+ data.tar.gz: a86a7586248bc15dcc64c88f257816c6e40a6bcd76b31b4674a5b86bb50bf9df3926201279579c7a606dcd83d23402e14cfa13281e7ed9e70bd0c0243fd78d68
data/LICENSE ADDED
@@ -0,0 +1,24 @@
1
+ This is free and unencumbered software released into the public domain.
2
+
3
+ Anyone is free to copy, modify, publish, use, compile, sell, or
4
+ distribute this software, either in source code form or as a compiled
5
+ binary, for any purpose, commercial or non-commercial, and by any
6
+ means.
7
+
8
+ In jurisdictions that recognize copyright laws, the author or authors
9
+ of this software dedicate any and all copyright interest in the
10
+ software to the public domain. We make this dedication for the benefit
11
+ of the public at large and to the detriment of our heirs and
12
+ successors. We intend this dedication to be an overt act of
13
+ relinquishment in perpetuity of all present and future rights to this
14
+ software under copyright law.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
19
+ IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
20
+ OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
21
+ ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
22
+ OTHER DEALINGS IN THE SOFTWARE.
23
+
24
+ For more information, please refer to <https://unlicense.org>
data/README.md CHANGED
@@ -16,7 +16,7 @@ This gem opens a dedicated HTTP port to allow Kubernetes to monitor your Rails a
16
16
  Add this line to your application's Gemfile:
17
17
 
18
18
  ```ruby
19
- gem 'kubernetes-health', '~> 3.12.1'
19
+ gem 'kubernetes-health', '~> 3.14'
20
20
  ```
21
21
 
22
22
  ## Enabling puma plugin
@@ -1,7 +1,13 @@
1
1
  require 'kubernetes/health/rack_on_sidekiq'
2
+ begin
3
+ require 'rackup'
4
+ rescue LoadError
5
+ # ignore
6
+ end
2
7
 
3
8
  if Kubernetes::Health::Config.enable_rack_on_sidekiq && Kubernetes::Health::SidekiqOptionsResolver[:concurrency].positive?
4
9
  Thread.new do
5
- Rack::Handler::WEBrick.run Kubernetes::Health::RackOnSidekiq.new, Port: Kubernetes::Health::Config.metrics_port
10
+ server = defined?(Rackup::Handler::WEBrick) ? Rackup::Handler::WEBrick : Rack::Handler::WEBrick
11
+ server.run Kubernetes::Health::RackOnSidekiq.new, Port: Kubernetes::Health::Config.metrics_port
6
12
  end
7
13
  end
@@ -5,7 +5,6 @@ require 'prometheus/client/formats/text'
5
5
  module Kubernetes
6
6
  module Health
7
7
  class RackOnSidekiq
8
-
9
8
  def call(env)
10
9
  req = ::Rack::Request.new(env)
11
10
  content = ''
@@ -53,7 +52,6 @@ module Kubernetes
53
52
  stats[:sidekiq_usage] = (stats[:sidekiq_busy] / stats[:sidekiq_capacity].to_f).round(2)
54
53
  stats
55
54
  end
56
-
57
55
  end
58
56
  end
59
- end
57
+ end
@@ -1,5 +1,5 @@
1
1
  module Kubernetes
2
2
  module Health
3
- VERSION = '3.13.0'.freeze
3
+ VERSION = '3.14.0'.freeze
4
4
  end
5
5
  end
@@ -1,5 +1,5 @@
1
- require "kubernetes/health/config"
2
- require "kubernetes/health/sidekiq_options_resolver"
3
- require "kubernetes/health/version"
4
- require "kubernetes/health/engine"
5
- require "kubernetes/health/railtie"
1
+ require 'kubernetes/health/config'
2
+ require 'kubernetes/health/sidekiq_options_resolver'
3
+ require 'kubernetes/health/version'
4
+ require 'kubernetes/health/engine'
5
+ require 'kubernetes/health/railtie'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kubernetes-health
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.13.0
4
+ version: 3.14.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Wagner Caixeta
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-06-04 00:00:00.000000000 Z
11
+ date: 2024-09-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -129,6 +129,7 @@ files:
129
129
  - ".rspec"
130
130
  - ".travis.yml"
131
131
  - Gemfile
132
+ - LICENSE
132
133
  - README.md
133
134
  - Rakefile
134
135
  - app/controllers/kubernetes/health_controller.rb
@@ -169,7 +170,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
169
170
  - !ruby/object:Gem::Version
170
171
  version: '0'
171
172
  requirements: []
172
- rubygems_version: 3.5.7
173
+ rubygems_version: 3.1.4
173
174
  signing_key:
174
175
  specification_version: 4
175
176
  summary: This gem allows kubernetes monitoring your app while it is running migrates