dquangsinh / fb2pdf

Automatically exported from code.google.com/p/fb2pdf
0 stars 0 forks source link

download timeout #20

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
I can see S3 download which is stuck for 20+ minutes. Last message in log:

2007-03-06 10:11:25,083 DEBUG    Creating temporary directory
'/tmp/1173204685'.
2007-03-06 10:11:25,085 DEBUG    Downloading
'http://s3.amazonaws.com/fb2pdf/6ea
f159360d4abf5b8380caba6f97783.fb2' to file
'kompyuterra_kompyuterra_676_jurnal_k
ompyuterra_n_8_ot_27_fevralya_2007_goda.fb2'.

We should put some reasonable timeout on download.

Original issue reported on code.google.com by kroko...@gmail.com on 6 Mar 2007 at 6:34

GoogleCodeExporter commented 8 years ago
please take a look if you have a moment

Original comment by kroko...@gmail.com on 8 Mar 2007 at 5:06

GoogleCodeExporter commented 8 years ago
wanna try? ;)

Original comment by kroko...@gmail.com on 9 Mar 2007 at 7:52

GoogleCodeExporter commented 8 years ago
This is becomes kind of critical. I see lot errors in log related to S3 upload.

Original comment by kroko...@gmail.com on 9 Mar 2007 at 5:50

GoogleCodeExporter commented 8 years ago
Also we need upload timeout. So in general we need config option for network
operations timeouts.

Original comment by kroko...@gmail.com on 9 Mar 2007 at 9:46

GoogleCodeExporter commented 8 years ago
For upload timeout here is a hint:

http://code.google.com/p/boto/issues/detail?id=24&can=2&q=

Original comment by kroko...@gmail.com on 9 Mar 2007 at 10:02

GoogleCodeExporter commented 8 years ago
so far I found only one way to set a timeout for urllib2.
socket.setdefaulttimeout(1)
The problem is that this timeout is global and will apply to all socket 
operations

Original comment by alex.s...@gmail.com on 14 Mar 2007 at 9:34

GoogleCodeExporter commented 8 years ago
here is very recent discussion (with Guido van Rossum as one of participants) 
about 
urllib2 timeout

http://www.gossamer-threads.com/lists/python/dev/551282

Original comment by alex.s...@gmail.com on 15 Mar 2007 at 12:11