fluentd 1.16.9 → 1.17.0

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.
Files changed (84) hide show
  1. checksums.yaml +4 -4
  2. data/.github/DISCUSSION_TEMPLATE/q-a-japanese.yml +50 -0
  3. data/.github/DISCUSSION_TEMPLATE/q-a.yml +47 -0
  4. data/.github/workflows/test-ruby-head.yml +31 -0
  5. data/.github/workflows/test.yml +3 -35
  6. data/CHANGELOG.md +33 -85
  7. data/README.md +3 -1
  8. data/Rakefile +1 -1
  9. data/fluentd.gemspec +9 -10
  10. data/lib/fluent/command/binlog_reader.rb +1 -1
  11. data/lib/fluent/command/fluentd.rb +1 -1
  12. data/lib/fluent/compat/formatter.rb +0 -6
  13. data/lib/fluent/config/configure_proxy.rb +2 -2
  14. data/lib/fluent/config/parser.rb +3 -15
  15. data/lib/fluent/config/types.rb +1 -1
  16. data/lib/fluent/config/v1_parser.rb +1 -1
  17. data/lib/fluent/config/yaml_parser/parser.rb +0 -4
  18. data/lib/fluent/configurable.rb +2 -2
  19. data/lib/fluent/counter/mutex_hash.rb +1 -1
  20. data/lib/fluent/fluent_log_event_router.rb +0 -2
  21. data/lib/fluent/plugin/buf_file.rb +1 -1
  22. data/lib/fluent/plugin/buffer/file_chunk.rb +1 -1
  23. data/lib/fluent/plugin/buffer/file_single_chunk.rb +2 -3
  24. data/lib/fluent/plugin/filter_parser.rb +26 -8
  25. data/lib/fluent/plugin/formatter_csv.rb +4 -18
  26. data/lib/fluent/plugin/in_http.rb +17 -52
  27. data/lib/fluent/plugin/in_tail.rb +35 -3
  28. data/lib/fluent/plugin/out_file.rb +0 -8
  29. data/lib/fluent/plugin/out_http.rb +125 -13
  30. data/lib/fluent/plugin/owned_by_mixin.rb +0 -1
  31. data/lib/fluent/plugin/parser_json.rb +34 -9
  32. data/lib/fluent/plugin/parser_msgpack.rb +24 -3
  33. data/lib/fluent/plugin_helper/metrics.rb +2 -2
  34. data/lib/fluent/registry.rb +6 -6
  35. data/lib/fluent/supervisor.rb +3 -3
  36. data/lib/fluent/test/output_test.rb +1 -1
  37. data/lib/fluent/unique_id.rb +1 -1
  38. data/lib/fluent/version.rb +1 -1
  39. data/lib/fluent/winsvc.rb +8 -38
  40. data/test/command/test_cat.rb +2 -2
  41. data/test/command/test_fluentd.rb +10 -57
  42. data/test/config/test_plugin_configuration.rb +6 -6
  43. data/test/helper.rb +7 -27
  44. data/test/log/test_console_adapter.rb +10 -3
  45. data/test/plugin/data/log_numeric/01.log +0 -0
  46. data/test/plugin/data/log_numeric/02.log +0 -0
  47. data/test/plugin/data/log_numeric/12.log +0 -0
  48. data/test/plugin/data/log_numeric/14.log +0 -0
  49. data/test/plugin/in_tail/test_io_handler.rb +14 -13
  50. data/test/plugin/in_tail/test_position_file.rb +7 -6
  51. data/test/plugin/out_forward/test_ack_handler.rb +3 -3
  52. data/test/plugin/out_forward/test_socket_cache.rb +3 -3
  53. data/test/plugin/test_buffer.rb +2 -2
  54. data/test/plugin/test_filter_grep.rb +1 -1
  55. data/test/plugin/test_in_forward.rb +1 -2
  56. data/test/plugin/test_in_http.rb +23 -1
  57. data/test/plugin/test_in_monitor_agent.rb +6 -6
  58. data/test/plugin/test_in_syslog.rb +18 -25
  59. data/test/plugin/test_in_tail.rb +153 -5
  60. data/test/plugin/test_in_tcp.rb +1 -1
  61. data/test/plugin/test_in_udp.rb +10 -16
  62. data/test/plugin/test_out_exec_filter.rb +7 -12
  63. data/test/plugin/test_out_file.rb +2 -22
  64. data/test/plugin/test_out_forward.rb +3 -2
  65. data/test/plugin/test_out_http.rb +128 -0
  66. data/test/plugin/test_out_stream.rb +1 -1
  67. data/test/plugin/test_output.rb +1 -1
  68. data/test/plugin/test_output_as_buffered.rb +2 -2
  69. data/test/plugin/test_output_as_buffered_retries.rb +2 -2
  70. data/test/plugin/test_owned_by.rb +0 -1
  71. data/test/plugin/test_parser_csv.rb +1 -1
  72. data/test/plugin/test_parser_json.rb +106 -31
  73. data/test/plugin/test_parser_msgpack.rb +127 -0
  74. data/test/plugin/test_storage.rb +0 -1
  75. data/test/plugin_helper/test_child_process.rb +4 -4
  76. data/test/plugin_helper/test_http_server_helper.rb +1 -1
  77. data/test/plugin_helper/test_server.rb +41 -64
  78. data/test/plugin_helper/test_socket.rb +1 -1
  79. data/test/test_config.rb +0 -6
  80. data/test/test_event_router.rb +2 -2
  81. data/test/test_supervisor.rb +21 -30
  82. data/test/test_tls.rb +1 -1
  83. metadata +88 -18
  84. data/test/scripts/windows_service_test.ps1 +0 -73
metadata CHANGED
@@ -1,13 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluentd
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.16.9
4
+ version: 1.17.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sadayuki Furuhashi
8
+ autorequire:
8
9
  bindir: bin
9
10
  cert_chain: []
10
- date: 1980-01-02 00:00:00.000000000 Z
11
+ date: 2024-04-30 00:00:00.000000000 Z
11
12
  dependencies:
12
13
  - !ruby/object:Gem::Dependency
13
14
  name: bundler
@@ -200,33 +201,47 @@ dependencies:
200
201
  - !ruby/object:Gem::Version
201
202
  version: '1.4'
202
203
  - !ruby/object:Gem::Dependency
203
- name: console
204
+ name: base64
204
205
  requirement: !ruby/object:Gem::Requirement
205
206
  requirements:
206
- - - "<"
207
+ - - "~>"
207
208
  - !ruby/object:Gem::Version
208
- version: '1.24'
209
+ version: '0.2'
209
210
  type: :runtime
210
211
  prerelease: false
211
212
  version_requirements: !ruby/object:Gem::Requirement
212
213
  requirements:
213
- - - "<"
214
+ - - "~>"
215
+ - !ruby/object:Gem::Version
216
+ version: '0.2'
217
+ - !ruby/object:Gem::Dependency
218
+ name: csv
219
+ requirement: !ruby/object:Gem::Requirement
220
+ requirements:
221
+ - - "~>"
222
+ - !ruby/object:Gem::Version
223
+ version: '3.2'
224
+ type: :runtime
225
+ prerelease: false
226
+ version_requirements: !ruby/object:Gem::Requirement
227
+ requirements:
228
+ - - "~>"
214
229
  - !ruby/object:Gem::Version
215
- version: '1.24'
230
+ version: '3.2'
216
231
  - !ruby/object:Gem::Dependency
217
- name: logger
232
+ name: drb
218
233
  requirement: !ruby/object:Gem::Requirement
219
234
  requirements:
220
235
  - - "~>"
221
236
  - !ruby/object:Gem::Version
