MCPcopy Index your code
hub / github.com/koding/kite / Close

Method Close

server.go:41–62  ·  view source on GitHub ↗

Close stops the server and the kontrol client instance.

()

Source from the content-addressed store, hash-verified

39
40// Close stops the server and the kontrol client instance.
41func (k *Kite) Close() {
42 k.Log.Info("Closing kite...")
43
44 k.kontrol.Lock()
45 if k.kontrol != nil && k.kontrol.Client != nil {
46 k.kontrol.Close()
47 }
48 k.kontrol.Unlock()
49
50 if k.listener != nil {
51 k.listener.Close()
52 k.listener = nil
53 }
54
55 k.mu.Lock()
56 cache := k.verifyCache
57 k.mu.Unlock()
58
59 if cache != nil {
60 cache.StopGC()
61 }
62}
63
64func (k *Kite) Addr() string {
65 return net.JoinHostPort(k.Config.IP, strconv.Itoa(k.Config.Port))

Callers 15

RegisterHTTPMethod · 0.45
sendHeartbeatsMethod · 0.45
CloseMethod · 0.45
CloseMethod · 0.45
registerToProxyKiteMethod · 0.45
TestMethod_ThrottlingFunction · 0.45
TestMethod_LatestFunction · 0.45
TestMethod_FirstFunction · 0.45
TestMethod_ErrorFunction · 0.45
TestMethod_BaseFunction · 0.45
TestContextFunction · 0.45
TestMultipleFunction · 0.45

Calls 1

InfoMethod · 0.80

Tested by 11

TestMethod_ThrottlingFunction · 0.36
TestMethod_LatestFunction · 0.36
TestMethod_FirstFunction · 0.36
TestMethod_ErrorFunction · 0.36
TestMethod_BaseFunction · 0.36
TestContextFunction · 0.36
TestMultipleFunction · 0.36
TestSendErrorFunction · 0.36
TestConcurrencyFunction · 0.36
TestKiteFunction · 0.36