473,498 Members | 1,379 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

HTTP Keep-Alive with urllib2

Someone once asked about this an got no answer:

http://groups.google.dk/group/comp.l...11efce3b1776cf

Maybe I am luckier :)

Does anyone know how to do Keep-Alive with urllib2, that is, how to get
a persistent HTTP connection, instead of a new connection being opened
for every request?

/David
Nov 22 '05 #1
2 7269
David Rasmussen wrote:
Someone once asked about this an got no answer:

http://groups.google.dk/group/comp.l...11efce3b1776cf

Maybe I am luckier :)

Does anyone know how to do Keep-Alive with urllib2, that is, how to get
a persistent HTTP connection, instead of a new connection being opened
for every request?


This would imply the answer is "it's not possible":

sholden@bigboy ~/Projects/pycon
$ grep -i keep-alive /lib/python2.4/urllib*.py

regards
Steve
--
Steve Holden +44 150 684 7255 +1 800 494 3119
Holden Web LLC www.holdenweb.com
PyCon TX 2006 www.python.org/pycon/

Nov 22 '05 #2
David Rasmussen wrote:
Someone once asked about this an got no answer:

http://groups.google.dk/group/comp.l...11efce3b1776cf

Maybe I am luckier :)

Does anyone know how to do Keep-Alive with urllib2, that is, how to get
a persistent HTTP connection, instead of a new connection being opened
for every request?


This would imply the answer is "it's not possible":

sholden@bigboy ~/Projects/pycon
$ grep -i keep-alive /lib/python2.4/urllib*.py

regards
Steve
--
Steve Holden +44 150 684 7255 +1 800 494 3119
Holden Web LLC www.holdenweb.com
PyCon TX 2006 www.python.org/pycon/

Nov 22 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
1417
by: Ron | last post by:
Hello, I keep getting a runtime error with the following ado routine that I run from a VB6 app - note: I tried it with ref to mdac2.6 and mdac2.7 and mdac2.8. This worked once, but it doesn't...
6
2401
by: Drew | last post by:
I have been trying to figure out why I am getting this message... I have an application that is 20 different ASP pages that works in sequential order (step1, step2, step3...). After each step the...
6
8616
by: Steve Jorgensen | last post by:
I tried to fix a problem for a client today in which report sections and even individual text controls in some of their reports are being split across page boundaries. Of course, I was thinking...
6
2494
by: Microsoft News | last post by:
Hi, I have been using several http server code examples from the web, include one from msdn, and I can't seem to get a simple http server thread working. I can connect the server successful...
0
1664
by: Mike Hoorens | last post by:
Hi there. This looks like a good place to get help with a problem I am having: - We have a c# windows app, which performs an HTTPWebRequest to a IIS box on Internet to retrieve an XML response....
3
1164
by: Rajiv Das | last post by:
C# 2.0 XP SP2 In My Code, I am using HttpWebRequest to visit a particular URL. I am required to generate a snapshot image (if this request were made through say IE) and save as jpeg. About .1...
1
1782
by: Mark Rae | last post by:
Hi, Development machine is: AMD dual-core 64-bit Athlon 4Gb RAM 2 x 160Gb SATA hard drives WinXP Pro + SP2 and all the latest patches Visual Studio.NET 2005 SQL Server 2005 developer...
15
6684
by: l3vi | last post by:
I have a new system Im building that stores entries of what people are searching for on my sites. I want to be able to keep records of how many times a keyword was searched for daily, and from...
11
9256
by: cty0000 | last post by:
I have some quiestion... I want to draw line,point,rectangles and etc... on the from So I code like this.. public update() { g = this.CreateGraphics(); g.FillRectangle(Brushes.White, x1,...
0
1762
by: db2admin | last post by:
hello, we take full on sunday and incremental delta rest of the days everyday. i want to keep only 8 weeks of backups on TSM. i am trying to understand the meaning of parameter "keep" in...
0
7124
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
6998
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
1
6884
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7375
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5460
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4586
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3078
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
651
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
287
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.