[MERGE] Add call_with_body_stream to _SmartClient; add support for streamed request bodies to the server.
andrew.bennetts at canonical.com
Mon Jan 12 04:47:20 GMT 2009
This patch adds support for streamed request bodies to the smart client
and server. It was always a planned part of the protocol so it
shouldn't cause any trouble for earlier servers; they'll just reject
those requests with no fuss (and no disconnections required).
The API on the client is that you can pass an iterable to
_SmartClient.call_with_body_stream. The iterable should produce
The API on the server is that a class implementing an RPC may override
do_chunk to receive body bytes as they arrive. Or, as before, they may
leave the default implementation of do_chunk untouched and just
implement do_body to receive the entire body as a single string.
There are a few parts of this patch related to tuples and bencode that
are superceded by
Those parts are basically tangential to this patch anyway.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 35983 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20090112/549a7561/attachment-0001.bin
More information about the bazaar