Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Core] There's no way to find out if transfer is completed on server side #37

Closed
lleoha opened this issue Jul 9, 2014 · 1 comment
Closed
Labels

Comments

@lleoha
Copy link

lleoha commented Jul 9, 2014

Let's look at this:

"Clients SHOULD send all remaining bytes of a resource in a single PATCH request, but MAY also use multiple small requests for scenarios where this is desirable"

So how the server is going to know if transfer is completed since it doesn't know how many subsequent patch requests are going to be sent?
It looks like the only way to find out if file is completely transferred is to use POST file creation extension and keep expected file size somewhere.

I think file size to be uploaded should be in the core protocol, since file creation is not specified in the core and does't have to be implemented the way of POST extension. Each PATCH request should be "self-supporting" and should include what is the final file size (especially giving the fact that client knows what the file size is).

@Acconut
Copy link
Member

Acconut commented Dec 3, 2014

It looks like the only way to find out if file is completely transferred is to use POST file creation extension and keep expected file size somewhere

That's how the current tusd implementation works.

Forcing the client to specify a fixed size at the beginning would conflict with streaming uploads of a variable size (see #16).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants