Tuesday 14 March 2017

How to gracefully update a node based API?

How can I make sure that every request has finished before I update a node API server? Is there any npm package or good practice to handle this?

These two scenarios needs to be considered: 1. Stop new request from coming while we update packages, dependencies, source code 2. Make sure that the request and every child process that are executing finished properly before restarting the service (we use pm2)



via Alejandro Magnorsky

No comments:

Post a Comment