[#1048] control: Add ListShards RPC wrappers

Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
Pavel Karpy 2021-12-17 18:23:46 +03:00 committed by Alex Vanin
parent a6b3e16975
commit f88a12eaa7
2 changed files with 41 additions and 0 deletions

View file

@ -92,3 +92,22 @@ func (w *dropObjectsResponseWrapper) FromGRPCMessage(m grpc.Message) error {
return nil
}
type listShardsRequestWrapper struct {
m *ListShardsResponse
}
func (w *listShardsRequestWrapper) ToGRPCMessage() grpc.Message {
return w.m
}
func (w *listShardsRequestWrapper) FromGRPCMessage(m grpc.Message) error {
var ok bool
w.m, ok = m.(*ListShardsResponse)
if !ok {
return message.NewUnexpectedMessageType(m, w.m)
}
return nil
}