yet another mongrel2 => wsgi gateway
- From:
- Ryan Kelly
- Date:
- 2011-01-27 @ 23:30
Hi All,
I'm finally happy enough with my mongrel2-to-WSGI gateway to announce
it on this list. Code here:
https://github.com/rfk/m2wsgi
Fun things that you might not find in similar packages:
* full support for chunked response encoding
* streaming reads of large "async upload" requests
* pluggable IO backends (currently threads, eventlet and gevent)
There's also an experimental alternate protocol for getting requests
out of Mongrel2, using a XREQ socket rather than a PULL socket. I've
been using it to explore the issues kicked around in my earlier "safely
shut down a handler" thread. See m2wsgi/devices/pull2xreq.py for
details.
Cheers,
Ryan
--
Ryan Kelly
http://www.rfk.id.au | This message is digitally signed. Please visit
ryan@rfk.id.au | http://www.rfk.id.au/ramblings/gpg/ for details
Re: [mongrel2] yet another mongrel2 => wsgi gateway
- From:
- Loic d'Anterroches
- Date:
- 2011-01-28 @ 07:51
Hello,
> I'm finally happy enough with my mongrel2-to-WSGI gateway to announce
> it on this list. Code here:
>
> https://github.com/rfk/m2wsgi
>
>
> Fun things that you might not find in similar packages:
>
> * full support for chunked response encoding
> * streaming reads of large "async upload" requests
> * pluggable IO backends (currently threads, eventlet and gevent)
>
> There's also an experimental alternate protocol for getting requests
> out of Mongrel2, using a XREQ socket rather than a PULL socket. I've
> been using it to explore the issues kicked around in my earlier "safely
> shut down a handler" thread. See m2wsgi/devices/pull2xreq.py for
> details.
This is really why I think that the choice of zmq as transport for
Mongrel2 is genius (a bit like % for sprintf in Python). The protocol is
very simple and you can as you wish adapt and extend it to fit your needs.
loïc