1

I'm currently developing a nodejs with express web application which is able to start other webservers, also with express.

The problem is: If the main express webserver goes down (which happens during development) all the references to the started webservers get lost but they're still listening on the ports they've been bound to.

So the question is: is there a way to clean all those things up from nodejs?

  • possible duplicate of [how to properly close node-express server?](http://stackoverflow.com/questions/14515954/how-to-properly-close-node-express-server) – Alfonso Presa Aug 28 '15 at 12:48
  • Check if you're properly closing the server as told here: http://stackoverflow.com/questions/14515954/how-to-properly-close-node-express-server. If you need to do it on the main express webserver try listener to it's close event: https://nodejs.org/api/http.html#http_event_close – Alfonso Presa Aug 28 '15 at 12:48
  • Show us the code you're using for starting the other web servers. If these are additional processes, then you will need to terminate the other processes. – jfriend00 Aug 28 '15 at 15:26

0 Answers0