ing
This commit is contained in:
parent
8e43174376
commit
f3709ed461
|
@ -10,7 +10,7 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
type ServerHandlers struct {
|
type ServerHandlers struct {
|
||||||
Registry rpc.Registry
|
RPCRegistry rpc.Registry
|
||||||
|
|
||||||
codecs map[string]protocol.ServerCodec
|
codecs map[string]protocol.ServerCodec
|
||||||
}
|
}
|
||||||
|
@ -56,8 +56,8 @@ func (sh *ServerHandlers) OnPostWriteError(w io.Writer, err error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (sh *ServerHandlers) Validate() {
|
func (sh *ServerHandlers) Validate() {
|
||||||
if nil == sh.Registry {
|
if nil == sh.RPCRegistry {
|
||||||
panic("Registry(RPCRegistry) must be specified.")
|
panic("RPCRegistry must be specified.")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -77,5 +77,5 @@ func (sh *ServerHandlers) getCodec(contentType string) (protocol.ServerCodec, er
|
||||||
}
|
}
|
||||||
|
|
||||||
func (sh *ServerHandlers) invoke(codec protocol.RegistryCodec) (result interface{}, err error) {
|
func (sh *ServerHandlers) invoke(codec protocol.RegistryCodec) (result interface{}, err error) {
|
||||||
return sh.Registry.Invoke(codec)
|
return sh.RPCRegistry.Invoke(codec)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user