blob: 3bc9d6bb4ee1bc68ed2ed841c414534dd3c5f7f6 [file] [log] [blame]
<div class="wiki-content maincontent"><h3>The ZeroConf Transport</h3>
<p>The ZeroConf transport works just like <link><page ri:content-title="Discovery Transport Reference"></page><link-body>Discovery Transport</link-body></link>, except that it uses a <link><page ri:content-title="ZeroConf"></page></link> based discovery agent to locate the list of broker uris to connect to.</p>
<h4>Configuration Syntax</h4>
<p><strong>zeroconf:serviceName?transportOptions</strong><br clear="none">
or<br clear="none">
<strong>zeroconf:serviceName</strong></p>
<p>where <em>serviceName</em> is the Zeroconf service name; which seems to start with an underscore (_) and must end with a dot (.). So we can use this service name to distinguish development, UAT &amp; production brokers - or group them into domains etc.</p>
<p>Note that to be able to use ZeroConf to find brokers, the brokers need to have <link><page ri:content-title="Discovery"></page></link> enabled. To configure discovery in a Broker you should use the <link><page ri:content-title="Xml Configuration"></page></link>. Its basically something like...</p>
<structured-macro ac:macro-id="6985defe-7571-4905-ae3f-ca6d372f1ebe" ac:name="code" ac:schema-version="1"><plain-text-body>
&lt;broker name="foo"&gt;
&lt;transportConnectors&gt;
&lt;transportConnector name="openwire" uri="tcp://0.0.0.0:61616" discoveryUri="zeroconf:_activemq_development. /&gt;
&lt;/transportConnectors&gt;
...
&lt;/broker&gt;
</plain-text-body></structured-macro>
<h5>Example client URI</h5>
<structured-macro ac:macro-id="dc56016e-8011-4157-a33f-097e11f39c98" ac:name="noformat" ac:schema-version="1"><plain-text-body>
zeroconf:_activemq_development.
</plain-text-body></structured-macro></div>