prometheus_exporter 0.4.17 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (35) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ci.yml +36 -0
  3. data/.rubocop.yml +2 -1
  4. data/CHANGELOG +23 -1
  5. data/README.md +248 -7
  6. data/bin/prometheus_exporter +28 -1
  7. data/lib/prometheus_exporter.rb +14 -0
  8. data/lib/prometheus_exporter/client.rb +31 -3
  9. data/lib/prometheus_exporter/instrumentation.rb +2 -0
  10. data/lib/prometheus_exporter/instrumentation/active_record.rb +2 -13
  11. data/lib/prometheus_exporter/instrumentation/process.rb +3 -12
  12. data/lib/prometheus_exporter/instrumentation/shoryuken.rb +31 -0
  13. data/lib/prometheus_exporter/instrumentation/sidekiq.rb +44 -3
  14. data/lib/prometheus_exporter/instrumentation/sidekiq_queue.rb +50 -0
  15. data/lib/prometheus_exporter/metric/base.rb +4 -0
  16. data/lib/prometheus_exporter/metric/counter.rb +4 -0
  17. data/lib/prometheus_exporter/metric/gauge.rb +4 -0
  18. data/lib/prometheus_exporter/metric/histogram.rb +6 -0
  19. data/lib/prometheus_exporter/metric/summary.rb +7 -0
  20. data/lib/prometheus_exporter/middleware.rb +13 -2
  21. data/lib/prometheus_exporter/server.rb +2 -0
  22. data/lib/prometheus_exporter/server/active_record_collector.rb +1 -0
  23. data/lib/prometheus_exporter/server/collector.rb +2 -0
  24. data/lib/prometheus_exporter/server/delayed_job_collector.rb +11 -0
  25. data/lib/prometheus_exporter/server/hutch_collector.rb +6 -0
  26. data/lib/prometheus_exporter/server/runner.rb +26 -27
  27. data/lib/prometheus_exporter/server/shoryuken_collector.rb +67 -0
  28. data/lib/prometheus_exporter/server/sidekiq_collector.rb +11 -2
  29. data/lib/prometheus_exporter/server/sidekiq_queue_collector.rb +46 -0
  30. data/lib/prometheus_exporter/server/web_collector.rb +5 -0
  31. data/lib/prometheus_exporter/server/web_server.rb +29 -16
  32. data/lib/prometheus_exporter/version.rb +1 -1
  33. data/prometheus_exporter.gemspec +16 -14
  34. metadata +17 -12
  35. data/.travis.yml +0 -12
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module PrometheusExporter
4
- VERSION = "0.4.17"
4
+ VERSION = '0.6.0'
5
5
  end
@@ -5,26 +5,28 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
5
5
  require "prometheus_exporter/version"
6
6
 
7
7
  Gem::Specification.new do |spec|
8
- spec.name = "prometheus_exporter"
9
- spec.version = PrometheusExporter::VERSION
10
- spec.authors = ["Sam Saffron"]
11
- spec.email = ["sam.saffron@gmail.com"]
8
+ spec.name = "prometheus_exporter"
9
+ spec.version = PrometheusExporter::VERSION
10
+ spec.authors = ["Sam Saffron"]
11
+ spec.email = ["sam.saffron@gmail.com"]
12
12
 
13
- spec.summary = %q{Prometheus Exporter}
14
- spec.description = %q{Prometheus metric collector and exporter for Ruby}
15
- spec.homepage = "https://github.com/discourse/prometheus_exporter"
16
- spec.license = "MIT"
13
+ spec.summary = %q{Prometheus Exporter}
14
+ spec.description = %q{Prometheus metric collector and exporter for Ruby}
15
+ spec.homepage = "https://github.com/discourse/prometheus_exporter"
16
+ spec.license = "MIT"
17
17
 
18
- spec.files = `git ls-files -z`.split("\x0").reject do |f|
18
+ spec.post_install_message = "prometheus_exporter will only bind to localhost by default as of v0.5"
19
+
20
+ spec.files = `git ls-files -z`.split("\x0").reject do |f|
19
21
  f.match(%r{^(test|spec|features|bin)/})
20
22
  end
21
- spec.bindir = "bin"
22
- spec.executables = ["prometheus_exporter"]
23
- spec.require_paths = ["lib"]
23
+ spec.bindir = "bin"
24
+ spec.executables = ["prometheus_exporter"]
25
+ spec.require_paths = ["lib"]
24
26
 
25
27
  spec.add_development_dependency "rubocop", ">= 0.69"
26
28
  spec.add_development_dependency "bundler", "> 1.16"
27
- spec.add_development_dependency "rake", "~> 10.0"
29
+ spec.add_development_dependency "rake", "~> 13.0"
28
30
  spec.add_development_dependency "minitest", "~> 5.0"
29
31
  spec.add_development_dependency "guard", "~> 2.0"
