CPU usage 100% on MacOS
ft is working very well for me. I'm using it daily. However, I recently noticed the macbook was a little warm, when I checked the ft process had one CPU core at 100%. Check the attached screenshot. I'm guessing this might be due to checking if the file was written very rapidly! Maybe there is a way to hook into file monitoring/watch services into macos instead ? or at least check less aggressively. Happy to test any debug builds.
Thanks Ahmed! Yes it should definitely not use that much CPU. I'll look into it.
What protocol are you tunneling? Does the high CPU usage happen straight away, after a while, after a disconnect?
You were right - it was checking if the file was written, without sleeping!
public static void Wait(int ms)
{
if (RuntimeInformation.IsOSPlatform(OSPlatform.Linux))
{
Thread.Sleep(ms);
return;
}
if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
{
WindowsDelay.Wait(ms);
return;
}
}
I'll fix it up tonight :)