storage: support resumable uploads

RE: #298

It works!

It's 200 lines, but it works!