-
Notifications
You must be signed in to change notification settings - Fork 29
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
Add optional path to ResourceId #125
Conversation
This is needed to implement a storage space concept where we can address resources through storage spaces directly.
👍 Needed for a clean solution in https://github.com/cs3org/reva/pull/1678/files#diff-89d1b854d47bbe9ff8ea47ca239fe5062e62bacc5adac34d00b7db5308353456R156-R168 |
More information about this idea: https://owncloud.dev/extensions/storage/terminology/#alternative-reference-triple- |
could you run |
@dragotin please generate the docs in this PR as well. This change allows for Dropbox-like path resolution: https://www.dropbox.com/developers/documentation/http/documentation Path formats Every file and folder in Dropbox also has an ID (e.g. "id:abc123xyz") that can be obtained from any endpoint that returns metadata. These IDs are case-sensitive, so they should always be stored with their case preserved, and always compared in a case-sensitive manner. Some endpoints, as noted in the individual endpoint documentation below, can accept IDs in addition to normal paths. A path relative to a folder's ID can be constructed by using a slash (e.g. "id:abc123xyz/hello.txt"). |
@labkode @ishank011 @dragotin @C0rby @refs should we be a little more radical and get rid of the
The space_id really should be a uuid, but to remain backwards compatible (also for migration purposes) I suggest using a storage_provider_id and an opaque_id, which would allow using the same routing as we use today: either space id based or path based. We should not transport the space_id in the root_id, because then the root_id would carry two different meanings:
In 1. the root_id is used by the storage provider to determine the storage space. root_id cannot be used to reference a node. references would have to use paths relative to the storage space root, leaking path segments. I tried to clarify this by giving the Thoughts? |
Documentation is updated. |
@butonic I'd prefer the approach in #126 to this, but I'm not sure I understand your explanation.
Do you mean that space_id can also have the syntax
Why not? So the root ID and opaque ID for the same container are different? In my understanding, if I need to access via the old opaque ID, my The idea of exposing both the old resource ID and path in the reference makes sense to me but I don't fully understand your comments. Can we have a discussion regarding this? To unblock your development, you can generate the go bindings using |
Yes, #126 would be awesome!
yes, but with
Think of So why call the id property I hope that clarifies why I think having a
I'd love to!
#126 would require more changes, yes. We can work towards implmenting them using a temporary branch. Will dig into that tomorrow. |
superseded by #130 |
Superseded by other PR |
This is needed to implement a storage space concept where we can address resources through storage spaces directly.