Skip to content

Commit

Permalink
feat: Allows to create sessions in sessions service (#384)
Browse files Browse the repository at this point in the history
  • Loading branch information
lemaitre-aneo authored Aug 17, 2023
2 parents e729a48 + fd38572 commit 5e55f4b
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
17 changes: 17 additions & 0 deletions Protos/V1/sessions_common.proto
Original file line number Diff line number Diff line change
Expand Up @@ -105,3 +105,20 @@ message CancelSessionRequest {
message CancelSessionResponse {
SessionRaw session = 1; /** The session. */
}

/**
* Request for creating session.
*/
message CreateSessionRequest {
TaskOptions default_task_option = 1; /** Default tasks options for tasks in the session */
repeated string partition_ids = 2; /** List of partitions allowed during the session */
}

/*
Reply after session creation.
We have this reply in case of success.
When the session creation is not successful, there is an rpc exception.
*/
message CreateSessionReply {
string session_id = 1; /** Session id of the created session if successful */
}
5 changes: 5 additions & 0 deletions Protos/V1/sessions_service.proto
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,9 @@ service Sessions {
* Cancel a session by its id.
*/
rpc CancelSession(CancelSessionRequest) returns (CancelSessionResponse) {}

/**
* Create a session
*/
rpc CreateSession(CreateSessionRequest) returns (CreateSessionReply);
}

0 comments on commit 5e55f4b

Please sign in to comment.