Refactor into server->request->response structure.