5

Possible Duplicate:
What is node.js?
Usages of Node.js - What obstacles is it aiming to provide a ramp for?

What is the correct scenario to use server side javascript? like node.js What kind of problems it solves?

2
  • 6 solid reasons to use node.js Commented Dec 22, 2011 at 12:24
  • My question was not specific to node.js, but server side script in general. Thanks. Commented Dec 22, 2011 at 12:58

1 Answer 1

1
  • Node.js solves the problem of serving many concurrent users from I/O based servers.
  • By I/O I mean that little to none computation is done in the request response cycle from the server part.
  • By concurrent I meany that thousands of users can keep a connection open with the server.
  • Having a persistent connection allows real time communication, the server can push over the opened connection, in a sense this way the server can be thought of as initiating the communication (comet, server push).

All this allows having a large user-base with little server resources and real-time communication (chat etc).

Sign up to request clarification or add additional context in comments.

4 Comments

I don't quite understand your point. Is this something like long polling?
@ZolaKt: yes, node.js works well for long polling
@SergeiTulentsev: is it used just for long polling, or are there any other significant advantages? If it is only for long polling why not use a COMET approach, why resort to javascript?
It is used for all sorts of things. Some people serve HTML with it. Use what you're familiar with, not what some guy on the internet tells you to. :-)

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.