MCPcopy Create free account
hub / github.com/0xUnixIO/pulse / DoStop

Method DoStop

internal/nodeapi/api.go:155–160  ·  view source on GitHub ↗

DoStop 停止 xray 核心;如果未运行视为成功。

()

Source from the content-addressed store, hash-verified

153
154// DoStop 停止 xray 核心;如果未运行视为成功。
155func (a *API) DoStop() (coremanager.Status, error) {
156if err := a.xrManager.Stop(); err != nil && !errors.Is(err, coremanager.ErrNotRunning) {
157return coremanager.Status{}, err
158}
159return a.xrManager.Status(), nil
160}
161
162// DoRestart 用新配置重启核心。
163func (a *API) DoRestart(config, core string) (coremanager.Status, error) {

Callers 1

HandleMethod · 0.80

Calls 2

StopMethod · 0.65
StatusMethod · 0.65

Tested by

no test coverage detected