Conversation
|
Hmm, can't build io-event on Windows: https://github.com/fluent/fluentd/runs/7645045887?check_suite_focus=true |
|
I'm seeing.. |
|
Hmm, this log is not outputted. I don't know why... In master, when launching Fluentd with this config, the log is outputted using ConsoleAdapter. |
|
https://github.com/socketry/async-io/blob/v1.34.3/lib/async/io/socket.rb#L157 At this point, somehow I'm thinking about the possibility that the logger is not passed to the child task correctly. |
|
It seems that fluentd/lib/fluent/plugin_helper/http_server.rb Lines 74 to 76 in bf7498d |
|
https://github.com/socketry/console/blob/main/lib/console.rb#L13-L19 |
|
We may have to do something like this... --- a/lib/fluent/plugin_helper/http_server/server.rb
+++ b/lib/fluent/plugin_helper/http_server/server.rb
@@ -40,7 +40,6 @@ module Fluent
@uri = URI("#{scheme}://#{@addr}:#{@port}").to_s
@router = Router.new(default_app)
@server_task = nil
- Console.logger = Fluent::Log::ConsoleAdapter.wrap(@logger)
opts = if tls_context
{ ssl_context: tls_context }
@@ -55,10 +54,12 @@ module Fluent
end
def start(notify = nil)
+ Console.logger = Fluent::Log::ConsoleAdapter.wrap(@logger)
@logger.debug("Start async HTTP server listening #{@uri}")
Async do |task|
@server_task = task.async do
+ Console.logger = Fluent::Log::ConsoleAdapter.wrap(@logger)
@server.run
end
if notify |
Thanks for checking it. |
|
Note: We have to consider the possibility of |
Signed-off-by: Takuro Ashie <ashie@clear-code.com>
Because dependent io-event (v1.0.9) can't build on Windows. Signed-off-by: Takuro Ashie <ashie@clear-code.com>
Signed-off-by: Takuro Ashie <ashie@clear-code.com>
Signed-off-by: Takuro Ashie <ashie@clear-code.com>
|
Hmm, GitHub "update branch" feature is not what I want. rebased manually. |
It should be "Update with rebase". |
|
It looks like as of v0.65.0 the |
Thanks notifying it, we'll check it. |
|
This pull request isn't ready for v1.17, we postpone merging this. |
|
This PR has been automatically marked as stale because it has been open 30 days with no activity. Remove stale label or comment or this PR will be closed in 7 days |
|
Seems that currently |
|
Async 2.x supports Ruby 3.1 or later only. |
|
Hmm, io-event gem still have a problem on windows platform. https://github.com/Watson1978/fluentd/actions/runs/10483331006/job/29035871921 |
|
We'll continue this work in #4619 |
Which issue(s) this PR fixes:
Fixes #
What this PR does / why we need it:
http_serverplugin helper doesn't work with Async 2.x gem due to using obsolete usage.This PR updates it to follow current documented way:
https://github.com/socketry/async-http/blob/0a65acd7cf7486e1877f0da86580e1692cd8207b/readme.md#usage
It's applicable both Async 2.x & Async 1.x.
But this PR still stay on Async 1.x because io-event gem which is required by Async 2.x can't build on Windows.
Docs Changes:
None
Release Note:
Same with the title