-
Notifications
You must be signed in to change notification settings - Fork 340
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
Eliminate collections package, remove /files endpoint #1444
Labels
Comments
Closed
suggestion: first do openAPI spec and then communicate to Rinke / JS team |
Regarding the proposed solutions:
|
@acud Correct me if I am wrong
|
This was
linked to
pull requests
Apr 1, 2021
Completed sub-tasks:
In progress:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Task
The
collection
package needs to be deprecated as it proxies every manifest on Swarm. This is remnant of a period where we were pivoting around the approach we wanted to use for manifests.Right now, when a user uploads a directory or a file, the file(s) get processed with their arbitrary length content chunked and saved, yielding the content addressed hash for the content. Now, in order for us to know which type of file it is, so that browsers can correctly display the file, metadata is required, alongside with file names, directories, etc. This is used with the mantaray manifest, and is used in the
/dirs
endpoint (but not in the/files
, where only a metadata entry is used from the collections package).Arising from this change there are 2 problems:
/files
endpoint becomes unusable, since we need to add support to metadata in order to display the file correctlyThe solutions:
/files
endpoint should be removed, and either/bzz
or/dirs
endpoint should support single file uploads. This can be nicely handled. Right now,/dirs
needs anx-tar
content type to upload a directory. We can catch all"other"
content types and fall-back into a"single-file mode"
, resulting in a manifest generated with just a single entry and the necessary metadata and content addressed hash needed to retrieve.Acceptance criteria
/files
api removed/bzz
must accept single file upload/bzz
endpoint, create manifest, with a single entry with the reference and metadata, path should be emptyThe text was updated successfully, but these errors were encountered: