Re: Does socket.setdefaulttimeout affect the timeouts in MySQLdb?

2007-04-24 Thread Steve Holden
John Nagle wrote: > Does setting "socket.setdefaulttimeout" affect the timeout in MySQLdb > for connections to the database? I'm getting database connection timeouts on > a local (same machine) connnection, and I've been setting > "socket.setdefaulttim

Does socket.setdefaulttimeout affect the timeouts in MySQLdb?

2007-04-23 Thread John Nagle
Does setting "socket.setdefaulttimeout" affect the timeout in MySQLdb for connections to the database? I'm getting database connection timeouts on a local (same machine) connnection, and I've been setting "socket.setdefaulttimeout" to 15 seconds so web page open

Re: Threads and socket.setdefaulttimeout

2005-10-19 Thread Steve Holden
Russell Warren wrote: > Thanks for the detailed repsone... sorry for the lag in responding to > it. [discussion of problems with timeouts on threaded code's sockets] > > Not quite what I was after I don't think since potentially interfering > code needs to check the lock (via acquire) to avoid con

Re: Threads and socket.setdefaulttimeout

2005-10-19 Thread Russell Warren
Thanks for the detailed repsone... sorry for the lag in responding to it. After reading and further thought, the only reason I was using setdefaulttimeout in the first place (rather then using a direct settimeout on the socket) was because it seemed like the only way (and easy) of getting access t

Re: Threads and socket.setdefaulttimeout

2005-10-12 Thread Steve Holden
that I haven't ever used different timeout values for the sockets in different parallel threads, so this is a new problem to me. > All suggestions appreciated! Hopefully I'm just missing something > obvious. > > Russ > > #--- This script confirms that settimeout's a

Threads and socket.setdefaulttimeout

2005-10-12 Thread Russell Warren
are atomic/uninterruptable and no other thread can sneak in between? All suggestions appreciated! Hopefully I'm just missing something obvious. Russ #--- This script confirms that settimeout's affect is across threads import threading, xmlrpclib, socket def st(): socket.setdef

Re: socket.setdefaulttimeout()

2005-10-09 Thread Fredrik Lundh
"rtilley" wrote: > Perhaps this is a dumb question... but here goes. Should a socket client > and a socket server each have different values for > socket.setdefaulttimeout() what happens? Does the one with the shortest > timeout period end first? the timeout is a loca

socket.setdefaulttimeout()

2005-10-08 Thread rtilley
Perhaps this is a dumb question... but here goes. Should a socket client and a socket server each have different values for socket.setdefaulttimeout() what happens? Does the one with the shortest timeout period end first? -- http://mail.python.org/mailman/listinfo/python-list

Re: scope of socket.setdefaulttimeout?

2005-09-30 Thread Steve Holden
Russell Warren wrote: > Does anyone know the scope of the socket.setdefaulttimeout call? Is it > a cross-process/system setting or does it stay local in the application > in which it is called? > > I've been testing this and it seems to stay in the application scope, > b

scope of socket.setdefaulttimeout?

2005-09-29 Thread Russell Warren
Does anyone know the scope of the socket.setdefaulttimeout call? Is it a cross-process/system setting or does it stay local in the application in which it is called? I've been testing this and it seems to stay in the application scope, but the paranoid side of me thinks I may be mi