[zeromq-dev] Connecting to a different socket after connecting and sending messages to one socket?
Praveen Baratam
praveen.baratam+zmq at gmail.com
Thu Nov 18 22:22:41 CET 2010
Hello All!
I have a particular situation where client nodes connect to server nodes to
solve tasks (PUSH-PULL). At any given point there are many clients (PUSH -
Connect) connected to all the available servers (PULL - Bound) and each
client distributes task-messages to the servers in a load balanced way. Now
for the available number of servers (PULL - Bound) are unable to take the
load from the clients and we need to add an extra computing server node
(PULL - Bound) so that clients can connect and delegate task-messages to the
new server/compute node.
Which means I have to issue a connect call to the PUSH socket on the client
to connect to the newly instantiated server PULL socket endpoint after the
client started sending messages to the existing servers' PULL sockets.
Can it be done?
Simply put, the logic is as follows:-
1. pushSocket - connect to endpoint 1
2. pushSocket - connect to endpoint 2
3. .....
4. pushSocket connect to endpoint M
5. send messages through pushSocket to endpoint 1 through endpoint M in a
load balanced way
6. Add another endpoint, endpoint N into the cluster
7. pushSocket - conntect to endpoint N
8. send messages through pushSocket to endpoint 1 through endpoint N in a
load balanced way
This is similar to the Task Ventillator example explaining PUSH-PULL pair in
the guide except that we have arbitrarily joining and leaving ventillators
and also arbitrarily joining and leaving workers.
Somebody please suggest me if this is possible.
Thank you,
Dr. Praveen Baratam
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20101119/b9688895/attachment.htm>
More information about the zeromq-dev
mailing list