Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSami Hiltunen <shiltunen@gitlab.com>2020-07-23 15:18:59 +0300
committerSami Hiltunen <shiltunen@gitlab.com>2020-07-28 10:18:34 +0300
commitd96e4c796ca6a184e514471c935a75610cca8353 (patch)
treebd109118a93c014178820222a616d14c83eabd02 /proto/praefect.proto
parent4bb38a198255d9b898763eedfd64508b72af7b3b (diff)
add accept-dataloss sub-command
Adds 'accept-dataloss' sub-command which allows designating a new authoritative storage for a repository. This might be necessary if a repository is in read-only mode and recovering the data is not viable. The current version of the repository on the authoritative storage is considered latest and versions on the other physical storages will be overwritten with it.
Diffstat (limited to 'proto/praefect.proto')
-rw-r--r--proto/praefect.proto19
1 files changed, 18 insertions, 1 deletions
diff --git a/proto/praefect.proto b/proto/praefect.proto
index 468642c53..22c2d61b7 100644
--- a/proto/praefect.proto
+++ b/proto/praefect.proto
@@ -6,7 +6,6 @@ option go_package = "gitlab.com/gitlab-org/gitaly/proto/go/gitalypb";
import "lint.proto";
import "shared.proto";
-import "google/protobuf/timestamp.proto";
service PraefectInfoService {
rpc RepositoryReplicas(RepositoryReplicasRequest) returns (RepositoryReplicasResponse) {
@@ -43,8 +42,26 @@ service PraefectInfoService {
scope_level: STORAGE
};
}
+
+ // SetAuthoritativeStorage sets the authoritative storage for a repository on a given virtual storage.
+ // This causes the current version of the repository on the authoritative storage to be considered the
+ // latest and overwrite any other version on the virtual storage.
+ rpc SetAuthoritativeStorage(SetAuthoritativeStorageRequest) returns (SetAuthoritativeStorageResponse) {
+ option (op_type) = {
+ op: MUTATOR
+ scope_level: STORAGE
+ };
+ }
}
+message SetAuthoritativeStorageRequest {
+ string virtual_storage = 1 [(storage)=true];
+ string relative_path = 2;
+ string authoritative_storage = 3;
+}
+
+message SetAuthoritativeStorageResponse {}
+
message EnableWritesRequest {
// virtual_storage is the name of the virtual storage to enable writes for.
string virtual_storage = 1 [(storage)=true];