mirror of
https://github.com/duanhf2012/origin.git
synced 2026-04-10 01:37:29 +08:00
优化rpc错误返回
This commit is contained in:
@@ -81,12 +81,10 @@ func (server *Server) Start(listenAddr string) {
|
||||
|
||||
func (agent *RpcAgent) OnDestroy() {}
|
||||
|
||||
func (agent *RpcAgent) WriteResponse(processor IRpcProcessor,serviceMethod string,seq uint64,reply interface{},err RpcError) {
|
||||
func (agent *RpcAgent) WriteResponse(processor IRpcProcessor,serviceMethod string,seq uint64,reply interface{},rpcError RpcError) {
|
||||
var mReply []byte
|
||||
var rpcError RpcError
|
||||
var errM error
|
||||
|
||||
|
||||
if reply!=nil {
|
||||
mReply,errM = processor.Marshal(reply)
|
||||
if errM != nil {
|
||||
|
||||
Reference in New Issue
Block a user