On Thursday, January 14, 2016 at 6:55:10 PM UTC-5, Srikanth Bemineni wrote:
>
> from uwsgidecorators import postfork
>
> This is needed for initiating my cassandra connections on forking. 
> uwsgidecorator imports uwsgi, which will be only available when I run using 
> uwsgi. So when I start development from fresh checked out code. I need to 
> comment these lines. 
>

You can usually handle stuff like that where you have a `config` available, 
or use environment variables / a custom namespace.  then you conditionally 
do the imports and handle the atfork.

otherwise, i think you might get better performance by using waitress and 
manually starting/stopping a local uwsgi server when you want to test on 
that particular platform.

i do 99% of my testing on nginx->waitress, but can also toggle nginx->uwsgi 
for a few specific tests (such as the atfork stuff).

-- 
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/pylons-discuss.
For more options, visit https://groups.google.com/d/optout.

Reply via email to