A send will only one of the consumers, listening on yhe same address, will receibe the message in roumd robin fashion.
So if yoi have 4 comsumer listening to the same address then a publish means all 4 will get it. While a send only one at a time will get it.
Hi @javadevmtlThanks for your response.I understand the diff between send() and publish() my question was diff. I asked how can I use publish and still have only one consumer that consume the message in the same instance group?For example lets say you have three services: one-service, two-service,three-servicelet's say you have 3 instances of each. (3's one-service, 3's two-service, 3's three-service)now one service want to publish message to two-service and three-service. so what will happen? all the 6 instances will get the message.the only way to over come this is to use send() and send to two-service and send to three service. but thats not real pub-sub as the sender sending explicitly to it's consumers his message.what happen if 'tomrrow' i have four-service with 3 instances ? then I need to modify one-service again and add another send() method to the four-serviceget my issue?
--
You received this message because you are subscribed to a topic in the Google Groups "vert.x" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/vertx/dJCoIpTR9zg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to vertx+un...@googlegroups.com.
Visit this group at https://groups.google.com/group/vertx.
To view this discussion on the web, visit https://groups.google.com/d/msgid/vertx/66251c71-79db-4e10-9a97-e68651708a5b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
To unsubscribe from this group and all its topics, send an email to vertx+unsubscribe@googlegroups.com.
To unsubscribe from this group and all its topics, send an email to vertx+un...@googlegroups.com.