juju: github.com/juju/juju/worker/terminationworker Index | Files

package terminationworker

import "github.com/juju/juju/worker/terminationworker"


Package Files

manifold.go worker.go


const TerminationSignal = syscall.SIGABRT

TerminationSignal is the signal that indicates the agent should terminate and uninstall itself.

We do not use SIGTERM as SIGTERM is the default signal used to initiate a graceful shutdown.

func Manifold Uses

func Manifold() dependency.Manifold

Manifold returns a manifold whose worker returns ErrTerminateAgent if a termination signal is received by the process it's running in.

func NewWorker Uses

func NewWorker() worker.Worker

NewWorker returns a worker that waits for a TerminationSignal signal, and then exits with worker.ErrTerminateAgent.

Package terminationworker imports 7 packages (graph) and is imported by 105 packages. Updated 2020-05-01. Refresh now. Tools for package owners.