fluentd 1.11.4-x86-mingw32 → 1.12.3-x86-mingw32
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of fluentd might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/.deepsource.toml +13 -0
- data/.github/ISSUE_TEMPLATE/bug_report.md +1 -1
- data/.github/ISSUE_TEMPLATE/config.yml +5 -0
- data/.github/workflows/linux-test.yaml +36 -0
- data/.github/workflows/macos-test.yaml +30 -0
- data/.github/workflows/stale-actions.yml +22 -0
- data/.github/workflows/windows-test.yaml +35 -0
- data/.gitlab-ci.yml +41 -19
- data/CHANGELOG.md +166 -0
- data/MAINTAINERS.md +5 -2
- data/README.md +7 -4
- data/bin/fluent-cap-ctl +7 -0
- data/bin/fluent-ctl +7 -0
- data/fluentd.gemspec +7 -5
- data/lib/fluent/capability.rb +87 -0
- data/lib/fluent/command/bundler_injection.rb +1 -1
- data/lib/fluent/command/ca_generate.rb +6 -3
- data/lib/fluent/command/cap_ctl.rb +174 -0
- data/lib/fluent/command/cat.rb +0 -1
- data/lib/fluent/command/ctl.rb +177 -0
- data/lib/fluent/command/fluentd.rb +4 -0
- data/lib/fluent/command/plugin_config_formatter.rb +18 -2
- data/lib/fluent/command/plugin_generator.rb +31 -1
- data/lib/fluent/compat/parser.rb +2 -2
- data/lib/fluent/config/section.rb +2 -2
- data/lib/fluent/config/types.rb +2 -2
- data/lib/fluent/env.rb +4 -0
- data/lib/fluent/event.rb +3 -13
- data/lib/fluent/load.rb +0 -1
- data/lib/fluent/plugin.rb +5 -0
- data/lib/fluent/plugin/buffer.rb +2 -21
- data/lib/fluent/plugin/file_wrapper.rb +39 -3
- data/lib/fluent/plugin/formatter.rb +24 -0
- data/lib/fluent/plugin/formatter_csv.rb +1 -1
- data/lib/fluent/plugin/formatter_hash.rb +3 -1
- data/lib/fluent/plugin/formatter_json.rb +3 -1
- data/lib/fluent/plugin/formatter_ltsv.rb +7 -5
- data/lib/fluent/plugin/formatter_out_file.rb +6 -4
- data/lib/fluent/plugin/formatter_single_value.rb +4 -2
- data/lib/fluent/plugin/formatter_tsv.rb +4 -2
- data/lib/fluent/plugin/in_http.rb +24 -3
- data/lib/fluent/plugin/in_monitor_agent.rb +1 -1
- data/lib/fluent/plugin/in_tail.rb +129 -41
- data/lib/fluent/plugin/in_tail/position_file.rb +39 -14
- data/lib/fluent/plugin/in_tcp.rb +1 -0
- data/lib/fluent/plugin/out_copy.rb +18 -5
- data/lib/fluent/plugin/out_exec_filter.rb +3 -3
- data/lib/fluent/plugin/out_forward.rb +61 -28
- data/lib/fluent/plugin/out_http.rb +28 -3
- data/lib/fluent/plugin/output.rb +18 -10
- data/lib/fluent/plugin/parser_csv.rb +2 -2
- data/lib/fluent/plugin/parser_syslog.rb +2 -2
- data/lib/fluent/plugin/storage_local.rb +4 -4
- data/lib/fluent/plugin_helper/http_server/compat/server.rb +1 -1
- data/lib/fluent/plugin_helper/inject.rb +4 -2
- data/lib/fluent/plugin_helper/retry_state.rb +4 -0
- data/lib/fluent/plugin_helper/server.rb +4 -2
- data/lib/fluent/plugin_helper/socket_option.rb +2 -2
- data/lib/fluent/supervisor.rb +153 -48
- data/lib/fluent/system_config.rb +2 -1
- data/lib/fluent/time.rb +58 -1
- data/lib/fluent/version.rb +1 -1
- data/lib/fluent/winsvc.rb +22 -4
- data/templates/new_gem/fluent-plugin.gemspec.erb +3 -3
- data/templates/plugin_config_formatter/param.md-table.erb +10 -0
- data/test/command/test_binlog_reader.rb +22 -6
- data/test/command/test_cap_ctl.rb +100 -0
- data/test/command/test_ctl.rb +57 -0
- data/test/command/test_fluentd.rb +38 -0
- data/test/command/test_plugin_config_formatter.rb +124 -2
- data/test/config/test_configurable.rb +1 -1
- data/test/plugin/in_tail/test_position_file.rb +46 -26
- data/test/plugin/test_file_wrapper.rb +105 -0
- data/test/plugin/test_filter_stdout.rb +6 -1
- data/test/plugin/test_formatter_hash.rb +6 -3
- data/test/plugin/test_formatter_json.rb +14 -4
- data/test/plugin/test_formatter_ltsv.rb +13 -5
- data/test/plugin/test_formatter_out_file.rb +35 -14
- data/test/plugin/test_formatter_single_value.rb +12 -6
- data/test/plugin/test_formatter_tsv.rb +12 -4
- data/test/plugin/test_in_exec.rb +1 -1
- data/test/plugin/test_in_http.rb +25 -0
- data/test/plugin/test_in_tail.rb +503 -42
- data/test/plugin/test_out_copy.rb +87 -0
- data/test/plugin/test_out_file.rb +23 -18
- data/test/plugin/test_out_forward.rb +94 -6
- data/test/plugin/test_out_http.rb +20 -1
- data/test/plugin/test_output.rb +15 -3
- data/test/plugin/test_output_as_buffered_backup.rb +2 -0
- data/test/plugin/test_parser_csv.rb +14 -0
- data/test/plugin/test_parser_syslog.rb +16 -2
- data/test/plugin/test_sd_file.rb +1 -1
- data/test/plugin_helper/service_discovery/test_manager.rb +1 -1
- data/test/plugin_helper/test_child_process.rb +5 -2
- data/test/plugin_helper/test_compat_parameters.rb +7 -2
- data/test/plugin_helper/test_http_server_helper.rb +4 -2
- data/test/plugin_helper/test_inject.rb +29 -0
- data/test/plugin_helper/test_server.rb +26 -7
- data/test/test_capability.rb +74 -0
- data/test/test_event.rb +16 -0
- data/test/test_formatter.rb +64 -10
- data/test/test_output.rb +8 -3
- data/test/test_supervisor.rb +150 -1
- data/test/test_time_parser.rb +109 -0
- metadata +87 -33
- data/.travis.yml +0 -57
- data/appveyor.yml +0 -28
data/test/test_output.rb
CHANGED
@@ -117,7 +117,7 @@ module FluentOutputTest
|
|
117
117
|
end
|
118
118
|
|
119
119
|
mock(d.instance.log).warn("Use different plugin for secondary. Check the plugin works with primary like secondary_file",
|
120
|
-
|
120
|
+
primary: d.instance.class.to_s, secondary: "Fluent::Plugin::Test2Output")
|
121
121
|
d.configure(CONFIG + %[
|
122
122
|
<secondary>
|
123
123
|
type test2
|
@@ -133,7 +133,7 @@ module FluentOutputTest
|
|
133
133
|
d = Fluent::Test::BufferedOutputTestDriver.new(Fluent::ObjectBufferedOutput)
|
134
134
|
|
135
135
|
mock(d.instance.log).warn("Use different plugin for secondary. Check the plugin works with primary like secondary_file",
|
136
|
-
|
136
|
+
primary: d.instance.class.to_s, secondary: "Fluent::Plugin::Test2Output").never
|
137
137
|
d.configure(CONFIG + %[
|
138
138
|
<secondary>
|
139
139
|
type test2
|
@@ -230,6 +230,11 @@ module FluentOutputTest
|
|
230
230
|
setup do
|
231
231
|
@time = Time.parse("2011-01-02 13:14:15 UTC")
|
232
232
|
Timecop.freeze(@time)
|
233
|
+
@newline = if Fluent.windows?
|
234
|
+
"\r\n"
|
235
|
+
else
|
236
|
+
"\n"
|
237
|
+
end
|
233
238
|
end
|
234
239
|
|
235
240
|
teardown do
|
@@ -265,7 +270,7 @@ module FluentOutputTest
|
|
265
270
|
])
|
266
271
|
time = Time.parse("2016-11-08 12:00:00 UTC").to_i
|
267
272
|
d.emit({"a" => 1}, time)
|
268
|
-
d.expect_format %[2016-11-08T12:00:00Z\ttest\t{"a":1,"time":"2016-11-08T12:00:00Z"}
|
273
|
+
d.expect_format %[2016-11-08T12:00:00Z\ttest\t{"a":1,"time":"2016-11-08T12:00:00Z"}#{@newline}]
|
269
274
|
d.run
|
270
275
|
end
|
271
276
|
end
|
data/test/test_supervisor.rb
CHANGED
@@ -8,6 +8,10 @@ require 'net/http'
|
|
8
8
|
require 'uri'
|
9
9
|
require 'fileutils'
|
10
10
|
|
11
|
+
if Fluent.windows?
|
12
|
+
require 'win32/event'
|
13
|
+
end
|
14
|
+
|
11
15
|
class SupervisorTest < ::Test::Unit::TestCase
|
12
16
|
class DummyServer
|
13
17
|
include Fluent::ServerModule
|
@@ -107,6 +111,32 @@ class SupervisorTest < ::Test::Unit::TestCase
|
|
107
111
|
$log.out.reset if $log && $log.out && $log.out.respond_to?(:reset)
|
108
112
|
end
|
109
113
|
|
114
|
+
def test_main_process_command_handlers
|
115
|
+
omit "Only for Windows, alternative to UNIX signals" unless Fluent.windows?
|
116
|
+
|
117
|
+
create_info_dummy_logger
|
118
|
+
|
119
|
+
opts = Fluent::Supervisor.default_options
|
120
|
+
sv = Fluent::Supervisor.new(opts)
|
121
|
+
r, w = IO.pipe
|
122
|
+
$stdin = r
|
123
|
+
sv.send(:install_main_process_signal_handlers)
|
124
|
+
|
125
|
+
begin
|
126
|
+
w.write("GRACEFUL_RESTART\n")
|
127
|
+
w.flush
|
128
|
+
ensure
|
129
|
+
$stdin = STDIN
|
130
|
+
end
|
131
|
+
|
132
|
+
sleep 1
|
133
|
+
|
134
|
+
info_msg = '[info]: force flushing buffered events' + "\n"
|
135
|
+
assert{ $log.out.logs.first.end_with?(info_msg) }
|
136
|
+
ensure
|
137
|
+
$log.out.reset if $log && $log.out && $log.out.respond_to?(:reset)
|
138
|
+
end
|
139
|
+
|
110
140
|
def test_supervisor_signal_handler
|
111
141
|
omit "Windows cannot handle signals" if Fluent.windows?
|
112
142
|
|
@@ -128,6 +158,60 @@ class SupervisorTest < ::Test::Unit::TestCase
|
|
128
158
|
$log.out.reset if $log && $log.out && $log.out.respond_to?(:reset)
|
129
159
|
end
|
130
160
|
|
161
|
+
def test_windows_shutdown_event
|
162
|
+
omit "Only for Windows platform" unless Fluent.windows?
|
163
|
+
|
164
|
+
server = DummyServer.new
|
165
|
+
def server.config
|
166
|
+
{:signame => "TestFluentdEvent"}
|
167
|
+
end
|
168
|
+
|
169
|
+
mock(server).stop(true)
|
170
|
+
stub(Process).kill.times(0)
|
171
|
+
|
172
|
+
server.install_windows_event_handler
|
173
|
+
begin
|
174
|
+
sleep 0.1 # Wait for starting windows event thread
|
175
|
+
event = Win32::Event.open("TestFluentdEvent")
|
176
|
+
event.set
|
177
|
+
event.close
|
178
|
+
ensure
|
179
|
+
server.stop_windows_event_thread
|
180
|
+
end
|
181
|
+
|
182
|
+
debug_msg = '[debug]: Got Win32 event "TestFluentdEvent"'
|
183
|
+
logs = $log.out.logs
|
184
|
+
assert{ logs.any?{|log| log.include?(debug_msg) } }
|
185
|
+
ensure
|
186
|
+
$log.out.reset if $log && $log.out && $log.out.respond_to?(:reset)
|
187
|
+
end
|
188
|
+
|
189
|
+
def test_supervisor_event_handler
|
190
|
+
omit "Only for Windows, alternative to UNIX signals" unless Fluent.windows?
|
191
|
+
|
192
|
+
create_debug_dummy_logger
|
193
|
+
|
194
|
+
server = DummyServer.new
|
195
|
+
def server.config
|
196
|
+
{:signame => "TestFluentdEvent"}
|
197
|
+
end
|
198
|
+
server.install_windows_event_handler
|
199
|
+
begin
|
200
|
+
sleep 0.1 # Wait for starting windows event thread
|
201
|
+
event = Win32::Event.open("TestFluentdEvent_USR1")
|
202
|
+
event.set
|
203
|
+
event.close
|
204
|
+
ensure
|
205
|
+
server.stop_windows_event_thread
|
206
|
+
end
|
207
|
+
|
208
|
+
debug_msg = '[debug]: Got Win32 event "TestFluentdEvent_USR1"'
|
209
|
+
logs = $log.out.logs
|
210
|
+
assert{ logs.any?{|log| log.include?(debug_msg) } }
|
211
|
+
ensure
|
212
|
+
$log.out.reset if $log && $log.out && $log.out.respond_to?(:reset)
|
213
|
+
end
|
214
|
+
|
131
215
|
def test_rpc_server
|
132
216
|
omit "Windows cannot handle signals" if Fluent.windows?
|
133
217
|
|
@@ -150,7 +234,7 @@ class SupervisorTest < ::Test::Unit::TestCase
|
|
150
234
|
server.run_rpc_server
|
151
235
|
|
152
236
|
sv.send(:install_main_process_signal_handlers)
|
153
|
-
Net::HTTP.get
|
237
|
+
response = Net::HTTP.get(URI.parse('http://127.0.0.1:24447/api/plugins.flushBuffers'))
|
154
238
|
info_msg = '[info]: force flushing buffered events' + "\n"
|
155
239
|
|
156
240
|
server.stop_rpc_server
|
@@ -159,11 +243,45 @@ class SupervisorTest < ::Test::Unit::TestCase
|
|
159
243
|
# This test will be passed in such environment.
|
160
244
|
pend unless $log.out.logs.first
|
161
245
|
|
246
|
+
assert_equal('{"ok":true}', response)
|
162
247
|
assert{ $log.out.logs.first.end_with?(info_msg) }
|
163
248
|
ensure
|
164
249
|
$log.out.reset if $log.out.is_a?(Fluent::Test::DummyLogDevice)
|
165
250
|
end
|
166
251
|
|
252
|
+
def test_rpc_server_windows
|
253
|
+
omit "Only for windows platform" unless Fluent.windows?
|
254
|
+
|
255
|
+
create_info_dummy_logger
|
256
|
+
|
257
|
+
opts = Fluent::Supervisor.default_options
|
258
|
+
sv = Fluent::Supervisor.new(opts)
|
259
|
+
conf_data = <<-EOC
|
260
|
+
<system>
|
261
|
+
rpc_endpoint 0.0.0.0:24447
|
262
|
+
</system>
|
263
|
+
EOC
|
264
|
+
conf = Fluent::Config.parse(conf_data, "(test)", "(test_dir)", true)
|
265
|
+
sys_conf = sv.__send__(:build_system_config, conf)
|
266
|
+
|
267
|
+
server = DummyServer.new
|
268
|
+
def server.config
|
269
|
+
{
|
270
|
+
:signame => "TestFluentdEvent",
|
271
|
+
:worker_pid => 5963,
|
272
|
+
}
|
273
|
+
end
|
274
|
+
server.rpc_endpoint = sys_conf.rpc_endpoint
|
275
|
+
|
276
|
+
server.run_rpc_server
|
277
|
+
|
278
|
+
mock(server).restart(true) { nil }
|
279
|
+
response = Net::HTTP.get(URI.parse('http://127.0.0.1:24447/api/plugins.flushBuffers'))
|
280
|
+
|
281
|
+
server.stop_rpc_server
|
282
|
+
assert_equal('{"ok":true}', response)
|
283
|
+
end
|
284
|
+
|
167
285
|
def test_load_config
|
168
286
|
tmp_dir = "#{TMP_DIR}/dir/test_load_config.conf"
|
169
287
|
conf_info_str = %[
|
@@ -399,6 +517,37 @@ class SupervisorTest < ::Test::Unit::TestCase
|
|
399
517
|
assert_equal Fluent::Log::LEVEL_ERROR, $log.level
|
400
518
|
end
|
401
519
|
|
520
|
+
def test_enable_shared_socket
|
521
|
+
server = DummyServer.new
|
522
|
+
begin
|
523
|
+
ENV.delete('SERVERENGINE_SOCKETMANAGER_PATH')
|
524
|
+
server.before_run
|
525
|
+
sleep 0.1 if Fluent.windows? # Wait for starting windows event thread
|
526
|
+
assert_not_nil(ENV['SERVERENGINE_SOCKETMANAGER_PATH'])
|
527
|
+
ensure
|
528
|
+
server.after_run
|
529
|
+
ENV.delete('SERVERENGINE_SOCKETMANAGER_PATH')
|
530
|
+
end
|
531
|
+
end
|
532
|
+
|
533
|
+
def test_disable_shared_socket
|
534
|
+
server = DummyServer.new
|
535
|
+
def server.config
|
536
|
+
{
|
537
|
+
:disable_shared_socket => true,
|
538
|
+
}
|
539
|
+
end
|
540
|
+
begin
|
541
|
+
ENV.delete('SERVERENGINE_SOCKETMANAGER_PATH')
|
542
|
+
server.before_run
|
543
|
+
sleep 0.1 if Fluent.windows? # Wait for starting windows event thread
|
544
|
+
assert_nil(ENV['SERVERENGINE_SOCKETMANAGER_PATH'])
|
545
|
+
ensure
|
546
|
+
server.after_run
|
547
|
+
ENV.delete('SERVERENGINE_SOCKETMANAGER_PATH')
|
548
|
+
end
|
549
|
+
end
|
550
|
+
|
402
551
|
def create_debug_dummy_logger
|
403
552
|
dl_opts = {}
|
404
553
|
dl_opts[:log_level] = ServerEngine::DaemonLogger::DEBUG
|
data/test/test_time_parser.rb
CHANGED
@@ -228,4 +228,113 @@ class TimeParserTest < ::Test::Unit::TestCase
|
|
228
228
|
assert_equal_event_time(time, parser.parse("#{time.sec}.#{time.nsec}"))
|
229
229
|
end
|
230
230
|
end
|
231
|
+
|
232
|
+
sub_test_case 'MixedTimeParser fallback' do
|
233
|
+
class DummyForTimeParser
|
234
|
+
include Fluent::Configurable
|
235
|
+
include Fluent::TimeMixin::Parser
|
236
|
+
end
|
237
|
+
|
238
|
+
test 'no time_format_fallbacks failure' do
|
239
|
+
i = DummyForTimeParser.new
|
240
|
+
assert_raise(Fluent::ConfigError.new("time_type is :mixed but time_format and time_format_fallbacks is empty.")) do
|
241
|
+
i.configure(config_element('parse', '', {'time_type' => 'mixed'}))
|
242
|
+
end
|
243
|
+
end
|
244
|
+
|
245
|
+
test 'fallback time format failure' do
|
246
|
+
i = DummyForTimeParser.new
|
247
|
+
i.configure(config_element('parse', '',
|
248
|
+
{'time_type' => 'mixed',
|
249
|
+
'time_format_fallbacks' => ['%iso8601']}))
|
250
|
+
parser = i.time_parser_create
|
251
|
+
assert_raise(Fluent::TimeParser::TimeParseError.new("invalid time format: value = INVALID, even though fallbacks: Fluent::TimeParser")) do
|
252
|
+
parser.parse("INVALID")
|
253
|
+
end
|
254
|
+
end
|
255
|
+
|
256
|
+
test 'primary format is unixtime, secondary %iso8601 is used' do
|
257
|
+
i = DummyForTimeParser.new
|
258
|
+
i.configure(config_element('parse', '',
|
259
|
+
{'time_type' => 'mixed',
|
260
|
+
'time_format' => 'unixtime',
|
261
|
+
'time_format_fallbacks' => ['%iso8601']}))
|
262
|
+
parser = i.time_parser_create
|
263
|
+
time = event_time('2021-01-01T12:00:00+0900')
|
264
|
+
assert_equal_event_time(time, parser.parse('2021-01-01T12:00:00+0900'))
|
265
|
+
end
|
266
|
+
|
267
|
+
test 'primary format is %iso8601, secondary unixtime is used' do
|
268
|
+
i = DummyForTimeParser.new
|
269
|
+
i.configure(config_element('parse', '',
|
270
|
+
{'time_type' => 'mixed',
|
271
|
+
'time_format' => '%iso8601',
|
272
|
+
'time_format_fallbacks' => ['unixtime']}))
|
273
|
+
parser = i.time_parser_create
|
274
|
+
time = event_time('2021-01-01T12:00:00+0900')
|
275
|
+
assert_equal_event_time(time, parser.parse("#{time.sec}"))
|
276
|
+
end
|
277
|
+
|
278
|
+
test 'primary format is %iso8601, no secondary is used' do
|
279
|
+
i = DummyForTimeParser.new
|
280
|
+
i.configure(config_element('parse', '',
|
281
|
+
{'time_type' => 'mixed',
|
282
|
+
'time_format' => '%iso8601'}))
|
283
|
+
parser = i.time_parser_create
|
284
|
+
time = event_time('2021-01-01T12:00:00+0900')
|
285
|
+
assert_equal_event_time(time, parser.parse("2021-01-01T12:00:00+0900"))
|
286
|
+
end
|
287
|
+
|
288
|
+
test 'primary format is unixtime, no secondary is used' do
|
289
|
+
i = DummyForTimeParser.new
|
290
|
+
i.configure(config_element('parse', '',
|
291
|
+
{'time_type' => 'mixed',
|
292
|
+
'time_format' => 'unixtime'}))
|
293
|
+
parser = i.time_parser_create
|
294
|
+
time = event_time('2021-01-01T12:00:00+0900')
|
295
|
+
assert_equal_event_time(time, parser.parse("#{time.sec}"))
|
296
|
+
end
|
297
|
+
|
298
|
+
test 'primary format is %iso8601, raise error because of no appropriate secondary' do
|
299
|
+
i = DummyForTimeParser.new
|
300
|
+
i.configure(config_element('parse', '',
|
301
|
+
{'time_type' => 'mixed',
|
302
|
+
'time_format' => '%iso8601'}))
|
303
|
+
parser = i.time_parser_create
|
304
|
+
time = event_time('2021-01-01T12:00:00+0900')
|
305
|
+
assert_raise("Fluent::TimeParser::TimeParseError: invalid time format: value = #{time.sec}, even though fallbacks: Fluent::TimeParser") do
|
306
|
+
parser.parse("#{time.sec}")
|
307
|
+
end
|
308
|
+
end
|
309
|
+
|
310
|
+
test 'primary format is unixtime, raise error because of no appropriate secondary' do
|
311
|
+
i = DummyForTimeParser.new
|
312
|
+
i.configure(config_element('parse', '',
|
313
|
+
{'time_type' => 'mixed',
|
314
|
+
'time_format' => 'unixtime'}))
|
315
|
+
parser = i.time_parser_create
|
316
|
+
time = event_time('2021-01-01T12:00:00+0900')
|
317
|
+
assert_raise("Fluent::TimeParser::TimeParseError: invalid time format: value = #{time}, even though fallbacks: Fluent::NumericTimeParser") do
|
318
|
+
parser.parse("2021-01-01T12:00:00+0900")
|
319
|
+
end
|
320
|
+
end
|
321
|
+
|
322
|
+
test 'fallback to unixtime' do
|
323
|
+
i = DummyForTimeParser.new
|
324
|
+
i.configure(config_element('parse', '', {'time_type' => 'mixed',
|
325
|
+
'time_format_fallbacks' => ['%iso8601', 'unixtime']}))
|
326
|
+
parser = i.time_parser_create
|
327
|
+
time = event_time('2021-01-01T12:00:00+0900')
|
328
|
+
assert_equal_event_time(Fluent::EventTime.new(time.to_i), parser.parse("#{time.sec}"))
|
329
|
+
end
|
330
|
+
|
331
|
+
test 'fallback to %iso8601' do
|
332
|
+
i = DummyForTimeParser.new
|
333
|
+
i.configure(config_element('parse', '', {'time_type' => 'mixed',
|
334
|
+
'time_format_fallbacks' => ['unixtime', '%iso8601']}))
|
335
|
+
parser = i.time_parser_create
|
336
|
+
time = event_time('2021-01-01T12:00:00+0900')
|
337
|
+
assert_equal_event_time(time, parser.parse('2021-01-01T12:00:00+0900'))
|
338
|
+
end
|
339
|
+
end
|
231
340
|
end
|
metadata
CHANGED
@@ -1,15 +1,29 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fluentd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.12.3
|
5
5
|
platform: x86-mingw32
|
6
6
|
authors:
|
7
7
|
- Sadayuki Furuhashi
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-04-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0'
|
13
27
|
- !ruby/object:Gem::Dependency
|
14
28
|
name: msgpack
|
15
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -70,7 +84,7 @@ dependencies:
|
|
70
84
|
requirements:
|
71
85
|
- - ">="
|
72
86
|
- !ruby/object:Gem::Version
|
73
|
-
version: 2.
|
87
|
+
version: 2.2.2
|
74
88
|
- - "<"
|
75
89
|
- !ruby/object:Gem::Version
|
76
90
|
version: 3.0.0
|
@@ -80,7 +94,7 @@ dependencies:
|
|
80
94
|
requirements:
|
81
95
|
- - ">="
|
82
96
|
- !ruby/object:Gem::Version
|
83
|
-
version: 2.
|
97
|
+
version: 2.2.2
|
84
98
|
- - "<"
|
85
99
|
- !ruby/object:Gem::Version
|
86
100
|
version: 3.0.0
|
@@ -172,20 +186,60 @@ dependencies:
|
|
172
186
|
- - "<"
|
173
187
|
- !ruby/object:Gem::Version
|
174
188
|
version: 1.0.0
|
189
|
+
- !ruby/object:Gem::Dependency
|
190
|
+
name: webrick
|
191
|
+
requirement: !ruby/object:Gem::Requirement
|
192
|
+
requirements:
|
193
|
+
- - ">="
|
194
|
+
- !ruby/object:Gem::Version
|
195
|
+
version: 1.4.2
|
196
|
+
- - "<"
|
197
|
+
- !ruby/object:Gem::Version
|
198
|
+
version: 1.8.0
|
199
|
+
type: :runtime
|
200
|
+
prerelease: false
|
201
|
+
version_requirements: !ruby/object:Gem::Requirement
|
202
|
+
requirements:
|
203
|
+
- - ">="
|
204
|
+
- !ruby/object:Gem::Version
|
205
|
+
version: 1.4.2
|
206
|
+
- - "<"
|
207
|
+
- !ruby/object:Gem::Version
|
208
|
+
version: 1.8.0
|
209
|
+
- !ruby/object:Gem::Dependency
|
210
|
+
name: win32-api
|
211
|
+
requirement: !ruby/object:Gem::Requirement
|
212
|
+
requirements:
|
213
|
+
- - ">="
|
214
|
+
- !ruby/object:Gem::Version
|
215
|
+
version: '1.10'
|
216
|
+
- - "<"
|
217
|
+
- !ruby/object:Gem::Version
|
218
|
+
version: 2.0.0
|
219
|
+
type: :runtime
|
220
|
+
prerelease: false
|
221
|
+
version_requirements: !ruby/object:Gem::Requirement
|
222
|
+
requirements:
|
223
|
+
- - ">="
|
224
|
+
- !ruby/object:Gem::Version
|
225
|
+
version: '1.10'
|
226
|
+
- - "<"
|
227
|
+
- !ruby/object:Gem::Version
|
228
|
+
version: 2.0.0
|
175
229
|
- !ruby/object:Gem::Dependency
|
176
230
|
name: win32-service
|
177
231
|
requirement: !ruby/object:Gem::Requirement
|
178
232
|
requirements:
|
179
233
|
- - "~>"
|
180
234
|
- !ruby/object:Gem::Version
|
181
|
-
version: 2.
|
235
|
+
version: 2.2.0
|
182
236
|
type: :runtime
|
183
237
|
prerelease: false
|
184
238
|
version_requirements: !ruby/object:Gem::Requirement
|
185
239
|
requirements:
|
186
240
|
- - "~>"
|
187
241
|
- !ruby/object:Gem::Version
|
188
|
-
version: 2.
|
242
|
+
version: 2.2.0
|
189
243
|
- !ruby/object:Gem::Dependency
|
190
244
|
name: win32-ipc
|
191
245
|
requirement: !ruby/object:Gem::Requirement
|
@@ -304,14 +358,14 @@ dependencies:
|
|
304
358
|
requirements:
|
305
359
|
- - "~>"
|
306
360
|
- !ruby/object:Gem::Version
|
307
|
-
version: '
|
361
|
+
version: '3.0'
|
308
362
|
type: :development
|
309
363
|
prerelease: false
|
310
364
|
version_requirements: !ruby/object:Gem::Requirement
|
311
365
|
requirements:
|
312
366
|
- - "~>"
|
313
367
|
- !ruby/object:Gem::Version
|
314
|
-
version: '
|
368
|
+
version: '3.0'
|
315
369
|
- !ruby/object:Gem::Dependency
|
316
370
|
name: timecop
|
317
371
|
requirement: !ruby/object:Gem::Requirement
|
@@ -374,40 +428,20 @@ dependencies:
|
|
374
428
|
- - "<"
|
375
429
|
- !ruby/object:Gem::Version
|
376
430
|
version: '4'
|
377
|
-
- !ruby/object:Gem::Dependency
|
378
|
-
name: ext_monitor
|
379
|
-
requirement: !ruby/object:Gem::Requirement
|
380
|
-
requirements:
|
381
|
-
- - ">="
|
382
|
-
- !ruby/object:Gem::Version
|
383
|
-
version: 0.1.2
|
384
|
-
- - "<"
|
385
|
-
- !ruby/object:Gem::Version
|
386
|
-
version: '0.2'
|
387
|
-
type: :development
|
388
|
-
prerelease: false
|
389
|
-
version_requirements: !ruby/object:Gem::Requirement
|
390
|
-
requirements:
|
391
|
-
- - ">="
|
392
|
-
- !ruby/object:Gem::Version
|
393
|
-
version: 0.1.2
|
394
|
-
- - "<"
|
395
|
-
- !ruby/object:Gem::Version
|
396
|
-
version: '0.2'
|
397
431
|
- !ruby/object:Gem::Dependency
|
398
432
|
name: async-http
|
399
433
|
requirement: !ruby/object:Gem::Requirement
|
400
434
|
requirements:
|
401
435
|
- - ">="
|
402
436
|
- !ruby/object:Gem::Version
|
403
|
-
version:
|
437
|
+
version: 0.50.0
|
404
438
|
type: :development
|
405
439
|
prerelease: false
|
406
440
|
version_requirements: !ruby/object:Gem::Requirement
|
407
441
|
requirements:
|
408
442
|
- - ">="
|
409
443
|
- !ruby/object:Gem::Version
|
410
|
-
version:
|
444
|
+
version: 0.50.0
|
411
445
|
description: Fluentd is an open source data collector designed to scale and simplify
|
412
446
|
log management. It can collect, process and ship many kinds of data in near real-time.
|
413
447
|
email:
|
@@ -415,7 +449,9 @@ email:
|
|
415
449
|
executables:
|
416
450
|
- fluent-binlog-reader
|
417
451
|
- fluent-ca-generate
|
452
|
+
- fluent-cap-ctl
|
418
453
|
- fluent-cat
|
454
|
+
- fluent-ctl
|
419
455
|
- fluent-debug
|
420
456
|
- fluent-gem
|
421
457
|
- fluent-plugin-config-format
|
@@ -424,15 +460,20 @@ executables:
|
|
424
460
|
extensions: []
|
425
461
|
extra_rdoc_files: []
|
426
462
|
files:
|
463
|
+
- ".deepsource.toml"
|
427
464
|
- ".drone.yml"
|
428
465
|
- ".github/ISSUE_TEMPLATE.md"
|
429
466
|
- ".github/ISSUE_TEMPLATE/bug_report.md"
|
467
|
+
- ".github/ISSUE_TEMPLATE/config.yml"
|
430
468
|
- ".github/ISSUE_TEMPLATE/feature_request.md"
|
431
469
|
- ".github/PULL_REQUEST_TEMPLATE.md"
|
432
470
|
- ".github/workflows/issue-auto-closer.yml"
|
471
|
+
- ".github/workflows/linux-test.yaml"
|
472
|
+
- ".github/workflows/macos-test.yaml"
|
473
|
+
- ".github/workflows/stale-actions.yml"
|
474
|
+
- ".github/workflows/windows-test.yaml"
|
433
475
|
- ".gitignore"
|
434
476
|
- ".gitlab-ci.yml"
|
435
|
-
- ".travis.yml"
|
436
477
|
- ADOPTERS.md
|
437
478
|
- AUTHORS
|
438
479
|
- CHANGELOG.md
|
@@ -444,10 +485,11 @@ files:
|
|
444
485
|
- MAINTAINERS.md
|
445
486
|
- README.md
|
446
487
|
- Rakefile
|
447
|
-
- appveyor.yml
|
448
488
|
- bin/fluent-binlog-reader
|
449
489
|
- bin/fluent-ca-generate
|
490
|
+
- bin/fluent-cap-ctl
|
450
491
|
- bin/fluent-cat
|
492
|
+
- bin/fluent-ctl
|
451
493
|
- bin/fluent-debug
|
452
494
|
- bin/fluent-gem
|
453
495
|
- bin/fluent-plugin-config-format
|
@@ -495,11 +537,14 @@ files:
|
|
495
537
|
- fluent.conf
|
496
538
|
- fluentd.gemspec
|
497
539
|
- lib/fluent/agent.rb
|
540
|
+
- lib/fluent/capability.rb
|
498
541
|
- lib/fluent/clock.rb
|
499
542
|
- lib/fluent/command/binlog_reader.rb
|
500
543
|
- lib/fluent/command/bundler_injection.rb
|
501
544
|
- lib/fluent/command/ca_generate.rb
|
545
|
+
- lib/fluent/command/cap_ctl.rb
|
502
546
|
- lib/fluent/command/cat.rb
|
547
|
+
- lib/fluent/command/ctl.rb
|
503
548
|
- lib/fluent/command/debug.rb
|
504
549
|
- lib/fluent/command/fluentd.rb
|
505
550
|
- lib/fluent/command/plugin_config_formatter.rb
|
@@ -741,10 +786,13 @@ files:
|
|
741
786
|
- templates/new_gem/test/plugin/test_output.rb.erb
|
742
787
|
- templates/new_gem/test/plugin/test_parser.rb.erb
|
743
788
|
- templates/plugin_config_formatter/param.md-compact.erb
|
789
|
+
- templates/plugin_config_formatter/param.md-table.erb
|
744
790
|
- templates/plugin_config_formatter/param.md.erb
|
745
791
|
- templates/plugin_config_formatter/section.md.erb
|
746
792
|
- test/command/test_binlog_reader.rb
|
747
793
|
- test/command/test_ca_generate.rb
|
794
|
+
- test/command/test_cap_ctl.rb
|
795
|
+
- test/command/test_ctl.rb
|
748
796
|
- test/command/test_fluentd.rb
|
749
797
|
- test/command/test_plugin_config_formatter.rb
|
750
798
|
- test/command/test_plugin_generator.rb
|
@@ -802,6 +850,7 @@ files:
|
|
802
850
|
- test/plugin/test_buffer_memory_chunk.rb
|
803
851
|
- test/plugin/test_compressable.rb
|
804
852
|
- test/plugin/test_file_util.rb
|
853
|
+
- test/plugin/test_file_wrapper.rb
|
805
854
|
- test/plugin/test_filter.rb
|
806
855
|
- test/plugin/test_filter_grep.rb
|
807
856
|
- test/plugin/test_filter_parser.rb
|
@@ -921,6 +970,7 @@ files:
|
|
921
970
|
- test/scripts/fluent/plugin/out_test.rb
|
922
971
|
- test/scripts/fluent/plugin/out_test2.rb
|
923
972
|
- test/scripts/fluent/plugin/parser_known.rb
|
973
|
+
- test/test_capability.rb
|
924
974
|
- test/test_clock.rb
|
925
975
|
- test/test_config.rb
|
926
976
|
- test/test_configdsl.rb
|
@@ -972,13 +1022,15 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
972
1022
|
- !ruby/object:Gem::Version
|
973
1023
|
version: '0'
|
974
1024
|
requirements: []
|
975
|
-
rubygems_version: 3.
|
1025
|
+
rubygems_version: 3.1.2
|
976
1026
|
signing_key:
|
977
1027
|
specification_version: 4
|
978
1028
|
summary: Fluentd event collector
|
979
1029
|
test_files:
|
980
1030
|
- test/command/test_binlog_reader.rb
|
981
1031
|
- test/command/test_ca_generate.rb
|
1032
|
+
- test/command/test_cap_ctl.rb
|
1033
|
+
- test/command/test_ctl.rb
|
982
1034
|
- test/command/test_fluentd.rb
|
983
1035
|
- test/command/test_plugin_config_formatter.rb
|
984
1036
|
- test/command/test_plugin_generator.rb
|
@@ -1036,6 +1088,7 @@ test_files:
|
|
1036
1088
|
- test/plugin/test_buffer_memory_chunk.rb
|
1037
1089
|
- test/plugin/test_compressable.rb
|
1038
1090
|
- test/plugin/test_file_util.rb
|
1091
|
+
- test/plugin/test_file_wrapper.rb
|
1039
1092
|
- test/plugin/test_filter.rb
|
1040
1093
|
- test/plugin/test_filter_grep.rb
|
1041
1094
|
- test/plugin/test_filter_parser.rb
|
@@ -1155,6 +1208,7 @@ test_files:
|
|
1155
1208
|
- test/scripts/fluent/plugin/out_test.rb
|
1156
1209
|
- test/scripts/fluent/plugin/out_test2.rb
|
1157
1210
|
- test/scripts/fluent/plugin/parser_known.rb
|
1211
|
+
- test/test_capability.rb
|
1158
1212
|
- test/test_clock.rb
|
1159
1213
|
- test/test_config.rb
|
1160
1214
|
- test/test_configdsl.rb
|