forked from TrueCloudLab/frostfs-node
[#1048] control: Add ListShards
RPC wrappers
Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
parent
a6b3e16975
commit
f88a12eaa7
2 changed files with 41 additions and 0 deletions
|
@ -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
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue