frostfs-api/session/service.proto
Leonard Lyubich 40420f3ab0 [#31] refs: Use OwnerID message in all services
Change the type of all fields for identifier of the container owner to
refs.OwnerID. This will allow you to follow a single format and not duplicate
its description.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2020-08-06 22:00:01 +03:00

40 lines
1.5 KiB
Protocol Buffer

syntax = "proto3";
package session;
option go_package = "github.com/nspcc-dev/neofs-api-go/session";
option csharp_namespace = "NeoFS.API.Session";
import "service/meta.proto";
import "service/verify.proto";
import "refs/types.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
option (gogoproto.stable_marshaler_all) = true;
service Session {
// Create opens new session between the client and the server
rpc Create (CreateRequest) returns (CreateResponse);
}
// CreateRequest carries an information necessary for opening a session
message CreateRequest {
// OwnerID carries an identifier of a session initiator.
refs.OwnerID OwnerID = 1;
// Lifetime carries a lifetime of the session
service.TokenLifetime Lifetime = 2 [(gogoproto.embed) = true, (gogoproto.nullable) = false];
// RequestMetaHeader contains information about request meta headers (should be embedded into message)
service.RequestMetaHeader Meta = 98 [(gogoproto.embed) = true, (gogoproto.nullable) = false];
// RequestVerificationHeader is a set of signatures of every NeoFS Node that processed request (should be embedded into message)
service.RequestVerificationHeader Verify = 99 [(gogoproto.embed) = true, (gogoproto.nullable) = false];
}
// CreateResponse carries an information about the opened session
message CreateResponse {
// ID carries an identifier of session token
bytes ID = 1 [(gogoproto.customtype) = "TokenID", (gogoproto.nullable) = false];
// SessionKey carries a session public key
bytes SessionKey = 2;
}