-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
An "option" is received twice #6
Comments
Just run the thing on 3-4-5 machines and was able to confirm that:
So instead of having one Maybe because of that each newly connected node reports "start" as many times as the total amount of nodes connected. I am not sure about the implication, does it mean that there are N listeners per node waiting for the same event now? |
Actually, maybe there are actually I can confirm visually that |
Thanks Alexey. Looking at it 2015-10-19 11:29 GMT+02:00 Alexey Raga notifications@github.com:
Alberto. |
Alexey: can you post the code here? there are different examples of pi 2015-10-19 12:12 GMT+02:00 Alberto G. Corona agocorona@gmail.com:
Alberto. |
Sure, it was based on the one in the
|
The problem is tat connect does connect to the whole cluster. Not to an Try connect myNode mainNode Instead of And get the host and port of both nodes from the command line for each I'm away now but I will post here the neccesary changes as soon as I can The nodes must be executed separately with different node parameters. You have to put in the command line the host, port of the local node and the host, port of a node already connected to the cluster. The first one can connect to itself. the, substitute map (connect mainNode) nodes for connect node mainNode and execute as many times the program as nodes you want to have. I have created a Transient.Move.Services module that I´m testing now to hot load new nodes in machines, but they need a bootstrap service that must be executed one by one in each node. There is no way to spawn services in remote nodes without first distributing the core infrastructure by hand... |
I think it is essentially the same because I always start my nodes by giving them just two parameters. Sorry I wasn't clear about it. It is like:
So you right, Anyway, I've tested it with just Below are the changed bits code. I only use two parameters, the first is the "self" node and the second is the "cluster master" node which is always the same:
Thanks for your help. |
It is strange. Even with two nodes, when I "start" in the first node, the second node also display results, and it does not have to. It is something related with connect, since when give the list of nodes manually: main = do
args <- getArgs
let (local, remote)= if length args > 0 then (createNode "localhost" 2000, createNode "localhost" 2001)
else (createNode "localhost" 2001, createNode "localhost" 2000)
addNodes [local, remote] by switching local and remote ports depending on if the command line has an extra argument or not. In this case they work ok. It must be something related with connect,which simply should update the nodes list in each node. |
I found it. It should use But still when a node start, the other nodes also display results. That should not happen, but it seems to be a different issue. |
I will open a new issue for the extra calculation messages in the "slave" nodes |
I am running a
distributed pi
example on 3 physical nodes where I connect nodes one-by-one to the same "main" node.What I see is that the 3rd node prints the
option
message twice. Does it mean that every message is received twice?Here are the connect process logs:
Node 1 (main, 192.168.1.6)
Node 2 (192.168.1.153)
Node 3 (192.168.1.151)
The text was updated successfully, but these errors were encountered: