forked from TrueCloudLab/frostfs-api-go
[#265] v2/rpc: Add SendIntermediateResult RPC
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
35567afd11
commit
710d1994a4
1 changed files with 18 additions and 1 deletions
|
@ -9,7 +9,8 @@ import (
|
||||||
const serviceReputation = serviceNamePrefix + "reputation.ReputationService"
|
const serviceReputation = serviceNamePrefix + "reputation.ReputationService"
|
||||||
|
|
||||||
const (
|
const (
|
||||||
rpcReputationSendLocalTrust = "SendLocalTrust"
|
rpcReputationSendLocalTrust = "SendLocalTrust"
|
||||||
|
rpcReputationSendIntermediateResult = "SendIntermediateResult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// SendLocalTrust executes ReputationService.SendLocalTrust RPC.
|
// SendLocalTrust executes ReputationService.SendLocalTrust RPC.
|
||||||
|
@ -27,3 +28,19 @@ func SendLocalTrust(
|
||||||
|
|
||||||
return resp, nil
|
return resp, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// SendIntermediateResult executes ReputationService.SendIntermediateResult RPC.
|
||||||
|
func SendIntermediateResult(
|
||||||
|
cli *client.Client,
|
||||||
|
req *reputation.SendIntermediateResultRequest,
|
||||||
|
opts ...client.CallOption,
|
||||||
|
) (*reputation.SendIntermediateResultRequest, error) {
|
||||||
|
resp := new(reputation.SendIntermediateResultRequest)
|
||||||
|
|
||||||
|
err := client.SendUnary(cli, common.CallMethodInfoUnary(serviceReputation, rpcReputationSendIntermediateResult), req, resp, opts...)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
return resp, nil
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue