Reputation: 114
Is there any way to have an asynchronous client and server in ZeroMQ, using the same TCP-port and many sockets?
I already tried the ROUTER/ROUTER
pattern, but with no luck.
The plan is to have an asymmetric connection with send and receive patterns among processors. So a Processor
-entity will be a Client and also be a Server at the same time.
Upvotes: 1
Views: 89
Reputation: 1
Is there any way to have an asynchronous client and server in ZeroMQ, using the same TCP-port and many sockets ?
As a preventive step, in other words, before getting into troubles, best review the main conceptual differences in [ ZeroMQ hierarchy in less than a five seconds ] or other posts and discussions here.
The Yes above means, one-.bind()
-many-.connect()
-s, which composition still uses a just one <transport-class>://<a-class-specific-address>
, that for a tcp://
transport-class on IPv4 means that one tcp://A.B.C.D:port#
occupied for this whole 1:MANY
-sockets-composition.
For obvious reasons, more complex compositions, like many-.bind()
-s-many-.connect()
-s, are possible, where feasible, given both the ZeroMQ infrastructure topology options and also socket-"in-band"-message-routing features are thus setup and used for smart-decisions on actual message-flow mechanics.
Upvotes: 1