Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/pup/lib/core/process.ts>Process

Universal process manager built in Deno
Go to Latest
class Process
import { Process } from "https://deno.land/x/pup@1.0.0-rc.6/lib/core/process.ts";

Constructors

new
Process(pup: Pup, config: ProcessConfiguration)

Properties

private
blocked: boolean
private
optional
code: number
private
optional
cronJob: Cron
private
optional
cronTerminateJob: Cron
private
optional
exited: Date
private
killRunner: (reason: string) => boolean

Kills the current runner and performs cleanup.

private
optional
pendingRestartReason: string
private
optional
pid: number
private
restarts: number
private
optional
runner: Runner | WorkerRunner
private
setupCron: () => unknown
private
setupCronTerminate: () => unknown
private
setupWatch: (paths: string[]) => unknown
private
optional
signal: string
private
optional
started: Date
private
status: ProcessState
private
optional
telemetry: TelemetryData
private
updated: Date
block: (reason: string) => unknown

Blocks the process.

cleanup: () => unknown
readonly
config: ProcessConfiguration
isPendingRestart: () => unknown
readonly
pup: Pup
restart: (reason: string) => unknown

Restarts the process.

stop: (reason: string) => Promise<boolean>

Stops the process and cleans up the resources.

unblock: (reason: string) => unknown

Unblocks the process.

Methods

Initialize process setup, watchers and events.

start(reason?: string, restart?: boolean)

Starts the process after validating the conditions for start.