wget-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: wget2 | wget2 doesn't honour --timeout option (#671)


From: Roger Marco Hernandez (@RogerMarcoHernandez)
Subject: Re: wget2 | wget2 doesn't honour --timeout option (#671)
Date: Tue, 09 Jul 2024 11:17:51 +0000



Roger Marco Hernandez commented on a discussion: 
https://gitlab.com/gnuwget/wget2/-/issues/671#note_1989770801


@rockdaboot I've been investigating in regards to connection timeouts and 
whilst there are workarounds, like the provided patch, seems like, as you said, 
they are exclusive to Linux. All other systems usually ignore SO_SNDTIMEO for 
connections and apply their defaults (Linux - 60 seconds, Windows - 20 
seconds...).

The 
[0e60ece8](https://gitlab.com/gnuwget/wget2/-/commit/0e60ece89ab11f9aa9199eb9ca8b187259ea9000)
 commit that changed to a synchronous connection approach to fix connection 
fallback IP's didn't mention any timeouts, so AFAIK, there are three possible 
solutions, each one stricter than the previous:
- Allow connection timeouts to asynchronous sockets only (falling back to the 
original asynchronous timeout detection). In which case, specifying a 
connection timeout (async) would fail in cases like (GitHub 
#325)[https://github.com/rockdaboot/wget2/issues/325].
- Allow connection timeouts only for Linux systems. This solution, although 
being strict, should always work unless Linux decides not to honor SO_SNDTIMEO 
for connections anymore.
- Only allow DNS and read timeouts.

In the end, it all boils down to the fact that most used operating systems do 
not provide any synchronous way to set a connection timeout programmatically 
without modifying system defaults, either at socket level or TCP level.

-- 
Reply to this email directly or view it on GitLab: 
https://gitlab.com/gnuwget/wget2/-/issues/671#note_1989770801
You're receiving this email because of your account on gitlab.com.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]