-
Notifications
You must be signed in to change notification settings - Fork 149
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
Resumable Uploads: application/partial-upload
media type
#2743
Conversation
# Media Type `application/partial-upload` | ||
|
||
The `application/partial-upload` media type describes a contiguous block of data that should be uploaded to a resource. There is no minimum size on the block of data and it might be empty. The start and end of block of data might align with the start and end of the file that should be uploaded, but are not required to do so. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor nit:
The start and end of THE block of data might align with the start and end of the file that should be uploaded, but are not required to do so.
or
The start and end of THE data might align with the start and end of the file that should be uploaded, but are not required to do so.
Should we avoid using "file" as the thing to be uploaded and use something more generic like "resource that should be uploaded"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right with the missing the.
Regarding file/resource: I am also struggling with the same question of what the call the thing that we want to upload. File might not be the best choice as it might be confused with a file that is saved on disk as seen from an operating system's point of view. With resumable uploads, you can also upload streaming data that is not such a file but is generated on-demand. Resource is also problematic as it has a special meaning in HTTP: https://httpwg.org/specs/rfc9110.html#resources
We could use the term file if we stat at the beginning of the document that it not only refers to files on disks, but all kinds of data sources (streaming or not).
#2743 made the use of `application/partial-upload` media type mandatory for appending to an upload. This warrants a new interop version.
As discussed in #2501 and #2610, the PATCH requests needs a suiting media type to describe the message content.
Since there does not seem to be an existing, suitable media type, we proposed the
application/partial-upload
media type on the media-types mailing list. This PR is a first, rough attempt at including such a media type in the draft.