-
Notifications
You must be signed in to change notification settings - Fork 0
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
Add fluentd to logging options #1
Conversation
pkg/types/logs.go
Outdated
@@ -24,6 +24,7 @@ type TraefikLog struct { | |||
Level string `description:"Log level set to traefik logs." json:"level,omitempty" toml:"level,omitempty" yaml:"level,omitempty" export:"true"` | |||
FilePath string `description:"Traefik log file path. Stdout is used when omitted or empty." json:"filePath,omitempty" toml:"filePath,omitempty" yaml:"filePath,omitempty"` | |||
Format string `description:"Traefik log format: json | common" json:"format,omitempty" toml:"format,omitempty" yaml:"format,omitempty"` | |||
Fluent string `description:"Fluent endpoint (format: http(s)://host:port)" json:"fluent,omitempty" toml:"fluent,omitempty" yaml:"fluent,omitempty"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be placed inside a Hook
struct, where additional hooks can be added over time?
I'm also not convinced about the naming of this, it could be Provider
, LogProvider
, LoggingHook
, WDYT?
I'm wondering what approach would be best for adding tests to this, documentation would also need to be included for this to make it into review. |
I think dummy fluentd mockup could be enougth ? |
i agree |
Will working on tests, I test the case where traefik is stopped but fluentd is not available/down and the process hangs up for way to long. Working on something to get this working. |
A unit test is available in https://github.com/bearstech/traefik/blob/add-fluentd/pkg/log/fluent_test.go. Should I go with documentation update ? @notsureifkevin |
It also looks like that values are not quite good and traefik hangs up for too long is there is no available |
If requested I can work on an integration test, just let me know ! Edit: I try this morning but I still have some errors... |
Hey @notsureifkevin can I have some return on this PR, what are the next steps ? Thanks ! |
Anything new on this? Cloud Native Proxie should be able to log to fluentd in 2022 ... |
I tried to relaunch the discussion with Traefik but 🤷 |
Closing due to unresponsivess on Traefik side. |
What does this PR do?
This PR adds fluentd support to Traefik logger. (discussed on Discord for Traefik Hackaethon)
Motivation
This PR is inspired by traefik#2151
More
Additional Notes
IMO, the main thing we need to discuss is how configuration is presented to end-user.
If needed I can work on multiple output support as requested in traefik#2151