a simple sample for socket.