telegraf 1.0.0 → 2.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/test.yml +37 -6
- data/.rubocop.yml +8 -72
- data/Appraisals +6 -0
- data/CHANGELOG.md +38 -1
- data/Gemfile +1 -2
- data/README.md +6 -3
- data/gemfiles/rails_7.0.gemfile +21 -0
- data/lib/telegraf/active_job.rb +3 -3
- data/lib/telegraf/agent.rb +1 -1
- data/lib/telegraf/grape.rb +33 -0
- data/lib/telegraf/railtie.rb +23 -8
- data/lib/telegraf/sidekiq.rb +6 -6
- data/lib/telegraf/version.rb +4 -4
- data/renovate.json +5 -0
- data/telegraf.gemspec +6 -3
- metadata +9 -6
- data/.github/workflows/lint.yml +0 -20
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f2506d8a79e471b78413607796219aa467e330bed37f379482ae51f8b3f41d45
|
4
|
+
data.tar.gz: 30202e32e4584499161208af9d1e355bb6b8770d425675738a7b4a3e4cad553d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bac63da09a0586326816bb0bf13ec2ca10900af04be4c058f5dd4b524a579ea5752c02573e8b275030dcba8cd66fbcf8b3b96f0e6e7933068ffaffc49197d8e3
|
7
|
+
data.tar.gz: 261d7ef27d1afa299561581d946d85833a1254835ced37f9cf97d7a01e2364a7d43cd65cdfa1fe616216e75382373dcd840d1089751110549c4eb06d4651cf1d
|
data/.github/workflows/test.yml
CHANGED
@@ -1,23 +1,36 @@
|
|
1
|
-
|
2
|
-
|
1
|
+
# vim: ft=yaml
|
2
|
+
name: test
|
3
|
+
on: [push, pull_request]
|
3
4
|
jobs:
|
4
|
-
|
5
|
+
rspec:
|
5
6
|
name: Ruby ${{ matrix.ruby }} / ${{ matrix.gemfile }}
|
6
7
|
runs-on: ubuntu-20.04
|
7
8
|
|
8
9
|
strategy:
|
9
10
|
matrix:
|
10
11
|
ruby:
|
11
|
-
-
|
12
|
-
-
|
13
|
-
-
|
12
|
+
- "3.1"
|
13
|
+
- "3.0"
|
14
|
+
- "2.7"
|
15
|
+
- "2.6"
|
16
|
+
- "2.5"
|
14
17
|
gemfile:
|
15
18
|
- rails_5.2.gemfile
|
16
19
|
- rails_6.0.gemfile
|
17
20
|
- rails_6.1.gemfile
|
21
|
+
- rails_7.0.gemfile
|
18
22
|
- rack_2.0.gemfile
|
19
23
|
- rack_2.1.gemfile
|
20
24
|
- rack_2.2.gemfile
|
25
|
+
exclude:
|
26
|
+
- ruby: "3.1"
|
27
|
+
gemfile: rails_5.2.gemfile
|
28
|
+
- ruby: "3.0"
|
29
|
+
gemfile: rails_5.2.gemfile
|
30
|
+
- ruby: "2.6"
|
31
|
+
gemfile: rails_7.0.gemfile
|
32
|
+
- ruby: "2.5"
|
33
|
+
gemfile: rails_7.0.gemfile
|
21
34
|
fail-fast: false
|
22
35
|
|
23
36
|
env:
|
@@ -35,3 +48,21 @@ jobs:
|
|
35
48
|
bundler-cache: true
|
36
49
|
|
37
50
|
- run: bundle exec rspec --color --format documentation
|
51
|
+
|
52
|
+
rubocop:
|
53
|
+
name: rubocop
|
54
|
+
runs-on: ubuntu-20.04
|
55
|
+
|
56
|
+
env:
|
57
|
+
BUNDLE_WITHOUT: development
|
58
|
+
BUNDLE_JOBS: 4
|
59
|
+
BUNDLE_RETRY: 3
|
60
|
+
|
61
|
+
steps:
|
62
|
+
- uses: actions/checkout@master
|
63
|
+
- uses: ruby/setup-ruby@v1
|
64
|
+
with:
|
65
|
+
ruby-version: 3.0
|
66
|
+
bundler-cache: true
|
67
|
+
|
68
|
+
- run: bundle exec rubocop --parallel --color
|
data/.rubocop.yml
CHANGED
@@ -1,75 +1,11 @@
|
|
1
|
-
|
2
|
-
Include:
|
3
|
-
- "**/*.rb"
|
4
|
-
NewCops: enable
|
5
|
-
SuggestExtensions: false
|
6
|
-
TargetRubyVersion: 2.5
|
7
|
-
|
8
|
-
|
9
|
-
Layout/ArgumentAlignment:
|
10
|
-
EnforcedStyle: with_fixed_indentation
|
11
|
-
|
12
|
-
Layout/CaseIndentation:
|
13
|
-
EnforcedStyle: end
|
14
|
-
IndentOneStep: true
|
15
|
-
SupportedStyles:
|
16
|
-
- case
|
17
|
-
- end
|
18
|
-
|
19
|
-
Layout/FirstHashElementIndentation:
|
20
|
-
EnforcedStyle: consistent
|
21
|
-
|
22
|
-
Layout/LineLength:
|
23
|
-
Exclude:
|
24
|
-
- spec/**/*_spec.rb
|
25
|
-
|
26
|
-
Layout/SpaceInsideBlockBraces:
|
27
|
-
EnforcedStyle: space
|
28
|
-
EnforcedStyleForEmptyBraces: no_space
|
29
|
-
SpaceBeforeBlockParameters: false
|
30
|
-
|
31
|
-
Layout/SpaceInsideHashLiteralBraces:
|
32
|
-
EnforcedStyle: no_space
|
33
|
-
|
34
|
-
|
35
|
-
Metrics/AbcSize:
|
36
|
-
Enabled: false
|
37
|
-
|
38
|
-
Metrics/BlockLength:
|
39
|
-
Exclude:
|
40
|
-
- spec/**/*_spec.rb
|
1
|
+
# vim: ft=yaml
|
41
2
|
|
42
|
-
|
43
|
-
|
3
|
+
inherit_gem:
|
4
|
+
my-rubocop: default.yml
|
44
5
|
|
6
|
+
AllCops:
|
7
|
+
TargetRubyVersion: 2.5
|
8
|
+
SuggestExtensions: False
|
45
9
|
|
46
|
-
|
47
|
-
|
48
|
-
- Rakefile
|
49
|
-
- Gemfile
|
50
|
-
|
51
|
-
|
52
|
-
Style/ClassAndModuleChildren:
|
53
|
-
Enabled: false
|
54
|
-
|
55
|
-
Style/Documentation:
|
56
|
-
Enabled: false
|
57
|
-
|
58
|
-
Style/HashEachMethods:
|
59
|
-
Enabled: false
|
60
|
-
|
61
|
-
Style/HashTransformKeys:
|
62
|
-
Enabled: false
|
63
|
-
|
64
|
-
Style/HashTransformValues:
|
65
|
-
Enabled: false
|
66
|
-
|
67
|
-
Style/IfUnlessModifier:
|
68
|
-
Enabled: false
|
69
|
-
|
70
|
-
Style/RescueModifier:
|
71
|
-
Exclude:
|
72
|
-
- spec/**/*_spec.rb
|
73
|
-
|
74
|
-
Style/TrivialAccessors:
|
75
|
-
AllowPredicates: true
|
10
|
+
RSpec/FilePath:
|
11
|
+
Enabled: False
|
data/Appraisals
CHANGED
data/CHANGELOG.md
CHANGED
@@ -1,4 +1,7 @@
|
|
1
|
+
<!-- markdownlint-disable-file MD024 -->
|
2
|
+
|
1
3
|
# Changelog
|
4
|
+
|
2
5
|
All notable changes to this project will be documented in this file.
|
3
6
|
|
4
7
|
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
|
@@ -6,31 +9,65 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
|
|
6
9
|
|
7
10
|
## [Unreleased]
|
8
11
|
|
12
|
+
## [2.1.1] - 2022-08-23
|
13
|
+
|
14
|
+
### Fixed
|
15
|
+
|
16
|
+
- Possible RuntimeError: can't add a new key into hash during iteration (@MrSerth)
|
17
|
+
|
18
|
+
## [2.1.0] - 2022-01-24
|
19
|
+
|
20
|
+
### Added
|
21
|
+
|
22
|
+
- Support for Rails 7.0 and Ruby 3.1
|
23
|
+
- Grape API instrumentation (#17)
|
24
|
+
|
25
|
+
## [2.0.0] - 2021-09-30
|
26
|
+
|
27
|
+
### Changed
|
28
|
+
|
29
|
+
- The sidekiq middleware does not use keyword arguments as sidekiq does not handle them correctly on Ruby 3.0 (#14)
|
30
|
+
|
9
31
|
## [1.0.0] - 2021-01-26
|
32
|
+
|
10
33
|
### Added
|
34
|
+
|
11
35
|
- Global tags (#6)
|
12
36
|
|
13
37
|
## [0.8.0] - 2020-12-02
|
38
|
+
|
14
39
|
### Added
|
40
|
+
|
15
41
|
- ActiveJob instrumentation (#10)
|
16
42
|
|
17
43
|
## [0.7.0] - 2020-05-07
|
44
|
+
|
18
45
|
### Added
|
46
|
+
|
19
47
|
- Sidekiq middleware (#8)
|
20
48
|
|
21
49
|
## [0.6.1] - 2020-04-01
|
50
|
+
|
22
51
|
### Fixed
|
52
|
+
|
23
53
|
- Fix type in instrumentation option (#7)
|
24
54
|
|
25
55
|
## [0.6.0] - 2020-03-31
|
56
|
+
|
26
57
|
### Added
|
58
|
+
|
27
59
|
- New Rack middleware and Rails plugin to collect request events (#5)
|
28
60
|
|
29
61
|
## 0.5.0 - undefined
|
62
|
+
|
30
63
|
### Changed
|
64
|
+
|
31
65
|
- Remove `influxdb` not unnecessarily restrict users needing a specific influxdb client.
|
32
66
|
|
33
|
-
[
|
67
|
+
[unreleased]: https://github.com/jgraichen/telegraf-ruby/compare/v2.1.1...HEAD
|
68
|
+
[2.1.1]: https://github.com/jgraichen/telegraf-ruby/compare/v2.1.0...v2.1.1
|
69
|
+
[2.1.0]: https://github.com/jgraichen/telegraf-ruby/compare/v2.0.0...v2.1.0
|
70
|
+
[2.0.0]: https://github.com/jgraichen/telegraf-ruby/compare/v1.0.0...v2.0.0
|
34
71
|
[1.0.0]: https://github.com/jgraichen/telegraf-ruby/compare/v0.8.0...v1.0.0
|
35
72
|
[0.8.0]: https://github.com/jgraichen/telegraf-ruby/compare/v0.7.0...v0.8.0
|
36
73
|
[0.7.0]: https://github.com/jgraichen/telegraf-ruby/compare/v0.6.1...v0.7.0
|
data/Gemfile
CHANGED
@@ -5,10 +5,9 @@ source 'https://rubygems.org'
|
|
5
5
|
# Specify your gem's dependencies in telegraf.gemspec
|
6
6
|
gemspec
|
7
7
|
|
8
|
+
gem 'my-rubocop', github: 'jgraichen/my-rubocop', ref: 'v6'
|
8
9
|
gem 'rake'
|
9
10
|
gem 'rspec', '~> 3.8'
|
10
|
-
gem 'rubocop', '~> 1.7'
|
11
|
-
gem 'rubocop-rspec', '~> 1.41'
|
12
11
|
|
13
12
|
group :test do
|
14
13
|
gem 'rack'
|
data/README.md
CHANGED
@@ -1,5 +1,8 @@
|
|
1
1
|
# Telegraf
|
2
2
|
|
3
|
+
[](https://rubygems.org/gems/telegraf)
|
4
|
+
[](https://github.com/jgraichen/telegraf-ruby/actions)
|
5
|
+
|
3
6
|
Send events to a local [Telegraf](https://github.com/influxdata/telegraf) agent or anything that can receive the InfluxDB line protocol.
|
4
7
|
|
5
8
|
It further includes plugins for Rack, Rails, ActiveJob and Sidekiq to collect request events. See plugin usage details below.
|
@@ -78,7 +81,7 @@ require "telegraf/rails"
|
|
78
81
|
|
79
82
|
class MyApplication > ::Rails::Application
|
80
83
|
# Configure receiver
|
81
|
-
config.telegraf.connect = "udp://localhost:
|
84
|
+
config.telegraf.connect = "udp://localhost:8094"
|
82
85
|
|
83
86
|
# Global tags added to all events. These will override
|
84
87
|
# any local tag with the same name.
|
@@ -125,7 +128,7 @@ require "telegraf/active_job"
|
|
125
128
|
agent = ::Telegraf::Agent.new
|
126
129
|
ActiveSupport::Notifications.subscribe(
|
127
130
|
'perform.active_job',
|
128
|
-
Telegraf::ActiveJob.new(agent: agent, series: '
|
131
|
+
Telegraf::ActiveJob.new(agent: agent, series: 'active_job', tags: {global: 'tag'})
|
129
132
|
)
|
130
133
|
```
|
131
134
|
|
@@ -139,7 +142,7 @@ require "telegraf/sidekiq"
|
|
139
142
|
agent = ::Telegraf::Agent.new
|
140
143
|
Sidekiq.configure_server do |config|
|
141
144
|
config.server_middleware do |chain|
|
142
|
-
chain.add ::Telegraf::Sidekiq::Middleware, agent: agent, series: '
|
145
|
+
chain.add ::Telegraf::Sidekiq::Middleware, agent: agent, series: 'sidekiq', tags: {global: 'tag'}
|
143
146
|
end
|
144
147
|
end
|
145
148
|
```
|
@@ -0,0 +1,21 @@
|
|
1
|
+
# This file was generated by Appraisal
|
2
|
+
|
3
|
+
source "https://rubygems.org"
|
4
|
+
|
5
|
+
gem "rake"
|
6
|
+
gem "rspec", "~> 3.8"
|
7
|
+
gem "rubocop", "~> 1.7"
|
8
|
+
gem "rubocop-rspec", "~> 1.41"
|
9
|
+
|
10
|
+
group :test do
|
11
|
+
gem "rack"
|
12
|
+
gem "rails", "~> 7.0.0"
|
13
|
+
gem "sidekiq", "~> 6.0"
|
14
|
+
end
|
15
|
+
|
16
|
+
group :development do
|
17
|
+
gem "appraisal"
|
18
|
+
gem "rake-release", "~> 1.2"
|
19
|
+
end
|
20
|
+
|
21
|
+
gemspec path: "../"
|
data/lib/telegraf/active_job.rb
CHANGED
@@ -39,11 +39,11 @@ module Telegraf
|
|
39
39
|
**@tags,
|
40
40
|
job: job.class.name,
|
41
41
|
queue: job.queue_name,
|
42
|
-
errors: payload.key?(:exception_object)
|
42
|
+
errors: payload.key?(:exception_object),
|
43
43
|
},
|
44
44
|
values: {
|
45
|
-
app_ms: ((finish - start) * 1000.0) # milliseconds
|
46
|
-
}
|
45
|
+
app_ms: ((finish - start) * 1000.0), # milliseconds
|
46
|
+
},
|
47
47
|
)
|
48
48
|
end
|
49
49
|
end
|
data/lib/telegraf/agent.rb
CHANGED
@@ -0,0 +1,33 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Telegraf
|
4
|
+
# Telegraf::Grape
|
5
|
+
#
|
6
|
+
# This class extends requests metrics with details for Grape API endpoints.
|
7
|
+
#
|
8
|
+
#
|
9
|
+
# Tags:
|
10
|
+
#
|
11
|
+
# * `controller`:
|
12
|
+
# The Grape endpoint class.
|
13
|
+
#
|
14
|
+
# * `instance`:
|
15
|
+
# The Grape endpoint class.
|
16
|
+
#
|
17
|
+
# * `format`:
|
18
|
+
# Grape's internal identifier for the response format.
|
19
|
+
#
|
20
|
+
class Grape
|
21
|
+
def call(_name, _start, _finish, _id, payload)
|
22
|
+
point = payload[:env][::Telegraf::Rack::FIELD_NAME]
|
23
|
+
return unless point
|
24
|
+
|
25
|
+
endpoint = payload[:endpoint]
|
26
|
+
return unless endpoint
|
27
|
+
|
28
|
+
point.tags[:controller] = endpoint.options[:for].to_s
|
29
|
+
point.tags[:instance] = point.tags[:controller]
|
30
|
+
point.tags[:format] = payload[:env]['api.format']
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
data/lib/telegraf/railtie.rb
CHANGED
@@ -3,6 +3,7 @@
|
|
3
3
|
require 'rails'
|
4
4
|
require 'telegraf'
|
5
5
|
require 'telegraf/active_job'
|
6
|
+
require 'telegraf/grape'
|
6
7
|
require 'telegraf/rack'
|
7
8
|
require 'telegraf/sidekiq'
|
8
9
|
|
@@ -57,6 +58,10 @@ module Telegraf
|
|
57
58
|
# Install request instrumentation
|
58
59
|
config.telegraf.instrumentation = true
|
59
60
|
|
61
|
+
# Install Grape instrumentation
|
62
|
+
config.telegraf.grape = ::ActiveSupport::OrderedOptions.new
|
63
|
+
config.telegraf.grape.enabled = defined?(::Grape)
|
64
|
+
|
60
65
|
# Install ActiveJob instrumentation
|
61
66
|
config.telegraf.active_job = ::ActiveSupport::OrderedOptions.new
|
62
67
|
config.telegraf.active_job.enabled = defined?(::ActiveJob)
|
@@ -70,12 +75,11 @@ module Telegraf
|
|
70
75
|
config.telegraf.sidekiq.tags = {}
|
71
76
|
|
72
77
|
initializer 'telegraf.agent' do |app|
|
73
|
-
app.config.telegraf.agent ||=
|
78
|
+
app.config.telegraf.agent ||= \
|
74
79
|
::Telegraf::Agent.new \
|
75
80
|
app.config.telegraf.connect,
|
76
81
|
logger: Rails.logger,
|
77
82
|
tags: app.config.telegraf.tags
|
78
|
-
end
|
79
83
|
end
|
80
84
|
|
81
85
|
initializer 'telegraf.rack' do |app|
|
@@ -92,7 +96,7 @@ module Telegraf
|
|
92
96
|
next unless app.config.telegraf.instrumentation
|
93
97
|
|
94
98
|
ActiveSupport::Notifications.subscribe(
|
95
|
-
'process_action.action_controller'
|
99
|
+
'process_action.action_controller',
|
96
100
|
) do |_name, start, finish, _id, payload|
|
97
101
|
point = payload[:headers].env[::Telegraf::Rack::FIELD_NAME]
|
98
102
|
next unless point
|
@@ -108,6 +112,15 @@ module Telegraf
|
|
108
112
|
end
|
109
113
|
end
|
110
114
|
|
115
|
+
initializer 'telegraf.grape' do |app|
|
116
|
+
next unless app.config.telegraf.grape.enabled
|
117
|
+
|
118
|
+
ActiveSupport::Notifications.subscribe(
|
119
|
+
'endpoint_run.grape',
|
120
|
+
Telegraf::Grape.new,
|
121
|
+
)
|
122
|
+
end
|
123
|
+
|
111
124
|
initializer 'telegraf.active_job' do |app|
|
112
125
|
next unless app.config.telegraf.active_job.enabled
|
113
126
|
|
@@ -116,8 +129,8 @@ module Telegraf
|
|
116
129
|
Telegraf::ActiveJob.new(
|
117
130
|
agent: app.config.telegraf.agent,
|
118
131
|
series: app.config.telegraf.active_job.series,
|
119
|
-
tags: app.config.telegraf.active_job.tags
|
120
|
-
)
|
132
|
+
tags: app.config.telegraf.active_job.tags,
|
133
|
+
),
|
121
134
|
)
|
122
135
|
end
|
123
136
|
|
@@ -127,9 +140,11 @@ module Telegraf
|
|
127
140
|
::Sidekiq.configure_server do |config|
|
128
141
|
config.server_middleware do |chain|
|
129
142
|
chain.add Telegraf::Sidekiq::Middleware, \
|
130
|
-
|
131
|
-
|
132
|
-
|
143
|
+
app.config.telegraf.agent,
|
144
|
+
{
|
145
|
+
series: app.config.telegraf.sidekiq.series,
|
146
|
+
tags: app.config.telegraf.sidekiq.tags,
|
147
|
+
}
|
133
148
|
end
|
134
149
|
end
|
135
150
|
end
|
data/lib/telegraf/sidekiq.rb
CHANGED
@@ -37,10 +37,10 @@ module Telegraf
|
|
37
37
|
# Only present for "normal" (async) jobs (with tag `type` of "job").
|
38
38
|
#
|
39
39
|
class Middleware
|
40
|
-
def initialize(agent
|
40
|
+
def initialize(agent, options = {})
|
41
41
|
@agent = agent
|
42
|
-
@series = series.
|
43
|
-
@tags = tags.freeze
|
42
|
+
@series = options.fetch(:series, 'sidekiq').to_str.freeze
|
43
|
+
@tags = options.fetch(:tags, {}).to_hash.freeze
|
44
44
|
end
|
45
45
|
|
46
46
|
def call(worker, job, queue)
|
@@ -52,11 +52,11 @@ module Telegraf
|
|
52
52
|
errors: true,
|
53
53
|
retry: job.key?('retried_at'),
|
54
54
|
queue: queue,
|
55
|
-
worker: worker.class.name
|
55
|
+
worker: worker.class.name,
|
56
56
|
}
|
57
57
|
|
58
58
|
values = {
|
59
|
-
retry_count: job['retry_count']
|
59
|
+
retry_count: job['retry_count'],
|
60
60
|
}.compact
|
61
61
|
|
62
62
|
# The "enqueued_at" key is not present for scheduled jobs.
|
@@ -80,7 +80,7 @@ module Telegraf
|
|
80
80
|
values[:app_ms] = (job_stop - job_start) * 1000 # milliseconds
|
81
81
|
|
82
82
|
@agent.write(
|
83
|
-
@series, tags: tags, values: values
|
83
|
+
@series, tags: tags, values: values,
|
84
84
|
)
|
85
85
|
end
|
86
86
|
end
|
data/lib/telegraf/version.rb
CHANGED
@@ -2,11 +2,11 @@
|
|
2
2
|
|
3
3
|
module Telegraf
|
4
4
|
module VERSION
|
5
|
-
MAJOR =
|
6
|
-
MINOR =
|
7
|
-
PATCH =
|
5
|
+
MAJOR = 2
|
6
|
+
MINOR = 1
|
7
|
+
PATCH = 1
|
8
8
|
STAGE = nil
|
9
|
-
STRING = [MAJOR, MINOR, PATCH, STAGE].
|
9
|
+
STRING = [MAJOR, MINOR, PATCH, STAGE].compact.join('.').freeze
|
10
10
|
|
11
11
|
def self.to_s
|
12
12
|
STRING
|
data/telegraf.gemspec
CHANGED
@@ -1,7 +1,6 @@
|
|
1
|
-
# coding: utf-8
|
2
1
|
# frozen_string_literal: true
|
3
2
|
|
4
|
-
lib = File.expand_path('
|
3
|
+
lib = File.expand_path('lib', __dir__)
|
5
4
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
6
5
|
require 'telegraf/version'
|
7
6
|
|
@@ -16,6 +15,10 @@ Gem::Specification.new do |spec|
|
|
16
15
|
spec.homepage = 'https://github.com/jgraichen/telegraf-ruby'
|
17
16
|
spec.license = 'LGPLv3'
|
18
17
|
|
18
|
+
spec.metadata = {
|
19
|
+
'rubygems_mfa_required' => 'true',
|
20
|
+
}
|
21
|
+
|
19
22
|
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
20
23
|
f.match(%r{^(test|spec|features)/})
|
21
24
|
end
|
@@ -24,7 +27,7 @@ Gem::Specification.new do |spec|
|
|
24
27
|
spec.executables = spec.files.grep(%r{^exe/}) {|f| File.basename(f) }
|
25
28
|
spec.require_paths = ['lib']
|
26
29
|
|
30
|
+
spec.required_ruby_version = '>= 2.5'
|
27
31
|
spec.add_dependency 'influxdb'
|
28
|
-
|
29
32
|
spec.add_development_dependency 'bundler'
|
30
33
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: telegraf
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 2.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jan Graichen
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-08-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: influxdb
|
@@ -46,7 +46,6 @@ extensions: []
|
|
46
46
|
extra_rdoc_files: []
|
47
47
|
files:
|
48
48
|
- ".editorconfig"
|
49
|
-
- ".github/workflows/lint.yml"
|
50
49
|
- ".github/workflows/test.yml"
|
51
50
|
- ".gitignore"
|
52
51
|
- ".rspec"
|
@@ -65,19 +64,23 @@ files:
|
|
65
64
|
- gemfiles/rails_5.2.gemfile
|
66
65
|
- gemfiles/rails_6.0.gemfile
|
67
66
|
- gemfiles/rails_6.1.gemfile
|
67
|
+
- gemfiles/rails_7.0.gemfile
|
68
68
|
- lib/telegraf.rb
|
69
69
|
- lib/telegraf/active_job.rb
|
70
70
|
- lib/telegraf/agent.rb
|
71
|
+
- lib/telegraf/grape.rb
|
71
72
|
- lib/telegraf/rack.rb
|
72
73
|
- lib/telegraf/rails.rb
|
73
74
|
- lib/telegraf/railtie.rb
|
74
75
|
- lib/telegraf/sidekiq.rb
|
75
76
|
- lib/telegraf/version.rb
|
77
|
+
- renovate.json
|
76
78
|
- telegraf.gemspec
|
77
79
|
homepage: https://github.com/jgraichen/telegraf-ruby
|
78
80
|
licenses:
|
79
81
|
- LGPLv3
|
80
|
-
metadata:
|
82
|
+
metadata:
|
83
|
+
rubygems_mfa_required: 'true'
|
81
84
|
post_install_message:
|
82
85
|
rdoc_options: []
|
83
86
|
require_paths:
|
@@ -86,14 +89,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
86
89
|
requirements:
|
87
90
|
- - ">="
|
88
91
|
- !ruby/object:Gem::Version
|
89
|
-
version: '
|
92
|
+
version: '2.5'
|
90
93
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
91
94
|
requirements:
|
92
95
|
- - ">="
|
93
96
|
- !ruby/object:Gem::Version
|
94
97
|
version: '0'
|
95
98
|
requirements: []
|
96
|
-
rubygems_version: 3.
|
99
|
+
rubygems_version: 3.3.7
|
97
100
|
signing_key:
|
98
101
|
specification_version: 4
|
99
102
|
summary: Metric Reporter to local telegraf agent
|
data/.github/workflows/lint.yml
DELETED
@@ -1,20 +0,0 @@
|
|
1
|
-
name: Lint
|
2
|
-
on: [push]
|
3
|
-
jobs:
|
4
|
-
rubocop:
|
5
|
-
name: rubocop
|
6
|
-
runs-on: ubuntu-20.04
|
7
|
-
|
8
|
-
env:
|
9
|
-
BUNDLE_WITHOUT: development
|
10
|
-
BUNDLE_JOBS: 4
|
11
|
-
BUNDLE_RETRY: 3
|
12
|
-
|
13
|
-
steps:
|
14
|
-
- uses: actions/checkout@master
|
15
|
-
- uses: ruby/setup-ruby@v1
|
16
|
-
with:
|
17
|
-
ruby-version: 2.7
|
18
|
-
bundler-cache: true
|
19
|
-
|
20
|
-
- run: bundle exec rubocop --parallel --color
|