forked from TrueCloudLab/frostfs-node
[#1086] services/control: implement DumpShard
RPC
Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
parent
aa53418119
commit
0e60b1d6c9
9 changed files with 783 additions and 141 deletions
|
@ -14,6 +14,7 @@ const (
|
|||
rpcDropObjects = "DropObjects"
|
||||
rpcListShards = "ListShards"
|
||||
rpcSetShardMode = "SetShardMode"
|
||||
rpcDumpShard = "DumpShard"
|
||||
)
|
||||
|
||||
// HealthCheck executes ControlService.HealthCheck RPC.
|
||||
|
@ -144,3 +145,16 @@ func SetShardMode(
|
|||
|
||||
return wResp.m, nil
|
||||
}
|
||||
|
||||
// DumpShard executes ControlService.DumpShard RPC.
|
||||
func DumpShard(cli *client.Client, req *DumpShardRequest, opts ...client.CallOption) (*DumpShardResponse, error) {
|
||||
wResp := new(dumpShardResponseWrapper)
|
||||
wReq := &requestWrapper{m: req}
|
||||
|
||||
err := client.SendUnary(cli, common.CallMethodInfoUnary(serviceName, rpcDumpShard), wReq, wResp, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return wResp.DumpShardResponse, nil
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue