Description
Tips for Plone performance tuning and making your add-on product and customizations faster.
For multicore systems, which basically all production systems nowadays are, you might want to optimize Python threading vs. processes. You may also tune how many Python interpreter instructions are run before doing green thread switches in the interpreter.
Storing sessions in ZEO/ZODB does not scale well, since they are very prone to raise ConflictErrors if there is considerable load on the system.
Memcached provides a more scalable session backend.
For more information, see lovely.session add-on product.
http://plope.com/Members/chrism/iostat_debugging
Summary:
<mcdonc> well, the example has await at about 40X svctime.. that's pretty shitty
<mcdonc> i mean that box was useless
These tips are especially critical when running Plone on low-memory virtual private server (VPS).
Add PTS_LANGUAGES to buildout.cfg to declare which .po files are loaded on the start-up:
[instance]
...
environment-vars =
PTS_LANGUAGES=en fi
How to offload blob processing from Zope:
Do not use LanguageIndex, and update your LinguaPlone to version 3.1.
Write transactions much worse performance-wise than read transactions.
By default, every login is a write transaction. Also, Plone needs to update the logged-in user's session timestamp once in a while to keep the session active.
With a high amount of users, you may start seeing many ConflictErrors (read conflicts) with ZODB.
There are some tricks you can use here:
This specifies how many requests one ZEO front-end client (ZServer) can handle.
The default set by buildout default is 2.
Adjust it:
[client1]
recipe = plone.recipe.zope2instance
....
zserver-threads = 5
Find good value by doing performance testing for your site.
Note
Increasing thread count is useful if your Plone site does server-to-server traffic and your Plone site needs to wait for the other end, thus blocking Zope threads.
More info:
The source code of this file is hosted on GitHub. Everyone can update and fix errors in this document with few clicks - no downloads needed.
For basic information about updating this manual and Sphinx format please see Writing and updating the manual guide.