activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject [05/51] [abbrv] [partial] activemq-web git commit: Add body.storage type
Date Thu, 14 Dec 2017 14:48:29 GMT
http://git-wip-us.apache.org/repos/asf/activemq-web/blob/7a7d976c/jboss-integration.xml
----------------------------------------------------------------------
diff --git a/jboss-integration.xml b/jboss-integration.xml
index afc19be..16c619e 100644
--- a/jboss-integration.xml
+++ b/jboss-integration.xml
@@ -1,811 +1,2 @@
-<div class="wiki-content maincontent"><h1 id="JBossIntegration-IntegratingApacheActiveMQwithJBoss">Integrating Apache ActiveMQ with JBoss</h1>
-
-<p>Integration with application servers is a common scenario in the enterprise Java world, especially when it comes to messaging. <a shape="rect" class="external-link" href="http://activemq.org/" rel="nofollow">ActiveMQ</a> is a JMS 1.1 compliant, open source, Apache Licensed, message oriented middleware (MOM) with <a shape="rect" class="external-link" href="http://activemq.org/site/changes-in-40.html" rel="nofollow">many</a>, <a shape="rect" class="external-link" href="http://activemq.org/site/new-features-in-41.html" rel="nofollow">many</a> features far beyond the JMS specification. ActiveMQ offers many different <a shape="rect" class="external-link" href="http://activemq.org/site/connectivity.html" rel="nofollow">points of connectivity</a>, many <a shape="rect" class="external-link" href="http://activemq.org/site/cross-language-clients.html" rel="nofollow">cross language clients</a> and many <a shape="rect" class="external-link" href="http://activemq.org/site/protocols.html" rel=
 "nofollow">pluggable transport protocols</a> including integration with any J2EE 1.4 application server.</p>
-
-<p>One of the application servers in the open source world is JBoss. A very common requirement is to configure ActiveMQ as the messaging infrastructure within JBoss. Although there is <a shape="rect" class="external-link" href="http://www.activemq.org/site/jboss-integration.html" rel="nofollow">a bit of documentation</a> on this integration, this article seeks to provide much more detail and explanation. So if you have a need to integrate ActiveMQ with JBoss, this article is for you.</p>
-
-<p>This article explains how to configure JBoss to start up ActiveMQ as part of its lifecycle and how to configure the ActiveMQ resource adapter to handle the messaging and transactionality between ActiveMQ and JBoss.</p>
-
-<h2 id="JBossIntegration-Requirements">Requirements</h2>
-
-<p>Below are the software requirements for this article with links to download each:</p>
-<ul><li><a shape="rect" class="external-link" href="http://activemq.org/site/download.html" rel="nofollow">Apache ActiveMQ 4.0.1+</a></li><li><a shape="rect" class="external-link" href="http://sourceforge.net/project/showfiles.php?group_id=22866&amp;package_id=16942&amp;release_id=416591" rel="nofollow">JBoss 4.0.4+</a></li><li><a shape="rect" class="external-link" href="http://www.java.com/en/download/index.jsp" rel="nofollow">Sun Java 1.5+</a></li><li><a shape="rect" class="external-link" href="http://ant.apache.org/bindownload.cgi">Apache Ant 1.6+</a></li></ul>
-
-
-<p>Though this article is using Unix, the installation and integration will work on any platform running Sun Java. It is recommended that each piece of software be downloaded before working through the steps is this article. Once each piece of software has been downloaded, proceed to the first step.</p>
-
-<h2 id="JBossIntegration-InstalltheJ2SE1.5">Install the J2SE 1.5</h2>
-
-<p>The first step in this process is to install Java 1.5 and verify that it runs correctly. Using the link above, find, download and install the correct version of Java for your platform. Once Java is installed and in the PATH, test it to see that it runs correctly using the following command:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-$ java -version
-java version &quot;1.5.0_06&quot;
-Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_06-112)
-Java HotSpot(TM) Client VM (build 1.5.0_06-64, mixed mode, sharing)
-]]></script>
-</div></div>
-<p>Depending upon your platform and the exact build number of Java 1.5, your output may vary slightly. As long as it's Java 1.5 and the version information is output, you should be ready to proceed to the next step.</p>
-
-<h2 id="JBossIntegration-InstallApacheAnt">Install Apache Ant</h2>
-
-<p>The second step is to install Apache Ant. Simply download it using the link above, expand somewhere on your hard drive and place the <code>bin</code> directory in the PATH. This will allow you to test it quickly using the commands below:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-$ ant -version
-Apache Ant version 1.6.2 compiled on July 16 2004
-]]></script>
-</div></div>
-<p>As long as you see the version output above, Ant should be usable. If you did not see the version output or received an error, consult the Ant documentation or mailing list archives to work out the issue. Please note that Ant is not used until the end of this whole exercise to test the integration.</p>
-
-<h2 id="JBossIntegration-InstalltheJBossApplicationServer">Install the JBoss Application Server</h2>
-
-<p>The third step in this process is to install JBoss and make sure it runs correctly before installing and configuring ActiveMQ. Upon downloading JBoss-4.0.4, expand it in a place where it can create a directory. Next, run the server using the following commands:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-$ cd jboss-4.0.4.GA
-$ ./bin/run.sh -c default
-=========================================================================
-
-  JBoss Bootstrap Environment
-
-  JBOSS_HOME: /opt/jboss-4.0.4.GA
-
-  JAVA: java
-
-  JAVA_OPTS: -server -Xms128m -Xmx512m -Dsun.rmi.dgc.client.gcInterval=3600000 
--Dsun.rmi.dgc.server.gcInterval=3600000 -Dprogram.name=run.sh
-
-  CLASSPATH: /opt/jboss-4.0.4.GA/bin/run.jar:/lib/tools.jar
-
-=========================================================================
-
-15:34:47,999 INFO  [Server] Starting JBoss (MX MicroKernel)...
-15:34:48,001 INFO  [Server] Release ID: JBoss [Zion] 4.0.4.GA (build: CVSTag=JBoss_4_0_4_GA date=200605151000)
-15:34:48,004 INFO  [Server] Home Dir: /opt/jboss-4.0.4.GA
-15:34:48,005 INFO  [Server] Home URL: file:/opt/jboss-4.0.4.GA/
-15:34:48,007 INFO  [Server] Patch URL: null
-15:34:48,007 INFO  [Server] Server Name: default
-15:34:48,007 INFO  [Server] Server Home Dir: /opt/jboss-4.0.4.GA/server/default
-15:34:48,011 INFO  [Server] Server Home URL: file:/opt/jboss-4.0.4.GA/server/default/
-15:34:48,012 INFO  [Server] Server Log Dir: /opt/jboss-4.0.4.GA/server/default/log
-15:34:48,017 INFO  [Server] Server Temp Dir: /opt/jboss-4.0.4.GA/server/default/tmp
-15:34:48,022 INFO  [Server] Root Deployment Filename: jboss-service.xml
-...
-15:35:17,360 INFO  [Server] JBoss (MX MicroKernel) [4.0.4.GA (build: CVSTag=JBoss_4_0_4_GA date=200605151000)] 
-Started in 22s:238ms
-]]></script>
-</div></div>
-<p>The first few lines of output from the JBoss startup indicates the configuration being used but the last line is the most important one. It tells you that JBoss has been started successfully on your system. For an extra measure of assurance, visit <a shape="rect" class="external-link" href="http://localhost:8080/web-console/" rel="nofollow">http://localhost:8080/web-console/</a> in a web browser to make sure you are able to see the JBoss web console. If you can see this console, everything should be ready to go.</p>
-
-<p>As a side note, the left-hand side of the web-console requires that the <a shape="rect" class="external-link" href="http://java.sun.com/products/plugin/" rel="nofollow">Java plugin</a> be properly installed. This is supposed to take place when installing the J2SE, so if it did not work correctly for you, I suggest that you consult some documentation about any errors you may be seeing. The Java plugin is not required for JBoss or ActiveMQ to function properly, it is simply for the JBoss web-console.</p>
-
-<p>Once JBoss is installed properly, shut it down using either the shutdown script or by simply typing ctrl-c to activate the shutdown hook. Once it is shut down, proceed to the next step.</p>
-
-<h2 id="JBossIntegration-PrepareforIntegratingApacheActiveMQwiththeJBossApplicationServer">Prepare for Integrating Apache ActiveMQ with the JBoss Application Server</h2>
-
-<p>The fourth step is to prepare your environment for integrating ActiveMQ with JBoss. If you haven't done so already, download Apache ActiveMQ using the link above. As of the writing of this article, the latest released version is 4.0.2-RC4. Upon downloading this archive, expand it in a place where it can create a directory, preferably in the same location where JBoss was expanded. Verify that the ActiveMQ RAR file is included using the following commands:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-$ cd ./incubator-activemq-4.0.2.tar.gz
-$ jar tvf /opt/incubator-activemq-4.0.2/lib/optional/activemq-ra-4.0.2.rar
-     0 Mon Sep 25 19:00:50 MDT 2006 META-INF/
-   399 Mon Sep 25 19:00:48 MDT 2006 META-INF/MANIFEST.MF
-   523 Mon Sep 25 13:07:40 MDT 2006 META-INF/DISCLAIMER.txt
- 11359 Mon Sep 25 13:07:40 MDT 2006 META-INF/LICENSE.txt
- 20305 Mon Sep 25 13:07:40 MDT 2006 META-INF/ra.xml
-  2334 Mon Sep 25 13:07:40 MDT 2006 broker-config.xml
- 70023 Mon Sep 25 19:00:48 MDT 2006 activemq-ra-4.0.2.jar
-1351744 Mon Sep 25 19:00:14 MDT 2006 activemq-core-4.0.2.jar
-232107 Mon Sep 25 18:22:48 MDT 2006 activeio-core-3.0-beta4.jar
-2143211 Tue Aug 01 11:44:50 MDT 2006 derby-10.1.1.0.jar
-1901653 Tue Aug 01 11:47:08 MDT 2006 spring-1.2.6.jar
- 94713 Tue Aug 01 11:47:22 MDT 2006 xbean-spring-2.2.jar
- 52915 Tue Aug 01 12:22:16 MDT 2006 commons-logging-1.1.jar
- 16030 Tue Aug 01 12:22:32 MDT 2006 geronimo-j2ee-management_1.0_spec-1.0.jar
-329586 Tue Aug 01 12:22:54 MDT 2006 backport-util-concurrent-2.1.jar
-358085 Tue Aug 01 12:23:26 MDT 2006 log4j-1.2.12.jar
-   523 Mon Sep 25 19:00:50 MDT 2006 META-INF/DISCLAIMER.txt
- 11359 Mon Sep 25 19:00:50 MDT 2006 META-INF/LICENSE.txt
-]]></script>
-</div></div>
-<p>This is simply a table of contents of the RAR file. There should only be one reason that this will fail - an incomplete download of the ActiveMQ tarball or zip file. Beyond that, depending on the version you download, some of the library versions may be slightly different.</p>
-
-<p>Now go back to the JBoss installation and create a directory for ActiveMQ in the JBoss deploy directory for the default JBoss context. Below are the commands to achieve this task:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-$ mkdir /opt/jboss-4.0.4.GA/server/default/deploy/activemq-ra.rar
-$ cd /opt/jboss-4.0.4.GA/server/default/deploy/activemq-ra.rar
-$ pwd
-/opt/jboss-4.0.4.GA/server/default/deploy/activemq-ra.rar
-]]></script>
-</div></div>
-<div class="panel" style="background-color: #ccccff;border-width: 1px;"><div class="panelContent" style="background-color: #ccccff;">
-<p><strong><em>NOTE:</em></strong> The creation of a directory is not required but is the easiest way to set up the ActiveMQ RAR when you're just getting started. This is due to the flexibility it affords during the development phase for the configuration to be changed very easily. The alternative is to JAR up the directory as a RAR file once the configuration is solid enough that it no longer needs to be changed. But leaving everything in a directory during development is the easiest path.</p>
-</div></div>
-<p>Now expand the activemq-ra-4.0.2.rar into the current working directory:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-jar xvf /opt/incubator-activemq-4.0.2/lib/optional/activemq-ra-4.0.2.rar
-  created: META-INF/
- inflated: META-INF/MANIFEST.MF
- inflated: META-INF/DISCLAIMER.txt
- inflated: META-INF/LICENSE.txt
- inflated: META-INF/ra.xml
- inflated: broker-config.xml
- inflated: activemq-ra-4.0.2.jar
- inflated: activemq-core-4.0.2.jar
- inflated: activeio-core-3.0-beta4.jar
- inflated: derby-10.1.1.0.jar
- inflated: spring-1.2.6.jar
- inflated: xbean-spring-2.2.jar
- inflated: commons-logging-1.1.jar
- inflated: geronimo-j2ee-management_1.0_spec-1.0.jar
- inflated: backport-util-concurrent-2.1.jar
- inflated: log4j-1.2.12.jar
- inflated: META-INF/DISCLAIMER.txt
- inflated: META-INF/LICENSE.txt
-]]></script>
-</div></div>
-<p>Below is a quick listing of the contents of that directory:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-$ ls -l
-total 12848
-drwxr-xr-x   6 bsnyder  bsnyder      204 Oct 16 16:27 META-INF
--rw-r--r--   1 bsnyder  bsnyder   232107 Oct 16 16:27 activeio-core-3.0-beta4.jar
--rw-r--r--   1 bsnyder  bsnyder  1351744 Oct 16 16:27 activemq-core-4.0.2.jar
--rw-r--r--   1 bsnyder  bsnyder    70023 Oct 16 16:27 activemq-ra-4.0.2.jar
--rw-r--r--   1 bsnyder  bsnyder   329586 Oct 16 16:27 backport-util-concurrent-2.1.jar
--rw-r--r--   1 bsnyder  bsnyder     2334 Oct 16 16:27 broker-config.xml
--rw-r--r--   1 bsnyder  bsnyder    52915 Oct 16 16:27 commons-logging-1.1.jar
--rw-r--r--   1 bsnyder  bsnyder  2143211 Oct 16 16:27 derby-10.1.1.0.jar
--rw-r--r--   1 bsnyder  bsnyder    16030 Oct 16 16:27 geronimo-j2ee-management_1.0_spec-1.0.jar
--rw-r--r--   1 bsnyder  bsnyder   358085 Oct 16 16:27 log4j-1.2.12.jar
--rw-r--r--   1 bsnyder  bsnyder  1901653 Oct 16 16:27 spring-1.2.6.jar
--rw-r--r--   1 bsnyder  bsnyder    94713 Oct 16 16:27 xbean-spring-2.2.jar
-]]></script>
-</div></div>
-<p>Now it's time to configure ActiveMQ.</p>
-
-<h2 id="JBossIntegration-ConfiguringApacheActiveMQ">Configuring Apache ActiveMQ</h2>
-
-<p>The fifth step is to actually configure ActiveMQ for integration with JBoss. Remember that you should be sitting in the following directory:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-/opt/jboss-4.0.4.GA/server/default/deploy/activemq-ra.rar
-]]></script>
-</div></div>
-<p>You may or may not have installed JBoss in <code>/opt</code>, that doesn't particularly matter. What does matter is that you're sitting in the directory that was created above to hold the contents of the expanded ActiveMQ RAR file.</p>
-<div class="panel" style="background-color: #ccccff;border-width: 1px;"><div class="panelContent" style="background-color: #ccccff;">
-<p><strong><em>NOTE:</em></strong> A RAR file is a Resource adapter ARchive (RAR). Resource adapters are a concept from the <a shape="rect" class="external-link" href="http://java.sun.com/j2ee/connector/" rel="nofollow">J2EE Connector Architecture (JCA)</a> and are used to interface with Enterprise Information Systems (EIS), i.e., systems external to the application server (e.g., relational databases, mainframes, MOMs, accounting systems, etc.). Resource adapters are often referred to as J2EE connectors and are very similar to the concept of a device driver for, say, a printer in that they contain information specific to connecting to a particular system. The difference with JCA is that that connection has been formalized in specification for Java. So the overall concepts of JCA is for connection to any EIS, but what does that mean? JCA 1.5 provides connectivity and more via the following contracts:</p>
-
-<p>Version 1.0 Contracts</p>
-
-<p>In version 1.0 of the Connector Architecture, three contracts are defined to address the functions mentioned above:</p>
-<ul><li>Connection Management Contract: Lets applications connect to an EIS through the resource adapter. It also allows the application server to pool connection requests to the EIS.</li><li>Transaction Management Contract: Allows an application to manage and perform transactional access across one-to-many EIS resource managers.</li><li>Security Contract: Provides support for secure access to the EIS.</li></ul>
-
-
-<p>New Contracts in Version 1.5</p>
-
-<p>In version 1.5 of the J2EE Connector Architecture, there are more contracts that a resource adapter must support, as new functionality and features made their way into the specification. A resource adapter can support these four new contracts by implementing the required interfaces defined in the specification for each contract.</p>
-<ul><li>Lifecycle Management Contract: Lets the application server manage the lifecycle &#8211; that is, the startup and shutdown functionality &#8211; of the resource adapter.</li><li>Work Management Contract: Allows the resource adapter to do work by submitting it to an application server for execution. Since the application server does the work for the resource adapter, the resource adapter needn't worry about thread management. Instead, the application server manages this aspect efficiently and can use thread pooling if necessary. Although the work management contract is not required (the resource adapter can choose to manage its own thread for work), it is definitely recommended.</li><li>Transaction Inflow Contract: Allows a resource adapter to propagate an imported transaction to an application server, as well as flow-in transaction completion and crash recovery initiated by an EIS.</li><li>Message Inflow Contract: Allows the resource adapter to synchronously or asynchronously
  deliver messages to endpoints in the application server, irrespective of message style, semantics, and infrastructure.</li></ul>
-
-
-<p><sub>Quoted from</sub> <sub><a shape="rect" class="external-link" href="http://java.sun.com/developer/technicalArticles/J2EE/connectorarch1_5/" rel="nofollow"><sub>What's New in the J2EE Connector Architecture 1.5</sub></a></sub></p>
-
-<p>For more information about JCA, please consult the <a shape="rect" class="external-link" href="http://java.sun.com/j2ee/connector/index.jsp" rel="nofollow">J2EE Connector Architecture documentation</a>.</p>
-</div></div>
-<p>Open the <code>META-INF/ra.xml</code> file and look for the following section:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>META-INF/ra.xml</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;config-property&gt;
-    &lt;description&gt;
-      The URL to the ActiveMQ server that you want this connection to connect to.  If using
-      an embedded broker, this value should be &#39;vm://localhost&#39;.
-    &lt;/description&gt;
-    &lt;config-property-name&gt;ServerUrl&lt;/config-property-name&gt;
-    &lt;config-property-type&gt;java.lang.String&lt;/config-property-type&gt;
-    &lt;config-property-value&gt;tcp://localhost:61616&lt;/config-property-value&gt;
-&lt;!-- &lt;config-property-value&gt;vm://localhost&lt;/config-property-value&gt; --&gt;
-  &lt;/config-property&gt;
-]]></script>
-</div></div>
-<p>The section above is used to tell the ActiveMQ RAR where ActiveMQ is located. By default, the in-VM protocol is commented out in favor of the tcp protocol. This will find ActiveMQ running on any interface on the localhost on port 61616. It's ok to just leave this alone if you don't mind the inefficiency of communicating within the JVM via TCP. However, it is recommended that <code>vm://</code> transport be used for an embedded broker, so comment out the <code>tcp://</code> transport and uncomment the <code>vm://</code> transport. Below is an example of this:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>META-INF/ra.xml</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;config-property&gt;
-    &lt;description&gt;
-      The URL to the ActiveMQ server that you want this connection to connect to.  If using
-      an embedded broker, this value should be &#39;vm://localhost&#39;.
-    &lt;/description&gt;
-    &lt;config-property-name&gt;ServerUrl&lt;/config-property-name&gt;
-    &lt;config-property-type&gt;java.lang.String&lt;/config-property-type&gt;
-    &lt;!-- &lt;config-property-value&gt;tcp://localhost:61616&lt;/config-property-value&gt; --&gt;
-    &lt;config-property-value&gt;vm://localhost&lt;/config-property-value&gt;
-  &lt;/config-property&gt;
-]]></script>
-</div></div>
-<p>Because we're embedding ActiveMQ inside of JBoss, it is more efficient to use the <code>vm://</code> transport, rather than to perform messaging over the <code>tcp://</code> transport.</p>
-
-<p>Now look further down the <code>META-INF/ra.xml</code> file and locate the following section:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>META-INF/ra.xml</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;config-property&gt;
-    &lt;description&gt;
-      Sets the XML configuration file used to configure the embedded ActiveMQ broker via
-      Spring if using embedded mode.
-
-      BrokerXmlConfig is the filename which is assumed to be on the classpath unless
-      a URL is specified. So a value of foo/bar.xml would be assumed to be on the
-      classpath whereas file:dir/file.xml would use the file system.
-      Any valid URL string is supported.
-    &lt;/description&gt;
-    &lt;config-property-name&gt;BrokerXmlConfig&lt;/config-property-name&gt;
-    &lt;config-property-type&gt;java.lang.String&lt;/config-property-type&gt;
-    &lt;config-property-value&gt;&lt;/config-property-value&gt;
-    &lt;!--
-    &lt;config-property-value&gt;xbean:broker-config.xml&lt;/config-property-value&gt;
-    --&gt;
-  &lt;/config-property&gt;
-]]></script>
-</div></div>
-<p>The section above needs to be changed to uncomment the second to last line and remove/replace the empty element that is above it. Below is an example of how this should be changed:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>META-INF/ra.xml</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;config-property&gt;
-    &lt;description&gt;
-      Sets the XML configuration file used to configure the embedded ActiveMQ broker via
-      Spring if using embedded mode.
-
-      BrokerXmlConfig is the filename which is assumed to be on the classpath unless
-      a URL is specified. So a value of foo/bar.xml would be assumed to be on the
-      classpath whereas file:dir/file.xml would use the file system.
-      Any valid URL string is supported.
-    &lt;/description&gt;
-    &lt;config-property-name&gt;BrokerXmlConfig&lt;/config-property-name&gt;
-    &lt;config-property-type&gt;java.lang.String&lt;/config-property-type&gt;
-    &lt;config-property-value&gt;xbean:broker-config.xml&lt;/config-property-value&gt;
-  &lt;/config-property&gt;
-]]></script>
-</div></div>
-<p>This change tells the ActiveMQ RAR to read a configuration file named <code>broker-config.xml</code> (the <code>xbean:</code> that proceeds the filename is simply a hint to class doing the reading of the configuration file) which is located on the CLASSPATH. In this case, the <code>broker-config.xml</code> file is located in the <code>activemq-ra.rar</code> directory. Save the changes to that file and then open the <code>broker-config.xml</code> file.</p>
-
-<p>The <code>broker-config.xml</code> file <em>is</em> the ActiveMQ configuration file. This is the file used to configure ActiveMQ. The default contents of this file are usable, but should be customized to suit your environment. There are several items of note about this configuration. The most prominent sections to note in this file are the <code>&lt;persistenceAdapter&gt;</code> element and the <code>&lt;transportConnectors&gt;</code> and <code>&lt;networkConnectors&gt;</code> elements as seen below:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>broker-config.xml</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;beans xmlns=&quot;http://activemq.org/config/1.0&quot;&gt;
-
-  &lt;broker useJmx=&quot;true&quot;&gt;
-  ...
-    &lt;persistenceAdapter&gt;
-      &lt;journaledJDBC journalLogFiles=&quot;5&quot; dataDirectory=&quot;activemq-data&quot;/&gt;
-      &lt;!-- To use a different datasource, use th following syntax : --&gt;
-      &lt;!--
-      &lt;journaledJDBC journalLogFiles=&quot;5&quot; dataDirectory=&quot;../data&quot; dataSource=&quot;#postgres-ds&quot;/&gt;
-       --&gt;
-    &lt;/persistenceAdapter&gt;
-
-    &lt;transportConnectors&gt;
-      &lt;!-- prefixing a connector with discovery: causes the connector to be advertiesed over rendezvous --&gt;
-      &lt;transportConnector uri=&quot;tcp://localhost:61616&quot; discoveryUri=&quot;multicast://default&quot;/&gt;
-    &lt;/transportConnectors&gt;
-
-    &lt;networkConnectors&gt;
-      &lt;!-- by default just auto discover the other brokers --&gt;
-      &lt;networkConnector uri=&quot;multicast://default&quot;/&gt;
-      &lt;!--
-      &lt;networkConnector uri=&quot;static://(tcp://host1:61616,tcp://host2:61616)&quot;/&gt;
-      --&gt;
-    &lt;/networkConnectors&gt;
-
-  &lt;/broker&gt;
-
-&lt;/beans&gt;
-]]></script>
-</div></div>
-<p>The first change to this file is to add the brokerName attribute to the broker element and provide a name:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;broker useJmx=&quot;true&quot; brokerName=&quot;bruce.broker1&quot;&gt;
-]]></script>
-</div></div>
-<p>In addition, this same name is used further down the configuration to provide a name for the <code>&lt;transportConnector&gt;</code> element:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;transportConnector name=&quot;bruce.broker1&quot; uri=&quot;tcp://localhost:61616&quot; discoveryUri=&quot;multicast://default&quot;/&gt;
-]]></script>
-</div></div>
-<p>Now we'll tell ActiveMQ not to initialize JMX because we'll use the existing one that JBoss has:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;!-- put the following as the first child of the broker tag --&gt;
-&lt;managementContext&gt;&lt;!-- we&#39;ll use an existing one (JBoss) instead of creating one --&gt;
-  &lt;managementContext createConnector=&quot;false&quot;/&gt;
-&lt;/managementContext&gt;
-]]></script>
-</div></div>
-<p>The <code>&lt;persistenceAdapter&gt;</code> element should be reconfigured to store its data in an appropriate place.  On JBoss, that's most likely within the "data" directory of the server configuration you're using.  We're going to set this dynamically using an XBean and Spring feature that allows us to inject system properties values into the configuration. First this needs to be enabled:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;!-- put the following as the first child of the beans element --&gt;
-&lt;bean xmlns=&quot;&quot; class=&quot;org.springframework.beans.factory.config.PropertyPlaceholderConfigurer&quot;/&gt;
-]]></script>
-</div></div>
-<p>Now, modify the <code>dataDirectory</code> attribute of the <code>journaledJDBC</code> element to be the following: <code>${jboss.server.data.dir}/activemq</code>.</p>
-
-<p>The <code>&lt;transportConnectors&gt;</code> element is used to advertise the ActiveMQ broker for client-to-broker communications and the <code>&lt;networkConnectors&gt;</code> element advertises the ActiveMQ broker for broker-to-broker communications. The default configuration is to use the ActiveMQ <a shape="rect" class="external-link" href="http://www.activemq.org/site/multicast-transport-reference.html" rel="nofollow">multicast transport</a> for both. This is simply an easy configuration under which to get ActiveMQ up and running, so we'll just leave it at that for the time being.</p>
-<div class="panel" style="background-color: #ccccff;border-width: 1px;"><div class="panelContent" style="background-color: #ccccff;">
-<p><strong><em>NOTE:</em></strong> There are far more configuration options available for ActiveMQ than are noted here. The configuration above is only enough to just get ActiveMQ up and running, nothing more. For more information on the ActiveMQ configuration, see the <a shape="rect" class="external-link" href="http://www.activemq.org/site/xbean-xml-reference-41.html" rel="nofollow">ActiveMQ 4.1 XML Reference</a>.</p>
-</div></div>
-<p>Now we just need to start up JBoss to assure that it comes up correctly without error using the same commands we used previously to start JBoss:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-$ cd jboss-4.0.4.GA
-$ ./bin/run.sh -c default
-=========================================================================
-
-  JBoss Bootstrap Environment
-
-  JBOSS_HOME: /opt/jboss-4.0.4.GA
-
-  JAVA: java
-
-  JAVA_OPTS: -server -Xms128m -Xmx512m -Dsun.rmi.dgc.client.gcInterval=3600000 
--Dsun.rmi.dgc.server.gcInterval=3600000 -Dprogram.name=run.sh
-
-  CLASSPATH: /opt/jboss-4.0.4.GA/bin/run.jar:/lib/tools.jar
-
-=========================================================================
-
-15:34:47,999 INFO  [Server] Starting JBoss (MX MicroKernel)...
-15:34:48,001 INFO  [Server] Release ID: JBoss [Zion] 4.0.4.GA (build: CVSTag=JBoss_4_0_4_GA date=200605151000)
-15:34:48,004 INFO  [Server] Home Dir: /opt/jboss-4.0.4.GA
-15:34:48,005 INFO  [Server] Home URL: file:/opt/jboss-4.0.4.GA/
-15:34:48,007 INFO  [Server] Patch URL: null
-15:34:48,007 INFO  [Server] Server Name: default
-15:34:48,007 INFO  [Server] Server Home Dir: /opt/jboss-4.0.4.GA/server/default
-15:34:48,011 INFO  [Server] Server Home URL: file:/opt/jboss-4.0.4.GA/server/default/
-15:34:48,012 INFO  [Server] Server Log Dir: /opt/jboss-4.0.4.GA/server/default/log
-15:34:48,017 INFO  [Server] Server Temp Dir: /opt/jboss-4.0.4.GA/server/default/tmp
-15:34:48,022 INFO  [Server] Root Deployment Filename: jboss-service.xml
-...
-15:35:17,360 INFO  [Server] JBoss (MX MicroKernel) [4.0.4.GA (build: CVSTag=JBoss_4_0_4_GA date=200605151000)] 
-Started in 28s:576ms
-]]></script>
-</div></div>
-<p>As long as JBoss comes up without error, you're ready to move on to the next step.</p>
-
-<h2 id="JBossIntegration-ConfiguringJBoss">Configuring JBoss</h2>
-
-<p>The sixth step is to configure JBoss to initialize and start ActiveMQ whenever JBoss starts up. This is accomplished using an XML file that abides by the <a shape="rect" class="external-link" href="http://www.jboss.org/j2ee/dtd/jboss-ds_1_5.dtd" rel="nofollow">JBoss JCA DTD</a> for data sources. Like most other Java application servers on the market, the JBoss architecture uses the J2EE Connector Architecture to manage connections of any kind including JDBC, JMS, etc. and the JBoss JCA DTD denotes the allowed contents for creating an XML data source instance to configure JBoss JCA. Below is an example XML data source instance for use with JBoss:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>activemq-jms-ds.xml</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
-
-&lt;!DOCTYPE connection-factories
-    PUBLIC &quot;-//JBoss//DTD JBOSS JCA Config 1.5//EN&quot;
-    &quot;http://www.jboss.org/j2ee/dtd/jboss-ds_1_5.dtd&quot;&gt;
-
-&lt;connection-factories&gt;
-
-   &lt;tx-connection-factory&gt;
-      &lt;jndi-name&gt;activemq/QueueConnectionFactory&lt;/jndi-name&gt;
-      &lt;xa-transaction/&gt;
-      &lt;track-connection-by-tx/&gt;
-      &lt;rar-name&gt;activemq-ra.rar&lt;/rar-name&gt;
-      &lt;connection-definition&gt;javax.jms.QueueConnectionFactory&lt;/connection-definition&gt;
-      &lt;ServerUrl&gt;vm://localhost&lt;/ServerUrl&gt;
-      &lt;!--
-      &lt;UserName&gt;sa&lt;/UserName&gt;
-      &lt;Password&gt;&lt;/Password&gt;
-      --&gt;
-      &lt;min-pool-size&gt;1&lt;/min-pool-size&gt;
-      &lt;max-pool-size&gt;200&lt;/max-pool-size&gt;
-      &lt;blocking-timeout-millis&gt;30000&lt;/blocking-timeout-millis&gt;
-      &lt;idle-timeout-minutes&gt;3&lt;/idle-timeout-minutes&gt;
-   &lt;/tx-connection-factory&gt;
-
-   &lt;tx-connection-factory&gt;
-      &lt;jndi-name&gt;activemq/TopicConnectionFactory&lt;/jndi-name&gt;
-      &lt;xa-transaction/&gt;
-      &lt;track-connection-by-tx/&gt;
-      &lt;rar-name&gt;activemq-ra.rar&lt;/rar-name&gt;
-      &lt;connection-definition&gt;javax.jms.TopicConnectionFactory&lt;/connection-definition&gt;
-      &lt;ServerUrl&gt;vm://localhost&lt;/ServerUrl&gt;
-      &lt;!--
-      &lt;UserName&gt;sa&lt;/UserName&gt;
-      &lt;Password&gt;&lt;/Password&gt;
-      --&gt;
-      &lt;min-pool-size&gt;1&lt;/min-pool-size&gt;
-      &lt;max-pool-size&gt;200&lt;/max-pool-size&gt;
-      &lt;blocking-timeout-millis&gt;30000&lt;/blocking-timeout-millis&gt;
-      &lt;idle-timeout-minutes&gt;3&lt;/idle-timeout-minutes&gt;
-   &lt;/tx-connection-factory&gt;
-
-   &lt;mbean code=&quot;org.jboss.resource.deployment.AdminObject&quot; name=&quot;activemq.queue:name=outboundQueue&quot;&gt;
-      &lt;attribute name=&quot;JNDIName&quot;&gt;activemq/queue/outbound&lt;/attribute&gt;
-      &lt;depends optional-attribute-name=&quot;RARName&quot;&gt;jboss.jca:service=RARDeployment,name=&#39;activemq-ra.rar&#39;&lt;/depends&gt;
-      &lt;attribute name=&quot;Type&quot;&gt;javax.jms.Queue&lt;/attribute&gt;
-      &lt;attribute name=&quot;Properties&quot;&gt;PhysicalName=queue.outbound&lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-   &lt;mbean code=&quot;org.jboss.resource.deployment.AdminObject&quot; name=&quot;activemq.topic:name=inboundTopic&quot;&gt;
-      &lt;attribute name=&quot;JNDIName&quot;&gt;activemq/topic/inbound&lt;/attribute&gt;
-      &lt;depends optional-attribute-name=&quot;RARName&quot;&gt;jboss.jca:service=RARDeployment,name=&#39;activemq-ra.rar&#39;&lt;/depends&gt;
-      &lt;attribute name=&quot;Type&quot;&gt;javax.jms.Topic&lt;/attribute&gt;
-      &lt;attribute name=&quot;Properties&quot;&gt;PhysicalName=topic.inbound&lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-&lt;/connection-factories&gt;
-]]></script>
-</div></div>
-<p>This XML instance configures a JMS <code>QueueConnectionFactory</code> and a JMS <code>TopicConnectionFactory</code> and makes them available via JNDI. Also defined in this file are some {{AdminObject}}s which are used to specify a topic and a queue. This file should be dropped into the JBoss deploy directory. Its name (*-ds.xml) will cause it to be picked up by the JBoss deployer upon startup. Speaking of which, once this file is in place, a quick smoke test can be performed by simply starting up the JBoss server. Below is an example of the output that should be seen:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-=========================================================================
-
-  JBoss Bootstrap Environment
-
-  JBOSS_HOME: /opt/jboss
-
-  JAVA: java
-
-  JAVA_OPTS: -server -Xms128m -Xmx512m -Dsun.rmi.dgc.client.gcInterval=3600000 
--Dsun.rmi.dgc.server.gcInterval=3600000 -Dprogram.name=run.sh
-
-  CLASSPATH: /opt/jboss/bin/run.jar:/lib/tools.jar
-
-=========================================================================
-
-22:55:48,686 INFO  [Server] Starting JBoss (MX MicroKernel)...
-22:55:48,688 INFO  [Server] Release ID: JBoss [Zion] 4.0.4.GA (build: CVSTag=JBoss_4_0_4_GA date=200605151000)
-22:55:48,690 INFO  [Server] Home Dir: /opt/jboss-4.0.4.GA
-22:55:48,692 INFO  [Server] Home URL: file:/opt/jboss-4.0.4.GA/
-22:55:48,695 INFO  [Server] Patch URL: null
-22:55:48,697 INFO  [Server] Server Name: default
-22:55:48,698 INFO  [Server] Server Home Dir: /opt/jboss-4.0.4.GA/server/default
-22:55:48,701 INFO  [Server] Server Home URL: file:/opt/jboss-4.0.4.GA/server/default/
-22:55:48,702 INFO  [Server] Server Log Dir: /opt/jboss-4.0.4.GA/server/default/log
-22:55:48,704 INFO  [Server] Server Temp Dir: /opt/jboss-4.0.4.GA/server/default/tmp
-22:55:48,706 INFO  [Server] Root Deployment Filename: jboss-service.xml
-22:55:49,092 INFO  [ServerInfo] Java version: 1.5.0_06,Apple Computer, Inc.
-22:55:49,101 INFO  [ServerInfo] Java VM: Java HotSpot(TM) Server VM 1.5.0_06-64,&quot;Apple Computer, Inc.&quot;
-22:55:49,102 INFO  [ServerInfo] OS-System: Mac OS X 10.4.8,i386
-22:55:49,803 INFO  [Server] Core system initialized
-22:55:53,379 INFO  [WebService] Using RMI server codebase: http://rattlesnake:8083/
-22:55:53,400 INFO  [Log4jService$URLWatchTimerTask] Configuring from URL: resource:log4j.xml
-22:55:54,034 INFO  [NamingService] JNDI bootstrap JNP=/0.0.0.0:1099, RMI=/0.0.0.0:1098, backlog=50, 
-no client SocketFactory, Server SocketFactory=class
-org.jboss.net.sockets.DefaultSocketFactory
-22:55:58,475 INFO  [Embedded] Catalina naming disabled
-22:55:58,566 INFO  [ClusterRuleSetFactory] Unable to find a cluster rule set in the classpath. 
-Will load the default rule set.
-22:55:58,569 INFO  [ClusterRuleSetFactory] Unable to find a cluster rule set in the classpath. 
-Will load the default rule set.
-22:55:59,110 INFO  [Http11BaseProtocol] Initializing Coyote HTTP/1.1 on http-0.0.0.0-8080
-22:55:59,114 INFO  [Catalina] Initialization processed in 545 ms
-22:55:59,116 INFO  [StandardService] Starting service jboss.web
-22:55:59,121 INFO  [StandardEngine] Starting Servlet Engine: Apache Tomcat/5.5.17
-22:55:59,179 INFO  [StandardHost] XML validation disabled
-22:55:59,221 INFO  [Catalina] Server startup in 105 ms
-22:55:59,600 INFO  [TomcatDeployer] deploy, ctxPath=/invoker, warUrl=.../deploy/http-invoker.sar/invoker.war/
-22:55:59,874 INFO  [WebappLoader] Dual registration of jndi stream handler: factory already defined
-22:56:00,899 INFO  [TomcatDeployer] deploy, ctxPath=/, warUrl=.../deploy/jbossweb-tomcat55.sar/ROOT.war/
-22:56:01,700 INFO  [TomcatDeployer] deploy, ctxPath=/jbossws, warUrl=.../tmp/deploy/tmp60528jbossws-exp.war/
-22:56:01,891 INFO  [SubscriptionManager] Bound event dispatcher to java:/EventDispatcher
-22:56:02,203 INFO  [TomcatDeployer] deploy, ctxPath=/jbossmq-httpil, 
-warUrl=.../deploy/jms/jbossmq-httpil.sar/jbossmq-httpil.war/
-22:56:04,546 INFO  [TomcatDeployer] deploy, ctxPath=/web-console, 
-warUrl=.../deploy/management/console-mgr.sar/web-console.war/
-22:56:05,690 INFO  [MailService] Mail Service bound to java:/Mail
-22:56:07,215 INFO  [RARDeployment] Required license terms exist, view META-INF/ra.xml in 
-.../deploy/activemq-ra.rar/
-22:56:07,452 INFO  [XBeanXmlBeanDefinitionReader] Loading XML bean definitions from class 
-path resource [broker-config.xml]
-22:56:07,750 INFO  [ClassPathXmlApplicationContext] Bean factory for application context 
-[org.apache.xbean.spring.context.ClassPathXmlApplicationContext;hashCode=13887543]:
-org.springframework.beans.factory.support.DefaultListableBeanFactory defining
-beans [org.apache.activemq.xbean.XBeanBrokerService]; root of BeanFactory hierarchy
-22:56:07,765 INFO  [ClassPathXmlApplicationContext] 1 beans defined in application context
-[org.apache.xbean.spring.context.ClassPathXmlApplicationContext;hashCode=13887543]
-22:56:07,773 INFO  [CollectionFactory] JDK 1.4+ collections available
-22:56:07,778 INFO  [ClassPathXmlApplicationContext] Unable to locate MessageSource with name 
-&#39;messageSource&#39;: using default
-[org.springframework.context.support.DelegatingMessageSource@5fee96]
-22:56:07,781 INFO  [ClassPathXmlApplicationContext] Unable to locate ApplicationEventMulticaster 
-with name &#39;applicationEventMulticaster&#39;: using default
-[org.springframework.context.event.SimpleApplicationEventMulticaster@78c714]
-22:56:07,783 INFO  [DefaultListableBeanFactory] Pre-instantiating singletons in factory
- [org.springframework.beans.factory.support.DefaultListableBeanFactory
-defining beans [org.apache.activemq.xbean.XBeanBrokerService]; root of BeanFactory hierarchy]
-22:56:08,181 INFO  [BrokerService] ActiveMQ 4.0.2 JMS Message Broker (bruce.broker1) is starting
-22:56:08,181 INFO  [BrokerService] For help or more information please see: 
-http://incubator.apache.org/activemq/
-22:56:09,989 INFO  [JDBCPersistenceAdapter] Database driver recognized: 
-[apache_derby_embedded_jdbc_driver]
-22:56:11,026 INFO  [JournalPersistenceAdapter] Journal Recovery Started from: Active Journal: 
-using 5 x 20.0 Megs at: /opt/jboss-4.0.4.GA/activemq-data/journal
-22:56:11,169 INFO  [JournalPersistenceAdapter] Journal Recovered: 0 message(s) in transactions recovered.
-22:56:11,489 INFO  [TransportServerThreadSupport] Listening for connections at: tcp://rattlesnake:61616
-22:56:11,491 WARN  [MulticastDiscoveryAgent] brokerName not set
-22:56:11,519 INFO  [TransportConnector] Connector bruce.broker1 Started
-22:56:11,522 INFO  [NetworkConnector] Network Connector bridge Started
-22:56:11,522 INFO  [BrokerService] ActiveMQ JMS Message Broker 
-(bruce.broker1, ID:rattlesnake-59052-1161060967859-1:0) started
-22:56:11,556 INFO  [RARDeployment] Required license terms exist, view META-INF/ra.xml in 
-.../deploy/jboss-ha-local-jdbc.rar
-22:56:11,599 INFO  [RARDeployment] Required license terms exist, view META-INF/ra.xml in 
-.../deploy/jboss-ha-xa-jdbc.rar
-22:56:11,623 INFO  [RARDeployment] Required license terms exist, view META-INF/ra.xml in 
-.../deploy/jboss-local-jdbc.rar
-22:56:11,647 INFO  [RARDeployment] Required license terms exist, view META-INF/ra.xml in 
-.../deploy/jboss-xa-jdbc.rar
-22:56:11,737 INFO  [RARDeployment] Required license terms exist, view META-INF/ra.xml in 
-.../deploy/jms/jms-ra.rar
-22:56:11,847 INFO  [RARDeployment] Required license terms exist, view META-INF/ra.xml in 
-.../deploy/mail-ra.rar
-22:56:12,251 INFO  [ConnectionFactoryBindingService] Bound ConnectionManager 
-&#39;jboss.jca:service=ConnectionFactoryBinding,name=activemq/QueueConnectionFactory&#39; to
-JNDI name &#39;java:activemq/QueueConnectionFactory&#39;
-22:56:12,258 INFO  [ConnectionFactoryBindingService] Bound ConnectionManager 
-&#39;jboss.jca:service=ConnectionFactoryBinding,name=activemq/TopicConnectionFactory&#39; to
-JNDI name &#39;java:activemq/TopicConnectionFactory&#39;
-22:56:12,265 INFO  [AdminObject] Bound admin object &#39;org.apache.activemq.command.ActiveMQQueue&#39; 
-at &#39;activemq/queue/outbound&#39;
-22:56:12,330 INFO  [AdminObject] Bound admin object &#39;org.apache.activemq.command.ActiveMQTopic&#39; 
-at &#39;activemq/topic/inbound&#39;
-22:56:13,246 INFO  [ConnectionFactoryBindingService] Bound ConnectionManager 
-&#39;jboss.jca:service=DataSourceBinding,name=DefaultDS&#39; to JNDI name &#39;java:DefaultDS&#39;
-22:56:13,842 INFO  [A] Bound to JNDI name: queue/A
-22:56:13,845 INFO  [B] Bound to JNDI name: queue/B
-22:56:13,846 INFO  [C] Bound to JNDI name: queue/C
-22:56:13,848 INFO  [D] Bound to JNDI name: queue/D
-22:56:13,850 INFO  [ex] Bound to JNDI name: queue/ex
-22:56:13,876 INFO  [testTopic] Bound to JNDI name: topic/testTopic
-22:56:13,879 INFO  [securedTopic] Bound to JNDI name: topic/securedTopic
-22:56:13,880 INFO  [testDurableTopic] Bound to JNDI name: topic/testDurableTopic
-22:56:13,883 INFO  [testQueue] Bound to JNDI name: queue/testQueue
-22:56:13,994 INFO  [UILServerILService] JBossMQ UIL service available at : /0.0.0.0:8093
-22:56:14,055 INFO  [DLQ] Bound to JNDI name: queue/DLQ
-22:56:14,375 INFO  [ConnectionFactoryBindingService] Bound ConnectionManager 
-&#39;jboss.jca:service=ConnectionFactoryBinding,name=JmsXA&#39; to JNDI name &#39;java:JmsXA&#39;
-22:56:14,525 INFO  [TomcatDeployer] deploy, ctxPath=/jmx-console, warUrl=.../deploy/jmx-console.war/
-22:56:14,991 INFO  [Http11BaseProtocol] Starting Coyote HTTP/1.1 on http-0.0.0.0-8080
-22:56:15,071 INFO  [ChannelSocket] JK: ajp13 listening on /0.0.0.0:8009
-22:56:15,082 INFO  [JkMain] Jk running ID=0 time=0/25  config=null
-22:56:15,108 INFO  [Server] JBoss (MX MicroKernel) [4.0.4.GA (build: CVSTag=JBoss_4_0_4_GA date=200605151000)] 
-Started in 26s:398ms
-]]></script>
-</div></div>
-<p>Note the startup messages from both ActiveMQ and from the <code>AdminObject}}s creating an {{ActiveMQQueue</code> and an <code>ActiveMQTopic</code>. These are good indications that the configuration is correct, but needs to be verified a bit further. This is covered in the next section.</p>
-
-<h2 id="JBossIntegration-TestingtheIntegration">Testing the Integration</h2>
-
-<p>The seventh and final step is to perform a slightly more comprehensive smoke test of the integration. This can be accomplished using Apache Ant via the examples that come with the ActiveMQ binary distribution. An Ant build.xml file is included which provides easy access to a simple consumer and a simple producer. The producer will be used to send messages that are received by the consumer. To proceed with this testing, just follow the steps below:</p>
-<ol><li>In the first terminal, start up JBoss. The same startup script can be used here as was used above.</li><li>In the second terminal, use the commands below to run the ActiveMQ consumer:
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-$ cd /opt/incubator-activemq-4.0.2/examples    #note in activemq v5 the directory is just &quot;example&quot; not &quot;examples&quot;
-$ ant consumer
-Buildfile: build.xml
-
-init:
-    [mkdir] Created dir: /opt/incubator-activemq-4.0.2/example/target/classes
-    [mkdir] Created dir: /opt/incubator-activemq-4.0.2/example/src/ddl
-
-compile:
-    [javac] Compiling 6 source files to /opt/incubator-activemq-4.0.2/example/target/classes
-
-consumer:
-     [echo] Running consumer against server at $url = tcp://localhost:61616 for subject $subject = TEST.FOO
-     [java] Connecting to URL: tcp://localhost:61616
-     [java] Consuming queue: TEST.FOO
-     [java] Using non-durable subscription
-     [java] We are about to wait until we consume: 10 message(s) then we will shutdown
-]]></script>
-</div></div></li><li>In the third terminal, use the commands below to run the ActiveMQ producer:
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
-$ cd /opt/incubator-activemq-4.0.2/examples
-$ ant producer
-Buildfile: build.xml
-
-init:
-
-compile:
-
-producer:
-     [echo] Running producer against server at $url = tcp://localhost:61616 for subject $subject = TEST.FOO
-     [java] Connecting to URL: tcp://localhost:61616
-     [java] Publishing a Message with size 1000 to queue: TEST.FOO
-     [java] Using non-durable publishing
-     [java] Sleeping between publish 0 ms
-     [java] Sending message: Message: 0 sent at: Mon Oct 16 23:21:08 MDT 2006  ...
-     [java] Sending message: Message: 1 sent at: Mon Oct 16 23:21:08 MDT 2006  ...
-     [java] Sending message: Message: 2 sent at: Mon Oct 16 23:21:08 MDT 2006  ...
-     [java] Sending message: Message: 3 sent at: Mon Oct 16 23:21:08 MDT 2006  ...
-     [java] Sending message: Message: 4 sent at: Mon Oct 16 23:21:08 MDT 2006  ...
-     [java] Sending message: Message: 5 sent at: Mon Oct 16 23:21:08 MDT 2006  ...
-     [java] Sending message: Message: 6 sent at: Mon Oct 16 23:21:08 MDT 2006  ...
-     [java] Sending message: Message: 7 sent at: Mon Oct 16 23:21:08 MDT 2006  ...
-     [java] Sending message: Message: 8 sent at: Mon Oct 16 23:21:08 MDT 2006  ...
-     [java] Sending message: Message: 9 sent at: Mon Oct 16 23:21:08 MDT 2006  ...
-     [java] Done.
-     [java] connection {
-     [java]   session {
-     [java]     messageCount{ count: 10 unit: count startTime: 1161062468001 lastSampleTime: 
-1161062468340 description: Number of messages exchanged }
-     [java]     messageRateTime{ count: 10 maxTime: 142 minTime: 1 totalTime: 315 averageTime: 31.5 
-averageTimeExMinMax: 21.5 averagePerSecond: 31.746031746031747
-averagePerSecondExMinMax: 46.51162790697674 unit: millis startTime: 1161062468002 lastSampleTime: 
-1161062468340 description: Time taken to process a message (thoughtput rate) }
-     [java]     pendingMessageCount{ count: 0 unit: count startTime: 1161062468001 lastSampleTime: 
-1161062468001 description: Number of pending messages }
-     [java]     expiredMessageCount{ count: 0 unit: count startTime: 1161062468001 lastSampleTime: 
-1161062468001 description: Number of expired messages }
-     [java]     messageWaitTime{ count: 0 maxTime: 0 minTime: 0 totalTime: 0 averageTime: 0.0 
-averageTimeExMinMax: 0.0 averagePerSecond: 0.0
-averagePerSecondExMinMax: 0.0 unit: millis startTime: 1161062468002 lastSampleTime: 1161062468002 
-description: Time spent by a message before being delivered }
-     [java]     durableSubscriptionCount{ count: 0 unit: count startTime: 1161062468002 lastSampleTime: 
-1161062468002 description: The number of durable
-subscriptions }
-
-     [java]     producers {
-     [java]       producer queue://TEST.FOO {
-     [java]         messageCount{ count: 10 unit: count startTime: 1161062468025 lastSampleTime: 
-1161062468340 description: Number of messages processed }
-     [java]         messageRateTime{ count: 10 maxTime: 142 minTime: 1 totalTime: 315 averageTime: 
-31.5 averageTimeExMinMax: 21.5 averagePerSecond:
-31.746031746031747 averagePerSecondExMinMax: 46.51162790697674 unit: millis startTime: 1161062468025 
-lastSampleTime: 1161062468340 description: Time taken to
-process a message (thoughtput rate) }
-     [java]         pendingMessageCount{ count: 0 unit: count startTime: 1161062468025 lastSampleTime: 
-1161062468025 description: Number of pending messages }
-     [java]         messageRateTime{ count: 10 maxTime: 142 minTime: 1 totalTime: 315 averageTime: 31.5 
-averageTimeExMinMax: 21.5 averagePerSecond:
-31.746031746031747 averagePerSecondExMinMax: 46.51162790697674 unit: millis startTime: 1161062468025 
-lastSampleTime: 1161062468340 description: Time taken to
-process a message (thoughtput rate) }
-     [java]         expiredMessageCount{ count: 0 unit: count startTime: 1161062468025 lastSampleTime: 
-1161062468025 description: Number of expired messages }
-     [java]         messageWaitTime{ count: 0 maxTime: 0 minTime: 0 totalTime: 0 averageTime: 0.0 
-averageTimeExMinMax: 0.0 averagePerSecond: 0.0
-averagePerSecondExMinMax: 0.0 unit: millis startTime: 1161062468025 lastSampleTime: 1161062468025 
-description: Time spent by a message before being delivered }
-     [java]       }
-     [java]     }
-     [java]     consumers {
-     [java]     }
-     [java]   }
-     [java] }
-]]></script>
-</div></div></li></ol>
-
-
-<p>Step 1 above just starts up JBoss. Step 2 above starts up a simple message consumer that comes with ActiveMQ. Step 3 above starts up a simple message producer that comes with ActiveMQ. Though the message consumer and message producer are simple utilities, the each one accepts many parameters making them extremely useful for testing ActiveMQ configurations.</p>
-
-<p>To paraphrase, what just happened was that the message producer sent 10 messages to the TEST.FOO destination and the message consumer received 10 messages from the TEST.FOO destination. Despite being a simple test, it does utilize the ActiveMQ broker, albeit only on a single machine. The next logical step is to set up a full network of ActiveMQ brokers.</p>
-
-<p>After setting up one broker within one instance of JBoss, setting up another is made much easier, but requires another machine or operating system instance. But that's a whole separate article and something to address another day.</p>
-
-<h2 id="JBossIntegration-Conclusion">Conclusion</h2>
-
-<p>What has been demonstrated here is the integration of ActiveMQ with the JBoss application server. This integration is quite common and performed by many enterprises. I hope that this was helpful to people interested in the integration of ActiveMQ with JBoss application server. If you have any questions or are interested in consulting services surrounding ActiveMQ, please <a shape="rect" class="external-link" href="http://www.logicblaze.com/contact.jsp" rel="nofollow">contact us</a> for more information.</p>
-
-<h3 id="JBossIntegration-Resources">Resources</h3>
-
-<p>Below are the configurations for use with both Spring 1.x and Spring 2.x:</p>
-
-
-    
-
-<div class="plugin_attachments_container">
-    <div class="plugin_attachments_table_container">
-        <fieldset class="hidden">
-            <input type="hidden" class="plugin_attachments_macro_render_param" name="pageId" value="67786">
-            <input type="hidden" name="deleteConfirmMessage" value="Are you sure you want to send the attached file " _0="_0" to="to" the="the" trash="trash" only="only" a="a" space="space" administrator="administrator" can="can" undo="undo" this="this" action.="action.">
-                                                    <input type="hidden" name="outputType" value="display">
-        </fieldset>
-                
-
-
-
-
-
-
-    
-
-
-
-<table class="attachments aui"><thead><tr><th colspan="1" rowspan="1" class="expand-column attachment-summary-toggle">&#160;</th><th colspan="1" rowspan="1" class="filename-column">            <a shape="rect" href="integrating-apache-activemq-with-jboss.xml?sortBy=name&amp;sortOrder=ascending">File</a>
-        </th><th colspan="1" rowspan="1" class="modified-column">            <span class="propersortedby $sortOrder"><a shape="rect" href="integrating-apache-activemq-with-jboss.xml?sortBy=date&amp;sortOrder=descending">Modified</a></span>
-        </th></tr></thead><tbody><tr class="attachment-row" id="attachment-59670763" data-attachment-id="59670763" data-attachment-idx="1"><td colspan="1" rowspan="1" class="attachment-summary-toggle">
-                    <span class="icon icon-section-closed" title="Show more info"></span>
-                </td><td colspan="1" rowspan="1" class="filename-column">
-                    
-
-    
-
-
-<span class="icon icon-file-unknown" title="File">File</span>                    <a shape="rect" class="filename" href="jboss-integration.data/amq-spring-1.2.6.tgz?api=v2" title="Download" data-filename="amq-spring-1.2.6.tgz" data-type="application/x-tar" data-linked-resource-container-id="67786">
-                        amq-spring-1.2.6.tgz
-                    </a>
-                                    </td><td colspan="1" rowspan="1" class="attachment-created modified-column">
-                    <span>Oct 03, 2007</span>
-                    <span>by</span>
-                        <a shape="rect" class="url fn confluence-userlink" href="https://cwiki.apache.org/confluence/display/~bsnyder">Bruce Snyder</a>                </td></tr><tr class="attachment-summary attachment-summary-59670763 hidden" data-attachment-id="59670763" data-attachment-filename="amq-spring-1.2.6.tgz"><td colspan="1" rowspan="1" class="attachment-summary-toggle"></td><td colspan="2" rowspan="1" class="attachment-details-wrapper">
-
-                    
-                                        <p class="attachment-labels">Labels</p>
-                    
-<div class="labels-section-content content-column" entityid="59670763" entitytype="attachment">
-	<div class="labels-content">
-		
-    <ul class="label-list  has-pen"><li class="no-labels-message">
-            No labels
-        </li><li class="labels-edit-container">
-            <a shape="rect" class="show-labels-editor" href="#" title="Edit Labels">
-                <span class="aui-icon aui-icon-small aui-iconfont-edit-small">Edit Labels</span>
-            </a>
-        </li></ul>
-
-    </div>
-</div>
-
-                                            <div class="attachment-history-wrapper"></div>
-                    
-                                            <div class="attachment-buttons">
-                                                            <a shape="rect" class="aui-button previewAttachmentLink" data-filename="amq-spring-1.2.6.tgz" data-file-src="/confluence/download/attachments/67786/amq-spring-1.2.6.tgz?api=v2" data-linked-resource-default-alias="amq-spring-1.2.6.tgz" data-mime-type="application/x-tar" data-linked-resource-container-id="67786" data-linked-resource-id="59670763">Preview</a>
-                            
-                                                    </div>
-                                    </td></tr><tr class="attachment-row" id="attachment-59670764" data-attachment-id="59670764" data-attachment-idx="2"><td colspan="1" rowspan="1" class="attachment-summary-toggle">
-                    <span class="icon icon-section-closed" title="Show more info"></span>
-                </td><td colspan="1" rowspan="1" class="filename-column">
-                    
-
-    
-
-
-<span class="icon icon-file-unknown" title="File">File</span>                    <a shape="rect" class="filename" href="jboss-integration.data/amq-spring-2.0.tgz?api=v2" title="Download" data-filename="amq-spring-2.0.tgz" data-type="application/x-tar" data-linked-resource-container-id="67786">
-                        amq-spring-2.0.tgz
-                    </a>
-                                    </td><td colspan="1" rowspan="1" class="attachment-created modified-column">
-                    <span>Oct 03, 2007</span>
-                    <span>by</span>
-                        <a shape="rect" class="url fn confluence-userlink" href="https://cwiki.apache.org/confluence/display/~bsnyder">Bruce Snyder</a>                </td></tr><tr class="attachment-summary attachment-summary-59670764 hidden" data-attachment-id="59670764" data-attachment-filename="amq-spring-2.0.tgz"><td colspan="1" rowspan="1" class="attachment-summary-toggle"></td><td colspan="2" rowspan="1" class="attachment-details-wrapper">
-
-                    
-                                        <p class="attachment-labels">Labels</p>
-                    
-<div class="labels-section-content content-column" entityid="59670764" entitytype="attachment">
-	<div class="labels-content">
-		
-    <ul class="label-list  has-pen"><li class="no-labels-message">
-            No labels
-        </li><li class="labels-edit-container">
-            <a shape="rect" class="show-labels-editor" href="#" title="Edit Labels">
-                <span class="aui-icon aui-icon-small aui-iconfont-edit-small">Edit Labels</span>
-            </a>
-        </li></ul>
-
-    </div>
-</div>
-
-                                            <div class="attachment-history-wrapper"></div>
-                    
-                                            <div class="attachment-buttons">
-                                                            <a shape="rect" class="aui-button previewAttachmentLink" data-filename="amq-spring-2.0.tgz" data-file-src="/confluence/download/attachments/67786/amq-spring-2.0.tgz?api=v2" data-linked-resource-default-alias="amq-spring-2.0.tgz" data-mime-type="application/x-tar" data-linked-resource-container-id="67786" data-linked-resource-id="59670764">Preview</a>
-                            
-                                                    </div>
-                                    </td></tr></tbody></table>
-    </div>
-    <div class="plugin_attachments_upload_container">
-            </div>
-
-    <div>
-                    <a shape="rect" class="download-all-link" href="/confluence/pages/downloadallattachments.action?pageId=67786" title="Download all the latest versions of attachments on this page as single zip file.">Download All</a>
-            </div>
-</div></div>
+<div class="wiki-content maincontent"><structured-macro ac:macro-id="bbc703bb-67f6-445e-be5e-58cf87290290" ac:name="include" ac:schema-version="1"><parameter ac:name=""><link><page ri:content-title="Integrating Apache ActiveMQ with JBoss"></page></link></parameter></structured-macro></div>
 

