Should we use Node.JS for enterprise solutions? No, never!

2 Flares Twitter 0 Facebook 0 Google+ 0 LinkedIn 2 Email -- Filament.io 2 Flares ×

I have many reasons why to avoid the use of Node.JS for enterprise solutions (webservices, websites, etc.), but I think that the following one is definitive:

  • Each error within a single script will make the whole application crash and will require a command-line restart

Let’s see the following example scenario:

Our Node.JS application (myapp) is a simple web app (it doesn’t matter which framework we use) that responds to the following 2 URIs: /myapp/test1/ and /myapp/test2/.
Those URIs are managed by two specific controllers: controller1.js and controller2.js.

Only controller2.js is bugged and so when /myapp/test2/ is requested by the browser it causes a fatal error.

Where’s the problem? Every web application works like that.
Yes, it is. But no other “old” application such as Php would crash within the single script error!
Let’s understand that also the other URL (/myapp/test1/) that contained the not bugged code will be unavailable within the node server crash. Unlike Php applications that will continue to correctly work if there is a single script with a fatal error.

I have many other reasons for thinking that Node.JS is just a toy, and not a professional tool, but I think this issue is one of the worst behaviours I could have ever found in a modern programming language.

Some interesting articles on the equivalence between node.JS and EVIL:

 

2 Flares Twitter 0 Facebook 0 Google+ 0 LinkedIn 2 Email -- Filament.io 2 Flares ×

Leave a Reply

Your email address will not be published. Required fields are marked *