MCPcopy Index your code
hub / github.com/CovenantSQL/CovenantSQL / GetEx

Method GetEx

rpc/mux/server_test.go:46–61  ·  view source on GitHub ↗
(id proto.NodeID, isAnonymous bool)

Source from the content-addressed store, hash-verified

44}
45
46func (p *nilSessionPool) GetEx(id proto.NodeID, isAnonymous bool) (conn rpc.Client, err error) {
47 var (
48 sess *mux.Session
49 stream *mux.Stream
50 )
51 if sess, err = newSession(id, isAnonymous); err != nil {
52 return
53 }
54 if stream, err = sess.OpenStream(); err != nil {
55 return
56 }
57 return rpc.NewClient(&oneOffMuxConn{
58 sess: sess,
59 Stream: stream,
60 }), nil
61}
62
63func (p *nilSessionPool) Close() error { return nil }
64

Callers 1

GetMethod · 0.95

Calls 2

NewClientFunction · 0.92
newSessionFunction · 0.85

Tested by

no test coverage detected