CPU usage with ssh.blocking = true (wodSSH / wodSSH.NET)
I am running multiple threads of the ssh class so I can run commands on several network devices at once. They are all set to 'blocking = true' and I am using the 'client.waitfor()' method to pause for the responses. While the regex I am using does work and will process correctly, when my code is 'waitingfor' the cpu core spikes to 100% usage while it waits for the data to return.
Is this normal? Is there a workaround without having to switch from blocking mode to using events?
- CPU usage with ssh.blocking = true - Marc M, 2014-04-12, 00:22
- CPU usage with ssh.blocking = true - wodSupport, 2014-04-12, 01:07