MCPcopy
hub / github.com/fatedier/frp / closeProxy

Method closeProxy

server/control.go:296–310  ·  view source on GitHub ↗
(pxy proxy.Proxy)

Source from the content-addressed store, hash-verified

294}
295
296func (ctl *Control) closeProxy(pxy proxy.Proxy) {
297 pxy.Close()
298 ctl.sessionCtx.PxyManager.Del(pxy.GetName())
299 metrics.Server.CloseProxy(pxy.GetName(), pxy.GetConfigurer().GetBaseConfig().Type)
300
301 notifyContent := &plugin.CloseProxyContent{
302 User: ctl.loginUserInfo(),
303 CloseProxy: msg.CloseProxy{
304 ProxyName: pxy.GetName(),
305 },
306 }
307 go func() {
308 _ = ctl.sessionCtx.PluginManager.CloseProxy(notifyContent)
309 }()
310}
311
312func (ctl *Control) worker() {
313 xl := ctl.xl

Callers 2

workerMethod · 0.95
CloseProxyMethod · 0.95

Calls 7

loginUserInfoMethod · 0.95
CloseMethod · 0.65
GetNameMethod · 0.65
CloseProxyMethod · 0.65
GetBaseConfigMethod · 0.65
GetConfigurerMethod · 0.65
DelMethod · 0.45

Tested by

no test coverage detected