hashicorp / hashicorp/go-retryablehttp

getBodyReaderAndContentLength: ioutil.ReadAll: OOM

Open
#145 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
Go
Stars
2.3k
Forks
298
PR merge metrics
No merged PRs in 30d

Description

When I use `go-retryablehttp` to put some resources to my server, I got an OOM.

After I analysed pprof, I found it was retryablehttp read the body into memory:

![image](https://user-images.githubusercontent.com/49066821/135058622-ae6884e7-5992-475e-9c78-88def5a3f0c4.png)

![image](https://user-images.githubusercontent.com/49066821/135058840-b1c74f55-7f61-4212-8716-2e83ca281c62.png)

This causes OOM when I upload a large file.

Could you please change to another implement?

My retryablehttp version: `0.7.0`

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.