0

we would like to create a meteor client web app, we already have a java based business logic server that exposes rest services (stateless).

Our intention was that the server of the meteor app(nodejs) will call the business logic server for many many rest services.

We are fearing the following :

Since there will be many rest calls from the nodejs to the java rest server and since the nodejs is single threaded will the whole architecture fail??

Urbanleg
  • 6,252
  • 16
  • 76
  • 139

1 Answers1

1

As long as you are not blocking that single thread, node is more than capable of handling as many requests as you are likely to throw at it.

All I/O operations in Node are evented and asynchronous. In essence, keep your own request / response operations asynchronous and you won't hit any problems.

There are a lot of answers / articles on this subject, but you'd do well to start with:

How the single threaded non blocking IO model works in Node.js http://blog.mixu.net/2011/02/01/understanding-the-node-js-event-loop/

Community
  • 1
  • 1
duncanhall
  • 11,035
  • 5
  • 54
  • 86