We run Pyramid via uwsgi, behind an OpenResty server (Nginx fork with 
embedded lua interpreter).  

IMHO the "best" stack is somewhat dependent on your application.  We have a 
large application and the forking model of uwsgi - combined with many of 
its management hooks - lets us aggressively leverage a lot of efficiencies 
via the copy-on-write memory behavior.  gunicorn was not nearly as 
performant for us with our core app, however it has been more performant on 
other apps.  We've run some smaller apps via waitress as a test, and forgot 
about it for months - it worked perfectly with no complaints.

Caddy is certainly a decent server - and has some of the best https 
termination and ssl certificate management in the field.  It has a built in 
ACME client, and can store provisioned certificates in the cloud, which 
simplifies a lot of devops in clustered environments.

I stay away from Apache and personally don't recommend it.  Nginx (and 
caddy) is far better with concurrent requests and throughput; they also 
have much lighter memory footprints. We can run a lot more uwsgi processes 
behind Nginx than any Apache deployment option - which means we can scale 
to more processes on a node before having to scale onto more nodes in a 
cluster.  In my experience, from a devops management and billing 
perspective, Apache tends to be much more expensive.

On Sunday, February 20, 2022 at 8:53:02 AM UTC-5 tfl...@gmail.com wrote:

> Hi,
> I've built a custom content management framework based on Pyramid; it's a 
> classic web application, based on ZODB and RelStorage with a PostgreSQL 
> backend, a Redis cache and an Elasticsearch index, and I'm actually looking 
> for the best production deployment option.
> Until now, I always used Apache with mod_wsgi, and I'm actually quite 
> happy with it, but I'd like to know if there is a better option with better 
> performance!
> In development mode, I already tried using "native" Waitress server, a 
> GUnicorn server, and I just tried using Pypy with Waitress or GUnicorn but 
> performances were quite "disappointing"!
>
> Any advice?
>
> Best regards,
> Thierry
> -- 
>   https://www.ulthar.net -- http://pyams.readthedocs.io
>

-- 
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to pylons-discuss+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pylons-discuss/0ef924de-ef7d-4152-bb70-b266f0a368c8n%40googlegroups.com.

Reply via email to