Hi, Help me wrap my head around async implementation in uwsgi. I come from perl world and use psgi, coroae and really enjoy uwsgi. Great thing you wrote.
My problem is that Coro is an overkill for me as my programs mostly AnyEvent (AE) based and I don't use coroutines to full power. Also, we have problems restarting uwsgi as Coro seg faults during perl's global destruction in our setup. In recently written service this cause a lot of pain as our worker spawns a child and due to seg fault has no chance to cleanup the child, what prevents uwsgi to start again. I wonder if it's possible to get rid of Coro and implement a plugin that would allow us to write async psgi applications using AnyEvent. Spent some time in uwsgi's code and from what I can see uwsgi's async implementation is a combination of co-routines and event loop. async option allocates N "cores" within a worker to handle N requests simultaneously. uGreen (co-routines) plugin implements uwsgi's context switches between these N "cores" by providing operations to suspend/resume a "core". uGreen also calls suspend/resume hooks in the request handler plugin if provided, in my case it would probably be psgi plugin or my custom. Open question: * can I write such plugin that works without co-routines in perl world? * how does event loop fits into uwsgi's async world? -- Руслан Закиров Руководитель отдела разработки веб-сервисов +7(916) 597-92-69, ruz @ <http://www.sports.ru/>
_______________________________________________ uWSGI mailing list uWSGI@lists.unbit.it http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi