handler = () => {
            resolve();
            stream.removeListener("close", handler);
            stream.removeListener("end", handler);
            stream.removeListener("error", handler);
        }
Makes a request over an underlying transport layer and returns the response.
@param request - The request to be made.