222
- version: '1.6'
237
+ version: '2.2'
223
238
  type: :runtime
224
239
  prerelease: false
225
240
  version_requirements: !ruby/object:Gem::Requirement
226
241
  requirements:
227
242
  - - "~>"
228
243
  - !ruby/object:Gem::Version
229
- version: '1.6'
244
+ version: '2.2'
230
245
  - !ruby/object:Gem::Dependency
231
246
  name: rake
232
247
  requirement: !ruby/object:Gem::Requirement
@@ -301,16 +316,16 @@ dependencies:
301
316
  name: timecop
302
317
  requirement: !ruby/object:Gem::Requirement
303
318
  requirements:
304
- - - "<"
319
+ - - "~>"
305
320
  - !ruby/object:Gem::Version
306
- version: 0.9.9
321
+ version: '0.9'
307
322
  type: :development
308
323
  prerelease: false
309
324
  version_requirements: !ruby/object:Gem::Requirement
310
325
  requirements:
311
- - - "<"
326
+ - - "~>"
312
327
  - !ruby/object:Gem::Version
313
- version: 0.9.9
328
+ version: '0.9'
314
329
  - !ruby/object:Gem::Dependency
315
330
  name: test-unit
316
331
  requirement: !ruby/object:Gem::Requirement
@@ -387,6 +402,48 @@ dependencies:
387
402
  - - ">="
388
403
  - !ruby/object:Gem::Version
389
404
  version: 0.50.0
405
+ - !ruby/object:Gem::Dependency
406
+ name: aws-sigv4
407
+ requirement: !ruby/object:Gem::Requirement
408
+ requirements:
409
+ - - "~>"
410
+ - !ruby/object:Gem::Version
411
+ version: '1.8'
412
+ type: :development
413
+ prerelease: false
414
+ version_requirements: !ruby/object:Gem::Requirement
415
+ requirements:
416
+ - - "~>"
417
+ - !ruby/object:Gem::Version
418
+ version: '1.8'
419
+ - !ruby/object:Gem::Dependency
420
+ name: aws-sdk-core
421
+ requirement: !ruby/object:Gem::Requirement
422
+ requirements:
423
+ - - "~>"
424
+ - !ruby/object:Gem::Version
425
+ version: '3.191'
426
+ type: :development
427
+ prerelease: false
428
+ version_requirements: !ruby/object:Gem::Requirement
429
+ requirements:
430
+ - - "~>"
431
+ - !ruby/object:Gem::Version
432
+ version: '3.191'
433
+ - !ruby/object:Gem::Dependency
434
+ name: rexml
435
+ requirement: !ruby/object:Gem::Requirement
436
+ requirements:
437
+ - - "~>"
438
+ - !ruby/object:Gem::Version
439
+ version: '3.2'
440
+ type: :development
441
+ prerelease: false
442
+ version_requirements: !ruby/object:Gem::Requirement
443
+ requirements:
444
+ - - "~>"
445
+ - !ruby/object:Gem::Version
446
+ version: '3.2'
390
447
  description: Fluentd is an open source data collector designed to scale and simplify
391
448
  log management. It can collect, process and ship many kinds of data in near real-time.
392
449
  email:
@@ -406,12 +463,15 @@ extensions: []
406
463
  extra_rdoc_files: []
407
464
  files:
408
465
  - ".deepsource.toml"
466
+ - ".github/DISCUSSION_TEMPLATE/q-a-japanese.yml"
467
+ - ".github/DISCUSSION_TEMPLATE/q-a.yml"
409
468
  - ".github/ISSUE_TEMPLATE.md"
410
469
  - ".github/ISSUE_TEMPLATE/bug_report.yml"
411
470
  - ".github/ISSUE_TEMPLATE/config.yml"
412
471
  - ".github/ISSUE_TEMPLATE/feature_request.yml"
413
472
  - ".github/PULL_REQUEST_TEMPLATE.md"
