Refactor connectToServer and startServer method of ShareCircleClient and
ShareCircleServer.