{:error, %HTTPoison.Error{id: nil, reason: "closed"}}
- Dominant language
- Elixir
- Stars
- 2.3k
- Forks
- 349
- PR merge metrics
- No merged PRs in 30d
Description
I’m getting a strange error in HTTPoison. When I do two request to a server “A” in the second I get connection close.
```
HTTPoison.get("http:/urla.com", [], [ ssl: [{:versions, [:'tlsv1.2']}] , hackney: [pool: :mypool], max_connections: 1000])
```
When I do this with other server it works.
```
HTTPoison.get("http:/google.com", [], [ ssl: [{:versions, [:'tlsv1.2']}] , hackney: [pool: :mypool], max_connections: 1000])
```
So I think it was a error on the server “A” , so a did a manual call with curl 20 times and all work perfect in the server “A” and “B”.
```
curl http://urla.com\?\[1-20\]
```
I tried with another lib and the server respond with no error.
```
HTTPotion.get("http:/urla.com")
```
I also tried with the default options and with the options above `[ ssl: [{:versions, [:'tlsv1.2']}] , hackney: [pool: :mypool], max_connections: 1000]`. But I get the same error.
Any tip what could be the error?
Contributor guide
No contributing guide indexed for this repository
Research direction
Start at the HTTPoison.get calls in the issue, comparing the failing server A request with the working server B request and the configured hackney pool and TLS options. Reproduce repeated requests and determine whether the closed connection is caused by HTTPoison, hackney configuration, or the server response. Done means identifying the cause and verifying that repeated requests behave correctly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- elixir
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 32/100