get websocket handshake implemented and implement connection tracking by URL; refactor to a simpler solution