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

Support for dynamic file path #225

Closed
angel-smile opened this issue Aug 20, 2015 · 3 comments
Closed

Support for dynamic file path #225

angel-smile opened this issue Aug 20, 2015 · 3 comments

Comments

@angel-smile
Copy link

Is there a way to specify dynamic file path/name in log-courier configuration file? The targeted log file rotates everyday with its name set as the date. It seems in logstash I can specify the file name in the configuration file as "/full_path/%{YEAR}%{MONTHNUM}%{MONTHDAY}". Is there a way to do this in log-courier?

Thanks in advance!

@driskell
Copy link
Owner

Good idea. Have you seen #37 ?

My only concern is timing though and if there could be missed logs because courier didn't see a dead file update at 23:59 on 2015-08-20 because it's next scan was 00:00 on 2015-08-21 and it scanned a different folder.

It all comes into timing with dead time I guess. Ensuring files kept open long enough to notice changes right until past the rotation.

#37 seems the root cause and this is a good partial solution. Be good to hear your thoughts on the dead time action mentioned there though.

@angel-smile
Copy link
Author

Hi Jason,

Many thanks for the response. I agree with you that the dead time action should be a solution for our issue. We are running an old version of log-courier. I'll upgrade it to the latest version and try dead time. It would still be good to be able to specify file path with regex like "%{YEAR}%{MONTHNUM}%{MONTHDAY}" though.

@angel-smile
Copy link
Author

Hi Jason,

"dead time" has fixed our problem. Do you want me to close the case or leave it open till regex feature for file path is implemented?

Thanks a lot for the help.

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

No branches or pull requests

2 participants