
Security News
vlt Launches "reproduce": A New Tool Challenging the Limits of Package Provenance
vlt's new "reproduce" tool verifies npm packages against their source code, outperforming traditional provenance adoption in the JavaScript ecosystem.
graceful-terminate
Advanced tools
Gracefully shutdown your node app. Graceful interrupts SIGTERM
and SIGINT
signals.
var graceful = require("graceful");
Cleanup before exit.
graceful.add(() => console.log("Cleaning up."));
^CCleaning up.
$
Prevent shutdown. Return true
in the function.
graceful.add(() => {
... // check some conditions
if (notReady()){
console.log("Cannot terminate yet");
return true; // don't shutdown.
}
return false; // shutdown
});
^CCannot terminate yet.
You can add multiple functions. Return true
in any function to prevent shutdown and stop executing other functions.
graceful.add(() => console.log("Cleaning up."));
graceful.add(() => {
console.log("Shutdown stops here.");
return true;
}
graceful.add(() => console.log("Won't get here"));
^CCleaning up.
Shutdown stops here.
MIT
FAQs
Gracefully shutdown your node app.
The npm package graceful-terminate receives a total of 0 weekly downloads. As such, graceful-terminate popularity was classified as not popular.
We found that graceful-terminate 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
vlt's new "reproduce" tool verifies npm packages against their source code, outperforming traditional provenance adoption in the JavaScript ecosystem.
Research
Security News
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
Research
The Socket Research Team discovered a malicious npm package, '@ton-wallet/create', stealing cryptocurrency wallet keys from developers and users in the TON ecosystem.