LibraryToggle FramesPrintFeedback

Discovery Protocols

Overview

A discovery protocol builds a connection to a message broker in two steps:

  1. Obtain a list of available broker endpoints.

  2. Connect to one or more endpoints from the discovered list, according to some selection algorithm.

Discovery protocols are particularly useful for clients that connect to a cluster of message brokers.

Summary of discovery protocols

Table 2 describes the discovery protocols that clients can use.

Table 2. Summary of Discovery Protocols

ProtocolSample URLDescription
Failoverfailover://(uri1,...,uriN)?TransportOptionsConfigure clients to connect to one of the broker endpoints from the URI list, uri1,...,uriN. The transport options, ?TransportOptions, are specified in the form of a query list. If no transport options are required, you can omit the parentheses and the question mark, ?. For more information see Failover Protocol in Fault Tolerant Messaging.
Discoverydiscovery://(DiscoveryAgentUri)?TransportOptionsConfigure clients to connect to one of the broker endpoints from a URI list that is dynamically discovered at runtime, using a discovery agent. The discovery agent URI, DiscoveryAgentUri, is normally a multicast discovery agent—for example, multicast://default. For more information see Dynamic Discovery Protocol.
Fanoutfanout://(DiscoveryAgentUri)?TransportOptionsConfigure clients to connect to all of the broker endpoints from a dynamically discovered URI list. For more information see Fanout Protocol.

Discovery agents

The discovery protocol supports a number of discovery agents, which are also specified in the form of a URI. For details of the supported discovery agents, see Discovery Agents.

[Note]Note

Although discovery agent URIs look superficially like transport URIs, they are not the same thing. A discovery agent URI can only be used in certain contexts and cannot be used directly in place of a transport URI.

Comments powered by Disqus