I use memcache and MEMDB for session storage and caching. The CentOS server is setup with an apache modwsgi process group, setup through the wsgihandler.py.
I establish the MemcacheClient and MEMDB as the cache and session db in my app's models/db.py file. It appears that when requests have been serviced, the TCP socket connections to memcached remain open and ESTABLISHED (state), piling up on top of one another. I can bandaid fix the problem by using the modwsgi -maximum-requests=X option to force the python interpreter processes to restart completely, but this is not ideal. Is there a hook to run a function after the session has been correctly stored and response sent back to apache, where I could manually run the memcache client's disconnect_all() ? Looking at gluon.main's wsgibase, I didn't see any simple options to fix this with. I am hesitant to hack my own code in there, as it would make updating web2py a pain with patch management. -r -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.

