added socket-io support to server and client sides