Dechunk HTTP requests by default (#11)

ProxyManager already has all the Request body's data. There is no never
a need to use chunked transfer encoding to the upstream process.
This commit is contained in:
Benson Wong
2024-11-19 09:40:44 -08:00
parent 5021e0f299
commit 7eec51f3f2
3 changed files with 10 additions and 4 deletions

View File

@@ -178,7 +178,7 @@ func (p *Process) ProxyRequest(w http.ResponseWriter, r *http.Request) {
http.Error(w, err.Error(), http.StatusInternalServerError)
return
}
req.Header = r.Header
req.Header = r.Header.Clone()
resp, err := client.Do(req)
if err != nil {
http.Error(w, err.Error(), http.StatusBadGateway)