-
Notifications
You must be signed in to change notification settings - Fork 5
Expose TUS capabilities through capabilities API #177
Comments
Proposal for JSON structure, under
The capability key name is the same as the header, stripped of "Tus-" and lowercased. if we decide to also implement the "max chunk size" header as per tus/tus-resumable-upload-protocol#93, we should also include those in the capabilities. |
Yeah, needed for the middleware/proxy scenarios, and clients could immediately go for |
note that the recommended chunk size could also be different depending on the storage. |
yes, exactly |
Talking about middleware and proxies… this would also be a good place to instruct clients to send For example:
|
@felix-schwarz I mean real size limits, that clients can't detect. Independent which method. Nothing can be sent > 100 MB. See my comment in owncloud/product#19 (comment).
Or check traefik example: Clients need to know max-size before 1st upload. |
@michaelstingl I wasn't referring to size limits. Sorry if my comment lacked clarity and/or context here. What I meant is that
can also be sent as
in case
|
|
with the two above PRs, and using the go.mod approach, you can start the reva services after setting the env variables:
it will make it advertise the given max chunk size in the capabilities |
yeah, builds nicely 👍
Capabilities
@PVince81 is this correct? |
With environment variable set, it looks good:
Didn't test with remote setup, but don't expect trouble: |
@PVince81 Nice! Since I see |
max_chunk_size = 0 means default unlimited. Regarding http_method_override I'm not sure if we need to change something on the server. If you like you can have a try. If this applies to the data provider where we use PATCH, I believe this one is already connected to tusd so it might already support it. If not then need to schedule time to add explicit support there.
|
@michaelstingl I'm fine removing the max-chunk-size as we didn't finish the discussion about it. |
No problem with |
Suggestion:
FWIW the support for |
suggestion makes sense to me. also:
|
added option in reva to disable TUS support on OC layer: cs3org/reva#791 @felix-schwarz due to the way how the capabilities struct is created I cannot remove the "tus_support" attribute when disabled, so it will have the value "null" instead when TUS is disabled.. |
I just went ahead and added support for "X-HTTP-Method-Override" to reva:
to test, use: |
Phoenix PR for acting on the chunk size and method override capabilities: owncloud/web#3568 |
reva PRs merged, will need a reva update:
|
implementation done, need to update docs for the new values |
PR for updating the ocis-reva docs: #251 |
I'm not sure where to put this as it's more of a protocol thing, did we have any new location for protocol docs ? @butonic @micbar |
Additionally to the headers (Tus-Version, Tus-Resumable, Tus-Extension) that are specified in a response of a PROPFIND or HEAD on a folder, we should also expose the general support for TUS through the capabilities API, so that a client does not need to bother with TUS related logic if the server doesn't have TUS enabled at all.
@michaelstingl @butonic @felix-schwarz @TheOneRing
The text was updated successfully, but these errors were encountered: