There are many ways to simulate a socket that not reporting the disconnection, but actually it is disconnected. Only logically (programmatically) using heart beat is reliable.