On Wednesday 10 December 2008 11:15:20 Chris G wrote:
I have some python scripts which convert reStructuredText to HTML 'on the fly' when xxxx.rst files are browsed.
When I look at the pages locally performance is acceptable but I have just tried remotely (from work) and it takes several minutes to display a new xxxx.rst page. Normal HTML and other stuff are shown at normal speed, I have some quite complex PHP (which I didn't write) being served by the same apache server and it's fine.
When you say "locally", do you meaning executing the Python in its own process? Or making an HTTP GET request from localhost to Apache running on localhost? i.e., is it the fact that the Python is running within Apache that's making it slow? Or is it the fact that you are making the request from elsewhere?
Can anyone suggest any reason for remote access to this being so incredibly slow? It's probably some dire misconfiguration somewhere but I don't know where to start looking really.
If the script runs slowly *because* it's being run within Apache, the next question to ask is how are you running it in Apache? CGI? FastCGI? mod_python?