-
Notifications
You must be signed in to change notification settings - Fork 46
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
log rotation #16
Comments
@joeblew99 To directly answer your question, there's no built-in log rotation with health. However, I might not understand your question. How does an unreliable WAN and remote servers relate to log rotation? What I typically do is log to a file on the server, and use the logrotate tool to rotate that file. |
Well because the WAN connection upstream of the remote server sucks, I need to store the logs. I am assuming that after it has pushed the logs up, it will remove them from the local storage. Otherwise I would need to do log rotation in such a way that it deletes the logs older than 7 days, so the hard disk does not fill up forever. How does this fit with your heslthd ? Am sorry for asking basic questions, but its been a long week of deadlines. I thought the fact that your code is designed for jobs to be very good for the type of project I have. |
@joeblew99 Gotcha. You might need to do something custom to handle that scenario. There's no logic in health that retries when the connection is good, for instance. The healthd architecture might be something you could look into. The JsonPollingSink will store metrics (not logs) for 5 minutes and expose them on an endpoint (now that I think about it, that sink actually does 'rotate' metrics). Then, healthd can scrape those metrics. This would be helpful in the case of unreliable connections -- if healthd fails to get some metrics, it can try again as long as it happens in 5 minutes. |
i am using this in an environment where the WAN gateway is not always up.
The servers are in remote locations.
So i was wondering if this supports some sort of log rotation, but still able to work with sinks ?
The text was updated successfully, but these errors were encountered: