Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix issue 555 about request header context-length missing #649

Merged
merged 5 commits into from
Jun 7, 2022
Merged

fix issue 555 about request header context-length missing #649

merged 5 commits into from
Jun 7, 2022

Conversation

suchen-sci
Copy link
Contributor

Golang http.NewRequestWithContext will set http.Request.ContentLength when body is bytes.Buffer, bytes.Reader or strings.Reader. If http.Request.ContentLength is not send, Golang std lib will delete Header of Context-Length when sending request. Fix #555

@codecov-commenter
Copy link

codecov-commenter commented Jun 7, 2022

Codecov Report

Merging #649 (eb2c4d5) into main (2aa4404) will decrease coverage by 0.12%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##             main     #649      +/-   ##
==========================================
- Coverage   80.12%   80.00%   -0.13%     
==========================================
  Files          95       95              
  Lines       10981    10986       +5     
==========================================
- Hits         8799     8789      -10     
- Misses       1705     1715      +10     
- Partials      477      482       +5     
Impacted Files Coverage Δ
pkg/filter/proxy/proxy.go 82.40% <ø> (ø)
pkg/filter/proxy/request.go 92.95% <0.00%> (-7.05%) ⬇️
pkg/cluster/cluster.go 59.00% <0.00%> (-1.87%) ⬇️
pkg/object/mqttproxy/client.go 80.54% <0.00%> (+0.90%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2aa4404...eb2c4d5. Read the comment docs.

@suchen-sci
Copy link
Contributor Author

updated!

pkg/filter/proxy/proxy.go Outdated Show resolved Hide resolved
@suchen-sci suchen-sci merged commit d98176f into easegress-io:main Jun 7, 2022
@suchen-sci suchen-sci deleted the request-header-context-length branch June 7, 2022 07:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The content-length header in the request is always replaced with transfer-encoding: chunked
5 participants