http://git-wip-us.apache.org/repos/asf/activemq-web/blob/7a7d976c/jca-container.xml
----------------------------------------------------------------------
diff --git a/jca-container.xml b/jca-container.xml
index 1973feb..260b5b3 100644
--- a/jca-container.xml
+++ b/jca-container.xml
@@ -1,22 +1,22 @@
-<div class="wiki-content maincontent"><div class="confluence-information-macro confluence-information-macro-information"><p class="title">The JCA Container is moving</p><span class="aui-icon aui-icon-small aui-iconfont-info confluence-information-macro-icon"></span><div class="confluence-information-macro-body">
+<div class="wiki-content maincontent"><structured-macro ac:macro-id="16f901d0-bd02-4fa3-9c19-e0c3ae27f48b" ac:name="info" ac:schema-version="1"><parameter ac:name="title">The JCA Container is moving</parameter><rich-text-body>
 <p>We will continune to support the ActiveMQ JCA Container up until ActiveMQ 3.1.</p>
 
-<p>After that point we will be moving to <a shape="rect" class="external-link" href="http://jencks.codehaus.org/" rel="nofollow">Jencks</a> which is a migration of the ActiveMQ codebase together with code <a shape="rect" class="external-link" href="http://geronimo.apache.org">Geronimo</a> and from some other contributors.</p>
+<p>After that point we will be moving to <a shape="rect" href="http://jencks.codehaus.org/">Jencks</a> which is a migration of the ActiveMQ codebase together with code <a shape="rect" href="http://geronimo.apache.org">Geronimo</a> and from some other contributors.</p>
 
 <p>Jencks is completely logically equivalent to the ActiveMQ JCA Container and migrating to it is pretty simple (mostly just a class name change for the JCA container) - though the benefits of Jencks are that it supports full XA recovery and works well with Geronimo's TransactionManager and WorkManager.</p>
 
