Skip to content

Commit

Permalink
storage provider: add CreateSymlink (#89)
Browse files Browse the repository at this point in the history
Signed-off-by: Jörn Friedrich Dreyer <[email protected]>
  • Loading branch information
butonic authored Sep 3, 2020
1 parent 8856bcd commit 174dfb6
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cs3/gateway/v1beta1/gateway_api.proto
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,8 @@ service GatewayAPI {
// Returns the resource information at the provided reference.
// MUST return CODE_NOT_FOUND if the reference does not exist.
rpc Stat(cs3.storage.provider.v1beta1.StatRequest) returns (cs3.storage.provider.v1beta1.StatResponse);
// Creates a symlink to another resource.
rpc CreateSymlink(cs3.storage.provider.v1beta1.CreateSymlinkRequest) returns (cs3.storage.provider.v1beta1.CreateSymlinkResponse);
// Sets arbitrary metadata into a storage resource.
// Arbitrary metadata is returned in a cs3.storage.provider.v1beta1.ResourceInfo.
rpc SetArbitraryMetadata(cs3.storage.provider.v1beta1.SetArbitraryMetadataRequest) returns (cs3.storage.provider.v1beta1.SetArbitraryMetadataResponse);
Expand Down
23 changes: 23 additions & 0 deletions cs3/storage/provider/v1beta1/provider_api.proto
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,8 @@ service ProviderAPI {
// MUST return CODE_NOT_FOUND if the reference does not exist.
// MUST return CODE_PRECONDITION_FAILED if the acl does not exist.
rpc UpdateGrant(UpdateGrantRequest) returns (UpdateGrantResponse);
// Creates a symlink to another resource.
rpc CreateSymlink(CreateSymlinkRequest) returns (CreateSymlinkResponse);
// Creates a reference to another resource in the same cluster or another domain (OCM shares).
// The references resource can be accessed by the protocol specificied in the request message.
rpc CreateReference(CreateReferenceRequest) returns (CreateReferenceResponse);
Expand Down Expand Up @@ -623,6 +625,27 @@ message UpdateGrantResponse {
cs3.types.v1beta1.Opaque opaque = 2;
}

message CreateSymlinkRequest {
// OPTIONAL.
// Opaque information.
cs3.types.v1beta1.Opaque opaque = 1;
// REQUIRED.
// The location where to store the symlink.
string path = 2;
// REQUIRED.
// The link target can hold arbitrary text; if later resolved,
// a relative link is interpreted in relation to its parent directory
string target = 3;
}

message CreateSymlinkResponse {
// REQUIRED.
// The response status.
cs3.rpc.v1beta1.Status status = 1;
// OPTIONAL.
// Opaque information.
cs3.types.v1beta1.Opaque opaque = 2;
}
message CreateReferenceRequest {
// OPTIONAL.
// Opaque information.
Expand Down

0 comments on commit 174dfb6

Please sign in to comment.