Implemented the TCP event on the server.