Socket
Socket
Sign inDemoInstall

ps-watchdog

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ps-watchdog

A module that kills the current process and all the children if the event loop is unresponsive


Version published
Weekly downloads
2
Maintainers
1
Weekly downloads
 
Created
Source

Ps-watchdog module

Kills the current process and all the children when the JavaScript event loop is busy for more than a configurable amount of time.

It forks a new process that waits for a periodical keepalive from the event loop.

Installing

npm install ps-watchdog

Using

import {Watchdog} from 'ps-watchdog';

const interval = 1000;
const times = 2;
const watchdog = new Watchdog(interval, times);
watchdog.start();

interval: keepalive interval in milliseconds
times: number of times the process can miss the keepalive before getting killed

License

MIT

Author

Alessio Paccoia <alessio.paccoia@cubbit.io>

FAQs

Package last updated on 18 Jun 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc