handle messages in dedicated methods
send final message to server on termination

see: #185