414
473
  - ".github/workflows/stale-actions.yml"
474
+ - ".github/workflows/test-ruby-head.yml"
415
475
  - ".github/workflows/test.yml"
416
476
  - ".gitignore"
417
477
  - ADOPTERS.md
@@ -783,6 +843,10 @@ files:
783
843
  - test/plugin/data/log/foo/bar.log
784
844
  - test/plugin/data/log/foo/bar2
785
845
  - test/plugin/data/log/test.log
846
+ - test/plugin/data/log_numeric/01.log
847
+ - test/plugin/data/log_numeric/02.log
848
+ - test/plugin/data/log_numeric/12.log
849
+ - test/plugin/data/log_numeric/14.log
786
850
  - test/plugin/data/sd_file/config
787
851
  - test/plugin/data/sd_file/config.json
788
852
  - test/plugin/data/sd_file/config.yaml
@@ -867,6 +931,7 @@ files:
867
931
  - test/plugin/test_parser_csv.rb
868
932
  - test/plugin/test_parser_json.rb
869
933
  - test/plugin/test_parser_labeled_tsv.rb
934
+ - test/plugin/test_parser_msgpack.rb
870
935
  - test/plugin/test_parser_multiline.rb
871
936
  - test/plugin/test_parser_nginx.rb
872
937
  - test/plugin/test_parser_none.rb
@@ -930,7 +995,6 @@ files:
930
995
  - test/scripts/fluent/plugin/out_test.rb
931
996
  - test/scripts/fluent/plugin/out_test2.rb
932
997
  - test/scripts/fluent/plugin/parser_known.rb
933
- - test/scripts/windows_service_test.ps1
934
998
  - test/test_capability.rb
935
999
  - test/test_clock.rb
936
1000
  - test/test_config.rb
@@ -969,6 +1033,7 @@ homepage: https://www.fluentd.org/
969
1033
  licenses:
970
1034
  - Apache-2.0
971
1035
  metadata: {}
1036
+ post_install_message:
972
1037
  rdoc_options: []
973
1038
  require_paths:
974
1039
  - lib
@@ -976,14 +1041,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
976
1041
  requirements:
977
1042
  - - ">="
978
1043
  - !ruby/object:Gem::Version
979
- version: '2.4'
1044
+ version: '2.7'
980
1045
  required_rubygems_version: !ruby/object:Gem::Requirement
981
1046
  requirements:
982
1047
  - - ">="
983
1048
  - !ruby/object:Gem::Version
984
1049
  version: '0'
985
1050
  requirements: []
986
- rubygems_version: 3.6.8
1051
+ rubygems_version: 3.4.13
1052
+ signing_key:
987
1053
  specification_version: 4
988
1054
  summary: Fluentd event collector
989
1055
  test_files:
@@ -1025,6 +1091,10 @@ test_files:
1025
1091
  - test/plugin/data/log/foo/bar.log
1026
1092
  - test/plugin/data/log/foo/bar2
1027
1093
  - test/plugin/data/log/test.log
1094
+ - test/plugin/data/log_numeric/01.log
1095
+ - test/plugin/data/log_numeric/02.log
1096
+ - test/plugin/data/log_numeric/12.log
1097
+ - test/plugin/data/log_numeric/14.log
1028
1098
  - test/plugin/data/sd_file/config
1029
1099
  - test/plugin/data/sd_file/config.json
1030
1100
  - test/plugin/data/sd_file/config.yaml
@@ -1109,6 +1179,7 @@ test_files:
1109
1179
  - test/plugin/test_parser_csv.rb
1110
1180
  - test/plugin/test_parser_json.rb
1111
1181
  - test/plugin/test_parser_labeled_tsv.rb
1182
+ - test/plugin/test_parser_msgpack.rb
1112
1183
  - test/plugin/test_parser_multiline.rb
1113
1184
  - test/plugin/test_parser_nginx.rb
