kubernetes-health 3.12.4 → 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: 69c1ed0bafbc26dfa3d4cf60ed954557841469e134131a58826c5b17dbd2dd6e
4
- data.tar.gz: 6300a0c9d587f641cd649b0715162f701544560a39a69bfbaab40d16dc0c482d
3
+ metadata.gz: e3575c8bb4c8e379dff9f4f91e1b5ebcc19b144438dc75a1fa1c387370361299
4
+ data.tar.gz: 30bb81065ee295ed152e43469bd88b5c992b79275ff672358a7684c7724dd12d
5
5
  SHA512:
6
- metadata.gz: b622eb35caa632f931a22c4da90c6613ac65307d8def6a635ef91f73709a65b0d303f77ea9752e0a0e9e90e5b87d90892237a86cc4e7fd5bdf77fbb334697385
7
- data.tar.gz: 749a290a82252eb12a526c06fa84c201ef83d5e4122610ad1de0aa84683e316459515e1a174e6360104b4bd01d407f7ad9f0652b9ae25eb2b8c056ce1b82c334
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
- end
13
+ end
@@ -4,7 +4,7 @@ require "kubernetes/health/rack_on_rake"
4
4
  namespace :kubernetes_health do
5
5
  task :rack_on_rake do
6
6
  Thread.new do
7
- Rack::Handler::WEBrick.run Kubernetes::Health::RackOnRake.new, { Port: Kubernetes::Health::Config.metrics_port }
7
+ Rack::Handler::WEBrick.run Kubernetes::Health::RackOnRake.new, Port: Kubernetes::Health::Config.metrics_port
8
8
  end
9
9
  end
10
10
  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.12.4'.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.12.4
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-03-01 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.5
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