[#1086] services/control: implement RestoreShard RPC

Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
Evgenii Stratonikov 2022-01-25 14:54:35 +03:00 committed by Alex Vanin
parent 2ec4a3c897
commit 18cfd8b042
8 changed files with 763 additions and 122 deletions

View file

@ -28,6 +28,9 @@ service ControlService {
// Dump objects from the shard.
rpc DumpShard (DumpShardRequest) returns (DumpShardResponse);
// Restore objects from dump.
rpc RestoreShard (RestoreShardRequest) returns (RestoreShardResponse);
}
// Health check request.
@ -238,3 +241,38 @@ message DumpShardResponse {
// Body signature.
Signature signature = 2;
}
// RestoreShard request.
message RestoreShardRequest {
// Request body structure.
message Body {
// ID of the shard.
bytes shard_ID = 1;
// Path to the output.
string filepath = 2;
// Flag indicating whether object read errors should be ignored.
bool ignore_errors = 3;
}
// Body of restore shard request message.
Body body = 1;
// Body signature.
Signature signature = 2;
}
// RestoreShard response.
message RestoreShardResponse {
// Response body structure.
message Body {
}
// Body of restore shard response message.
Body body = 1;
// Body signature.
Signature signature = 2;
}