kubernetes-health 3.7.2 → 3.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/kubernetes-health.gemspec +1 -1
- data/lib/kubernetes/health/config.rb +1 -1
- data/lib/kubernetes/health/version.rb +1 -1
- data/lib/puma/plugin/kubernetes.rb +9 -9
- metadata +8 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: adaef68a4c3f4b6e2dcb2b3c7aa5f8c4e72544b22edb147e35e2f72c3e8c6da4
|
4
|
+
data.tar.gz: 52f4cf9f5aabdf55ad239ff23fab548e3d2e883c674b7a68bef0848699774078
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ee8c2fc80a2e8635a573beb6e8298a9756aaf292c0deb658797d77cc3a3337c7e9bfd83d00409068574b538156c2836d1fc5b2c6a41e5984d759864e05850595
|
7
|
+
data.tar.gz: 99855e3a23eb0c0f3fe90957c4d106bfebdd09c0e4434a1550907b300640ba4a7ed70c3ec8a845ca1aa2e2fc9f801a2ec811e000024544587d955dfbd945d469
|
data/kubernetes-health.gemspec
CHANGED
@@ -12,7 +12,7 @@ module Kubernetes
|
|
12
12
|
@@response_format = 'prometheus'
|
13
13
|
|
14
14
|
@@request_log_callback = lambda { |req, http_code, content|
|
15
|
-
Rails.logger.debug "Kubernetes Health
|
15
|
+
Rails.logger.debug "Kubernetes Health - Request: Path: #{req.path_info} / Params: #{req.params} / HTTP Code: #{http_code}\n#{content}" rescue nil
|
16
16
|
}
|
17
17
|
|
18
18
|
@@lock_or_wait = lambda { ActiveRecord::Base.connection.execute 'select pg_advisory_lock(123456789123456789);' }
|
@@ -9,26 +9,26 @@ Puma::Plugin.create do
|
|
9
9
|
|
10
10
|
app = Puma::Kubernetes::App.new launcher
|
11
11
|
uri = URI.parse str
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
12
|
+
log_writer = launcher.respond_to?(:log_writer) ? launcher.log_writer : launcher.events
|
13
|
+
puma_options = { min_threads: 0, max_threads: 1 }
|
14
|
+
puma_options[:log_writer] = log_writer unless log_writer.nil?
|
15
|
+
puma_server = Puma::Server.new app, launcher.events, puma_options
|
16
16
|
|
17
17
|
case uri.scheme
|
18
18
|
when 'tcp'
|
19
|
-
|
20
|
-
|
19
|
+
log_writer.log "* Starting kubernetes-healh server on #{str}"
|
20
|
+
puma_server.add_tcp_listener uri.host, uri.port
|
21
21
|
else
|
22
|
-
|
22
|
+
log_writer.error "Invalid control URI: #{str}"
|
23
23
|
end
|
24
24
|
|
25
25
|
launcher.events.register(:state) do |state|
|
26
26
|
if %i[halt restart stop].include?(state)
|
27
|
-
|
27
|
+
puma_server.stop(true) unless puma_server.shutting_down?
|
28
28
|
end
|
29
29
|
end
|
30
30
|
|
31
|
-
|
31
|
+
puma_server.run
|
32
32
|
end
|
33
33
|
# rubocop:enable Kubernetes/MethodLength, Kubernetes/AbcSize
|
34
34
|
end
|
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.
|
4
|
+
version: 3.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Wagner Caixeta
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-01-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -100,14 +100,14 @@ dependencies:
|
|
100
100
|
requirements:
|
101
101
|
- - ">="
|
102
102
|
- !ruby/object:Gem::Version
|
103
|
-
version: '0'
|
103
|
+
version: '5.0'
|
104
104
|
type: :runtime
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
108
|
- - ">="
|
109
109
|
- !ruby/object:Gem::Version
|
110
|
-
version: '0'
|
110
|
+
version: '5.0'
|
111
111
|
description: "\n This gem allows kubernetes monitoring your app while it is running
|
112
112
|
migrates and after it started.\n Features:\n * add routes /_readiness and
|
113
113
|
/_liveness on rails stack by default;\n * allow custom checks for /_readiness
|
@@ -147,7 +147,7 @@ files:
|
|
147
147
|
homepage: https://github.com/platbr/kubernetes-health
|
148
148
|
licenses: []
|
149
149
|
metadata: {}
|
150
|
-
post_install_message:
|
150
|
+
post_install_message:
|
151
151
|
rdoc_options: []
|
152
152
|
require_paths:
|
153
153
|
- lib
|
@@ -162,8 +162,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
162
162
|
- !ruby/object:Gem::Version
|
163
163
|
version: '0'
|
164
164
|
requirements: []
|
165
|
-
rubygems_version: 3.
|
166
|
-
signing_key:
|
165
|
+
rubygems_version: 3.3.3
|
166
|
+
signing_key:
|
167
167
|
specification_version: 4
|
168
168
|
summary: This gem allows kubernetes monitoring your app while it is running migrates
|
169
169
|
and after it started.
|