From 2b35b41c4c7be1ceb59473bb9de0df143958cca2 Mon Sep 17 00:00:00 2001 From: Chris Goller Date: Wed, 28 Aug 2024 16:13:31 -0500 Subject: [PATCH] feat: add API to reset project cache This API will delete all cache and terminate all machines of a project. Signed-off-by: Chris Goller --- proto/depot/core/v1/project.proto | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/proto/depot/core/v1/project.proto b/proto/depot/core/v1/project.proto index ff7c15c..1463853 100644 --- a/proto/depot/core/v1/project.proto +++ b/proto/depot/core/v1/project.proto @@ -19,6 +19,9 @@ service ProjectService { // Delete a project rpc DeleteProject(DeleteProjectRequest) returns (DeleteProjectResponse) {} + // Reset a project will terminate all machines and delete all cached data. + rpc ResetProject(ResetProjectRequest) returns (ResetProjectResponse) {} + // List project's trust policies. rpc ListTrustPolicies(ListTrustPoliciesRequest) returns (ListTrustPoliciesResponse) {} @@ -95,6 +98,12 @@ message DeleteProjectRequest { message DeleteProjectResponse {} +message ResetProjectRequest { + string project_id = 1; +} + +message ResetProjectResponse {} + message CachePolicy { optional int64 keep_bytes = 1 [deprecated = true]; int32 keep_days = 2;