martomi / chiadog

A watch dog providing a peace in mind that your Chia farm is running smoothly 24/7.
MIT License
457 stars 120 forks source link

FileLogConsumer: Throttle log polling #178

Closed martomi closed 3 years ago

martomi commented 3 years ago

Currently the loop isn't throttled which creates busy-wait and maxes out one of the CPU cores to 100%. This is because Pygtail exits its own loop every time it reaches the end of the debug.log file.

This also makes WARNING logs about non-existing debug.log file during log rotation statistically improbable.