func NewServer(url *common.URL, handlers func(*invocation.RPCInvocation) protocol.RPCResult) *Server {
	//init
	initServer(url.Protocol)

	srvConf.SSLEnabled = url.GetParamBool(constant.SSL_ENABLED_KEY, false)

	s := &Server{
		conf:           *srvConf,
		addr:           url.Location,
		codec:          remoting.GetCodec(url.Protocol),
		requestHandler: handlers,
	}

	s.rpcHandler = NewRpcServerHandler(s.conf.SessionNumber, s.conf.sessionTimeout, s)

	return s
}
// NewServer create a new Server
NewServer create a new Server
// NewServer create a new Server
func NewServer(url *common.URL, handlers func(*invocation.RPCInvocation) protocol.RPCResult) *Server {
	initServer(url.Protocol)
	srvConf.SSLEnabled = url.GetParamBool(constant.SSL_ENABLED_KEY, false)
	s := &Server{
		conf:           *srvConf,
		addr:           url.Location,
		codec:          remoting.GetCodec(url.Protocol),
		requestHandler: handlers,
	}
	s.rpcHandler = NewRpcServerHandler(s.conf.SessionNumber, s.conf.sessionTimeout, s)
	return s
}
func NewServer ( url * common . URL , handlers func ( * invocation . RPCInvocation ) protocol . RPCResult ) * Server { initServer ( url . Protocol ) srvConf . SSLEnabled = url . GetParamBool ( constant . SSL_ENABLED_KEY , false ) s := & Server { conf : * srvConf , addr : url . Location , codec : remoting . GetCodec ( url . Protocol ) , requestHandler : handlers , } s . rpcHandler = NewRpcServerHandler ( s . conf . SessionNumber , s . conf . sessionTimeout , s ) return s }
NewServer create a new Server
NewServer create a new Server
//init