Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions cs3/gateway/v1beta1/gateway_api.proto
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,15 @@ service GatewayAPI {
// WhoAmI returns the information for a user.
rpc WhoAmI(WhoAmIRequest) returns (WhoAmIResponse);
// *****************************************************************/
// **************************** EVENTS *****************************/
// *****************************************************************/

// Sends an event for asynchronous processing.
// The gateway MUST derive the sender and submitting user from the
// authenticated request context and SHOULD rate-limit this call per submitting
// user.
rpc PublishEvent(PublishEventRequest) returns (PublishEventResponse);
// *****************************************************************/
// ********************** APPLICATIONS AUTH ************************/
// *****************************************************************/

Expand Down Expand Up @@ -527,6 +536,28 @@ message WhoAmIResponse {
cs3.identity.user.v1beta1.User user = 3;
}

message PublishEventRequest {
// OPTIONAL.
// Opaque information.
cs3.types.v1beta1.Opaque opaque = 1;
// REQUIRED.
// The event to process. The gateway derives the sender and submitting
// user from the authenticated request context; callers MUST NOT supply them.
Event event = 2;
}

message PublishEventResponse {
// REQUIRED.
// The response status.
cs3.rpc.v1beta1.Status status = 1;
// OPTIONAL.
// Opaque information.
cs3.types.v1beta1.Opaque opaque = 2;
// OPTIONAL.
// Server-assigned event id, if the implementation returns one.
string event_id = 3;
}

message GetQuotaRequest {
// OPTIONAL.
// Opaque information.
Expand Down
11 changes: 11 additions & 0 deletions cs3/gateway/v1beta1/resources.proto
Original file line number Diff line number Diff line change
Expand Up @@ -134,3 +134,14 @@ message OCMShareResourceInfo {
// The corresponding resource information as returned by the storage provider.
cs3.storage.provider.v1beta1.ResourceInfo resource_info = 3;
}

// Event describes an event submitted through the gateway for
// asynchronous processing.
message Event {
// REQUIRED.
// The event type, for example "upload" or "share-creation".
string type = 1;
// OPTIONAL.
// Event-specific payload used by event rules and handlers.
cs3.types.v1beta1.Opaque data = 2;
}
Loading