-<p>So we do recommend you migrate to <a shape="rect" class="external-link" href="http://jencks.codehaus.org/" rel="nofollow">Jencks</a> whenever its easy for you to do so; projects such as <a shape="rect" class="external-link" href="http://lingo.codehaus.org/" rel="nofollow">Lingo</a> and <a shape="rect" class="external-link" href="http://servicemix.org/" rel="nofollow">ServiceMix</a> already have and it was an easy migration.</p></div></div>
+<p>So we do recommend you migrate to <a shape="rect" href="http://jencks.codehaus.org/">Jencks</a> whenever its easy for you to do so; projects such as <a shape="rect" href="http://lingo.codehaus.org/">Lingo</a> and <a shape="rect" href="http://servicemix.org/">ServiceMix</a> already have and it was an easy migration.</p></rich-text-body></structured-macro>
 <p>We have a lightweight, easily embeddable Spring based JCA container which allows us to provide MDB like functionality inside any Java application without requiring a full EJB container.</p>
 
 <p>This allows us to support <em>message driven pojos</em> using dependency injection for efficient JMS consumption together with pooling of the pojos using lightweight containers rather than relying on EJB.</p>
 
 <p>The JCA container also makes it easy to programatically at runtime create new message driven pojos rather than relying on the fixed deployment-time only option with EJB.</p>
 
