cloudflared-mirror/origin
Nuno Diegues 7bac4b15b0 TUN-5719: Re-attempt connection to edge with QUIC despite network error when there is no fallback
We have made 2 changes in the past that caused an unexpected edge case:
 1. when faced with QUIC "no network activity", give up re-attempts and fall-back
 2. when a protocol is chosen explicitly, rather than using auto (the default), do not fallback

The reasoning for 1. was to fallback quickly in situations where the user may not
have chosen QUIC, and simply got it because we auto-chose it (with the TXT DNS record),
but the users' environment does not allow egress via UDP.

The reasoning for 2. was to avoid falling back if the user explicitly chooses a
protocol. E.g., if the user chooses QUIC, she may want to do UDP proxying, so if
we fallback to HTTP2 protocol that will be unexpected since it does not support
UDP (and same applies for HTTP2 falling back to h2mux and TCP proxying).

This PR fixes the edge case that happens when both those changes 1. and 2. are
put together: when faced with a QUIC "no network activity", we should only try
to fallback if there is a possible fallback. Otherwise, we should exhaust the
retries as normal.
2022-01-27 22:12:25 +00:00
..
cloudflare_status_page.go TUN-1350: Enhance error messages with cloudflarestatus.com link, if relevant 2019-01-18 13:37:05 -06:00
cloudflare_status_page_test.go TUN-3837: Remove automation_email from cloudflared status page test 2021-02-01 15:07:37 +00:00
conn_aware_logger.go TUN-5368: Log connection issues with LogLevel that depends on tunnel state 2021-11-10 09:00:05 +00:00
external_control.go Fixed connection error handling by removing duplicated errors, standardizing on non-pointer error types 2021-01-22 10:58:06 -06:00
metrics.go TUN-4067: Reformat code for consistent import order, grouping, and fix formatting. Added goimports target to the Makefile to make this easier in the future. 2021-03-24 10:53:29 -05:00
pool.go TUN-4063: Cleanup dependencies between packages. 2021-03-09 14:02:59 +00:00
proxy.go Fix for Issue #501: Unexpected User-agent insertion when tunneling http request 2021-11-13 01:34:19 +01:00
proxy_posix_test.go TUN-5551: Reintroduce FIPS compliance for linux amd64 now as separate binaries 2021-12-20 21:50:42 +00:00
proxy_test.go Fix typos 2021-11-12 17:38:06 +02:00
reconnect.go Fix typos 2021-11-12 17:38:06 +02:00
reconnect_test.go TUN-3863: Consolidate header handling logic in the connection package; move headers definitions from h2mux to packages that manage them; cleanup header conversions 2021-03-29 21:57:56 +00:00
supervisor.go TUN-5368: Log connection issues with LogLevel that depends on tunnel state 2021-11-10 09:00:05 +00:00
tunnel.go TUN-5719: Re-attempt connection to edge with QUIC despite network error when there is no fallback 2022-01-27 22:12:25 +00:00
tunnel_test.go TUN-5719: Re-attempt connection to edge with QUIC despite network error when there is no fallback 2022-01-27 22:12:25 +00:00
tunnelsforha.go TUN-1270: cloudflared panic (HA metrics missing label) 2018-12-11 11:41:49 -06:00