me too. The default webserver is not - usually - meant for production 
anyway. I started the test with the idea "let's see if tornado on windows 
(i.e. without all the goodies of select/epoll) can be at least comparable 
with a threaded server".

PS: cherrypy (and rocket) uses a separate thread for every request. If I 
got that part right, limiting the threadpool to max 1 means that no 
concurrency at all is achieved. Unfortunately, it seems that I missed a 
step. Limiting using

server = wsgiserver.CherryPyWSGIServer(address, app, numthreads=1, max=1)

seems to raise rps to 68.93. 99% of the requests are served in 3078 ms.

server = wsgiserver.CherryPyWSGIServer(address, app, numthreads=10, max=20)

stops to rps 14.95 while the 99% of the requests are served in 8034 ms.

If someone can explain this to me I'll be glad to offer him a beer if he 
passes nearby Milan.
 

> I guess cherrypy spawns some threads, right? To be fair can you 
> ajust to use only one thread/process to match tornado. 
> I think you will see some improvements in cherrypy rps in this 
> particular bench, since the OS/Python threads switching contexts is 
> avoided. 
>
> I think web2py should not choose a webserver only in terms of speed, 
> but should focus on the simplest, complete and pure python webserver, 
> My 2 cents. 
>
> Ricardo 
>

-- 



Reply via email to