-<h2 id="JCAContainer-Example">Example</h2>
+<h2>Example</h2>
 
-<p>Here is <a shape="rect" class="external-link" href="http://docs.codehaus.org/download/attachments/23776/spring.xml" rel="nofollow">an example</a> of the Spring XML to deploy a pojo (EchoBean) on an inbound JMS subscription, on a topic in this particular example.</p>
+<p>Here is <a shape="rect" href="http://docs.codehaus.org/download/attachments/23776/spring.xml">an example</a> of the Spring XML to deploy a pojo (EchoBean) on an inbound JMS subscription, on a topic in this particular example.</p>
 
-<p>Firstly we can create as many JCAContainer instances as we need; currently we create one per JCA <a shape="rect" href="resource-adapter.xml">Resource Adapter</a> (i.e. JMS provider). The JCAContainer also uses a WorkManager which is JCA speak for a bunch of thread pools. We can share the WorkManager across JCAContainer instances or create one per JCAContainer.</p>
+<p>Firstly we can create as many JCAContainer instances as we need; currently we create one per JCA <link><page ri:content-title="Resource Adapter"></page></link> (i.e. JMS provider). The JCAContainer also uses a WorkManager which is JCA speak for a bunch of thread pools. We can share the WorkManager across JCAContainer instances or create one per JCAContainer.</p>
 
 <p>Once we have a JCAContainer we can add as many JCAConnector instances to it, via the <strong>addConnector</strong> factory method, each one representing a JMS subscription and providing a pool of POJOs to process the message. The subscription details are specified by an activationSpec property which is a bean typically dependent on the JMS provider; this allows providers to add new extensions while leaving your application code pure JMS.</p>
 
