From edbfae31411154cd455dc4ca2ca20e77cd6489f6 Mon Sep 17 00:00:00 2001 From: Erik Hugne Date: Tue, 5 Nov 2013 13:23:45 +0100 Subject: [PATCH] zmq: change TIPC default lookup domain when connecting By default, TIPC uses a closest first approach to find a publication that can satisfy your connection request. Any publication on the local node will automatically be chosen for all requests, even if you're trying to spread it out over multiple machines. We fix this by widening the default lookup scope. Signed-off-by: Erik Hugne --- src/tipc_address.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/tipc_address.cpp b/src/tipc_address.cpp index 0a3808d5..ff6700f4 100644 --- a/src/tipc_address.cpp +++ b/src/tipc_address.cpp @@ -60,6 +60,10 @@ int zmq::tipc_address_t::resolve (const char *name) address.addrtype = TIPC_ADDR_NAME; address.addr.name.name.type = type; address.addr.name.name.instance = lower; + /* Since we can't specify lookup domain when connecting + * (and we're not sure that we want it to be configurable) + * Change from 'closest first' approach, to search entire zone */ + address.addr.name.domain = tipc_addr(1, 0, 0); address.scope = 0; return 0; }