mirror of
https://github.com/smallnest/rpcx.git
synced 2025-10-15 12:42:16 +08:00
[+]优雅关机
This commit is contained in:
@@ -29,7 +29,12 @@ func (t *Arith) Mul(ctx context.Context, args *Args, reply *Reply) error {
|
||||
}
|
||||
|
||||
func (t *Arith) ThriftMul(ctx context.Context, args *testutils.ThriftArgs_, reply *testutils.ThriftReply) error {
|
||||
reply.C = args.A * args.B + 11111111
|
||||
reply.C = args.A * args.B
|
||||
return nil
|
||||
}
|
||||
|
||||
func (t *Arith) ConsumingOperation(ctx context.Context, args *testutils.ThriftArgs_, reply *testutils.ThriftReply) error {
|
||||
reply.C = args.A * args.B
|
||||
time.Sleep(10*time.Second)
|
||||
return nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user