Improved message id in tcpMessage and cleaned up class