Re: Only the first part is availble in the upload result of "Resumable Uploads of Unknown Size"

57 views
Skip to first unread message

Scherring Chong

unread,
Feb 27, 2013, 10:52:52 PM2/27/13
to gs-dis...@googlegroups.com
Anyone can give me some hints?

I think the key point is, why the HTTP response code is 200 instead of 308 (as
specified in your site)? It is enought to set

Content-Length: 524288
Content-Range: bytes 0-524287/*

in the header, for a "resumable upload of unknown size"? Anything else I have
to take into account also?

Thanks!



Scherring Chong於 2013年2月27日星期三UTC+8上午10時49分58秒寫道:
Hi,

I am trying to use the function "Resumable Uploads of Unknown Size" provided
by Google Cloud Storage as specified in

https://developers.google.com/storage/docs/developer-guide#unknownresumables

with Java. Up to Step 2 is OK. I can obtain the "upload_id" with HTTP response
code 201. However, when I tried to start the upload with the header as stated
(with a 512K buffer):

Content-Length: 524288
Content-Range: bytes 0-524287/*

together with the given "upload_id". The 1st attempted is successful, with a
HTTP response code 200 (instead of that stated to be 308). And then, for the
subsequence upload of the remaining parts, I have obtained code 200 too.
Finally, the process seems completed, however, when I check the upload result,
only the first part of 512K appeared.  All the others are missing. 

My test with a buffer 256K buffer shown similar result.

Would you mind to give me some hints on the problem?

Thanks a lot!



Scherring Chong

unread,
Mar 1, 2013, 4:44:59 AM3/1/13
to gs-dis...@googlegroups.com
Finally, I have located the caused. As I am using "jet3t" Java tool kits to
connect to Google Cloud Storage, the package has prefixed all those names of
metadata, part from those well known, with "x-goog-meta-", which make the
server cannot correctly interprete the message.

Thanks.
Reply all
Reply to author
Forward
0 new messages