>It's very difficult to tell what might be the cause of these timing
>differences without knowing what code is running.
The code is simple, downloading a pdf file on n pages, add a watermark to it and send it back.
>How are you running the code inside Tomcat? Are you using modjy, the
>WSGI gateway? Or are you running a servlet written in jython?
I am running the code inside a jython servlet like this simple example:
python and jython graph use the exact same code. I have integrated the service inside wsgiref.simple_server (http://docs.python.org/library/wsgiref.html)
To get the time, I wrote a simple python script using time.time that calls each servers (jython/pthon/tomcat) sequentially and store the results (a simple wget).
Does that help? Write now, I don't have any real hypothesis to try to validate except that servlet may re-compile to bytecode all python code at each calls, only profiling could give me hints but I rather do a theoretical analysis first before jumping there.
> I have integrate a jython2.5.1 service inside a java servlet (tomcat) andIt's very difficult to tell what might be the cause of these timing
> compared the performance to a std wsgi server.
> Take a look at this graph: (same service)
> Any idea why I get so bad performance? Is there a settings I should set? Is
> this a cachedir issue?
> I am not sure what to look at to get acceptable performances.
differences without knowing what code is running.
How are you running the code inside Tomcat? Are you using modjy, the
WSGI gateway? Or are you running a servlet written in jython?
For the curve labelled "jython" in your graph, what WSGI server are
you using for that? Did you use the same WSGI server for your cpython