-
Notifications
You must be signed in to change notification settings - Fork 103
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
How to properly use Content-Type #43
Comments
@evert wrote:
Thanks, now I understand you. A server supporting both upload protocols is an interesting idea and I see how Content-Type can be used to achieve that. I'm having a hard time coming up with a use case for this, especially today, when most servers support no resumable upload at all, but this doesn't mean it's invalid. So now I'll just think out loud. The way I see tus being used is via file-creation end point. In the response clients get a dedicated resource to represent the upload session, and this is tus and session specific. The end point where File Creation requests are sent could support several protocols... but it also allows no content at all, so Content-Type is useless there, at least for tus, isn't it? Actually, Content-Type in File-Creation is used already, assuming we'll send metadata in the payload, as we currently plan to. Hm. So to use Content-Type to differentiate between protocols an implementation would need to allow several protocols to be used while uploading a single file. This means a single client talking with a single server would want to change the protocol during the upload. Can you guys think of examples when this would be useful? Hm. Maybe one file could actually be uploaded by several clients running different protocols?
I think this is too complex in the sense that it makes all implementations slightly harder, while providing no value in most (?) cases. But at the same time, I'm interested in exploring the possibilities. I wouldn't want to standardize things too soon, unless ignoring them prevents doing anything in the future. In other words, as soon as I understand this can be done later, I'll be convinced it should wait for someone with a real-life use case that we can study. |
This seems to be a good plan. The upload URL should be tus specific. If you have multiple different upload protocols you could use different endpoints, e.g.
In my opinion that's not something we need to discuss about now. |
+1 |
This is a continuation of a discussion from issue #14. I created a new issue because it's a completely different subject. But you should read the posts there too.
The topic here is: should the protocol specify Content-Type of valid requests, and if so, what for and what types to use?
The text was updated successfully, but these errors were encountered: