Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow for errors to be reported to a file instead of stderr #97

Open
braydonk opened this issue Jul 20, 2023 · 0 comments
Open

Allow for errors to be reported to a file instead of stderr #97

braydonk opened this issue Jul 20, 2023 · 0 comments

Comments

@braydonk
Copy link

The Problem

Today, any errors in chunkio file operations will be reported to stderr. This is not a big deal when running an application using this library as a direct binary, since there are methods to redirect stderr when running directly. When running as a systemd service, you can set a StandardError configuration to report stderr to a file. The main situation where there is no recourse for this is when running as a Windows Service, which does not retain stderr and does not have a standard way to reconfigure it.

Potential Solution

Allow configuring a log file for any chunkio logs.

Alternatives Considered

Since the problem really shines as a Windows Service, this could be solved on Windows specifically by using the SetStdHandle function in the Win32 Console API. However, with all the work that would need to be done to allow configuration of this file just for Windows, you might as well do the implementation in a cross platform manner that may still benefit users on other platforms even if they have other escape hatches.

Additional Context

This issue was discussed in person at the Fluent Bit Developer's Meeting on July 12,2023.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant