blob: ed8f7aafe74a5f27fb5647cd56f6fa460556b5cd [file] [log] [blame]
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="generator" content="Asciidoctor 2.0.18">
<link rel="icon" type="image/png" href="images/favicon.png">
<title>Protocols and Interoperability</title>
<link rel="stylesheet" href="css/asciidoctor.css">
<link rel="stylesheet" href="css/font-awesome.css">
<link rel="stylesheet" href="css/rouge-github.css">
</head>
<body class="book toc2 toc-left">
<div id="header">
<h1>Protocols and Interoperability</h1>
<div id="toc" class="toc2">
<div id="toctitle"><a href="index.html">User Manual for 2.33.0</a></div>
<ul class="sectlevel1">
<li><a href="#supported-protocols">1. Supported Protocols</a>
<ul class="sectlevel2">
<li><a href="#amqp">1.1. AMQP</a></li>
<li><a href="#mqtt">1.2. MQTT</a></li>
<li><a href="#stomp">1.3. STOMP</a></li>
<li><a href="#openwire">1.4. OpenWire</a></li>
<li><a href="#core">1.5. Core</a></li>
</ul>
</li>
<li><a href="#configuring-acceptors">2. Configuring Acceptors</a></li>
</ul>
</div>
</div>
<div id="content">
<div id="preamble">
<div class="sectionbody">
<div class="paragraph">
<p>Apache ActiveMQ Artemis has a powerful &amp; flexible core which provides a foundation upon which other protocols can be implemented.
Each protocol implementation translates the ideas of its specific protocol onto this core.</p>
</div>
<div class="paragraph">
<p>The broker ships with a client implementation which interacts directly with this core.
It uses what&#8217;s called the <a href="core.html#using-core">"core" API</a>, and it communicates over the network using the "core" protocol.</p>
</div>
</div>
</div>
<div class="sect1">
<h2 id="supported-protocols"><a class="anchor" href="#supported-protocols"></a><a class="link" href="#supported-protocols">1. Supported Protocols</a></h2>
<div class="sectionbody">
<div class="paragraph">
<p>The broker has a pluggable protocol architecture.
Protocol plugins come in the form of protocol modules.
Each protocol module is included on the broker&#8217;s class path and loaded by the broker at boot time.
The broker ships with 5 protocol modules out of the box.</p>
</div>
<div class="sect2">
<h3 id="amqp"><a class="anchor" href="#amqp"></a><a class="link" href="#amqp">1.1. AMQP</a></h3>
<div class="paragraph">
<p><a href="https://en.wikipedia.org/wiki/AMQP">AMQP</a> is a specification for interoperable messaging.
It also defines a wire format, so any AMQP client can work with any messaging system that supports AMQP.
AMQP clients are available in many different programming languages.</p>
</div>
<div class="paragraph">
<p>Apache ActiveMQ Artemis implements the <a href="https://www.oasis-open.org/committees/tc_home.php?wg_abbrev=amqp">AMQP 1.0</a> specification.
Any client that supports the 1.0 specification will be able to interact with Apache ActiveMQ Artemis.</p>
</div>
<div class="paragraph">
<p>Please see <a href="amqp.html#amqp">AMQP</a> for more details.</p>
</div>
</div>
<div class="sect2">
<h3 id="mqtt"><a class="anchor" href="#mqtt"></a><a class="link" href="#mqtt">1.2. MQTT</a></h3>
<div class="paragraph">
<p><a href="https://mqtt.org/">MQTT</a> is a lightweight connectivity protocol.
It is designed to run in environments where device and networks are constrained.
Any client that supports the 3.1, 3.1.1, or 5 specification will be able to interact with Apache ActiveMQ Artemis.</p>
</div>
<div class="paragraph">
<p>Please see <a href="mqtt.html#mqtt">MQTT</a> for more details.</p>
</div>
</div>
<div class="sect2">
<h3 id="stomp"><a class="anchor" href="#stomp"></a><a class="link" href="#stomp">1.3. STOMP</a></h3>
<div class="paragraph">
<p><a href="https://stomp.github.io/">Stomp</a> is a very simple text protocol for interoperating with messaging systems.
It defines a wire format, so theoretically any Stomp client can work with any messaging system that supports Stomp.
Stomp clients are available in many different programming languages.
Any client that supports the 1.0, 1.1, or 1.2 specification will be able to interact with Apache ActiveMQ Artemis.</p>
</div>
<div class="paragraph">
<p>Please see <a href="stomp.html#stomp">Stomp</a> for more details.</p>
</div>
</div>
<div class="sect2">
<h3 id="openwire"><a class="anchor" href="#openwire"></a><a class="link" href="#openwire">1.4. OpenWire</a></h3>
<div class="paragraph">
<p>ActiveMQ Classic defines its own wire protocol: OpenWire.
In order to support ActiveMQ "Classic" clients, Apache ActiveMQ Artemis supports OpenWire.
Any ActiveMQ 5.12.x or higher can be used with Apache ActiveMQ Artemis.</p>
</div>
<div class="paragraph">
<p>Please see <a href="openwire.html#openwire">OpenWire</a> for more details.</p>
</div>
</div>
<div class="sect2">
<h3 id="core"><a class="anchor" href="#core"></a><a class="link" href="#core">1.5. Core</a></h3>
<div class="paragraph">
<p>ActiveMQ Classic defines its own wire protocol: OpenWire.
In order to support ActiveMQ "Classic" clients, Apache ActiveMQ Artemis supports OpenWire.
Any ActiveMQ 5.12.x or higher can be used with Apache ActiveMQ Artemis.</p>
</div>
<div class="paragraph">
<p>Please see <a href="core.html#using-core">Core</a> for more details.</p>
</div>
<div class="sect3">
<h4 id="apis-and-other-interfaces"><a class="anchor" href="#apis-and-other-interfaces"></a><a class="link" href="#apis-and-other-interfaces">1.5.1. APIs and Other Interfaces</a></h4>
<div class="paragraph">
<p>Although JMS and Jakarta Messaging are standardized APIs, they do not define a network protocol.
The ActiveMQ Artemis <a href="using-jms.html#using-jms-or-jakarta-messaging">JMS &amp; Jakarta Messaging clients</a> are implemented on top of the core protocol.
We also provide a <a href="using-jms.html#jndi">client-side JNDI implementation</a>.</p>
</div>
</div>
</div>
</div>
</div>
<div class="sect1">
<h2 id="configuring-acceptors"><a class="anchor" href="#configuring-acceptors"></a><a class="link" href="#configuring-acceptors">2. Configuring Acceptors</a></h2>
<div class="sectionbody">
<div class="paragraph">
<p>In order to make use of a particular protocol, a transport must be configured with the desired protocol enabled.
There is a whole section on configuring transports that can be found <a href="configuring-transports.html#configuring-the-transport">here</a>.</p>
</div>
<div class="paragraph">
<p>The default configuration shipped with the ActiveMQ Artemis distribution comes with a number of acceptors already defined, one for each of the above protocols plus a generic acceptor that supports all protocols.
To enable protocols on a particular acceptor simply add the <code>protocols</code> url parameter to the acceptor url where the value is one or more protocols (separated by commas).
If the <code>protocols</code> parameter is omitted from the url <strong>all</strong> protocols are enabled.</p>
</div>
<div class="ulist">
<ul>
<li>
<p>The following example enables only MQTT on port 1883</p>
<div class="listingblock">
<div class="content">
<pre class="rouge highlight nowrap"><code data-lang="xml"><span class="nt">&lt;acceptors&gt;</span>
<span class="nt">&lt;acceptor&gt;</span>tcp://localhost:1883?protocols=MQTT<span class="nt">&lt;/acceptor&gt;</span>
<span class="nt">&lt;/acceptors&gt;</span></code></pre>
</div>
</div>
</li>
<li>
<p>The following example enables MQTT and AMQP on port 5672</p>
<div class="listingblock">
<div class="content">
<pre class="rouge highlight nowrap"><code data-lang="xml"><span class="nt">&lt;acceptors&gt;</span>
<span class="nt">&lt;acceptor&gt;</span>tcp://localhost:5672?protocols=MQTT,AMQP<span class="nt">&lt;/acceptor&gt;</span>
<span class="nt">&lt;/acceptors&gt;</span></code></pre>
</div>
</div>
</li>
<li>
<p>The following example enables <strong>all</strong> protocols on <code>61616</code>:</p>
<div class="listingblock">
<div class="content">
<pre class="rouge highlight nowrap"><code data-lang="xml"><span class="nt">&lt;acceptors&gt;</span>
<span class="nt">&lt;acceptor&gt;</span>tcp://localhost:61616<span class="nt">&lt;/acceptor&gt;</span>
<span class="nt">&lt;/acceptors&gt;</span></code></pre>
</div>
</div>
</li>
</ul>
</div>
<div class="paragraph">
<p>Here are the supported protocols and their corresponding value used in the <code>protocols</code> url parameter.</p>
</div>
<table class="tableblock frame-all grid-all stretch">
<colgroup>
<col style="width: 50%;">
<col style="width: 50%;">
</colgroup>
<thead>
<tr>
<th class="tableblock halign-left valign-top">Protocol</th>
<th class="tableblock halign-left valign-top"><code>protocols</code> value</th>
</tr>
</thead>
<tbody>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock">Core (Artemis &amp; HornetQ native)</p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>CORE</code></p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock">OpenWire (5.x native)</p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>OPENWIRE</code></p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock">AMQP</p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>AMQP</code></p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock">MQTT</p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>MQTT</code></p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock">STOMP</p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>STOMP</code></p></td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</body>
</html>