Did you take a look at cluster api?
http://nodejs.org/api/cluster.html#cluster_worker_send_message_sendhandle
I think we can send msg to master process, and from master process,
broadcast msg to other workers.
More discussion can be referred in this link:
Asyn mechanism is useful in those tasks that act as servant, just give
those tasks order such as Come on, do something for me and get back as
soon as you've finished, that's it.
Your main flow should move forward smoothly while asyn methods are
executing, just mind when the result is returned.
Hi all,
I'm using cluster module to utilize multi-core machine (
http://nodejs.org/api/cluster.html#cluster_class_worker).
My program will be hosted in different machine, so in each worker I use
redis pubsub to broadcast to other servers.
The code should be like following snippet:
As Yi Tan suggested, using cluster to utilize multicore server should be
better.
On Thu, Aug 23, 2012 at 12:37 PM, Hitesh Joshi hitesh.webma...@gmail.comwrote:
I don't think this is a problem. Problem should occur when the response
time is in SECONDS like 3-4 second.
I really think nodejs
Seem that problem is the conflict between cluster module and socket.io:
https://github.com/LearnBoost/socket.io/issues/798#issuecomment-7965366
Anybody figure out the way to resolve it?
Thanks.
On Thu, Aug 23, 2012 at 4:01 PM, hd nguyen nguyenhd2...@gmail.com wrote:
Hi all,
I'm using
Thanks for your great work, I just read its description but seem it's quite
worthy to take a look :)
On Fri, Aug 3, 2012 at 11:13 AM, Evan evantah...@gmail.com wrote:
Hello Node.js Community -
I want to announce the release of actionHero version 3. This release adds
web socket support as a
it
by code (using Redis to store client's information)?
Regards,
On Mon, Jul 30, 2012 at 2:17 PM, hd nguyen nguyenhd2...@gmail.com wrote:
@Jimb: thank you so much for your useful comment :)
On Sat, Jul 28, 2012 at 2:05 AM, Jimb Esser wastel...@gmail.com wrote:
We're using HAProxy+stud
@Tim Cash:
Now I have not made any test to compare redis pubsub and zmq. But with our
business we intend to use redis pubsub as ultimate choice, and maybe we'll
ignore zmq.
On Mon, Jul 30, 2012 at 2:32 AM, Tim Cash timc...@gmail.com wrote:
@hd nguyen
I am also interested in comparing
пользователь mscdex написал:
On Jul 10, 6:04 am, hd nguyen nguyenhd2...@gmail.com wrote:
Any suggestion to build this module on windows? Or if you have this
node
modules, please share me.
Try this instead and let me know if it works for you: npm install
https://github.com/mscdex/**zeromq.node
Hi all,
I did some google search but still not found any example/tutorial for my
case.
Assume I have a nodejs app using socket io, and I want to use
node-http-proxy as load balancer.
My app is replicated in 2 servers with the same port.
server1: myapp_url:8000
server2: myapp_url:8000
How I
Of course we can write a code snippet to redirect request to expected
server manually by node-http-proxy.
Based on https://github.com/nodejitsu/node-http-proxy/ examples, I just can
find snippet code to stick from proxy server to ONE nodejs (using websocket/
socket.io), I want redirecting from
Sorry http://127.0.0.1: http://127.0.0.1:8000/3001, 8000 is my local
port for testing :)
On Thu, Jul 26, 2012 at 9:16 AM, hd nguyen nguyenhd2...@gmail.com wrote:
Your action should be http://127.0.0.1:8000;.
On Thu, Jul 26, 2012 at 8:32 AM, josh macmillan.jos...@gmail.com wrote:
I have
:20 AM UTC-4, hd nguyen wrote:
But I do have a concern why I cannot install it via npm install zmq
merely?
Anything I'm missing here?
The problem is that the header files that were supposed to come from the
libzmq-dev package are not being found by the build script. The commit I
made to my
OK got it.
Thanks a lot for your enthusiastic support :)
On Mon, Jul 16, 2012 at 1:12 PM, mscdex msc...@gmail.com wrote:
On Monday, July 16, 2012 2:04:01 AM UTC-4, hd nguyen wrote:
Do you have zmq module author know about this issue and suggest your fix?
I think it helps prevent different
, 2012 11:02:44 PM UTC-4, hd nguyen wrote:
../binding.cc:29:17: fatal error: zmq.h: No such file or directory
Looks like you don't have libzmq and/or libzmq-dev installed.
--
Job Board: http://jobs.nodejs.org/
Posting guidelines:
https://github.com/joyent/node/wiki/Mailing-List-Posting
ZMQ does not support libzmq 3.x but only 2.x.
在 2012年7月16日星期一UTC+8上午11时44分23秒,hd nguyen写道:
Hi mscdex,
Tried to run npm install libzmq libzmq-dev but seems those modules did
not exist in node module repository.
D:\NodeJS_Examples\pubsub\**node_modulesnpm install libzmq-dev
npm http GET
Thanks mscdex, it works now :)
But I do have a concern why I cannot install it via npm install zmq merely?
Anything I'm missing here?
On Mon, Jul 16, 2012 at 12:02 PM, mscdex msc...@gmail.com wrote:
On Monday, July 16, 2012 12:16:29 AM UTC-4, hd nguyen wrote:
Installed libzmq-dev
of them.
Thomas Blobaum
https://github.com/tblobaum
On Fri, Jul 13, 2012 at 12:29 AM, hd nguyen nguyenhd2...@gmail.com
wrote:
Thanks Tim for your suggestion about subscriber part.
Any suggestions for publisher part(one publisher for each ACTION or one
publisher for ALL ACTION)? I want
Hi all,
I have a concern when using pubsub mechanism of redis in my real application.
I built a MMO game with 5 servers (NodeJs) and use pubsub of Redis to
broadcast game state between servers.
But I concern which is the best practice to utilize this mechanism
efficiently with a lot of users
the same messages as each other; which means your clients will be
doubling up on emit operations.
Tim
On Fri, Jul 13, 2012 at 11:43:25AM +0700, hd nguyen wrote:
Hi all,
I have a concern when using pubsub mechanism of redis in my real
application.
I built a MMO game with 5 servers (NodeJs
Hi,
I'm using windows 7 64 bit, nodeJs 0.8.1 and intend to create a simple
example about pub/sub with Redis.
But now I cannot install nodejs redis module to use, get error when
executing: *npm install redis* or *npm install hiredis*
*
*
*[image: Inline image 1]
*
*
*
Not sure anything wrong
can't be compiled on windows because they require a *nix environment. I
could be wrong, but I distinctly remember reading that somewhere
On Jul 10, 2012, at 3:06 PM, hd nguyen wrote:
Hi,
I'm using windows 7 64 bit, nodeJs 0.8.1 and intend to create a simple
example about pub/sub with Redis
Thanks I posted this issue to git, but not sure it's fixed (soon or late).
Any suggestion to help me build redis module on windows 7?
On Tue, Jul 10, 2012 at 2:55 PM, Ryan Schmidt google-2...@ryandesign.comwrote:
On Jul 10, 2012, at 02:41, hd nguyen wrote:
But I wonder we should have
Hi,
I intend to create simple nodejs app using pub/sub features of ZeroMq, but
cannot install zmq module on windows 7 64 bit.
I googled it and seem it's acceptable bug, now zmq module does not support
windows.
Any suggestion to build this module on windows? Or if you have this node
modules,
into
../node_modules.
Tim.
On Tuesday, 10 July 2012, hd nguyen wrote:
Hi,
I'm using windows 7 64 bit, nodeJs 0.8.1 and intend to create a simple
example about pub/sub with Redis.
But now I cannot install nodejs redis module to use, get error when
executing: *npm install redis* or *npm
It works great.
Thanks so much :)
On Wed, Jul 11, 2012 at 1:14 AM, mscdex msc...@gmail.com wrote:
On Jul 10, 6:04 am, hd nguyen nguyenhd2...@gmail.com wrote:
Any suggestion to build this module on windows? Or if you have this node
modules, please share me.
Try this instead and let me
I looked at node http proxy and see that it lists ' Supports
WebSocketshttps://github.com/nodejitsu/node-http-proxy/blob/master/examples/websocket/websocket-proxy.js
'
feature, maybe need some more test on it to make sure it fits my
requirement.
@mscdex: you mean most load balancers now support
a communication channel
between the two node.js processes (raw TCP might be enough, personally I
would use Zeromq, but that's an implementation detail)
USER1 - GAME1 - GAME2 - USER2
Hope that helps,
Charles
On 5 July 2012 08:53, hd nguyen nguyenhd2...@gmail.com wrote:
I think
servers every moment, so
movement messages must be sent out straight away (no db).
Good luck with your project ;)
danmilon.
On 07/05/2012 11:21 AM, hd nguyen wrote:
It's right Charles.
And I also understand you and Dominic's idea, I just want to find a
tool/module that supports
Hi all,
I'm building a MMO (Massive Multiplayer Online) game with nodejs built in
server side, but now I'm getting stuck in how to make load balancing for
nodejs between multiple servers.
The game is using web socket to communicate with server. Example we have 2
servers that host GAME1, server1
Sorry NGINX :|
On Thu, Jul 5, 2012 at 11:51 AM, hd nguyen nguyenhd2...@gmail.com wrote:
Hi all,
I'm building a MMO (Massive Multiplayer Online) game with nodejs built in
server side, but now I'm getting stuck in how to make load balancing for
nodejs between multiple servers.
The game
Hi all,
I'm new here and want to make a simple test web app with NodeJS and Express
framework.
I created 2 request are http://localhost:3000/heavycompute (very long time
processing) and http://localhost:3000/
http://localhost:3000/heavycompute (just
display text, return immediately) and
weird a little bit.
Any other approach without creating sub process for each request like that?
Thanks.
On Fri, Jun 29, 2012 at 7:27 PM, Ben Noordhuis i...@bnoordhuis.nl wrote:
On Fri, Jun 29, 2012 at 12:49 PM, hd nguyen nguyenhd2...@gmail.com
wrote:
Hi all,
I'm new here and want to make
Thanks for your help and explanation.
Everything is quite clearer to me :)
On Fri, Jun 29, 2012 at 8:27 PM, Bradley Meck bradley.m...@gmail.comwrote:
Usually people use worker pools so they don't spawn up a new process per
request. The moving of heavy computation to other processes has various
34 matches
Mail list logo