Node.js reliability for large application

前端 未结 4 526
-上瘾入骨i
-上瘾入骨i 2021-01-31 02:57

I am new to Node.js and am currently questioning its reliability.

Based on what I\'ve seen so far, there seems to be a major flaw: any uncaught error/exceptions crashes

4条回答
  •  无人共我
    2021-01-31 03:24

    You have got full control of the base process, and that is a feature.

    If you compare Node to an Apache/PHP setup the latter is really just equivalent to having a simple Node server that sends each incoming request to it's own process which is terminated after the request has been handled.

    You can make that setup in Node if you wish, and in many cases something like that is probably a good idea. The great thing about Node is that you can break this pattern, you could for instance have the main process or another permanent process do session handling before a request is passed to it's handler.

    Node is a very flexible tool, that is good if you need this flexibility, but it takes some skill to handle.

提交回复
热议问题