Hi Loïc, I'm not sure what you're saying, could you give an example?
-Jason On 14:19 Mon 17 Sep , Loic d'Anterroches wrote: > Hello, > > short question. Why not directly "breaking" the wire level protocol and > get in the payload from and to the handlers an extra tnetstring (or json > from Mongrel2) part with additional metadata? > > This would allow any kind of communication between the M2 and the handlers. > > loïc > > On 2012-09-15 03:28, Jason Miller wrote: > > In the developo branch of my fork (https://github.com/jasom) I've > > created a new type of plugin system for handling replies from handlers. > > Included is a simple "sendfile" type implementation > > (tools/filters/sendfile.c). You can add it to a server similarly to how > > you do a Filter: > > > > sendfile=Xrequest(name="tools/filters/sendfile.so",settings={}) > > > > main = Server( > > ... > > xrequests=[sendfile], > > ... > > ) > > > > Before pulling this into the main repository I thought I'd ask for any > > comments about it. If you want to test the sendfile plugin you can do > > that as well. There is an example of how to do that in > > examples/http_0mq/sendfile.py; As you can see the extended request > > format is just like a normal handler deliver, except the first ID is "X" > > instead of a number. The payload must be a tnetstring, and can be > > anything serializable in tnetstrings, whic would allow e.g. sending > > dictionaries for doing fancy stuff in plugins. > > > > -Jason > > > > -- > Dr Loïc d'Anterroches > Founder Céondo Ltd > > w: www.ceondo.com | e: [email protected] > t: +44 (0)207 183 0016 | f: +44 (0)207 183 0124 > > Céondo Ltd > Dalton House > 60 Windsor Avenue > London > SW19 2RR / United Kingdom
