fluent-plugin-suppress 1.1.0 → 1.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 +5 -5
- data/.github/workflows/test.yml +18 -0
- data/fluent-plugin-suppress.gemspec +1 -1
- data/lib/fluent/plugin/filter_suppress.rb +2 -2
- data/lib/fluent/plugin/out_suppress.rb +3 -3
- metadata +4 -5
- data/.travis.yml +0 -9
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: abb843eab25b8ca62438b6342b38f189cfa73e500c51d4fd6c51976f6080b970
|
4
|
+
data.tar.gz: e5c98d0402bd7402b08d3342bd64babb0da25923e8dcb5be91c8c3883f1020e2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6d3eb6c899fbee42d3a4464b9188847028c0e9c5bf646dcfe02d876dc1e6a10ea32995c5edf80b5e17d8e94282a3f69fbfa816cab06bf09ba129be41e4bab0ea
|
7
|
+
data.tar.gz: 6c7dbed41a8b0a0dcce9c9b36a6b4afd7659ad0695e784ed5bc5b4aafcf9cabcef6e20af81b7c39645a1872f37903be0f569eaf3942700e3d79127bfb7a70ec9
|
@@ -0,0 +1,18 @@
|
|
1
|
+
name: test
|
2
|
+
on: [push]
|
3
|
+
jobs:
|
4
|
+
build:
|
5
|
+
runs-on: ubuntu-latest
|
6
|
+
strategy:
|
7
|
+
matrix:
|
8
|
+
ruby: ["3.1", "3.2", "3.3", "3.4"]
|
9
|
+
name: test on Ruby ${{ matrix.ruby }}
|
10
|
+
steps:
|
11
|
+
- uses: actions/checkout@v4
|
12
|
+
- uses: ruby/setup-ruby@v1
|
13
|
+
with:
|
14
|
+
ruby-version: ${{ matrix.ruby }}
|
15
|
+
bundler-cache: true
|
16
|
+
- run: bundle install
|
17
|
+
- run: |
|
18
|
+
bundle exec rake test
|
@@ -13,7 +13,7 @@ Gem::Specification.new do |gem|
|
|
13
13
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
14
14
|
gem.name = "fluent-plugin-suppress"
|
15
15
|
gem.require_paths = ["lib"]
|
16
|
-
gem.version = "1.1.
|
16
|
+
gem.version = "1.1.1"
|
17
17
|
|
18
18
|
gem.add_runtime_dependency "fluentd", [">= 0.14.8", "< 2"]
|
19
19
|
gem.add_development_dependency "rake", ">= 0.9.2"
|
@@ -35,14 +35,14 @@ module Fluent::Plugin
|
|
35
35
|
end
|
36
36
|
|
37
37
|
if slot.length >= @num
|
38
|
-
log.debug "suppressed record: #{record.to_json}"
|
38
|
+
log.debug { "suppressed record: #{record.to_json}" }
|
39
39
|
next
|
40
40
|
end
|
41
41
|
|
42
42
|
if @slots.length > @max_slot_num
|
43
43
|
(evict_key, evict_slot) = @slots.shift
|
44
44
|
if evict_slot.last && (evict_slot.last > expired)
|
45
|
-
log.warn "@slots length exceeded @max_slot_num: #{@max_slot_num}. Evicted slot for the key: #{evict_key}"
|
45
|
+
log.warn { "@slots length exceeded @max_slot_num: #{@max_slot_num}. Evicted slot for the key: #{evict_key}" }
|
46
46
|
end
|
47
47
|
end
|
48
48
|
|
@@ -49,14 +49,14 @@ module Fluent::Plugin
|
|
49
49
|
end
|
50
50
|
|
51
51
|
if slot.length >= @num
|
52
|
-
log.debug "suppressed record: #{record.to_json}"
|
52
|
+
log.debug { "suppressed record: #{record.to_json}" }
|
53
53
|
next
|
54
54
|
end
|
55
55
|
|
56
56
|
if @slots.length > @max_slot_num
|
57
57
|
(evict_key, evict_slot) = @slots.shift
|
58
58
|
if evict_slot.last && (evict_slot.last > expired)
|
59
|
-
log.warn "@slots length exceeded @max_slot_num: #{@max_slot_num}. Evicted slot for the key: #{evict_key}"
|
59
|
+
log.warn { "@slots length exceeded @max_slot_num: #{@max_slot_num}. Evicted slot for the key: #{evict_key}" }
|
60
60
|
end
|
61
61
|
end
|
62
62
|
|
@@ -66,7 +66,7 @@ module Fluent::Plugin
|
|
66
66
|
if @labelled || tag != _tag
|
67
67
|
router.emit(_tag, time, record)
|
68
68
|
else
|
69
|
-
log.warn "Drop record #{record} tag '#{tag}' was not replaced. Can't emit record, cause infinity looping. Set remove_tag_prefix, remove_tag_suffix, add_tag_prefix or add_tag_suffix correctly."
|
69
|
+
log.warn { "Drop record #{record} tag '#{tag}' was not replaced. Can't emit record, cause infinity looping. Set remove_tag_prefix, remove_tag_suffix, add_tag_prefix or add_tag_suffix correctly." }
|
70
70
|
end
|
71
71
|
end
|
72
72
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fluent-plugin-suppress
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- FUJIWARA Shunichiro
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2025-03-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: fluentd
|
@@ -65,8 +65,8 @@ executables: []
|
|
65
65
|
extensions: []
|
66
66
|
extra_rdoc_files: []
|
67
67
|
files:
|
68
|
+
- ".github/workflows/test.yml"
|
68
69
|
- ".gitignore"
|
69
|
-
- ".travis.yml"
|
70
70
|
- Changes
|
71
71
|
- Gemfile
|
72
72
|
- LICENSE
|
@@ -97,8 +97,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
97
97
|
- !ruby/object:Gem::Version
|
98
98
|
version: '0'
|
99
99
|
requirements: []
|
100
|
-
|
101
|
-
rubygems_version: 2.6.11
|
100
|
+
rubygems_version: 3.4.10
|
102
101
|
signing_key:
|
103
102
|
specification_version: 4
|
104
103
|
summary: Fluentd filter plugin to suppress same messages
|