[−][src]Function rouille::proxy::full_proxy
pub fn full_proxy<A>(
request: &Request,
config: ProxyConfig<A>
) -> Result<Response, FullProxyError> where
A: ToSocketAddrs,
Sends the request to another HTTP server using the configuration.
Contrary to proxy
, if the server fails to return a proper response then a response is
generated with the status code 502 or 504.
The only possible remaining error is if the body of the request was already extracted. Since this would be a logic error, it is acceptable to unwrap it.