[Zope] Re: compile time optimizations for python

Tres Seaver tseaver at palladion.com
Fri Jan 18 16:31:51 EST 2008


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

David Bear wrote:
> are there any compile time optimizations for python that would also
> help optimize zope? shared libraries? threads? 

The only one I know of for Python-compilation time:

 - Ensure that Python is compiled to use UCS2, rather than UCS4, for
   unicode (UCS2 is the default, but some "system" pythons use UCS4).

Runtime:

 - Run python with '-O' on the command-line helps (it turns of some
   'if __debug__' logging).

 - If you don't allow untrusted users to create templates or scripts
   on your site, set 'skip-ownership-checking yes' in your zope.conf.

 - Ensure that debugging and profiling are disabled in zope.conf.

 - Set your log levels as high as you can (at least INFO for the
   event log).

 - Tune the ZODB connection cache size (more objects, more memory,
   but faster).

 - Tune the ZEO disk cache size (the warning sign is seen lots of
   "ZEO cache flip" entries in the event log).



Tres.
- --
===================================================================
Tres Seaver          +1 540-429-0999          tseaver at palladion.com
Palladion Software   "Excellence by Design"    http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHkRrH+gerLs4ltQ4RAgIFAJ4s3vNNvHfYX7n+jYnRa1m9459MEwCff6aV
K0NYQg37T5TLUcLqcyxXse8=
=yHSW
-----END PGP SIGNATURE-----



More information about the Zope mailing list