supervisor

package module
v0.0.0-...-85a6648 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 4, 2022 License: Apache-2.0 Imports: 2 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

supervisor-api

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Supervisor

type Supervisor struct {
	// contains filtered or unexported fields
}

func New

func New(url string) (*Supervisor, error)

func (*Supervisor) ClearLog

func (s *Supervisor) ClearLog() (cleard bool, err error)

ClearLog 清空supervisord的日志

func (*Supervisor) GetAPIVersion

func (s *Supervisor) GetAPIVersion() (version string, err error)

GetAPIVersion 返回 supervisord 使用的 RPC API 的版本

func (*Supervisor) GetAllProcessInfo

func (s *Supervisor) GetAllProcessInfo() (info []processInfo, err error)

GetAllProcessInfo 获取所有的的supervisor进程的信息

func (*Supervisor) GetPID

func (s *Supervisor) GetPID() (pid int, err error)

GetPID 返回supervisord的PID

func (*Supervisor) GetProcessInfo

func (s *Supervisor) GetProcessInfo(name string) (info processInfo, err error)

GetProcessInfo 获取一个指定名字的supervisor进程的信息

func (*Supervisor) GetState

func (s *Supervisor) GetState() (st state, err error)

GetAPIVersion 返回supervisord使用的supervisor包的版本

func (*Supervisor) GetSupervisorVersion

func (s *Supervisor) GetSupervisorVersion() (version string, err error)

GetAPIVersion 返回supervisord使用的supervisor包的版本

func (*Supervisor) ListMethods

func (s *Supervisor) ListMethods() (methods []string, err error)

ListMethods 列出所有的方法

func (*Supervisor) ReadLog

func (s *Supervisor) ReadLog(offset int, length int) (log string, err error)

ReadLog 读取supervisord的日志

func (*Supervisor) Restart

func (s *Supervisor) Restart() (restarted bool, err error)

Restart 重启supervisord管理下的子进程

func (*Supervisor) Shutdown

func (s *Supervisor) Shutdown() (restarted bool, err error)

Shutdown 关闭 supervisord 进程

func (*Supervisor) StartAllProcesses

func (s *Supervisor) StartAllProcesses() (info []processStatusInfo, err error)

StartAllProcesses 启动所有进程

func (*Supervisor) StartProcess

func (s *Supervisor) StartProcess(name string) (pid int, err error)

StartProcess 通过名称启动进程, 启动成功返回pid, 失败pid为0

func (*Supervisor) StartProcessGroup

func (s *Supervisor) StartProcessGroup(name string) (info []processStatusInfo, err error)

StartProcessGroup 通过进程组名字启动进程组

func (*Supervisor) StopAllProcesses

func (s *Supervisor) StopAllProcesses() (info []processStatusInfo, err error)

StopAllProcesses 停止所有进程

func (*Supervisor) StopProcess

func (s *Supervisor) StopProcess(name string) (stoped bool, err error)

StopProcess 通过名称启动进程, 启动成功返回pid, 失败pid为0

func (*Supervisor) StopProcessGroup

func (s *Supervisor) StopProcessGroup(name string) (info []processStatusInfo, err error)

StopProcessGroup 通过进程组名字停止进程组

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址