[sheepdog] [PATCH v7 1/2] sheep/http: add range support for swift insterface
Liu Yuan
namei.unix at gmail.com
Wed Jan 22 04:45:25 CET 2014
On Tue, Jan 21, 2014 at 06:08:09PM +0800, Liu Yuan wrote:
> On Tue, Jan 21, 2014 at 05:54:14PM +0800, Robin Dong wrote:
> > From: Robin Dong <sanbai at taobao.com>
> >
> > In swift spec, "Range: bytes=13-15" in http header means "read the three bytes
> > of data after a 13-byte offset". We add this support by parsing http header and
> > read specific bytes in range.
> >
> > We don't support multi-ranges at present.
> >
> > Signed-off-by: Robin Dong <sanbai at taobao.com>
> > ---
> > v6-->v7:
> > 1. return error if 'offset' reachs out of object-size
> > 2. add test-case for offset bigger than object-size
>
> We should return "Requested Range Not Satisfiable" to end user of offset > size,
> internal error means server is probably donw or cruppted.
>
Applied after fixing the return error code for out of range get.
Thanks
Yuan
More information about the sheepdog
mailing list