Launch a local agent over ssh/command launcher and stop its process by kill -TSTP $PID. The agent stops responding and Jenkins notices is eventually closing its connection with clear exception.
- The channel is never disassociated from its computer so long running operations and other clients that only care for computer.channel != null will keep using it throwing exceptions all over the place. EDIT: The computer is not even temporarily offline and it does not seem to improve after all monitors has run as they all choke on closed channel.
- The channel is in the middle of closing procedure as it is outClosed but not inClosed. The other end does not send the close command for obvious reasons so it is never closed fully. I speculate that specifically is the reason why SlaveComputer#closeChannel() is not called thus causing the previous problem.
- The broken/half-closed/fully-closed channel is disassociated from computer that will therefore appear disconnected to all possible clients.