mirror of
https://github.com/fumiama/terasu-cloudflared.git
synced 2026-06-13 15:00:58 +08:00
TUN-6070: First connection retries other edge IPs if the error is quic timeout(likely due to firewall blocking UDP)
This commit is contained in:
@@ -7,6 +7,7 @@ import (
|
|||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/google/uuid"
|
"github.com/google/uuid"
|
||||||
|
"github.com/lucas-clemente/quic-go"
|
||||||
"github.com/rs/zerolog"
|
"github.com/rs/zerolog"
|
||||||
|
|
||||||
"github.com/cloudflare/cloudflared/connection"
|
"github.com/cloudflare/cloudflared/connection"
|
||||||
@@ -264,9 +265,9 @@ func (s *Supervisor) startFirstTunnel(
|
|||||||
switch err.(type) {
|
switch err.(type) {
|
||||||
case nil:
|
case nil:
|
||||||
return
|
return
|
||||||
// try the next address if it was a dialError(network problem) or
|
// try the next address if it was a quic.IdleTimeoutError, dialError(network problem) or
|
||||||
// dupConnRegisterTunnelError
|
// dupConnRegisterTunnelError
|
||||||
case edgediscovery.DialError, connection.DupConnRegisterTunnelError:
|
case *quic.IdleTimeoutError, edgediscovery.DialError, connection.DupConnRegisterTunnelError:
|
||||||
edgeErrors++
|
edgeErrors++
|
||||||
default:
|
default:
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user