blob: 83d69889ce1a837c15a39b423df90590a937fba4 [file] [log] [blame]
<div class="docbook"><div class="navheader"><table summary="Navigation header" width="100%"><tr><th align="center" colspan="3">4.5.&#160;Virtualhosts</th></tr><tr><td align="left" width="20%"><a accesskey="p" href="Java-Broker-Concepts-RemoteReplicationNodes.html">Prev</a>&#160;</td><th align="center" width="60%">Chapter&#160;4.&#160;Concepts</th><td align="right" width="20%">&#160;<a accesskey="n" href="Java-Broker-Concepts-Exchanges.html">Next</a></td></tr></table><hr /></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="Java-Broker-Concepts-Virtualhosts"></a>4.5.&#160;Virtualhosts</h2></div></div></div><p>A virtualhost is a container in which messaging is performed. Virtualhosts are independent;
the messaging that goes on within one virtualhost is independent of any messaging that goes on
in another virtualhost. For instance, a queue named <span class="emphasis"><em>foo</em></span> defined in one
virtualhost is completely independent of a queue named <span class="emphasis"><em>foo</em></span> in another
virtualhost.</p><p>A virtualhost is identified by a name which must be unique broker-wide. Clients use the name
to identify the virtualhost to which they wish to connect when they connect.</p><p>A virtualhost exists in a virtualhost node.</p><p>The virtualhost comprises a number of entities. This section summaries the purpose of
each of the entities and describes the relationships between them. These details are developed
further in the sub-sections that follow.</p><p><span class="emphasis"><em>Exchanges</em></span> is a named entity within the Virtual Host which receives
messages from producers and routes them to matching Queues. When using AMQP 0-8, 0-9, 0-9-1, 0-10
the exchange is the only way ingressing a message into the virtualhost. When using AMQP 1.0
producers may route messages via exchanges or direct to queues.</p><p><span class="emphasis"><em>Queues</em></span> are named entities that hold messages for delivery to consumer
applications.</p><p><span class="emphasis"><em>Connections</em></span> represent a live connection to the virtualhost from a
messaging client.</p><p>A <span class="emphasis"><em>Session</em></span> represents a context for the production or consumption of
messages. A Connection can have many Sessions.</p><p>A <span class="emphasis"><em>Consumer</em></span> represents a live consumer that is attached to queue.</p><p><span class="emphasis"><em>Loggers</em></span> are responsible for producing logs for this virtualhost.</p><p> The following diagram depicts the Virtualhost model: </p><div class="figure"><a id="d0e519"></a><p class="title"><strong>Figure&#160;4.3.&#160;Virtualhost Model showing major entities</strong></p><div class="figure-contents"><div class="mediaobject"><img alt="Virtual Host Model" src="images/VirtualHost-Model.png" /></div></div></div><p><br class="figure-break" />
</p><p>A <span class="emphasis"><em>virtualhost</em></span> is backed by storage which is used to store the
messages.</p></div><div class="navfooter"><hr /><table summary="Navigation footer" width="100%"><tr><td align="left" width="40%"><a accesskey="p" href="Java-Broker-Concepts-RemoteReplicationNodes.html">Prev</a>&#160;</td><td align="center" width="20%"><a accesskey="u" href="Java-Broker-Concepts.html">Up</a></td><td align="right" width="40%">&#160;<a accesskey="n" href="Java-Broker-Concepts-Exchanges.html">Next</a></td></tr><tr><td align="left" valign="top" width="40%">4.4.&#160;Remote Replication Nodes&#160;</td><td align="center" width="20%"><a accesskey="h" href="Apache-Qpid-Broker-J-Book.html">Home</a></td><td align="right" valign="top" width="40%">&#160;4.6.&#160;Exchanges</td></tr></table></div></div>