1114
1185
  - test/plugin/test_parser_none.rb
@@ -1172,7 +1243,6 @@ test_files:
1172
1243
  - test/scripts/fluent/plugin/out_test.rb
1173
1244
  - test/scripts/fluent/plugin/out_test2.rb
1174
1245
  - test/scripts/fluent/plugin/parser_known.rb
1175
- - test/scripts/windows_service_test.ps1
1176
1246
  - test/test_capability.rb
1177
1247
  - test/test_clock.rb
1178
1248
  - test/test_config.rb
@@ -1,73 +0,0 @@
1
- $ErrorActionPreference = "Stop"
2
- Set-PSDebug -Trace 1
3
-
4
- $default_conf_path = (Resolve-Path fluent.conf).Path
5
- $current_path = (Get-Location).Path
6
- $log_path = "$current_path/fluentd.log"
7
-
8
- ruby bin/fluentd --reg-winsvc i --reg-winsvc-fluentdopt "-c '$default_conf_path' -o '$log_path'"
9
-
10
- # Test: must not start automatically
11
- if ((Get-Service fluentdwinsvc).Status -ne "Stopped") {
12
- Write-Error "The service should not start automatically."
13
- }
14
-
15
- Start-Service fluentdwinsvc
16
- Start-Sleep 30
17
-
18
- # Test: the service should be running after started
19
- if ((Get-Service fluentdwinsvc).Status -ne "Running") {
20
- Write-Error "The service should be running after started."
21
- }
22
-
23
- # Test: no warn/error/fatal logs
24
- Get-ChildItem "*.log" | %{
25
- Get-Content $_
26
- if (Select-String -Path $_ -Pattern "[warn]", "[error]", "[fatal]" -SimpleMatch -Quiet) {
27
- Select-String -Path $_ -Pattern "[warn]", "[error]", "[fatal]" -SimpleMatch
28
- Write-Error "There are abnormal level logs in ${_}:"
29
- }
30
- }
31
-
32
- Stop-Service fluentdwinsvc
33
- Start-Sleep 10 # Somehow it is possible that some processes stay alive for a while. (This could be not good behavior...)
34
-
35
- # Test: status after stopped
36
- if ((Get-Service fluentdwinsvc).Status -ne "Stopped") {
37
- Write-Error "The service should be in 'Stopped' status after stopped."
38
- }
39
- # Test: all Ruby processes should stop
40
- $ruby_processes = Get-Process -name ruby -ErrorAction SilentlyContinue
41
- if ($ruby_processes.Count -ne 0) {
42
- Write-Output $ruby_processes
43
- Write-Error "All Ruby processes should stop."
44
- }
45
-
46
- # Test: service should stop when the supervisor fails to launch
47
- # https://github.com/fluent/fluentd/pull/4909
48
- $test_setting = @'
49
- <source>
50
- @type sample
51
- @id DUPLICATED_ID
52
- tag test
53
- </source>
54
- <match test>
55
- @type stdout
56
- @id DUPLICATED_ID
57
- </match>
58
- '@
59
- Add-Content -Path "duplicated_id.conf" -Encoding UTF8 -Value $test_setting
60
- ruby bin/fluentd --reg-winsvc-fluentdopt "-c '$current_path/duplicated_id.conf' -o '$log_path'"
61
- Start-Service fluentdwinsvc
62
- Start-Sleep 30
63
- if ((Get-Service fluentdwinsvc).Status -ne "Stopped") {
64
- Write-Error "The service should be in 'Stopped' status when the supervisor fails to launch."
65
- }
66
- $ruby_processes = Get-Process -name ruby -ErrorAction SilentlyContinue
67
- if ($ruby_processes.Count -ne 0) {
68
- Write-Output $ruby_processes
69
- Write-Error "All Ruby processes should stop."
70
- }
71
-
72
- ruby bin/fluentd --reg-winsvc u
73
- Remove-Item $log_path