Security News
JSR Working Group Kicks Off with Ambitious Roadmap and Plans for Open Governance
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.
Abstracts readiness/ liveness checks and graceful shutdown of Node.js services running in Kubernetes.
Abstracts initialisation and shutdown of Express.js services.
Disclaimer: I just needed something that works for my Kubernetes setup. This is far from a customisable service that could work across many projects in different environments.
Creates /healthz
health-check endpoint.
The health-check endpoint responds:
500
status code, message "SERVER IS NOT READY" when server is initialising.500
status code, message "SERVER IS SHUTTING DOWN" when server is shutting down.200
status code, message "SERVER IS READY" when server is accepting new connections.The default behaviour is:
SIGTERM
. Service shutdowns after 5 seconds.import express from 'express';
import {
createProcessManager
} from 'express-process-manager';
const app = express();
const server = app.listen(8080);
createProcessManager(server, app);
readinessProbe:
httpGet:
path: /healthz
port: 8080
periodSeconds: 5
initialDelaySeconds: 5
livenessProbe:
httpGet:
path: /healthz
port: 8080
periodSeconds: 5
initialDelaySeconds: 10
express-process-manager
is using Roarr to implement logging.
Set ROARR_LOG=true
environment variable to enable logging.
FAQs
Abstracts readiness, liveness and startup checks and graceful shutdown of Node.js services running in Kubernetes.
The npm package lightship receives a total of 47,770 weekly downloads. As such, lightship popularity was classified as popular.
We found that lightship demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Security News
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.
Security News
Research
An advanced npm supply chain attack is leveraging Ethereum smart contracts for decentralized, persistent malware control, evading traditional defenses.
Security News
Research
Attackers are impersonating Sindre Sorhus on npm with a fake 'chalk-node' package containing a malicious backdoor to compromise developers' projects.