[Yum-devel] urlgrabber socket timeouts

seth vidal skvidal at phy.duke.edu
Wed Sep 29 05:44:47 UTC 2004


> You're not in left field at all.  The only issue is that this is only
> available in 2.3.  In previous versions, you'd need to include a third
> party module.

Works for me - let's do a check for the function, if it's not there,
then it doesn't get set, sucks to be running python 2.2. :)

> I agree that this is a good way to go.  It doesn't completely solve
> timeout problems though because tcp timeouts won't always save you
> from a stupid/slow server.  A tcp timeout happens when one side sends
> a request but doesn't get an acknowledgement.  It's quite possible
> (and common in ssh or imap connections) to simply have no requests
> made for a very long time.  In that case, you'd also need higher-level
> timeouts, which I was looking into a couple weeks ago before I got
> swamped in work.

My tests:

set the timeout to 30s
start downloading something big
login to server, set -j DROP on the iptables from the downloading host
wait 30s, it times out
restart the download
login to server, set -j DROP on the iptables from the downloading host
wait 20s
unset the -j DROP
it continues the download
set the -j DROP
wait 30s, it times out.

Repeat the above with -j REJECT and turning off webserver.
Now I know that's not all of the possible situations but I'd be willing
to bet it's a good hunk of them.

> 
> In short, I'd have no problem implementing this as an "only >=2.3"
> feature.  However, we should probably be clear from the start that we
> will eventually remove the checks, meaning: if you want to use new
> urlgrabbers with old pythons for a long time, you should simply not
> use this option.

Fine by me.

This would make a lot of people happy, I'm certain.
-sv





More information about the Yum-devel mailing list