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

connect with http2 protocol may retry to connect #363

Closed
thenrio opened this issue May 29, 2024 · 1 comment
Closed

connect with http2 protocol may retry to connect #363

thenrio opened this issue May 29, 2024 · 1 comment

Comments

@thenrio
Copy link

thenrio commented May 29, 2024

On req-0.5.0,

The following is ok

iex(1)> Req.get("https://eno.nt", connect_options: [protocols: [:http1]])
{:error, %Req.TransportError{reason: :nxdomain}}

When I use http2 as protocol, then I see retry attempts:

iex(2)> Req.get("https://eno.nt", connect_options: [protocols: [:http2]])

13:57:26.725 [warning] Failed to connect to https://eno.nt:443: non-existing domain
{:error, %Req.HTTPError{protocol: :http2, reason: :disconnected}}
iex(3)>
13:57:27.077 [warning] Failed to connect to https://eno.nt:443: non-existing domain

13:57:27.622 [warning] Failed to connect to https://eno.nt:443: non-existing domain

13:57:28.321 [warning] Failed to connect to https://eno.nt:443: non-existing domain

I think we should not reconnect in this case.

@wojtekmach
Copy link
Owner

Thanks for the report. These retries are coming from Finch:

iex(1)> Req.get("https://eno.nt", connect_options: [protocols: [:http2]], retry: false)

20:48:14.421 [warning] Failed to connect to https://eno.nt:443: non-existing domain
{:error, %Req.HTTPError{protocol: :http2, reason: :disconnected}}

20:48:14.428 [warning] Failed to connect to https://eno.nt:443: non-existing domain

20:48:15.177 [warning] Failed to connect to https://eno.nt:443: non-existing domain

20:48:15.445 [warning] Failed to connect to https://eno.nt:443: non-existing domain

20:48:17.268 [warning] Failed to connect to https://eno.nt:443: non-existing domain

Could you re-open this in Finch repo? I'll of course be happy to make any required changes in Req. Thanks!

@wojtekmach wojtekmach closed this as not planned Won't fix, can't repro, duplicate, stale Jun 11, 2024
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

No branches or pull requests

2 participants