0
votes

I have deployed a node application in azure running under an app service. Now issue is that the sites goes down occasionally and stops responding. Once I restart the site its starts working.

If I see logs, its says IISNode has encountered an error.

My question is is there any way to log the error and restart node process gracefully.

What is the best practice approach for node website deployed in app service?

This is the only error I get- This is the only error I get

1
As written, this is too broad and unclear. You should edit your question to show what error(s) you're getting. There's nothing included right now, aside from you mentioning encountering an error. - David Makogon
Added error detail. Issue is node handler is crashing. On restarting it works. Some how I need to gracefully restart node process on error. - Anup Das Gupta
If we deploy an asp.net application in IIS, on error, IIS logs the error and continue serving other requests. In this case somehow node module is crashing and then works only when I restart app service. - Anup Das Gupta

1 Answers

0
votes

According the list on https://azure.microsoft.com/en-us/documentation/articles/app-service-web-nodejs-best-practices-and-troubleshoot-guide/

500 1004-1018 There was some error while sending the request or processing the response to/from node.exe. Check if node.exe crashed. check d:\home\LogFiles\logging-errors.txt for stack trace.

And more best practices and troubleshooting scenarios, you can refer to https://azure.microsoft.com/en-us/documentation/articles/app-service-web-nodejs-best-practices-and-troubleshoot-guide/.