@@ -24,19 +24,19 @@
 
 <p><strong>Note</strong> you must set the <strong>singleton</strong> flag to false for the POJOs if they are not thread safe.</p>
 
-<h2 id="JCAContainer-Requirements">Requirements</h2>
+<h2>Requirements</h2>
 
 <p>To be able to use the JCA container, you just need the following jars on your classpath</p>
-<ul><li><a shape="rect" href="initial-configuration.xml">required ActiveMQ jars</a> if you are using ActiveMQ as your JMS provider - or your provider's jars if not</li><li>activemq-container.jar</li><li>spring.jar</li><li>J2EE.jar (for the JCA APIs). If you are inside Tomcat, it doesn't like j2ee.jar on the classpath, so use the individual jars from Geronimo - e.g. geronimo-spec-j2ee-connector-*.jar for the JCA APIs</li><li>commons-collections.jar</li><li>commons-pool.jar</li><li>aopalliance.jar (a temporary dependency introduced by Spring's use of the TargetSource, we should be able to remove this dependency later on).</li></ul>
+<ul><li><link><page ri:content-title="Initial Configuration"></page><link-body>required ActiveMQ jars</link-body></link> if you are using ActiveMQ as your JMS provider - or your provider's jars if not</li><li>activemq-container.jar</li><li>spring.jar</li><li>J2EE.jar (for the JCA APIs). If you are inside Tomcat, it doesn't like j2ee.jar on the classpath, so use the individual jars from Geronimo - e.g. geronimo-spec-j2ee-connector-*.jar for the JCA APIs</li><li>commons-collections.jar</li><li>commons-pool.jar</li><li>aopalliance.jar (a temporary dependency introduced by Spring's use of the TargetSource, we should be able to remove this dependency later on).</li></ul>
 
 
 <p><strong>Note</strong> the classes and resources in activemq-container.jar are not included in activemq.jar</p>
 
 <p>To use the JCA Container please use the 2.x code release. Several problems were found and fixed with the 1.x branch of code.</p>
 
-<h2 id="JCAContainer-Thingstowatch">Things to watch</h2>
+<h2>Things to watch</h2>
 
-<p>By default the ActiveMQ <a shape="rect" href="resource-adapter.xml">Resource Adapter</a>  will try to connect to a remote broker (ie. tcp://localhost:61616).  Also if you want to set how the broker is configured via XML then try the <em>brokerXmlConfig</em> property.</p>
+<p>By default the ActiveMQ <link><page ri:content-title="Resource Adapter"></page></link>  will try to connect to a remote broker (ie. tcp://localhost:61616).  Also if you want to set how the broker is configured via XML then try the <em>brokerXmlConfig</em> property.</p>
 
 <p><em>Note:</em> In AMQ 3.x the default behavior is the ActiveMQ resource adapter will create an embedded broker</p></div>
 

http://git-wip-us.apache.org/repos/asf/activemq-web/blob/7a7d976c/jdbc-master-slave.xml
----------------------------------------------------------------------
diff --git a/jdbc-master-slave.xml b/jdbc-master-slave.xml
index 721ea9a..3054e0a 100644
--- a/jdbc-master-slave.xml
+++ b/jdbc-master-slave.xml
@@ -1,60 +1,57 @@
-<div class="wiki-content maincontent"><h2 id="JDBCMasterSlave-JDBCMasterSlave">JDBC Master Slave</h2>
+<div class="wiki-content maincontent"><h2>JDBC Master Slave</h2>
 
 <p>First supported in ActiveMQ version 4.1</p>
 
 <p>If you are using pure JDBC and not using the high performance journal then you are generally relying on your database as your single point of failure and persistence engine. If you do not have really high performance requirements this approach can make a lot of sense as you have a single persistence engine to backup and manage etc.</p>
 
-<h3 id="JDBCMasterSlave-Startup">Startup</h3>
+<h3>Startup</h3>
 
 <p>When using just JDBC as the data source you can use a Master Slave approach, running as many brokers as you wish as this diagram shows. On startup one master grabs an exclusive lock in the broker database - all other brokers are slaves and pause waiting for the exclusive lock.</p>
 
-<p><span class="confluence-embedded-file-wrapper"><img class="confluence-embedded-image" src="jdbc-master-slave.data/Startup.png" data-image-src="/confluence/download/attachments/35908/Startup.png?version=1&amp;modificationDate=1153463898000&amp;api=v2" data-unresolved-comment-count="0" data-linked-resource-id="3244" data-linked-resource-version="1" data-linked-resource-type="attachment" data-linked-resource-default-alias="Startup.png" data-base-url="https://cwiki.apache.org/confluence" data-linked-resource-content-type="image/png" data-linked-resource-container-id="35908" data-linked-resource-container-version="19"></span></p>
+<p><image><attachment ri:filename="Startup.png"></attachment></image></p>
 
-<p>Clients should be using the <a shape="rect" href="failover-transport-reference.xml">Failover Transport</a> to connect to the available brokers. e.g. using a URL something like the following</p>
+<p>Clients should be using the <link><page ri:content-title="Failover Transport Reference"></page><link-body>Failover Transport</link-body></link> to connect to the available brokers. e.g. using a URL something like the following</p>
 
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
+<structured-macro ac:macro-id="db1beb4a-1c76-4570-a616-b7c6c06728ba" ac:name="code" ac:schema-version="1"><plain-text-body>
 failover:(tcp://broker1:61616,tcp://broker2:61616,tcp://broker3:61616)
-]]></script>
-</div></div>
+</plain-text-body></structured-macro>
 
 <p>Only the master broker starts up its transport connectors and so the clients can only connect to the master.</p>
 
-<h3 id="JDBCMasterSlave-Masterfailure">Master failure</h3>
+<h3>Master failure</h3>
 
 <p>If the master looses connection to the database or looses the exclusive lock then it immediately shuts down. If a master shuts down or fails, one of the other slaves will grab the lock and so the topology switches to the following diagram</p>
 
-<p><span class="confluence-embedded-file-wrapper"><img class="confluence-embedded-image" src="jdbc-master-slave.data/MasterFailed.png" data-image-src="/confluence/download/attachments/35908/MasterFailed.png?version=1&amp;modificationDate=1153463898000&amp;api=v2" data-unresolved-comment-count="0" data-linked-resource-id="3264" data-linked-resource-version="1" data-linked-resource-type="attachment" data-linked-resource-default-alias="MasterFailed.png" data-base-url="https://cwiki.apache.org/confluence" data-linked-resource-content-type="image/png" data-linked-resource-container-id="35908" data-linked-resource-container-version="19"></span></p>
+<p><image><attachment ri:filename="MasterFailed.png"></attachment></image></p>
 
 <p>One of the other other slaves immediately grabs the exclusive lock on the database to them commences becoming the master, starting all of its transport connectors.</p>
 
 <p>Clients loose connection to the stopped master and then the failover transport tries to connect to the available brokers - of which the only one available is the new master.</p>
 
-<h3 id="JDBCMasterSlave-Masterrestart">Master restart</h3>
+<h3>Master restart</h3>
 
 <p>At any time you can restart other brokers which join the cluster and start as slaves waiting to become a master if the master is shutdown or a failure occurs. So the following topology is created after a restart of an old master...</p>
 
-<p><span class="confluence-embedded-file-wrapper"><img class="confluence-embedded-image" src="jdbc-master-slave.data/MasterRestarted.png" data-image-src="/confluence/download/attachments/35908/MasterRestarted.png?version=1&amp;modificationDate=1153463898000&amp;api=v2" data-unresolved-comment-count="0" data-linked-resource-id="3252" data-linked-resource-version="1" data-linked-resource-type="attachment" data-linked-resource-default-alias="MasterRestarted.png" data-base-url="https://cwiki.apache.org/confluence" data-linked-resource-content-type="image/png" data-linked-resource-container-id="35908" data-linked-resource-container-version="19"></span></p>
+<p><image><attachment ri:filename="MasterRestarted.png"></attachment></image></p>
 
-<h3 id="JDBCMasterSlave-ConfiguringJDBCMasterSlave">Configuring JDBC Master Slave</h3>
+<h3>Configuring JDBC Master Slave</h3>
 
 <p>By default if you use the <strong>&lt;jdbcPersistenceAdapter/&gt;</strong> to avoid the high performance journal you will be using JDBC Master Slave by default. You just need to run more than one broker and point the client side URIs to them to get master/slave. This works because they both try an acquire an exclusive lock on a shared table in the database and only one will succeed.</p>
 
 <p>The following example shows how to configure the ActiveMQ broker in JDBC Master Slave mode</p>
 
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
+<structured-macro ac:macro-id="19af32e7-f11e-422b-be63-ffa96eff017b" ac:name="code" ac:schema-version="1"><plain-text-body>
 &lt;beans&gt;
 
   &lt;!-- Allows us to use system properties as variables in this configuration file --&gt;
-  &lt;bean class=&quot;org.springframework.beans.factory.config.PropertyPlaceholderConfigurer&quot;/&gt;
+  &lt;bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/&gt;
   
-  &lt;broker xmlns=&quot;http://activemq.apache.org/schema/core&quot;&gt;
+  &lt;broker xmlns="http://activemq.apache.org/schema/core"&gt;
 
     &lt;destinationPolicy&gt;
       &lt;policyMap&gt;&lt;policyEntries&gt;
         
-          &lt;policyEntry topic=&quot;FOO.&gt;&quot;&gt;
+          &lt;policyEntry topic="FOO.&gt;"&gt;
             &lt;dispatchPolicy&gt;
               &lt;strictOrderDispatchPolicy /&gt;
             &lt;/dispatchPolicy&gt;
@@ -68,15 +65,15 @@ failover:(tcp://broker1:61616,tcp://broker2:61616,tcp://broker3:61616)
   
   
     &lt;persistenceAdapter&gt;
-        &lt;jdbcPersistenceAdapter dataDirectory=&quot;${activemq.base}/activemq-data&quot;/&gt;
+        &lt;jdbcPersistenceAdapter dataDirectory="${activemq.base}/activemq-data"/&gt;
 
         &lt;!-- 
-        &lt;jdbcPersistenceAdapter dataDirectory=&quot;activemq-data&quot; dataSource=&quot;#oracle-ds&quot;/&gt;
+        &lt;jdbcPersistenceAdapter dataDirectory="activemq-data" dataSource="#oracle-ds"/&gt;
         --&gt; 
     &lt;/persistenceAdapter&gt;
   
     &lt;transportConnectors&gt;
-       &lt;transportConnector name=&quot;default&quot; uri=&quot;tcp://localhost:61616&quot;/&gt;
+       &lt;transportConnector name="default" uri="tcp://localhost:61616"/&gt;
     &lt;/transportConnectors&gt;
     
   &lt;/broker&gt;
@@ -85,50 +82,50 @@ failover:(tcp://broker1:61616,tcp://broker2:61616,tcp://broker3:61616)
   
   &lt;!-- Postgres DataSource Sample Setup --&gt;
   &lt;!-- 
-  &lt;bean id=&quot;postgres-ds&quot; class=&quot;org.postgresql.ds.PGPoolingDataSource&quot;&gt;
-    &lt;property name=&quot;serverName&quot; value=&quot;localhost&quot;/&gt;
-    &lt;property name=&quot;databaseName&quot; value=&quot;activemq&quot;/&gt;
-    &lt;property name=&quot;portNumber&quot; value=&quot;0&quot;/&gt;
-    &lt;property name=&quot;user&quot; value=&quot;activemq&quot;/&gt;
-    &lt;property name=&quot;password&quot; value=&quot;activemq&quot;/&gt;
-    &lt;property name=&quot;dataSourceName&quot; value=&quot;postgres&quot;/&gt;
-    &lt;property name=&quot;initialConnections&quot; value=&quot;1&quot;/&gt;
-    &lt;property name=&quot;maxConnections&quot; value=&quot;10&quot;/&gt;
+  &lt;bean id="postgres-ds" class="org.postgresql.ds.PGPoolingDataSource"&gt;
+    &lt;property name="serverName" value="localhost"/&gt;
+    &lt;property name="databaseName" value="activemq"/&gt;
+    &lt;property name="portNumber" value="0"/&gt;
+    &lt;property name="user" value="activemq"/&gt;
+    &lt;property name="password" value="activemq"/&gt;
+    &lt;property name="dataSourceName" value="postgres"/&gt;
+    &lt;property name="initialConnections" value="1"/&gt;
+    &lt;property name="maxConnections" value="10"/&gt;
   &lt;/bean&gt;
   --&gt;
   
   &lt;!-- MySql DataSource Sample Setup --&gt;
   &lt;!-- 
-  &lt;bean id=&quot;mysql-ds&quot; class=&quot;org.apache.commons.dbcp.BasicDataSource&quot; destroy-method=&quot;close&quot;&gt;
-    &lt;property name=&quot;driverClassName&quot; value=&quot;com.mysql.jdbc.Driver&quot;/&gt;
-    &lt;property name=&quot;url&quot; value=&quot;jdbc:mysql://localhost/activemq?relaxAutoCommit=true&quot;/&gt;
-    &lt;property name=&quot;username&quot; value=&quot;activemq&quot;/&gt;
-    &lt;property name=&quot;password&quot; value=&quot;activemq&quot;/&gt;
-    &lt;property name=&quot;poolPreparedStatements&quot; value=&quot;true&quot;/&gt;
+  &lt;bean id="mysql-ds" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close"&gt;
+    &lt;property name="driverClassName" value="com.mysql.jdbc.Driver"/&gt;
+    &lt;property name="url" value="jdbc:mysql://localhost/activemq?relaxAutoCommit=true"/&gt;
+    &lt;property name="username" value="activemq"/&gt;
+    &lt;property name="password" value="activemq"/&gt;
+    &lt;property name="poolPreparedStatements" value="true"/&gt;
   &lt;/bean&gt;
   --&gt;  
    
   &lt;!-- Oracle DataSource Sample Setup --&gt;
   &lt;!--
-  &lt;bean id=&quot;oracle-ds&quot; class=&quot;org.apache.commons.dbcp.BasicDataSource&quot; destroy-method=&quot;close&quot;&gt;
-    &lt;property name=&quot;driverClassName&quot; value=&quot;oracle.jdbc.driver.OracleDriver&quot;/&gt;
-    &lt;property name=&quot;url&quot; value=&quot;jdbc:oracle:thin:@localhost:1521:AMQDB&quot;/&gt;
-    &lt;property name=&quot;username&quot; value=&quot;scott&quot;/&gt;
-    &lt;property name=&quot;password&quot; value=&quot;tiger&quot;/&gt;
-    &lt;property name=&quot;poolPreparedStatements&quot; value=&quot;true&quot;/&gt;
+  &lt;bean id="oracle-ds" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close"&gt;
+    &lt;property name="driverClassName" value="oracle.jdbc.driver.OracleDriver"/&gt;
+    &lt;property name="url" value="jdbc:oracle:thin:@localhost:1521:AMQDB"/&gt;
+    &lt;property name="username" value="scott"/&gt;
+    &lt;property name="password" value="tiger"/&gt;
+    &lt;property name="poolPreparedStatements" value="true"/&gt;
   &lt;/bean&gt;
   --&gt;
       
   &lt;!-- Embedded Derby DataSource Sample Setup --&gt;
   &lt;!-- 
-  &lt;bean id=&quot;derby-ds&quot; class=&quot;org.apache.derby.jdbc.EmbeddedDataSource&quot;&gt;
-    &lt;property name=&quot;databaseName&quot; value=&quot;derbydb&quot;/&gt;
-    &lt;property name=&quot;createDatabase&quot; value=&quot;create&quot;/&gt;
+  &lt;bean id="derby-ds" class="org.apache.derby.jdbc.EmbeddedDataSource"&gt;
+    &lt;property name="databaseName" value="derbydb"/&gt;
+    &lt;property name="createDatabase" value="create"/&gt;
   &lt;/bean&gt;
   --&gt;  
 
 &lt;/beans&gt;
-]]></script>
-</div></div>
+</plain-text-body></structured-macro>
+
 </div>
 


Mime
View raw message