[Eventmachine-talk] DistribuStream released

Tony Arcieri
Sat, 27 Oct 2007 02:39:52 -0000

On 10/26/07, Francis Cianfrocca <garbagecat10 at gmail.com>
wrote:
>
> HttpClient is functional and useful, but a bit of a throwaway, not
> designed very carefully. I''ll try to hack the chunked-transfer
support into
> it, but it could use a rethink. Anyone up for it?
>

#send_request is the biggest problem (and the method I overwrite).  The main
thing that''s needed, IMO, are objects which represent requests and
responses.  #send_request is pretty imperative and difficult to extend, so
in DistribuStream I ended up overriding the entire thing, when really all I
wanted to do was patch in a few additional types of headers.

Look at eventmachine_httpserver: this is actually a well-designed
and
> powerful piece of code.
>

I''ll certainly take a look at it, but since all the existing code uses
Mongrel the simplest way to go would be Kirk''s evented_mongrel.
However if
I can''t find a way to consume a PUT request''s body seperately
of the header
with evented_mongrel I''ll probably end up rewriting the HTTP server
components with eventmachine_httpserver.  It looks like it could use objects
which represent requests and responses as well, though.

Tony Arcieri
ClickCaster, Inc.
tony at clickcaster.com
-------------- next part --------------
An HTML attachment was scrubbed...