rpc/client/client_handler.go

22 lines
348 B
Go
Raw Normal View History

2017-10-31 18:25:44 +09:00
package client
import (
2017-11-01 12:40:26 +09:00
"net"
2017-10-31 18:25:44 +09:00
"time"
"git.loafle.net/commons_go/rpc"
"git.loafle.net/commons_go/rpc/protocol"
)
type ClientHandler interface {
2017-11-01 12:40:26 +09:00
Connect() (net.Conn, error)
2017-10-31 18:25:44 +09:00
GetCodec() protocol.ClientCodec
2017-11-01 12:10:39 +09:00
2017-10-31 18:25:44 +09:00
GetRPCRegistry() rpc.Registry
GetRequestTimeout() time.Duration
GetPendingRequests() int
GetRequestID() interface{}
Validate()
}