Ben Bangert wrote:
> Does the app work under mod_python when you remove the thread-local?
> Technically, that shouldn't affect anything.
>
> If you hadn't previously ran your app under mod_python, there is a
> known issue with pyexpat, cited in the Troubleshooting section:
> http://pylonshq.com/project/pylonshq/wiki/ModPython

Ah, thanks Ben.  I had previously fixed the pyexpat issue by symlinking
libexpat.so.0 to the appropriate version, but the machine seemed to
have regressed.  The system now works to some degree, but I still have
one remaining issue:

When I ran the app using paster, I was able to maintain one connection
per thread, which amounted to about 11 connections to the external
system.

When I switched to mod_python, I quickly got nearly 200 connections (at
which point the system refused to give any more), having made slightly
fewer than that many requests. I then assumed that Apache would only
allocate one request to any process at once, so I then changed my code
to only make one connection per process.  This seemed to work, and kept
the number of connections at 15. (My tests were with 10 concurrent
requests; Apache is configured to keep 5 processes free).

This all suggests to me that Apache allows one request per process, but
the Pylons processes spread those requests (unnecessarily) between
threads. Is that true?  Should one or the other be configured
differently?

Many thanks,

Graham


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss
-~----------~----~----~----~------~----~------~--~---

Reply via email to