util

package
Version: v1.9.2 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2021 License: MIT Imports: 9 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateListener added in v1.4.4

func CreateListener(address string) (net.Listener, error)

CreateListener crates socket listener based on DSN definition.

Types

type State

type State struct {
	// Pid contains process id.
	Pid int `json:"pid"`

	// Status of the worker.
	Status string `json:"status"`

	// Number of worker executions.
	NumJobs int64 `json:"numExecs"`

	// Created is unix nano timestamp of worker creation time.
	Created int64 `json:"created"`

	// MemoryUsage holds the information about worker memory usage in bytes.
	// Values might vary for different operating systems and based on RSS.
	MemoryUsage uint64 `json:"memoryUsage"`
}

State provides information about specific worker.

func ServerState

func ServerState(rr *roadrunner.Server) ([]*State, error)

ServerState returns list of all worker states of a given rr server.

func WorkerState

func WorkerState(w *roadrunner.Worker) (*State, error)

WorkerState creates new worker state definition.

Jump to

Keyboard shortcuts

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