[Zope-Coders] Re: [Zope-Checkins] CVS: Zope/lib/python/ZServer - utils.py:1.1 __init__.py:1.30

Stuart Bishop stuart.b@commonground.com.au
Sun, 20 Jul 2003 11:09:39 +1000


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Sunday, July 20, 2003, at 06:17  AM, Chris McDonough wrote:

> def getMaxSockets():
>     from medusa.test import max_sockets
>     return max_sockets.max_select_sockets()

Calling max_sockets.max_select_sockets increases the startup time
on a maxed out 1GHz PowerBook running OSX 10.2 by 20 seconds, which
we found out in the Melbourne Zope 3 sprint (Opening that many sockets
causes many netinfo database lookups, so watch the CPU utilization of
lookupd go through the roof). I have no idea if this is due to a bug
in the Python sockets module, a bug in the max_server_sockets code, or
just the way it is supposed to work.

In the Zope3 tree, this function and the others in maxsockets.py
just return 100.

Any objection to applying the same fix to the Zope HEAD?

Should I only do it "if sys.platform == 'darwin'"?


This method is not called on the 2.6 branch.


- -- 
Stuart Bishop <zen@shangri-la.dropbear.id.au>
http://shangri-la.dropbear.id.au/

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (Darwin)

iD8DBQE/GevYh8iUz1x5geARAkqQAKDsIR/U8bMV3equqwOoP1B4JYCWjgCguaHx
Zu3N85Ncdu4pvyeE6uzXBJk=
=PJWr
-----END PGP SIGNATURE-----