30
32
  spec.add_development_dependency "mini_racer", "~> 0.1"
@@ -32,7 +34,7 @@ Gem::Specification.new do |spec|
32
34
  spec.add_development_dependency "oj", "~> 3.0"
33
35
  spec.add_development_dependency "rack-test", "~> 0.8.3"
34
36
  spec.add_development_dependency "minitest-stub-const", "~> 0.6"
35
- spec.add_development_dependency 'rubocop-discourse', '~> 1.0'
37
+ spec.add_development_dependency "rubocop-discourse", ">2"
36
38
  if !RUBY_ENGINE == 'jruby'
37
39
  spec.add_development_dependency "raindrops", "~> 0.19"
38
40
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: prometheus_exporter
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.17
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sam Saffron
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-01-13 00:00:00.000000000 Z
11
+ date: 2020-11-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubocop
@@ -44,14 +44,14 @@ dependencies:
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '10.0'
47
+ version: '13.0'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: '10.0'
54
+ version: '13.0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: minitest
57
57
  requirement: !ruby/object:Gem::Requirement
@@ -154,16 +154,16 @@ dependencies:
154
154
  name: rubocop-discourse
155
155
  requirement: !ruby/object:Gem::Requirement
156
156
  requirements:
157
- - - "~>"
157
+ - - ">"
158
158
  - !ruby/object:Gem::Version
159
- version: '1.0'
159
+ version: '2'
160
160
  type: :development
161
161
  prerelease: false
162
162
  version_requirements: !ruby/object:Gem::Requirement
163
163
  requirements:
164
- - - "~>"
164
+ - - ">"
165
165
  - !ruby/object:Gem::Version
166
- version: '1.0'
166
+ version: '2'
167
167
  description: Prometheus metric collector and exporter for Ruby
168
168
  email:
169
169
  - sam.saffron@gmail.com
@@ -172,9 +172,9 @@ executables:
172
172
  extensions: []
173
173
  extra_rdoc_files: []
174
174
  files:
175
+ - ".github/workflows/ci.yml"
175
176
  - ".gitignore"
176
177
  - ".rubocop.yml"
177
- - ".travis.yml"
178
178
  - CHANGELOG
179
179
  - CODE_OF_CONDUCT.md
180
180
  - Gemfile
@@ -194,7 +194,9 @@ files:
194
194
  - lib/prometheus_exporter/instrumentation/method_profiler.rb
195
195
  - lib/prometheus_exporter/instrumentation/process.rb
196
196
  - lib/prometheus_exporter/instrumentation/puma.rb
197
+ - lib/prometheus_exporter/instrumentation/shoryuken.rb
197
198
  - lib/prometheus_exporter/instrumentation/sidekiq.rb
199
+ - lib/prometheus_exporter/instrumentation/sidekiq_queue.rb
198
200
  - lib/prometheus_exporter/instrumentation/unicorn.rb
199
201
  - lib/prometheus_exporter/metric.rb
200
202
  - lib/prometheus_exporter/metric/base.rb
@@ -212,7 +214,9 @@ files:
212
214
  - lib/prometheus_exporter/server/process_collector.rb
213
215
  - lib/prometheus_exporter/server/puma_collector.rb
214
216
  - lib/prometheus_exporter/server/runner.rb
217
+ - lib/prometheus_exporter/server/shoryuken_collector.rb
215
218
  - lib/prometheus_exporter/server/sidekiq_collector.rb
219
+ - lib/prometheus_exporter/server/sidekiq_queue_collector.rb
216
220
  - lib/prometheus_exporter/server/type_collector.rb
217
221
  - lib/prometheus_exporter/server/unicorn_collector.rb
218
222
  - lib/prometheus_exporter/server/web_collector.rb
@@ -223,7 +227,8 @@ homepage: https://github.com/discourse/prometheus_exporter
223
227
  licenses:
224
228
  - MIT
225
229
  metadata: {}
226
- post_install_message:
230
+ post_install_message: prometheus_exporter will only bind to localhost by default as
231
+ of v0.5
227
232
  rdoc_options: []
228
233
  require_paths:
229
234
  - lib
@@ -239,7 +244,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
239
244
  version: '0'
240
245
  requirements: []
241
246
  rubygems_version: 3.0.3
242
- signing_key:
247
+ signing_key:
243
248
  specification_version: 4
244
249
  summary: Prometheus Exporter
245
250
  test_files: []
@@ -1,12 +0,0 @@
1
- sudo: required
2
- language: ruby
3
- dist: trusty
4
- rvm:
5
- - 2.3
6
- - 2.4
7
- - 2.5
8
- - 2.6
9
- before_install: gem install bundler -v 1.16.1
10
- before_script: sudo sh -c 'echo 0 > /proc/sys/net/ipv6/conf/all/disable_ipv6'
11
-
12
- script: bundle exec rubocop && bundle exec rake