[jboss-cvs] JBoss Messaging SVN: r2535 - in trunk/docs/userguide: en and 1 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Thu Mar 1 12:59:50 EST 2007


Author: timfox
Date: 2007-03-01 12:59:50 -0500 (Thu, 01 Mar 2007)
New Revision: 2535

Added:
   trunk/docs/userguide/en/modules/about.xml
   trunk/docs/userguide/en/modules/c_configuration.xml
   trunk/docs/userguide/en/modules/c_installation.xml
   trunk/docs/userguide/en/modules/c_overview.xml
   trunk/docs/userguide/en/modules/configuration.xml
   trunk/docs/userguide/en/modules/gettingstarted.xml
   trunk/docs/userguide/en/modules/installation.xml
   trunk/docs/userguide/en/modules/introduction.xml
   trunk/docs/userguide/en/modules/performance.xml
   trunk/docs/userguide/en/modules/runningexamples.xml
Removed:
   trunk/docs/userguide/en/modules/CLUST_configuration.xml
   trunk/docs/userguide/en/modules/CLUST_installation.xml
   trunk/docs/userguide/en/modules/CLUST_overview.xml
   trunk/docs/userguide/en/modules/UG12_about.xml
   trunk/docs/userguide/en/modules/UG12_configuration.xml
   trunk/docs/userguide/en/modules/UG12_gettingstarted.xml
   trunk/docs/userguide/en/modules/UG12_installation.xml
   trunk/docs/userguide/en/modules/UG12_introduction.xml
   trunk/docs/userguide/en/modules/UG12_performance.xml
   trunk/docs/userguide/en/modules/UG12_runningexamples.xml
Modified:
   trunk/docs/userguide/build.xml
   trunk/docs/userguide/en/master.xml
Log:
more updates


Modified: trunk/docs/userguide/build.xml
===================================================================
--- trunk/docs/userguide/build.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/build.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,7 +1,7 @@
 <project name="jbmessaging.documentation" default="all" basedir=".">
 
-  <property name="build.dir" value="${basedir}/../../output/docs/userguide-1.2"/>
-  <property name="pdf.name"  value="JBossMessagingUsersGuide-1.2.pdf"/>
+  <property name="build.dir" value="${basedir}/../../output/docs/userguide"/>
+  <property name="pdf.name"  value="JBossMessagingUsersGuide.pdf"/>
   <import file="${basedir}/../../lib/docbook-support/support.xml"/>
 
   <target name="all" depends="clean">

Modified: trunk/docs/userguide/en/master.xml
===================================================================
--- trunk/docs/userguide/en/master.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/master.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,23 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3CR3//EN"
 "../../../lib/docbook-support/support/docbook-dtd/docbookx.dtd" [
-<!ENTITY about SYSTEM "modules/UG12_about.xml">
-<!ENTITY introduction SYSTEM "modules/UG12_introduction.xml">
-<!ENTITY C_overview SYSTEM "modules/CLUST_overview.xml">
-<!ENTITY gettingstarted SYSTEM "modules/UG12_gettingstarted.xml">
-<!ENTITY NC_installation SYSTEM "modules/UG12_installation.xml">
-<!ENTITY C_installation SYSTEM "modules/CLUST_installation.xml">
-<!ENTITY runningexamples SYSTEM "modules/UG12_runningexamples.xml">
-<!ENTITY configuration SYSTEM "modules/UG12_configuration.xml">
-<!ENTITY C_configuration SYSTEM "modules/CLUST_configuration.xml">
-<!ENTITY performance SYSTEM "modules/UG12_performance.xml">
-
-
-<!ENTITY C_about SYSTEM "modules/CLUST_about.xml">
-<!ENTITY C_introduction SYSTEM "modules/CLUST_introduction.xml">
-
-
-
+<!ENTITY about SYSTEM "modules/about.xml">
+<!ENTITY introduction SYSTEM "modules/introduction.xml">
+<!ENTITY c_overview SYSTEM "modules/c_overview.xml">
+<!ENTITY gettingstarted SYSTEM "modules/gettingstarted.xml">
+<!ENTITY nc_installation SYSTEM "modules/installation.xml">
+<!ENTITY c_installation SYSTEM "modules/c_installation.xml">
+<!ENTITY runningexamples SYSTEM "modules/runningexamples.xml">
+<!ENTITY configuration SYSTEM "modules/configuration.xml">
+<!ENTITY c_configuration SYSTEM "modules/c_configuration.xml">
+<!ENTITY performance SYSTEM "modules/performance.xml">
 ]>
 <book lang="en">
   <bookinfo>
@@ -33,23 +26,20 @@
 
   &introduction;
 
-  &C_overview;
+  &c_overview;
 
   &gettingstarted;
 
-  &NC_installation;
+  &nc_installation;
 
-  &C_installation;
+  &c_installation;
 
   &runningexamples;
 
   &configuration;
 
-  &C_configuration;
+  &c_configuration;
 
-
   &performance;
 
-
-
 </book>

Deleted: trunk/docs/userguide/en/modules/CLUST_configuration.xml
===================================================================
--- trunk/docs/userguide/en/modules/CLUST_configuration.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/modules/CLUST_configuration.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,115 +0,0 @@
-<chapter id="CLUST_configuration">
-
-   <title>JBoss Messaging Clustering Configuration</title>
-
-   <para>
-      In this chapter we will discuss how to configure JBoss Messaging clustering for different types of applications
-   </para>
-
-   <para>
-      Most of JBoss messaging clustering configuration revolves around the following variable:
-   </para>
-
-   <itemizedlist>
-
-      <listitem>Choosing the cluster router policy</listitem>
-
-      <listitem>Choosing the message redistributon policy</listitem>
-
-   </itemizedlist>
-
-   <section id="clusterrouter">
-
-      <title>Choosing the cluster router policy</title>
-
-      <para>
-
-      When a message is sent to a queue on particular node of the cluster, the system must decide whether the current node will handle it or whether it should send
-      it to another node to handle.
-      </para>
-
-      <para> The same applies if there are shared durable subscriptions on a topic and the message is being sent to a topic
-      </para>
-
-      <para>The correct decision to make depends on your application topology.</para>
-
-      <para>If your application consists of a set of servers with the same MDBs deployed on each server, and you have many well distributed producers sending
-      messages on all the nodes of the cluster, then the best policy is to always favour the local queue, since extra network trips are more expensive and the other
-      nodes are also havng local messages sent to them</para>
-
-      <para>However if your application consists of a set of homogenous MDBs but you have few or badly distributed producers, then always favouring the local producer
-      will mean the other nodes are being starved of messages and not using their CPUs cycles efficiently for messaging processing.</para>
-
-      <para>In this case, a good policy is to use a round robin routing policy where messages are round robin distributed to different nodes as they arrive.</para>
-
-      <para>In general, use the DefaultRoutingPolicy (this always favours the local queue) if you have many well distributed producers, and use the
-      RoundRobinRoutingPolicy if you have few or badly distributed producers.</para>
-
-      <para>This are specified in the clustered post office config, by specifying the following attribute</para>
-
-      <para>To favour the local queue:</para>
-
-      <programlisting>
-       &lt;attribute name="ClusterRouterFactory"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory&lt;/attribute&gt;
-      </programlisting>
-
-      <para>To round robin:</para>
-
-       <programlisting>
-         &lt;attribute name="ClusterRouterFactory"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.RoundRobinRouterFactory&lt;/attribute&gt;
-      </programlisting>
-
-   </section>
-
-
-   <section id="messagepull">
-
-      <title>Choosing the message pull policy</title>
-
-      <para>Once messages have arrived on queues in a cluster, in an ideal world they will all be consumed at the same rate, and there will be consumers on each node.
-      </para>
-
-      <para>However, in some application topologies, consumes may close on queues on a node, leaving messages otherwise stranded, or perhaps consumers
-      on some nodes are fast than consumers on other nodes causing messages to build up on one node or another and adversely effecting latency.
-      </para>
-
-      <para>JBoss Messaging allows messages to pulled from one node to another as load dictates in order to cope with such situations</para>
-
-      <para>Whether or not you should activate message pulling (message redistribution) depends on your application topology</para>
-
-      <para>For an application that consists of a set of servers with a heterogenous bank of MDBs (or other consumers) deployed on each node, consuming at
-      approximately the same rate, then message redistribution is not necessary.
-      </para>
-
-      <para>However, if your application consists of different numbers or rates of consumers on different nodes then message redistribution may help</para>
-
-      <warning>By its nature, message redistribution can result in messages being delivered in an order different to the strict ordering imposed by JMS. I.e.
-      messages can, sometimes be delivered in an order different to that which they were produced by their producer. If this ordering is important to you
-      then don't use message redistribution</warning>
-
-      <para>In general, use message redistribution when your consumers are not well distributed across the cluster or if they have greatly varying rates.</para>
-
-      <para>Message redistribution is set by setting the following attribute in the clustered post office configuration:
-      </para>
-
-      <para>
-      For no message redistribution:
-      </para>
-
-      <programlisting>
-           &lt;attribute name="MessagePullPolicy"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy&lt;/attribute&gt;
-      </programlisting>
-
-      <para>For message redistribution:</para>
-
-       <programlisting>
-           &lt;attribute name="MessagePullPolicy"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.DefaultMessagePullPolicy&lt;/attribute&gt;
-      </programlisting>
-
-      <para>When selecting message redistribution you should also choose a value of <literal>StatsSendPeriod</literal> appropriately.</para>
-
-   </section>
-
-
-
-</chapter>
\ No newline at end of file

Deleted: trunk/docs/userguide/en/modules/CLUST_installation.xml
===================================================================
--- trunk/docs/userguide/en/modules/CLUST_installation.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/modules/CLUST_installation.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,319 +0,0 @@
-<chapter id="CLUST_installation">
-
-   <title>JBoss Messaging Clustered Installation</title>
-
-    <note>
-        You need Apache ant 1.7.0 or newer pre-installed on your system and available in
-        you path in order to be able to perform the installation process described below.
-    </note>
-
-   <para>
-      Use the <filename>release-admin.xml</filename> ant script shipped with the release to
-      create individual cluster node configurations.
-   </para>
-
-   <para>
-      The typical usage is:
-   </para>
-
-   <programlisting>
-cd util
-ant -f release-admin.xml [-Did=node-id] [-Dports=port-config-label] 
-[-Ddatabase=db-name] cluster-node
-   </programlisting>                                                                                                                                      
-   <para>
-      where:
-      <itemizedlist>
-         <listitem>
-            <filename>node-id</filename> is the unique node ID, an integer that must be unique per
-            cluster. If not specified, it defaults to 0.
-         </listitem>
-         <listitem>
-            <filename>port-config-label</filename> is a binding manager server configuration label.
-
-            The short story behind this parameter is the following: multiple application servers
-            running on the same physical machine need to use different service port ranges to avoid
-            port conflicts. You can configure the whole port range used by a server instance
-            by enabling a special service, the binding management service, and specifiying a
-            "server" configuration in the binding manager's configuration file, which will determine
-            specific port values to use when starting that instance.
-
-            The Messaging installation script can enable the service binding manager and performs
-            all configuration changes automatically. You only need to specify the "server"
-            configuration you want to use, as 'port-config-label'.
-
-            If you plan to run your clustering nodes on different physical machines, this parameter
-            is irrelevant, and you should not use it. However, if you install two (or more) nodes of
-            your cluster on the same physical machine, you need to give the value corresponding to
-            a specific "server" configurations in the binding manager configuration file. JBoss AS
-            ships "out-of-the-box" with several pre-configured port ranges: 'ports-default',
-            'ports-01', 'ports-02', 'ports-03'. Use one of these.
-
-            If -Dports is not specified, the clustered instance created this way will fall over to
-            the default port range for a JBoss instace.
-
-            More details about the binding management service can be found in the Application Server
-            documentation, at the following address
-            <ulink url="http://docs.jboss.com/jbossas/guides/j2eeguide/r2/en/html_single/#ch10.bindingmanager">http://docs.jboss.com/jbossas/guides/j2eeguide/r2/en/html_single/#ch10.bindingmanager</ulink>
-         </listitem>
-         <listitem>
-            <filename>db-name</filename> is the name of the database you want to create the configurations for. Supported database names are: mysql, oracle,
-            postgresql, mssql, and sybase. Notice that if you create database configuration to any database other than MySQL, you will still need to
-            manually install the database JDBC drivers (MySQL drivers are provided as part of the distribution).
-         </listitem>
-      </itemizedlist>
-   </para>
-
-   <para>
-      Notice that you should have environment variable JBOSS_HOME correctly set to point to your JBoss AS distribution directory before executing any of the
-      scripts.
-   </para>
-
-   <para>
-      For example, in order to create the configuration for a four-node cluster intended to run
-      on the same physical machine, use the following sequence:
-   </para>
-
-   <programlisting>
-ant -f release-admin.xml cluster-node
-ant -f release-admin.xml -Did=1 -Dports=ports-01 cluster-node
-ant -f release-admin.xml -Did=2 -Dports=ports-02 cluster-node
-ant -f release-admin.xml -Did=3 -Dports=ports-03 cluster-node
-   </programlisting>
-
-   <para>
-      The sequence will create four cluster node configurations ("messaging-node0",
-      "messaging-node1", "messaging-node2" and "messaging-node3").
-   </para>
-
-   <para>
-      The first command will create a cluster node with ID equals to '0' and using the
-      default JBoss AS port assignments.
-   </para>
-
-   <para>
-      <warning>
-         The configuration that has just been created uses a generic mysql service descriptor.
-
-         Check <filename>$JBOSS_HOME/server/messaging-node&lt;id&gt;/deploy/mysql-ds.xml</filename>
-         and verify that that:
-         <itemizedlist>
-            <listitem>1. Your database is indeed mysql.</listitem>
-         <listitem>2. It is accessible from every physical node you installed Messaging on.</listitem>
-         <listitem>3. Contains a schema (database/tablespace) named 'messaging'.</listitem>
-         <listitem>4. The URL (hostname and port), username and password are correct.</listitem>
-         <listitem>5. The installed mysql-driver.jar's version maches your database.</listitem>
-           </itemizedlist>
-      </warning>
-      </para>
-
-
-   <para>
-      To start the cluster, from four different terminals, run:
-      </para>
-
-   <programlisting>
-cd $JBOSS_HOME/bin
-./run.sh -c messaging-node0
-
-cd $JBOSS_HOME/bin
-./run.sh -c messaging-node1
-
-cd $JBOSS_HOME/bin
-./run.sh -c messaging-node2
-
-cd $JBOSS_HOME/bin
-./run.sh -c messaging-node3
-    </programlisting>
-
-
-   <para>
-      A successful two node cluster startup produces a log similar to:
-   </para>
-
-
-   <para>
-      Node 0:
-   </para>
-
-
-   <programlisting>
-...
-
-00:24:04,796 WARN  [JDBCPersistenceManager]
-
-JBoss Messaging Warning: 
-	DataSource connection transaction isolation should be READ_COMMITTED, but it 
-	is currently REPEATABLE_READ.
-  Using an isolation level less strict than READ_COMMITTED may lead to data 
-	consistency problems.
-  Using an isolation level more strict than READ_COMMITTED may lead to deadlock.
-
-00:24:05,718 INFO  [ServerPeer] JBoss Messaging 1.2.0.CR1 server [0] started
-00:24:06,328 INFO  [STDOUT]
--------------------------------------------------------
-GMS: address is 127.0.0.1:2452
--------------------------------------------------------
-00:24:08,406 INFO  [DefaultClusteredPostOffice] ClusteredPostOffice
-[0:Clustered JMS:127.0.0.1:2452] got new view [127.0.0.1:2452|0] [127.0.0.1:2452]
-00:24:08,468 INFO  [STDOUT]
--------------------------------------------------------
-GMS: address is 127.0.0.1:2455
--------------------------------------------------------
-00:24:10,906 INFO  [ConnectionFactory] Connector socket://10.11.14.105:4457 has leasing 
-enabled, lease period 10000 milliseconds
-00:24:10,921 INFO  [ConnectionFactory] [/ConnectionFactory, /XAConnectionFactory, 
-java:/ConnectionFactory, java:/XAConnectionFactory] started
-00:24:10,953 INFO  [QueueService] Queue[/queue/DLQ] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,953 INFO  [QueueService] Queue[/queue/ExpiryQueue] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,953 INFO  [TopicService] Topic[/topic/testTopic] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,953 INFO  [TopicService] Topic[/topic/securedTopic] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,968 INFO  [TopicService] Topic[/topic/testDurableTopic] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,968 INFO  [QueueService] Queue[/queue/testQueue] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,968 INFO  [QueueService] Queue[/queue/A] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,968 INFO  [QueueService] Queue[/queue/B] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,968 INFO  [QueueService] Queue[/queue/C] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,968 INFO  [QueueService] Queue[/queue/D] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,968 INFO  [QueueService] Queue[/queue/ex] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,984 INFO  [QueueService] Queue[/queue/PrivateDLQ] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:10,984 INFO  [QueueService] Queue[/queue/PrivateExpiryQueue] started, 
-fullSize=75000, pageSize=2000, downCacheSize=2000
-00:24:10,984 INFO  [QueueService] Queue[/queue/QueueWithOwnDLQAndExpiryQueue] started, 
-fullSize=75000, pageSize=2000, downCacheSize=2000
-00:24:10,984 INFO  [TopicService] Topic[/topic/TopicWithOwnDLQAndExpiryQueue] started, 
-fullSize=75000, pageSize=2000, downCacheSize=2000
-00:24:10,984 INFO  [QueueService] Queue[/queue/QueueWithOwnRedeliveryDelay] started, 
-fullSize=75000, pageSize=2000, downCacheSize=2000
-00:24:10,984 INFO  [TopicService] Topic[/topic/TopicWithOwnRedeliveryDelay] started, 
-fullSize=75000, pageSize=2000, downCacheSize=2000
-00:24:11,000 INFO  [QueueService] Queue[/queue/testDistributedQueue] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:24:11,000 INFO  [TopicService] Topic[/topic/testDistributedTopic] started, fullSize=75000,
-pageSize=2000, downCacheSize=2000
-00:24:11,093 INFO  [ConnectionFactoryBindingService] Bound 
-ConnectionManager'jboss.jca:name=JmsXA,service=ConnectionFactoryBinding' to JNDI 
-name 'java:JmsXA'
-00:24:11,375 INFO  [TomcatDeployer] deploy, ctxPath=/jmx-console, 
-warUrl=.../deploy/jmx-console.war/
-00:24:12,171 INFO  [Http11BaseProtocol] Starting Coyote HTTP/1.1 on http-0.0.0.0-8080
-00:24:12,421 INFO  [ChannelSocket] JK: ajp13 listening on /0.0.0.0:8009
-00:24:12,453 INFO  [JkMain] Jk running ID=0 time=0/47  config=null
-00:24:12,515 INFO  [Server] JBoss (MX MicroKernel) [4.0.5.GA (build: CVSTag=Branch_4_0 
-date=200611221632)] 
-Started in 30s:375ms
-
-00:27:21,343 INFO  [DefaultClusteredPostOffice] ClusteredPostOffice
-[0:Clustered JMS:127.0.0.1:2452] got new view [127.0.0.1:2452|1] 
-[127.0.0.1:2452, 127.0.0.1:2474]
-
-</programlisting>
-
-   <para>
-      Node 1:
-   </para>
-
-   <programlisting>
-
-...
-
-00:33:54,468 WARN  [JDBCPersistenceManager]
-
-JBoss Messaging Warning: 
-DataSource connection transaction isolation should be READ_COMMITTED, but it is 
-currently REPEATABLE_READ.
-Using an isolation level less strict than READ_COMMITTED may lead to data consistency 
-problems.
-Using an isolation level more strict than READ_COMMITTED may lead to deadlock.
-
-00:33:55,062 INFO  [ServerPeer] JBoss Messaging 1.2.0.CR1 server [1] started
-00:33:55,609 INFO  [STDOUT]
--------------------------------------------------------
-GMS: address is 127.0.0.1:2514
--------------------------------------------------------
-00:33:57,734 INFO  [DefaultClusteredPostOffice] 
-ClusteredPostOffice[1:Clustered JMS:127.0.0.1:2514] got new 
-view [127.0.0.1:2452|3] [127.0.0.1:2452, 127.0.0.1:2514]
-00:33:57,765 INFO  [STDOUT]
--------------------------------------------------------
-GMS: address is 127.0.0.1:2519
--------------------------------------------------------
-00:34:00,203 INFO  [ConnectionFactory] Connector socket://10.11.14.105:4557 has leasing 
-enabled, lease period 20000 milliseconds
-00:34:00,203 INFO  [ConnectionFactory] [/ConnectionFactory, /XAConnectionFactory, 
-java:/ConnectionFactory, java:/XAConnectionFactory] started
-00:34:00,234 INFO  [QueueService] Queue[/queue/DLQ] started, fullSize=75000, pageSize=2000, 
-downCacheSize=2000
-00:34:00,234 INFO  [QueueService] Queue[/queue/ExpiryQueue] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,234 INFO  [TopicService] Topic[/topic/testTopic] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,250 INFO  [TopicService] Topic[/topic/securedTopic] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,250 INFO  [TopicService] Topic[/topic/testDurableTopic] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,250 INFO  [QueueService] Queue[/queue/testQueue] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,250 INFO  [QueueService] Queue[/queue/A] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,250 INFO  [QueueService] Queue[/queue/B] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,250 INFO  [QueueService] Queue[/queue/C] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,250 INFO  [QueueService] Queue[/queue/D] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,250 INFO  [QueueService] Queue[/queue/ex] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,265 INFO  [QueueService] Queue[/queue/PrivateDLQ] started, fullSize=75000, 
-pageSize=2000, downCacheSize=2000
-00:34:00,265 INFO  [QueueService] Queue[/queue/PrivateExpiryQueue] started, 
-fullSize=75000, pageSize=2000, downCacheSize=2000
-00:34:00,265 INFO  [QueueService] Queue[/queue/QueueWithOwnDLQAndExpiryQueue] 
-started, fullSize=75000, pageSize=2000, downCacheSize=2000
-00:34:00,265 INFO  [TopicService] Topic[/topic/TopicWithOwnDLQAndExpiryQueue] 
-started, fullSize=75000, pageSize=2000, downCacheSize=2000
-00:34:00,265 INFO  [QueueService] Queue[/queue/QueueWithOwnRedeliveryDelay] 
-started, fullSize=75000, pageSize=2000, downCacheSize=2000
-00:34:00,265 INFO  [TopicService] Topic[/topic/TopicWithOwnRedeliveryDelay] 
-started, fullSize=75000, pageSize=2000, downCacheSize=2000
-00:34:00,296 INFO  [QueueService] Queue[/queue/testDistributedQueue] 
-started, fullSize=75000, pageSize=2000, downCacheSize=2000
-00:34:00,296 INFO  [TopicService] Topic[/topic/testDistributedTopic] 
-started, fullSize=75000, pageSize=2000, downCacheSize=2000
-00:34:00,343 INFO  [ConnectionFactoryBindingService] Bound 
-ConnectionManager 'jboss.jca:name=JmsXA,
-service=ConnectionFactoryBinding' to JNDI name 'java:JmsXA'
-00:34:00,453 INFO  [TomcatDeployer] deploy, ctxPath=/jmx-console, 
-warUrl=.../deploy/jmx-console.war/
-00:34:00,796 INFO  [Http11BaseProtocol] Starting Coyote HTTP/1.1 on http-0.0.0.0-8180
-00:34:01,078 INFO  [ChannelSocket] JK: ajp13 listening on /0.0.0.0:8109
-00:34:01,125 INFO  [JkMain] Jk running ID=0 time=0/125  config=null
-00:34:01,125 INFO  [Server] JBoss (MX MicroKernel) 
-[4.0.5.GA (build: CVSTag=Branch_4_0 date=200611221632)] Started in 22s:547ms
-
-
-   </programlisting>
-
-
-   <note>
-      The installation script may fail while installing Messaging with source-generated
-      JBoss 4.0.5.GA-ejb3 instance. This is because release-admin.xml relies on finding
-      <filename>$JBOSS_HOME/docs/examples/binding-manager/sample-bindings.xml</filename>.
-      4.0.5.GA-ejb3 installations seem not to have a "docs" sub-directory. A very simple work-around
-      for this situation is to recursively copy the "docs" sub-directory available under a regular
-      (non-EJB3) source-generated 4.0.5.GA instance and retry the installation process.
-   </note>
-
-
-</chapter>

Deleted: trunk/docs/userguide/en/modules/CLUST_overview.xml
===================================================================
--- trunk/docs/userguide/en/modules/CLUST_overview.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/modules/CLUST_overview.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,146 +0,0 @@
-<chapter id="CLUST_overview">
-
-
-   <title>JBoss Messaging Clustering</title>
-
-    <para>
-      This section of the userguide gives a brief overview of the features available in
-        JBoss Messaging Clustering 1.2.0.GA. It gives a high level explanation of how
-        clustering works.
-     </para>
-
-   <section id="clustering_overview">
-      <title>JBoss Messaging Clustering Overview</title>
-
-      <para>
-      Here's a brief overview of how clustering works in JBoss Messaging 1.2.
-      </para>
-
-
-      <para>
-      Clustered destinations (queues and topics) can be deployed at all or none of the nodes of
-      the cluster.
-      A JMS client uses HA JNDI to lookup the connection factory. A client side load balancing
-      policy will automatically chose a node to connect to (This is similar to
-      how EJB clustering chooses a node).
-      </para>
-
-      <para>
-      The JMS client has now made a connection to a node where it can create sessions, message
-      producers and message consumers and browsers and send or consume messages,
-      using the standard JMS api.
-      When a distributed queue is deployed across the cluster, individual partial queues are
-      deployed on each node.
-      </para>
-
-      <para>
-      When a message is sent from a message producer attached to a particular node to a
-      distributed queue, a routing policy determines which partial queue will receive
-      the message.
-      By default the router will always pass the message to a local queue, if there is one,
-      this is so we avoid unnecessary network traffic.
-      If there is no local queue then a partial queue on a different node will be chosen by the
-      router, by default this will be round robin between remote partial queues.
-      </para>
-
-      <para>
-      When a message is sent to a distributed topic while attached to a node, there may be
-      multiple subscriptions on different nodes that need to receive the
-      message. Depending on the number and location of subscriptions, the message may be multicast
-      or unicast across the cluster so the other nodes can pick it up.
-      (All group communication, unicast, multicast and group management is handled by JGroups.)
-      </para>
-
-      <para>
-      In the case of shared durable subscriptions, if a durable subscription with the same name
-      exists on more than node, then only one of the instances needs to receive the message.
-      Which one is determined by the same routing policy used to route messages to partial queues.
-      All of this is accomplished without losing the reliability guarantees required by JMS.
-      </para>
-
-      <para>
-      Subscriptions (both durable and non durable) can be created on all nodes and will receive messages sent via any node.
-      What happens if the consumers on one queue/subscription are faster/slower than consumers on another?
-      Normally this would result in messages building up on that queue and fast consumers being starved of work on another, thus wasting CPU cycles on the node that
-      could be put to good use.
-      The most degenerate example is of a queue containing many messages then the consumers being closed on that queue.
-      The messages might potentially remain stranded on the queue until another consumer attaches.
-      A routing policy is no use here, since the messages have already been routed to the queuee and the consumers closed / slowed down
-      after they were routed there.
-      JBoss Messaging can deal with this problem by intelligently pulling messages from other less
-      busy nodes, if it detects idle consumers on the fast node and slow consumers
-      on another node.
-      </para>
-
-      <para>
-      Normally, persistent messages are persisted in a shared database which is shared by all nodes
-      in the cluster.
-
-      JBoss Messaging 1.2.1 will contain
-      an option where you can choose to not persist persistent messages in a database, but instead to replicate them between nodes of the cluster.
-
-      The idea here is the network IO on a fast network should be much faster than persisting to disk.
-      This solution should also be more scalable since different nodes replicate their messages onto
-      different other nodes - there is no "master node".
-
-      If the messages are replicated onto sufficient nodes and the hardware is set-up with UPS, then we believe a comparable reliability guarantee to persisting messages to disk
-      can be achieved. Of course, this won't be suitable for all situations, but you use the best tool for the job.
-      </para>
-
-   </section>
-
-
-    <section id="clustering_architectural_overview">
-        <title>Clustering Architectural Overview</title>
-
-        <para>
-           One of the fundamental Messaging Core building blocks is the "Post Office". A JBoss Messaging
-           Post Office is message routing component, which accepts messages for delivery and synchronously
-           forwards them to their destination queues or topic subscriptions.
-        </para>
-
-        <para>
-           There is a single Post Office instance per JBoss Messaging server (cluster node). Both queues
-           and topics deployed on a JBoss Messaging node are "plugged" into that Post Office instance.
-           Internally JBoss Messaging only deals  with the concepts of queues, and considers a topic to
-           just be a set of queues (one for each subscription). Depending on the type of subscription -
-           durable or non-durable - the corresponding queue saves messages to persistent storage or
-           it just holds messages in memory and discards them when the non-durable subscription is closed.
-        </para>
-
-        <para>
-           Therefore, for a JMS queue, the Post Office routes messages to one and only one core queue,
-           depending on the queue name, whereas for a JMS topic, the Post Office routes a message
-           to a set of core queues, one for each topic subscription, depending on the topic name.
-        </para>
-
-        <para>
-           Clustering across multiple address spaces is achieved by clustering Post Office instances. Each
-           JBoss Messaging cluster node runs a Clustered Post Office instance, which is aware of the presence
-           of all other clustered Post Offices in the cluster. There is an one-to-one relationship between cluster
-           nodes and clustered Post Office instances. So, naturally, the most important piece of clustering
-           configuration is the <emphasis>clustered Post Office service configuration</emphasis>,
-           covered in detail below.
-        </para>
-
-        <para>
-           Clustered Post Office instances connect to each other via JGroups and they heavily rely on JGroups
-           group management and notification mechanisms. <emphasis>JGroups stack configuration</emphasis>
-           is an essential part of JBoss Messaging clustering configuration. JGroups configuration is only
-           briefly addressed in this guide. Detailed information on JGroups can be found in JGroups
-           release documentation or on-line at <ulink url="http://www.jgroups.org">http://www.jgroups.org</ulink>
-           or <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups">http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups</ulink>
-        </para>
-
-        <para>
-           When routing messages, a clustered Post Office  has a choice of forwarding the message to local
-           queues or remote queues, plugged into remote Post Office instances that are part of the same
-           cluster. Local queues are usually preferred, but if a local queue is part of a distributed queue, has
-           no consumers, and other local queues part of the same distributed queue have consumers, messages
-           can be automatically redistributed, subject of the message redistribution policy in effect. This allows
-           us to create distributed queues and distributed topics.  <emphasis>Message redistribution
-           configuration</emphasis> is another subject that we will insist on.
-        </para>
-
-    </section>
-</chapter>

Deleted: trunk/docs/userguide/en/modules/UG12_about.xml
===================================================================
--- trunk/docs/userguide/en/modules/UG12_about.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/modules/UG12_about.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,72 +0,0 @@
-<chapter id="UG2_about">
-
-   <title>Introducing JBoss Messaging Release 1.2.0.GA</title>
-
-   <para>
-       JBoss Messaging is a high performance JMS provider in the JBoss Enterprise Middleware Stack
-       (JEMS). It is a complete rewrite of JBossMQ, which is the current default JMS provider in
-       JBoss AS 4.0.x series and JBoss AS 4.2.0. JBoss Messaging will be the default JMS provider in
-       JBoss AS 4.2.x series, probably starting with 4.2.1, and it is already the default provider
-       in JBoss 5.0.0.Beta.
-   </para>
-
-   <para>JBoss Messaging it is also the backbone of the JBoss ESB infrastructure.</para>
-   
-   <para>
-       Compared with JBossMQ, JBoss Messaging offers vastly improved performance in both single node
-       and clustered environments.
-       Please see
-       <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMessagingPerformanceResultsPre1_0">this wiki page</ulink>
-       for performance benchmarks and <xref linkend="UG2_performance"/> on how to generate your own
-       performance benchmarks. JBoss Messaging also features a much better modular architecture that
-       will allow us to add more features in the future.
-   </para>
-   
-   <para>
-       While JBoss Messaging only becomes the default JMS provider from JBoss AS 4.2.1 and JBoss 5.0,
-       production users on JBoss AS 4.0.x can still take advantage of the performance improvements
-       by easily replacing the JBossMQ module with JBoss Messaging.
-   </para>
-   
-   <para>
-       The procedure of swapping JMS providers is presented in detail in this manual.
-       In <xref linkend="UG2_installation"/> we discuss how to install and use JBoss Messaging in
-       JBoss 4.0.x production servers. We cover JBoss Messaging-specific configuration options,
-       as well as how to run the build-in sanity / performance tests.
-   </para>
-
-   <para>
-      This guide is work in progress, as new features will be added to the 1.2 baseline at a very
-      quick pace. Please send your suggestions or comments to the
-      <ulink url="http://www.jboss.org/index.html?module=bb&amp;op=viewforum&amp;f=238">JBoss Messaging user forum</ulink>.
-   </para>
-
-   <para>
-      <emphasis role="bold">Team:</emphasis>
-   </para>
-
-   <para>
-      Ovidiu Feodorov, Project Lead
-   </para>
-
-   <para>
-      Tim Fox, Technical Lead
-
-   </para>
-
-    <para>
-       Clebert Suconic, Core Messaging Developer
-    </para>
-
-   <para>
-      Other contributions by: Adrian Brock, Bela Ban, Alex Fu, Luc Texier, Aaron Walker,
-      Rajdeep Dua, Madhusudhan Konda, Juha Lindfors and Ron Sigal.
-   </para>
-
-   <para>
-       This manual was written with help from Luc Texier, Lead Support EMEA and
-       Sam Griffith Jr., JBoss Documentation Team.
-   </para>
-
-
-</chapter>

Deleted: trunk/docs/userguide/en/modules/UG12_configuration.xml
===================================================================
--- trunk/docs/userguide/en/modules/UG12_configuration.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/modules/UG12_configuration.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,2285 +0,0 @@
-<chapter id="UG2_configuration">
-  <title>Configuration</title>
-
-  <para>
-      The JMS API specifies how a messaging client interacts with a messaging server. The exact
-      definition and implementation of messaging services, such as message destinations and
-      connection factories, are specific to JMS providers. JBoss Messaging has its own
-      configuration files to configure services. If you are migrating services from JBossMQ
-      (or other JMS provider) to JBoss Messaging, you will need to understand those
-      configuration files.
-  </para>
-
-  <para>
-      In this chapter, we discuss how to configure various services inside JBoss Messaging,
-      which work together to provide JMS API level services to client applications.
-  </para>
-
-   <para>
-      Starting with the JBoss Messaging 1.0.1 release, the service configuration is spread among
-      several configuration files (the 1.0.0 release used to have all configuration information
-      lumped together in the SAR's deployment descriptor
-      <filename>jboss-messaging.sar/META-INF/jboss-service.xml</filename>).
-      Depending on the functionality provided by the services it configures, the configuration
-      data is distributed between
-      <filename>messaging-service.xml</filename>,
-      <filename>remoting-service.xml</filename>,
-      <filename>xxx-persistence-service.xml</filename>
-       (or <filename>clustered-xxx-persistence-service.xml</filename> for a clustered configuration,
-       more about clusterered configuration in <xref linkend="CLUST_configuration"/>),
-      <filename>connection-factories-service.xml</filename> and
-      <filename>destinations-service.xml</filename>.
-   </para>
-
-   <para>
-      The AOP client-side and server-side interceptor stacks are configured in
-      <filename>aop-messaging-client.xml</filename> and <filename>aop-messaging-server.xml</filename>.
-      Normally you will not want to change them, but you can some of the interceptors can be removed
-      to give a small performance increase, if you don't need them. Be very careful you have considered the security implications before removing the
-      security interceptor.
-   </para>
-
-  <section id="conf.serverpeer">
-    <title>Configuring the ServerPeer</title>
-
-    <para>
-       The Server Peer is the "heart" of the JBoss Messaging JMS facade. The server's configuration,
-       resides in <filename>messaging-service.xml</filename> configuration file.
-    </para>
-
-    <para>All JBoss Messaging services are rooted at the server peer</para>
-
-     <para>An example of a Server Peer configuration is presented below. Note that not all values for the server peer's attributes are
-     specified in the example</para>
-
-     <programlisting>
- &lt;mbean code="org.jboss.jms.server.ServerPeer"
-        name="jboss.messaging:service=ServerPeer"
-        xmbean-dd="xmdesc/ServerPeer-xmbean.xml"&gt;
-
-   &lt;constructor&gt;
-     &lt;!-- ServerPeerID --&gt;
-     &lt;arg type="int" value="0"/&gt;
-     &lt;!-- DefaultQueueJNDIContext --&gt;
-     &lt;arg type="java.lang.String" value="/queue"/&gt;
-     &lt;!-- DefaultTopicJNDIContext --&gt;
-     &lt;arg type="java.lang.String" value="/topic"/&gt;
-   &lt;/constructor&gt;
-
-   &lt;attribute name="PostOffice"&gt;jboss.messaging:service=PostOffice&lt;/attribute&gt;
-   &lt;attribute name="SecurityDomain"&gt;java:/jaas/messaging&lt;/attribute&gt;
-   &lt;attribute name="DefaultSecurityConfig"&gt;
-      &lt;security&gt;
-        &lt;role name="guest" read="true" write="true" create="true"/&gt;
-      &lt;/security&gt;
-   &lt;/attribute&gt;
-   &lt;attribute name="DefaultDLQ"&gt;
-       jboss.messaging.destination:service=Queue,name=DLQ&lt;/attribute&gt;
-   &lt;attribute name="DefaultMaxDeliveryAttempts"&gt;10&lt;/attribute&gt;
-   &lt;attribute name="DefaultExpiryQueue"&gt;
-       jboss.messaging.destination:service=Queue,name=ExpiryQueue&lt;/attribute&gt;
-   &lt;attribute name="DefaultRedeliveryDelay"&gt;0&lt;/attribute&gt;
-   &lt;attribute name="QueueStatsSamplePeriod"&gt;5000&lt;/attribute&gt;
-   &lt;attribute name="FailoverStartTimeout"&gt;60000&lt;/attribute&gt;
-   &lt;attribute name="FailoverCompleteTimeout"&gt;300000&lt;/attribute&gt;
-   &lt;attribute name="DefaultMessageCounterHistoryDayLimit"&gt;-1&lt;/attribute&gt;
-
-   &lt;depends optional-attribute-name="PersistenceManager"&gt;
-       jboss.messaging:service=PersistenceManager&lt;/depends&gt;
-   &lt;depends optional-attribute-name="JMSUserManager"&gt;
-       jboss.messaging:service=JMSUserManager&lt;/depends&gt;
-   &lt;depends&gt;jboss.messaging:service=Connector,transport=bisocket&lt;/depends&gt;
-
- &lt;/mbean&gt;
-     </programlisting>
-
-     <section id="conf.serverpeer.attributes">
-
-       <title>
-             We now discuss the MBean attributes of the ServerPeer MBean
-        </title>
-
-       <section id="conf.serverpeer.attributes.persistencemanager">
-           <title>PersistenceManager</title>
-
-           <para>
-              This is the persistence manager that the ServerPeer uses. You will not normally need to change this attribute.
-           </para>
-        </section>
-
-       <section id="conf.serverpeer.attributes.postoffice">
-           <title>PostOffice</title>
-
-           <para>
-              This is the post office that the ServerPeer uses. You will not normally need to change this attribute.
-              The post office is responsible for routing messages to queues and maintaining the mapping between addresses and queues.
-           </para>
-        </section>
-
-       <section id="conf.serverpeer.attributes.jmsusermanager">
-           <title>JMSUserManager</title>
-
-           <para>
-              This is the JMS user manager that the ServerPeer uses. You will not normally need to change this attribute.
-           </para>
-        </section>
-
-       <section id="conf.serverpeer.attributes.defaultdlq">
-           <title>DefaultDLQ</title>
-
-           <para>
-              This is the name of the default DLQ (Dead Letter Queue) the server peer will use for destinations. The DLQ can be overridden on a per
-              destination basis - see the destination MBean configuration for more details.
-
-              A DLQ is a special destination where messages are sent when the server has attempted to deliver them unsuccessfully more than a certain number of
-              times.
-
-              If the DLQ is not specified at all then the message will be removed after the maximum number of delivery attempts.
-
-              The maximum number of delivery attempts can be specified using the attribute DefaultMaxDeliveryAttempts for a global default or individually
-              on a per destination basis.
-
-           </para>
-        </section>
-
-       <section id="conf.serverpeer.attributes.defaultexpiryqueue">
-           <title>DefaultExpiryQueue</title>
-
-           <para>
-              This is the name of the default expiry queue the server peer will use for destinations. The expiry can be overridden on a per
-              destination basis - see the destination MBean configuration for more details.
-
-              An expiry queue is a special destination where messages are sent when they have expired. Message expiry is determined by the value of
-              Message::getJMSExpiration()
-
-              If the expiry queue is not specified at all then the message will be removed after it is expired.
-
-           </para>
-        </section>
-
-
-        <section id="conf.serverpeer.attributes.serverpeerid">
-           <title>ServerPeerID</title>
-
-           <para>
-              The unique id of the server. In a cluster each server MUST have a unique id.
-           </para>
-        </section>
-
-        <section id="conf.serverpeer.attributes.defaultqueuejndicontext">
-           <title>DefaultQueueJNDIContext</title>
-
-           <para>
-              The default JNDI context to use when binding queues. Defaults to /queue.
-           </para>
-        </section>
-
-        <section id="conf.serverpeer.attributes.defaultopicjndicontext">
-           <title>DefaultTopicJNDIContext</title>
-
-           <para>
-              The default JNDI context to use when binding topics. Defaults to /topic.
-           </para>
-        </section>
-
-        <section id="conf.serverpeer.attributes.destinations">
-           <title>Destinations</title>
-
-           <para>
-              Returns a list of the destinations (queues and topics) currently deployed.
-           </para>
-        </section>
-
-        <section id="conf.serverpeer.attributes.defaultmaxdeliveryattempts">
-           <title>DefaultMaxDeliveryAttempts</title>
-
-           <para>
-              The default for the maximum number of times delivery of a message will be attempted before sending the message to the DLQ, if configured.
-           </para>
-           <para>
-              The default value is <literal>10</literal >
-           </para>
-           <para>This value can also be overridden on a per destination basis</para>
-        </section>
-
-        <section id="conf.serverpeer.attributes.failoverstarttimeout">
-           <title>FailoverStartTimeout</title>
-
-           <para>
-              The maximum number of milliseconds the client will wait for failover to start on the server side when a problem is detected.
-           </para>
-           <para>
-              The default value is <literal>60000</literal> (one minute)
-           </para>
-
-        </section>
-
-        <section id="conf.serverpeer.attributes.failovercompletetimeout">
-           <title>FailoverCompleteTimeout</title>
-
-           <para>
-              The maximum number of milliseconds the client will wait for failover to complete on the server side after it has started.
-           </para>
-           <para>
-              The default value is <literal>300000</literal> (five minutes)
-           </para>
-        </section>
-
-        <section id="conf.serverpeer.attributes.defaultredliverydelay">
-           <title>DefaultRedeliveryDelay</title>
-
-           <para>
-              When redelivering a message after failure of previous delivery it is often beneficial to introduce a delay perform redelivery in order
-              to prevent thrashing of delivery-failure, delivery-failure etc
-           </para>
-           <para>
-              The default value is <literal>0</literal> which means there will be no delay.
-           </para>
-           <para>Change this if your application could benefit with a delay before redelivery. This value can also be overridden on a per destination basis</para>
-        </section>
-
-        <section id="conf.serverpeer.attributes.queuestatssampleperiod">
-           <title>QueueStatsSamplePeriod</title>
-
-           <para>
-              Periodically the server will query each queue to gets its message statistics. This is the period.
-           </para>
-           <para>
-              The default value is <literal>10000</literal> milliseconds
-           </para>
-        </section>
-
-
-        <section id="conf.serverpeer.attributes.defaultmessagecounterhistorydaylimit">
-              <title>DefaultMessageCounterHistoryDayLimit</title>
-
-              <para>
-                 JBoss Messaging provides a message counter history which shows the number of messages arriving on each queue of a certain number of
-                 days. This attribute represents the maxiumum number of days for which to store message counter history. It can be overridden on a per
-                 destination basis
-           </para>
-        </section>
-
-        <section id="conf.serverpeer.attributes.messagecounters">
-              <title>MessageCounters</title>
-
-              <para>
-                 JBoss Messaging provides a message counter for each queue.
-           </para>
-        </section>
-
-        <section id="conf.serverpeer.attributes.messagecounterstatistics">
-              <title>MessageCountersStatistics</title>
-
-              <para>
-                 JBoss Messaging provides statistics for each message counter for each queue.
-           </para>
-        </section>
-
-        <section id="conf.serverpeer.attributes.defaultsecurity">
-           <title>DefaultSecurityConfig</title>
-
-           <para>
-              Default security configuration is used when the security configuration for a specific
-              queue or topic has not been overridden in the destination's deployment descriptor.
-              It has exactly the same syntax and semantics as in JBossMQ.
-           </para>
-
-           <para>
-              The <literal>DefaultSecurityConfig</literal> attribute element should contain
-              one <literal>&lt;security&gt;</literal> element.
-              The <literal>&lt;security&gt;</literal> element can contain multiple
-              <literal>&lt;role&gt;</literal> elements. Each <literal>&lt;role&gt;</literal>
-              element defines the default access for that particular role.
-           </para>
-
-           <para>
-              If the <literal>read</literal> attribute is <literal>true</literal> then that role
-              will be able to read (create consumers, receive messaages or browse) destinations
-              by default.
-           </para>
-
-           <para>
-              If the <literal>write</literal> attribute is <literal>true</literal> then that role
-              will be able to write (create producers or send messages) to destinations by default.
-           </para>
-
-           <para>
-              If the <literal>create</literal> attribute is <literal>true</literal> then that role
-              will be able to create durable subscriptions on topics by default.
-           </para>
-        </section>
-     </section>
-
-
-     <section id="conf.serverpeer.operations">
-
-        <title>
-             We now discuss the MBean operations of the ServerPeer MBean
-        </title>
-
-        <section id="conf.serverpeer.operations.deployQueue">
-           <title>DeployQueue</title>
-
-           <para>
-              This operation lets you programmatically deploy a queue.
-           </para>
-
-           <para>There are two overloaded versions of this operation</para>
-
-           <para>If the queue already exists but is undeployed it is deployed. Otherwise it is created and deployed</para>
-
-           <para>The <literal>name</literal> parameter represents the name of the destination to deploy.</para>
-           <para>The <literal>jndiName</literal> parameter (optional) represents the full jndi name where to bind the destination. If this is not specified
-           then the destination will be bound in &lt;DefaultQueueJNDIContext&gt;/&lt;name&gt;</para>
-
-           <para>The first version of this operation deploys the destination with the default paging parameters. The second overloaded version deploys
-           the destination with the specified paging parameters. See the section on configuring destinations for a discussion of what the
-           paging parameters mean</para>
-
-        </section>
-
-       <section id="conf.serverpeer.operations.undeployQueue">
-           <title>UndeployQueue</title>
-
-           <para>
-              This operation lets you programmatically undeploy a queue.
-           </para>
-
-           <para>The queue is undeployed but is NOT removed from persistent storage.</para>
-
-           <para>This operation returns <literal>true</literal> if the queue was successfull undeployed. otherwise it returns <literal>false</literal></para>
-
-        </section>
-
-       <section id="conf.serverpeer.operations.destroyQueue">
-           <title>DestroyQueue</title>
-
-           <para>
-              This operation lets you programmatically destroy a queue.
-           </para>
-
-           <para>The queue is undeployed and then all its data is destroyed from the database</para>
-
-           <warning>Be careful when using this method since it will delete all data for the queue</warning>
-
-           <para>This operation returns <literal>true</literal> if the queue was successfully destroyed. otherwise it returns <literal>false</literal></para>
-
-        </section>
-
-        <section id="conf.serverpeer.operations.deployTopic">
-           <title>DeployTopic</title>
-
-           <para>
-              This operation lets you programmatically deploy a topic.
-           </para>
-
-           <para>There are two overloaded versions of this operation</para>
-
-           <para>If the topic already exists but is undeployed it is deployed. Otherwise it is created and deployed</para>
-
-           <para>The <literal>name</literal> parameter represents the name of the destination to deploy.</para>
-           <para>The <literal>jndiName</literal> parameter (optional) represents the full jndi name where to bind the destination. If this is not specified
-           then the destination will be bound in &lt;DefaultTopicJNDIContext&gt;/&lt;name&gt;</para>
-
-           <para>The first version of this operation deploys the destination with the default paging parameters. The second overloaded version deploys
-           the destination with the specified paging parameters. See the section on configuring destinations for a discussion of what the
-           paging parameters mean</para>
-
-        </section>
-
-       <section id="conf.serverpeer.operations.undeployTopic">
-           <title>UndeployTopic</title>
-
-           <para>
-              This operation lets you programmatically undeploy a topic.
-           </para>
-
-           <para>The queue is undeployed but is NOT removed from persistent storage.</para>
-
-           <para>This operation returns <literal>true</literal> if the topic was successfully undeployed. otherwise it returns <literal>false</literal></para>
-
-        </section>
-
-       <section id="conf.serverpeer.operations.destroyTopic">
-           <title>DestroyTopic</title>
-
-           <para>
-              This operation lets you programmatically destroy a topic.
-           </para>
-
-           <para>The topic is undeployed and then all its data is destroyed from the database</para>
-
-           <warning>Be careful when using this method since it will delete all data for the topic</warning>
-
-           <para>This operation returns <literal>true</literal> if the topic was successfully destroyed. otherwise it returns <literal>false</literal></para>
-
-        </section>
-
-       <section id="conf.serverpeer.operations.listmessagecountersashtml">
-           <title>ListMessageCountersHTML</title>
-
-           <para>
-              This operation returns message counters in an easy to display HTML format.
-           </para>
-        </section>
-
-       <section id="conf.serverpeer.operations.resetallmessagecounters">
-           <title>ResetAllMesageCounters</title>
-
-           <para>
-              This operation resets all message counters to zero.
-           </para>
-        </section>
-
-
-       <section id="conf.serverpeer.operations.resetallmessagecounterhistories">
-           <title>ResetAllMesageCounters</title>
-
-           <para>
-              This operation resets all message counter histories to zero.
-           </para>
-        </section>
-
-       <section id="conf.serverpeer.operations.enablemessagecounters">
-           <title>EnableMessageCounters</title>
-
-           <para>
-              This operation enables all message counters for all destinations. Message counters are disabled by default.
-           </para>
-        </section>
-
-       <section id="conf.serverpeer.operations.disablemessagecounters">
-           <title>DisableMessageCounters</title>
-
-           <para>
-              This operation disables all message counters for all destinations. Message counters are disabled by default.
-           </para>
-        </section>
-
-       <section id="conf.serverpeer.operations.retrievepreparedtransactions">
-           <title>RetrievePreparedTransactions</title>
-
-           <para>
-              Retrieves a list of the Xids for all transactions currently in a prepared state on the node.
-           </para>
-      </section>
-
-       <section id="conf.serverpeer.operations.showpreparedtransactions">
-           <title>ShowPreparedTransactions</title>
-
-           <para>
-              Retrieves a list of the Xids for all transactions currently in a prepared state on the node in an easy to display HTML format.
-           </para>
-      </section>
-
-
-     </section>
-
-  </section>
-
-     <section id="conf.changingds">
-        <title>Changing the Database</title>
-
-        <para>
-               Several JBoss Messaging services interact with persistent storage. They include: The Persistence Manager,
-               The PostOffice and the JMS User Manager.
-               The Persistence Manager is used to handle the message-related persistence.
-               The Post Office handles binding related persistence.
-               The JMS User manager handles user related persistence
-               The configuration for all these MBeans is handled in the <filename>xxx-persistence-service.xml</filename> file
-        </para>
-
-        <para>
-           If the database you want to switch to is one of MySQL, Oracle, PostgreSQL, MS SQL Sever or Sybase,
-           persistence configuration files are already available in
-           the <filename>examples/config</filename> directory of the release bundle.
-        </para>
-
-        <para>
-           In order to enable support for one of these databases, just replace the default
-           <filename>hsqldb-persistence-service.xml</filename> configuration file with the
-           database-specific configuration file and restart the server.
-        </para>
-
-        <para>
-           Also, be aware that by default, the Messaging services relying on a datastore
-           are referencing <literal>"java:/DefaultDS"</literal> for the datasource.
-           If you are deploying a datasource with a different JNDI name, you need to update
-           all the <literal>DataSource</literal> attribute in the persistence configuration file.
-
-           Example data source configurations for each of the popular databases are available in the distribution.
-        </para>
-
-     </section>
-
-
-  <section id="conf.postoffice">
-    <title>Configuring the Post office</title>
-
-    <para>It is the job of the post office to route messages to their destination(s).
-    </para>
-
-    <para>The post office maintains the mappings between addresses to which messages can be sent and their final queues.</para>
-
-    <para>For example when sending a message with an address that represents a JMS queue name, the post office will route this to a single
-    queue - the JMS queue. When sending a message with an address that repesents a JMS topic name, the post office will route this to a set of
-    queues - one for each JMS subscription.</para>
-
-    <para>The post office also handles the persistence for the mapping of addresses</para>
-
-    <para>JBoss Messaging comes with two different post office implementations - depending on whether you want clustering or not. The clustered post office
-    has the ability to route messages to other nodes in the cluster</para>
-
-    <para>Whether you use the clustered post office or not depends on whether you deploy the <literal>clustered-xxx-persistence-service.xml</literal> MBean config
-    or just the non clustered <literal>xxx-persistence-service.xml</literal> file.</para>
-
-    <para>It is likely that in future releases of JBoss Messaging the clustered and non clustered post offices will be combined into a single post office for
-    ease of configuration</para>
-
-    <section id="conf.postoffice.nonclustered">
-       <title>Non clustered post office</title>
-
-       <para>The non clustered post office should be used where clustering is not required. It will be used when the
-       non clustered <literal>xxx-persistence-service.xml</literal> file is deployed.</para>
-
-       <para>Here is an example of a non clustered post office configuration:</para>
-
-       <programlisting>
-
-&lt;mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-      name="jboss.messaging:service=PostOffice"
-      xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
-      &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
-      &lt;attribute name="PostOfficeName"&gt;JMS&lt;/attribute&gt;
-      &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
-      &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
-      &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
-CREATE_POSTOFFICE_TABLE=CREATE TABLE JBM_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, CLUSTERED CHAR(1))
-INSERT_BINDING=INSERT INTO JBM_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_BINDING=DELETE FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
-LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
-      ]]&gt;&lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-       </programlisting>
-
-       <section id="conf.postoffice.nonclustered.attributes">
-
-       <title>The non clustered post office has the following attributes</title>
-
-          <section id="conf.postoffice.nonclustered.attributes.datasource">
-             <title>DataSource</title>
-             <para>The datasource the postoffice should use for persisting its mapping data</para>
-          </section>
-
-          <section id="conf.postoffice.nonclustered.attributes.sqlproperties">
-              <title>SQLProperties</title>
-              <para>
-                            This is where the DDL and DML for the particular database is specified.
-                            If a particular DDL or DML statement is not overridden, the default Hypersonic
-                            configuration will be used for that statement.
-           </para>
-          </section>
-
-          <section id="conf.postoffice.nonclustered.attributes.createtables">
-               <title>CreateTablesOnStartup</title>
-
-               <para>
-                  Set this to <literal>true</literal> if you wish the post office to attempt
-                  to create the tables (and indexes) when it starts. If the tables (or indexes)
-                  already exist a <literal>SQLException</literal> will be thrown by the JDBC driver and
-                  ignored by the Persistence Manager, allowing it to continue.
-               </para>
-               <para>
-                  By default the value of <literal>CreateTablesOnStartup</literal> attribute
-                  is set to <literal>true</literal>
-               </para>
-         </section>
-
-          <section id="conf.postoffice.nonclustered.attributes.postofficename">
-               <title>PostOfficeName</title>
-
-               <para>
-                  The name of the post office
-               </para>
-         </section>
-      </section>
-   </section>
-
-
-   <section id="conf.postoffice.clustered">
-       <title>Clustered post office</title>
-
-       <para>The clustered post office should be used where clustering is required. It will be used when the
-       clustered <literal>clustered-xxx-persistence-service.xml</literal> file is deployed.</para>
-
-       <para>Here is an example of a clustered post office configuration:</para>
-
-       <programlisting>
-
-&lt;mbean code="org.jboss.messaging.core.plugin.ClusteredPostOfficeService"
-      name="jboss.messaging:service=PostOffice"
-      xmbean-dd="xmdesc/ClusteredPostOffice-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
-      &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
-      &lt;attribute name="PostOfficeName"&gt;Clustered JMS&lt;/attribute&gt;
-      &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
-      &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
-      &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
-CREATE_POSTOFFICE_TABLE=CREATE TABLE JBM_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, CLUSTERED CHAR(1))
-INSERT_BINDING=INSERT INTO JBM_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_BINDING=DELETE FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
-LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
-      ]]&gt;&lt;/attribute&gt;
-      &lt;attribute name="GroupName"&gt;DefaultPostOffice&lt;/attribute&gt;
-      &lt;attribute name="StateTimeout"&gt;5000&lt;/attribute&gt;
-      &lt;attribute name="CastTimeout"&gt;5000&lt;/attribute&gt;
-      &lt;attribute name="StatsSendPeriod"&gt;10000&lt;/attribute&gt;
-      &lt;attribute name="MessagePullPolicy"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy&lt;/attribute&gt;
-      &lt;attribute name="ClusterRouterFactory"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory&lt;/attribute&gt;
-
-
-      &lt;attribute name="ChannelFactoryName"&gt;jgroups.mux:name=Multiplexer&lt;/attribute&gt;
-      &lt;attribute name="SyncChannelName"&gt;udp-sync&lt;/attribute&gt;
-      &lt;attribute name="AsyncChannelName"&gt;udp&lt;/attribute&gt;
-      &lt;attribute name="ChannelPartitionName"&gt;${jboss.partition.name:DefaultPartition}-JMS&lt;/attribute&gt;
-
-      &lt;attribute name="AsyncChannelConfig"&gt;
-         &lt;config&gt;
-            &lt;UDP mcast_recv_buf_size="500000" down_thread="false" ip_mcast="true" mcast_send_buf_size="32000"
-           mcast_port="45567" ucast_recv_buf_size="500000" use_incoming_packet_handler="false"
-           mcast_addr="228.8.8.8" use_outgoing_packet_handler="true" loopback="true" ucast_send_buf_size="32000" ip_ttl="32" bind_addr="127.0.0.1"/&gt;
-            &lt;AUTOCONF down_thread="false" up_thread="false"/&gt;
-            &lt;PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/&gt;
-            &lt;MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/&gt;
-            &lt;FD_SOCK down_thread="false" up_thread="false"/&gt;
-            &lt;FD timeout="20000" max_tries="3" down_thread="false" up_thread="false" shun="true"/&gt;
-            &lt;VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/&gt;
-            &lt;pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
-                         retransmit_timeout="100,200,600,1200,2400,4800"/&gt;
-            &lt;UNICAST timeout="1200,2400,3600" down_thread="false" up_thread="false"/&gt;
-            &lt;pbcast.STABLE stability_delay="1000" desired_avg_gossip="20000" down_thread="false" max_bytes="0" up_thread="false"/&gt;
-            &lt;FRAG frag_size="8192" down_thread="false" up_thread="false"/&gt;
-            &lt;VIEW_SYNC avg_send_interval="60000" down_thread="false" up_thread="false" /&gt;
-            &lt;pbcast.GMS print_local_addr="true" join_timeout="3000" down_thread="false" join_retry_timeout="2000" up_thread="false" shun="true"/&gt;
-         &lt;/config&gt;
-      &lt;/attribute&gt;
-
-      &lt;attribute name="SyncChannelConfig"&gt;
-         &lt;config&gt;
-            &lt;UDP mcast_recv_buf_size="500000" down_thread="false" ip_mcast="true" mcast_send_buf_size="32000"
-           mcast_port="45568" ucast_recv_buf_size="500000" use_incoming_packet_handler="false"
-           mcast_addr="228.8.8.8" use_outgoing_packet_handler="true" loopback="true" ucast_send_buf_size="32000" ip_ttl="32" bind_addr="127.0.0.1"/&gt;
-            &lt;AUTOCONF down_thread="false" up_thread="false"/&gt;
-            &lt;PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/&gt;
-            &lt;MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/&gt;
-            &lt;FD_SOCK down_thread="false" up_thread="false"/&gt;
-            &lt;FD timeout="20000" max_tries="3" down_thread="false" up_thread="false" shun="true"/&gt;
-            &lt;VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/&gt;
-            &lt;pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
-                         retransmit_timeout="100,200,600,1200,2400,4800"/&gt;
-            &lt;UNICAST timeout="1200,2400,3600" down_thread="false" up_thread="false"/&gt;
-            &lt;pbcast.STABLE stability_delay="1000" desired_avg_gossip="20000" down_thread="false" max_bytes="0" up_thread="false"/&gt;
-            &lt;FRAG frag_size="8192" down_thread="false" up_thread="false"/&gt;
-            &lt;VIEW_SYNC avg_send_interval="60000" down_thread="false" up_thread="false" /&gt;
-            &lt;pbcast.GMS print_local_addr="true" join_timeout="3000" down_thread="false" join_retry_timeout="2000" up_thread="false" shun="true"/&gt;
-            &lt;pbcast.STATE_TRANSFER down_thread="false" up_thread="false"/&gt;
-         &lt;/config&gt;
-      &lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-       </programlisting>
-
-       <section id="conf.postoffice.clustered.attributes">
-
-       <title>The nclustered post office has the following attributes</title>
-
-          <section id="conf.postoffice.clustered.attributes.datasource">
-             <title>DataSource</title>
-             <para>The datasource the postoffice should use for persisting its mapping data</para>
-          </section>
-
-          <section id="conf.postoffice.clustered.attributes.sqlproperties">
-              <title>SQLProperties</title>
-              <para>
-                            This is where the DDL and DML for the particular database is specified.
-                            If a particular DDL or DML statement is not overridden, the default Hypersonic
-                            configuration will be used for that statement.
-           </para>
-          </section>
-
-          <section id="conf.postoffice.clustered.attributes.createtables">
-               <title>CreateTablesOnStartup</title>
-
-               <para>
-                  Set this to <literal>true</literal> if you wish the post office to attempt
-                  to create the tables (and indexes) when it starts. If the tables (or indexes)
-                  already exist a <literal>SQLException</literal> will be thrown by the JDBC driver and
-                  ignored by the Persistence Manager, allowing it to continue.
-               </para>
-               <para>
-                  By default the value of <literal>CreateTablesOnStartup</literal> attribute
-                  is set to <literal>true</literal>
-               </para>
-         </section>
-
-          <section id="conf.postoffice.clustered.attributes.postofficename">
-               <title>PostOfficeName</title>
-
-               <para>
-                  The name of the post office
-               </para>
-         </section>
-
-          <section id="conf.postoffice.clustered.attributes.nodeidview">
-               <title>NodeIDView</title>
-
-               <para>
-                  This returns set containing the node ids of all the nodes in the cluster
-               </para>
-         </section>
-
-          <section id="conf.postoffice.clustered.attributes.groupname">
-               <title>GroupName</title>
-
-               <para>
-                  All post offices in the cluster with the same group name will form a cluster together. Make sure the group name matches with
-                  all the nodes in the cluster you want to form a cluster with.
-               </para>
-         </section>
-
-          <section id="conf.postoffice.clustered.attributes.messagepullpolicy">
-               <title>MessagePullPolicy</title>
-               <para>
-                  JBoss Messaging has the ability for queues on one node to pull messages from other nodes when they have exhausted their local messages.
-               </para>
-               <para>This prevents messages from getting stranded on nodes with slow or no consumers, and balances out message processing across the cluster.</para>
-               <para>How, if and when messages are pulled from one node to another is determined by the MessagePullPolicy</para>
-               <para>By default this set to <literal>org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy</literal> which is a dummy
-               implementation which never pulls messages from one node to another.</para>
-               <para>Whether you need message redistribution or not depends on your application topology - please see the section on clustering configuration for
-               more details</para>
-               <para>If you require message redistribution then set this value to <literal>org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy</literal>
-               </para>
-               <warning>Enabling message redistribution can result in the strict JMS message ordering guarantee being lost (i.e. the order of receipt of messages from
-               a particular producer is retained). If this is not acceptable then do not enable message redistribution.</warning>
-         </section>
-
-          <section id="conf.postoffice.clustered.attributes.clusterrouterfactory">
-               <title>ClusterRouterFactory</title>
-               <para>
-                  When a message arrives on a node - JBoss Messaging needs to decide whether to route it to a local queue or a remote queue on a different node.
-               </para>
-               <para>This setting allows you to specify the factory that determines this routing</para>
-               <para>By default this set to <literal>org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory</literal> which always favours
-               a local queue if one is available otherwise it round robins amongst other queues.</para>
-               <para>The particular router factory you require depends on your application topology - please see the section on clustering configuration for
-               more details</para>
-               <para>Other values this attribute can be set to are <literal>org.jboss.messaging.core.plugin.postoffice.cluster.RoundRobinRouterFactory</literal>
-               if you do not want to favour the local queue.
-               </para>
-         </section>
-
-          <section id="conf.postoffice.clustered.attributes.statetimeout">
-               <title>StateTimeout</title>
-               <para>
-                  The maximum time to wait when waiting for the group state to arrive when a node joins a pre-existing cluster.
-               </para>
-               <para>The default value is <literal>5000</literal> milliseconds
-               </para>
-         </section>
-
-          <section id="conf.postoffice.clustered.attributes.casttimeout">
-               <title>CastTimeout</title>
-               <para>
-                  The maximum time to wait for a reply casting message synchronously
-               </para>
-               <para>The default value is <literal>5000</literal> milliseconds
-               </para>
-         </section>
-
-         <section id="conf.postoffice.clustered.attributes.statssendperiod">
-               <title>StatsSendPeriod</title>
-               <para>
-                       When clustering, each node in the cluster will broadcast statistics periodically to inform the other nodes of their queues and the number of
-                       messages in them. This data is then used by the message redistribution policy to redistribute messages if necessary.
-                       This value represents the number of milliseconds between statistics broadcasts.
-              </para>
-              <para>
-                       The default value is <literal>10000</literal> milliseconds
-              </para>
-         </section>
-
-         <section id="conf.postoffice.clustered.attributes.syncchannelconfig">
-               <title>SyncChannelConfig</title>
-               <para>
-                    JBoss Messaging uses JGroups for all group management. This contains the JGroups stack configuration for the synchronous channel.
-              </para>
-              <para>The synchronous channel is used for sending request/reeciving responses from other nodes in the cluster</para>
-              <para>
-               The details of the JGroups configuration won't be discussed here since it is standard JGroups configuration.
-                       Detailed information on JGroups can be found in JGroups release documentation or on-line at
-                       <ulink url="http://www.jgroups.org">http://www.jgroups.org</ulink> or
-                 <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups">http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups</ulink>
-              </para>
-         </section>
-
-         <section id="conf.postoffice.clustered.attributes.asyncchannelconfig">
-               <title>AsyncChannelConfig</title>
-               <para>
-                    JBoss Messaging uses JGroups for all group management. This contains the JGroups stack configuration for the asynchronous channel.
-              </para>
-              <para>The asynchronous channel is used for sending sending/receiving messages from other nodes in the cluster</para>
-              <para>
-               The details of the JGroups configuration won't be discussed here since it is standard JGroups configuration.
-                       Detailed information on JGroups can be found in JGroups release documentation or on-line at
-                       <ulink url="http://www.jgroups.org">http://www.jgroups.org</ulink> or
-                 <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups">http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups</ulink>
-              </para>
-         </section>
-
-         <section id="conf.postoffice.clustered.attributes.threadpoolsize">
-               <title>ThreadPoolSize</title>
-               <para>
-                    The post office uses a thread pool for dispatching requests/handling responses from the cluster. This attribute represents the maximum size of
-                    that pool
-              </para>
-              <para>The default value of this is <literal>50</literal> threads</para>
-         </section>
-
-      </section>
-   </section>
-   </section>
-
-
-
-  <section id="conf.persistencemanager">
-    <title>Configuring the Persistence Manager</title>
-
-    <para>It is the job of the persistence manager to manage all message related persistence.
-    </para>
-
-
-    <para>
-       JBoss Messaging ships with a JDBC Persistence Manager used for handling persistence of
-       message data in a relational database accessed via JDBC. The Persistence Manager
-       implementation is pluggable (the Persistence Manager is a Messaging server plug-in),
-       this making possible to provide other implementations for persisting message data in
-       non relational stores, file stores etc.
-    </para>
-
-     <para>
-        The configuration of "persistent" services is grouped in a
-        <filename>xxx-persistence-service.xml</filename> file, where the actual file prefix is
-        usually inferred from its corresponding database JDBC connection string. By default,
-        Messaging ships with a <filename>hsqldb-persistence-service.xml</filename>, which configures
-        the Messaging server to use the in-VM Hypersonic database instance that comes by default
-        with any JBossAS instance.
-     </para>
-
-     <warning>
-        <para>
-        The default Persistence Manager configuration is works out of the box with Hypersonic,
-        however it must be stressed that Hypersonic should not be used in a production environment
-        mainly due to its limited support for transaction isolation and its propensity to behave
-        erratically under high load.
-        </para>
-        <para>
-           The
-           <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=ConfigJBossMQDB">Critique of Hypersonic</ulink>
-           wiki page outlines some of the well-known issues occuring when using this database.
-        </para>
-     </warning>
-
-     <para>
-        JBoss Messaging also ships with pre-made Persistence Manager configurations for MySQL,
-        Oracle, PostgreSQL, Sybase and MS SQL Server. The example <filename>mysql-persistence-service.xml</filename>,
-        <filename>oracle-persistence-service.xml</filename>,
-        <filename>postgres-persistence-service.xml</filename> and
-        <filename>sybase-persistence-service.xml</filename> and
-        <filename>mssql-persistence-service.xml</filename> configuration files are available
-        in the <filename>examples/config</filename> directory of the release bundle.
-     </para>
-
-     <para>
-        Users are encouraged to contribute their own configuration files where we will thoroughly test them before certifying them for suppported use
-        with JBoss Messaging. The JDBC Persistence Manager has been designed
-        to use standard SQL for the DML so writing a JDBC Persistence Manager configuration for another
-        database is usually only a fairly simple matter of changing DDL in the configuration
-        which is likely to be different for different databases.
-     </para>
-
-     <para>
-        The default Hypersonic persistence configuration file is listed below:
-     </para>
-
-   <programlisting>
-
-      &lt;server&gt;
-
-         &lt;mbean code="org.jboss.messaging.core.plugin.JDBCPersistenceManagerService"
-            name="jboss.messaging:service=PersistenceManager"
-            xmbean-dd="xmdesc/JDBCPersistenceManager-xmbean.xml"&gt;
-            &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
-            &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
-            &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
-            &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
-            &lt;attribute name="UsingBatchUpdates"&gt;false&lt;/attribute&gt;
-            &lt;attribute name="MaxParams"&gt;500&lt;/attribute&gt;
-         &lt;/mbean&gt;
-
-         &lt;mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-            name="jboss.messaging:service=PostOffice"
-            xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml"&gt;
-            &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-            &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
-            &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
-            &lt;attribute name="PostOfficeName"&gt;JMS&lt;/attribute&gt;
-            &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
-            &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
-         &lt;/mbean&gt;
-
-         &lt;mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
-            name="jboss.messaging:service=JMSUserManager"
-            xmbean-dd="xmdesc/JMSUserManager-xmbean.xml"&gt;
-            &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
-            &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
-            &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
-            &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
-            &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
-      POPULATE.TABLES.1=INSERT INTO JBM_USER (USER_ID,PASSWD,CLIENTID) VALUES ('dilbert','dogbert','dilbert-id')
-            ]]&gt;&lt;/attribute&gt;
-         &lt;/mbean&gt;
-
-      &lt;/server&gt;
-
-   </programlisting>
-
-     <para>
-        An example of a Persistence Manager configuration for a MySQL database follows:
-     </para>
-
-  <programlisting>
-
-   &lt;server&gt;
-
-      &lt;mbean code="org.jboss.messaging.core.plugin.JDBCPersistenceManagerService"
-            name="jboss.messaging:service=PersistenceManager"
-            xmbean-dd="xmdesc/JDBCPersistenceManager-xmbean.xml"&gt;
-            &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
-            &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
-            &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
-            &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
-            &lt;attribute name="UsingBatchUpdates"&gt;true&lt;/attribute&gt;
-            &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
-      CREATE_MESSAGE_REFERENCE=CREATE TABLE JBM_MSG_REF (CHANNEL_ID BIGINT, MESSAGE_ID BIGINT, TRANSACTION_ID BIGINT, STATE CHAR(1), ORD BIGINT, PAGE_ORD BIGINT, DELIVERY_COUNT INTEGER, SCHED_DELIVERY BIGINT, PRIMARY KEY(CHANNEL_ID, MESSAGE_ID))
-      CREATE_IDX_MESSAGE_REF_TX=CREATE INDEX JBM_MSG_REF_TX ON JBM_MSG_REF (TRANSACTION_ID)
-      CREATE_IDX_MESSAGE_REF_ORD=CREATE INDEX JBM_MSG_REF_ORD ON JBM_MSG_REF (ORD)
-      CREATE_IDX_MESSAGE_REF_PAGE_ORD=CREATE INDEX JBM_MSG_REF_PAGE_ORD ON JBM_MSG_REF (PAGE_ORD)
-      CREATE_IDX_MESSAGE_REF_MESSAGE_ID=CREATE INDEX JBM_MSG_REF_MESSAGE_ID ON JBM_MSG_REF (MESSAGE_ID)
-      CREATE_IDX_MESSAGE_REF_SCHED_DELIVERY=CREATE INDEX JBM_MSG_REF_SCHED_DELIVERY ON JBM_MSG_REF (SCHED_DELIVERY)
-      CREATE_MESSAGE=CREATE TABLE JBM_MSG (MESSAGE_ID BIGINT, RELIABLE CHAR(1), EXPIRATION BIGINT, TIMESTAMP BIGINT, PRIORITY TINYINT, HEADERS MEDIUMBLOB, PAYLOAD LONGBLOB, CHANNEL_COUNT INTEGER, TYPE TINYINT, PRIMARY KEY (MESSAGE_ID))
-      CREATE_TRANSACTION=CREATE TABLE JBM_TX (TRANSACTION_ID BIGINT, BRANCH_QUAL VARBINARY(254), FORMAT_ID INTEGER, GLOBAL_TXID VARBINARY(254), PRIMARY KEY (TRANSACTION_ID))
-      CREATE_COUNTER=CREATE TABLE JBM_COUNTER (NAME VARCHAR(255), NEXT_ID BIGINT, PRIMARY KEY(NAME))
-      INSERT_MESSAGE_REF=INSERT INTO JBM_MSG_REF (CHANNEL_ID, MESSAGE_ID, TRANSACTION_ID, STATE, ORD, PAGE_ORD, DELIVERY_COUNT, SCHED_DELIVERY) VALUES (?, ?, ?, ?, ?, ?, ?, ?)
-      DELETE_MESSAGE_REF=DELETE FROM JBM_MSG_REF WHERE MESSAGE_ID=? AND CHANNEL_ID=? AND STATE='C'
-      UPDATE_MESSAGE_REF=UPDATE JBM_MSG_REF SET TRANSACTION_ID=?, STATE='-' WHERE MESSAGE_ID=? AND CHANNEL_ID=? AND STATE='C'
-      UPDATE_PAGE_ORDER=UPDATE JBM_MSG_REF SET PAGE_ORD = ? WHERE MESSAGE_ID=? AND CHANNEL_ID=?
-      COMMIT_MESSAGE_REF1=UPDATE JBM_MSG_REF SET STATE='C', TRANSACTION_ID = NULL WHERE TRANSACTION_ID=? AND STATE='+'
-      COMMIT_MESSAGE_REF2=DELETE FROM JBM_MSG_REF WHERE TRANSACTION_ID=? AND STATE='-'
-      ROLLBACK_MESSAGE_REF1=DELETE FROM JBM_MSG_REF WHERE TRANSACTION_ID=? AND STATE='+'
-      ROLLBACK_MESSAGE_REF2=UPDATE JBM_MSG_REF SET STATE='C', TRANSACTION_ID = NULL WHERE TRANSACTION_ID=? AND STATE='-'
-      LOAD_PAGED_REFS=SELECT MESSAGE_ID, DELIVERY_COUNT, PAGE_ORD, SCHED_DELIVERY FROM JBM_MSG_REF WHERE CHANNEL_ID = ? AND PAGE_ORD BETWEEN ? AND ? ORDER BY PAGE_ORD
-      LOAD_UNPAGED_REFS=SELECT MESSAGE_ID, DELIVERY_COUNT, SCHED_DELIVERY FROM JBM_MSG_REF WHERE STATE = 'C' AND CHANNEL_ID = ? AND PAGE_ORD IS NULL ORDER BY ORD
-      LOAD_REFS=SELECT MESSAGE_ID, DELIVERY_COUNT, SCHED_DELIVERY FROM JBM_MSG_REF WHERE STATE = 'C' AND CHANNEL_ID = ? ORDER BY ORD
-      UPDATE_REFS_NOT_PAGED=UPDATE JBM_MSG_REF SET PAGE_ORD = NULL WHERE PAGE_ORD BETWEEN ? AND ? AND CHANNEL_ID=?
-      SELECT_MIN_MAX_PAGE_ORD=SELECT MIN(PAGE_ORD), MAX(PAGE_ORD) FROM JBM_MSG_REF WHERE CHANNEL_ID = ?
-      SELECT_EXISTS_REF=SELECT MESSAGE_ID FROM JBM_MSG_REF WHERE CHANNEL_ID = ? AND MESSAGE_ID = ?
-      SELECT_EXISTS_REF_MESSAGE_ID=SELECT MESSAGE_ID FROM JBM_MSG_REF WHERE MESSAGE_ID = ?
-      UPDATE_DELIVERY_COUNT=UPDATE JBM_MSG_REF SET DELIVERY_COUNT = ? WHERE CHANNEL_ID = ? AND MESSAGE_ID = ?
-      UPDATE_CHANNEL_ID=UPDATE JBM_MSG_REF SET CHANNEL_ID = ? WHERE CHANNEL_ID = ?
-      LOAD_MESSAGES=SELECT MESSAGE_ID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, HEADERS, PAYLOAD, TYPE FROM JBM_MSG
-      INSERT_MESSAGE=INSERT INTO JBM_MSG (MESSAGE_ID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, HEADERS, PAYLOAD, CHANNEL_COUNT, TYPE) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)
-      INC_CHANNEL_COUNT=UPDATE JBM_MSG SET CHANNEL_COUNT = CHANNEL_COUNT + 1 WHERE MESSAGE_ID=?
-      DEC_CHANNEL_COUNT=UPDATE JBM_MSG SET CHANNEL_COUNT = CHANNEL_COUNT - 1 WHERE MESSAGE_ID=?
-      DELETE_MESSAGE=DELETE FROM JBM_MSG WHERE MESSAGE_ID=? AND CHANNEL_COUNT=0
-      MESSAGE_ID_COLUMN=MESSAGE_ID
-      MESSAGE_EXISTS=SELECT MESSAGE_ID FROM JBM_MSG WHERE MESSAGE_ID = ? FOR UPDATE
-      INSERT_TRANSACTION=INSERT INTO JBM_TX (TRANSACTION_ID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID) VALUES(?, ?, ?, ?)
-      DELETE_TRANSACTION=DELETE FROM JBM_TX WHERE TRANSACTION_ID = ?
-      SELECT_PREPARED_TRANSACTIONS=SELECT TRANSACTION_ID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID FROM JBM_TX
-      SELECT_MESSAGE_ID_FOR_REF=SELECT MESSAGE_ID, CHANNEL_ID FROM JBM_MSG_REF WHERE TRANSACTION_ID = ? AND STATE = '+' ORDER BY ORD
-      SELECT_MESSAGE_ID_FOR_ACK=SELECT MESSAGE_ID, CHANNEL_ID FROM JBM_MSG_REF WHERE TRANSACTION_ID = ? AND STATE = '-' ORDER BY ORD
-      UPDATE_COUNTER=UPDATE JBM_COUNTER SET NEXT_ID = ? WHERE NAME=?
-      SELECT_COUNTER=SELECT NEXT_ID FROM JBM_COUNTER WHERE NAME=? FOR UPDATE
-      INSERT_COUNTER=INSERT INTO JBM_COUNTER (NAME, NEXT_ID) VALUES (?, ?)
-      SELECT_ALL_CHANNELS=SELECT DISTINCT(CHANNEL_ID) FROM JBM_MSG_REF
-            ]]&gt;&lt;/attribute&gt;
-            &lt;attribute name="MaxParams"&gt;500&lt;/attribute&gt;
-      &lt;/mbean&gt;
-
-      &lt;mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-         name="jboss.messaging:service=PostOffice"
-         xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml"&gt;
-         &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-         &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
-         &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
-         &lt;attribute name="PostOfficeName"&gt;JMS&lt;/attribute&gt;
-         &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
-         &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
-         &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
-   CREATE_POSTOFFICE_TABLE=CREATE TABLE JBM_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, CLUSTERED CHAR(1))
-   INSERT_BINDING=INSERT INTO JBM_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED) VALUES (?, ?, ?, ?, ?, ?, ?)
-   DELETE_BINDING=DELETE FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
-   LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
-         ]]&gt;&lt;/attribute&gt;
-      &lt;/mbean&gt;
-
-      &lt;mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
-         name="jboss.messaging:service=JMSUserManager"
-         xmbean-dd="xmdesc/JMSUserManager-xmbean.xml"&gt;
-         &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
-         &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
-         &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
-         &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
-         &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
-   CREATE_USER_TABLE=CREATE TABLE JBM_USER (USER_ID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128), PRIMARY KEY(USER_ID))
-   CREATE_ROLE_TABLE=CREATE TABLE JBM_ROLE (ROLE_ID VARCHAR(32) NOT NULL, USER_ID VARCHAR(32) NOT NULL, PRIMARY KEY(USER_ID, ROLE_ID))
-   SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JBM_USER WHERE USER_ID=?
-   POPULATE.TABLES.1=INSERT INTO JBM_USER (USER_ID,PASSWD,CLIENTID) VALUES ('dilbert','dogbert','dilbert-id')
-         ]]&gt;&lt;/attribute&gt;
-      &lt;/mbean&gt;
-
-   &lt;/server&gt;
-
-  </programlisting>
-
-     <section id="conf.persistencemanager.attributes">
-
-
-        <title>
-        We now discuss the MBean attributes of the PersistenceManager MBean
-        </title>
-
-        <section id="conf.persistencemanager.attributes.createtables">
-           <title>CreateTablesOnStartup</title>
-
-           <para>
-              Set this to <literal>true</literal> if you wish the Persistence Manager to attempt
-              to create the tables (and indexes) when it starts. If the tables (or indexes)
-              already exist a <literal>SQLException</literal> will be thrown by the JDBC driver and
-              ignored by the Persistence Manager, allowing it to continue.
-           </para>
-           <para>
-              By default the value of <literal>CreateTablesOnStartup</literal> attribute
-              is set to <literal>true</literal>
-           </para>
-     </section>
-
-      <section id="conf.persistencemanager.attributes.batchupdates">
-           <title>UsingBatchUpdates</title>
-
-           <para>
-              Set this to <literal>true</literal> if the database supports JDBC batch updates.
-              The JDBC Persistence Manager will then group multiple database updates in batches
-              to aid performance.
-           </para>
-         <para>
-            By default the value of <literal>UsingBatchUpdates</literal> attribute
-            is set to <literal>false</literal>
-         </para>
-       </section>
-
-      <section id="conf.persistencemanager.attributes.binarystream">
-           <title>UsingBinaryStream</title>
-
-           <para>
-              Set this to <literal>true</literal> if you want messages to be store and read using a JDBC binary stream rather than using
-              getBytes(), setBytes(). Some database has limits on the maximum number of bytes that can be get/set using getBytes()/setBytes().
-           </para>
-         <para>
-            By default the value of <literal>UsingBinaryStream</literal> attribute
-            is set to <literal>true</literal>
-         </para>
-       </section>
-
-      <section id="conf.persistencemanager.attributes.trailingbyte">
-           <title>UsingTrailingByte</title>
-
-           <para>
-              Certain version of Sybase are known to truncate blobs if they have trailing zeros. To prevent this if this attribute is set to
-              <literal>true</literal> then a trailing non zero byte will be added and removed to each blob before and after persistence to prevent
-              the database from truncating it. Currently this is only known to be necessary for Sybase.
-           </para>
-         <para>
-            By default the value of <literal>UsingTrailingByte</literal> attribute
-            is set to <literal>false</literal>
-         </para>
-       </section>
-
-       <section id="conf.persistencemanager.attributes.sqlproperties">
-           <title>SQLProperties</title>
-
-           <para>
-              This is where the DDL and DML for the particular database is specified.
-              If a particular DDL or DML statement is not overridden, the default Hypersonic
-              configuration will be used for that statement.
-           </para>
-        </section>
-
-        <section id="conf.persistencemanager.attributes.maxparams">
-          <title>MaxParams</title>
-
-          <para>
-             When loading messages the persistence manager will generate prepared statements with many parameters. This value tells the persistence
-             manager what the absolute maximum number of parameters are allowable per prepared statement.
-
-          </para>
-          <para>
-           By default the value of <literal>MaxParams</literal> attribute
-           is set to <literal>100</literal>
-        </para>
-       </section>
-
-    </section>
-
-   </section>
-
-
- <section id="conf.jmsusermanager">
-   <title>Configuring the JMS user manager</title>
-
-      <para>The JMS user manager handles the mapping of pre-configured client IDs to users and also managers the user and role tables which may or
-      may not be used depending on which login module you have configured</para>
-
-      <para>Here is an example JMSUserManager configuration</para>
-
-      <programlisting>
-
-   &lt;mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
-      name="jboss.messaging:service=JMSUserManager"
-      xmbean-dd="xmdesc/JMSUserManager-xmbean.xml"&gt;
-      &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
-      &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
-      &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
-      &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
-      &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JBM_USER (USER_ID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128), PRIMARY KEY(USER_ID))
-CREATE_ROLE_TABLE=CREATE TABLE JBM_ROLE (ROLE_ID VARCHAR(32) NOT NULL, USER_ID VARCHAR(32) NOT NULL, PRIMARY KEY(USER_ID, ROLE_ID))
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JBM_USER WHERE USER_ID=?
-POPULATE.TABLES.1=INSERT INTO JBM_USER (USER_ID,PASSWD,CLIENTID) VALUES ('dilbert','dogbert','dilbert-id')
-      ]]&gt;&lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-      </programlisting>
-
-        <section id="conf.persistencemanager.attributes">
-
-
-        <title>
-        We now discuss the MBean attributes of the PersistenceManager MBean
-        </title>
-
-        <section id="conf.jmsusermanager.attributes.createtables">
-           <title>CreateTablesOnStartup</title>
-
-           <para>
-              Set this to <literal>true</literal> if you wish the JMS user manager to attempt
-              to create the tables (and indexes) when it starts. If the tables (or indexes)
-              already exist a <literal>SQLException</literal> will be thrown by the JDBC driver and
-              ignored by the Persistence Manager, allowing it to continue.
-           </para>
-           <para>
-              By default the value of <literal>CreateTablesOnStartup</literal> attribute
-              is set to <literal>true</literal>
-           </para>
-     </section>
-
-      <section id="conf.jmsusermanager.attributes.batchupdates">
-           <title>UsingBatchUpdates</title>
-
-           <para>
-              Set this to <literal>true</literal> if the database supports JDBC batch updates.
-              The JDBC Persistence Manager will then group multiple database updates in batches
-              to aid performance.
-           </para>
-         <para>
-            By default the value of <literal>UsingBatchUpdates</literal> attribute
-            is set to <literal>false</literal>
-         </para>
-       </section>
-
-
-       <section id="conf.jmsusermanager.attributes.sqlproperties">
-           <title>SQLProperties</title>
-
-           <para>
-              This is where the DDL and DML for the particular database is specified.
-              If a particular DDL or DML statement is not overridden, the default Hypersonic
-              configuration will be used for that statement.
-           </para>
-
-           <para>
-           Default user and role data can also be specified here. Any data to be inserted must be specified with property names starting with
-           <literal>POPULATE.TABLES</literal> as in the above example.
-           </para>
-        </section>
-
-
-     </section>
-
-  </section>
-
-
-  <section id="conf.destination">
-    <title>Configuring Destinations</title>
-
-<section id="conf.preconf.destinations">
-        <title>Pre-configured destinations</title>
-
-        <para>
-           JBoss Messaging  ships with a default set of pre-configured destinations that will be
-           deployed during the server start up. The file that contains configuration for these
-           destinations is <filename>destinations-service.xml</filename>. A section of
-           this file is listed below:
-        </para>
-
-        <programlisting>
-   &lt;!--
-      The Default Dead Letter Queue. This destination is a dependency of an EJB MDB container.
-   --&gt;
-
-   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
-      name="jboss.messaging.destination:service=Queue,name=DLQ"
-      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-   &lt;/mbean&gt;
-
-
-   &lt;mbean code="org.jboss.jms.server.destination.TopicService"
-      name="jboss.messaging.destination:service=Topic,name=testTopic"
-      xmbean-dd="xmdesc/Topic-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-      &lt;attribute name="SecurityConfig"&gt;
-         &lt;security&gt;
-            &lt;role name="guest" read="true" write="true"/&gt;
-            &lt;role name="publisher" read="true" write="true" create="false"/&gt;
-            &lt;role name="durpublisher" read="true" write="true" create="true"/&gt;
-         &lt;/security&gt;
-      &lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-   &lt;mbean code="org.jboss.jms.server.destination.TopicService"
-      name="jboss.messaging.destination:service=Topic,name=securedTopic"
-      xmbean-dd="xmdesc/Topic-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-      &lt;attribute name="SecurityConfig"&gt;
-         &lt;security&gt;
-            &lt;role name="publisher" read="true" write="true" create="false"/&gt;
-         &lt;/security&gt;
-      &lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-
-   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
-      name="jboss.messaging.destination:service=Queue,name=testQueue"
-      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-      &lt;attribute name="SecurityConfig"&gt;
-         &lt;security&gt;
-            &lt;role name="guest" read="true" write="true"/&gt;
-            &lt;role name="publisher" read="true" write="true" create="false"/&gt;
-            &lt;role name="noacc" read="false" write="false" create="false"/&gt;
-         &lt;/security&gt;
-      &lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
-      name="jboss.messaging.destination:service=Queue,name=A"
-      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-   &lt;/mbean&gt;
-
-
-   &lt;!-- It's possible for indiviual queues and topics to use a specific queue for
-   an expiry or DLQ --&gt;
-
-   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
-      name="jboss.messaging.destination:service=Queue,name=PrivateDLQ"
-      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-   &lt;/mbean&gt;
-
-   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
-      name="jboss.messaging.destination:service=Queue,name=PrivateExpiryQueue"
-      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-   &lt;/mbean&gt;
-
-   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
-      name="jboss.messaging.destination:service=Queue,name=QueueWithOwnDLQAndExpiryQueue"
-      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-      &lt;attribute name="DLQ"&gt;jboss.messaging.destination:service=Queue,name=PrivateDLQ&lt;/attribute&gt;
-      &lt;attribute name="ExpiryQueue"&gt;jboss.messaging.destination:service=Queue,name=PrivateExpiryQueue&lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-   &lt;mbean code="org.jboss.jms.server.destination.TopicService"
-      name="jboss.messaging.destination:service=Topic,name=TopicWithOwnDLQAndExpiryQueue"
-      xmbean-dd="xmdesc/Topic-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-      &lt;attribute name="DLQ"&gt;jboss.messaging.destination:service=Queue,name=PrivateDLQ&lt;/attribute&gt;
-      &lt;attribute name="ExpiryQueue"&gt;jboss.messaging.destination:service=Queue,name=PrivateExpiryQueue&lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-
-   &lt;mbean code="org.jboss.jms.server.destination.TopicService"
-      name="jboss.messaging.destination:service=Topic,name=TopicWithOwnRedeliveryDelay"
-      xmbean-dd="xmdesc/Topic-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-      &lt;attribute name="RedeliveryDelay"&gt;5000&lt;/attribute&gt;
-   &lt;/mbean&gt;
-
-
-   &lt;mbean code="org.jboss.jms.server.destination.TopicService"
-      name="jboss.messaging.destination:service=Topic,name=testDistributedTopic"
-      xmbean-dd="xmdesc/Topic-xmbean.xml"&gt;
-      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
-      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
-      &lt;attribute name="Clustered"&gt;true&lt;/attribute&gt;
-   &lt;/mbean&gt;
-....
-        </programlisting>
-
-    </section>
-
-
-    <section id="conf.destination.queue">
-
-       <title>Configuring queues</title>
-
-        <section id="conf.destination.queue.attributes">
-
-            <title>
-            We now discuss the MBean attributes of the Queue MBean
-            </title>
-
-               <section id="conf.destination.queue.attributes.name">
-                  <title>Name</title>
-                  <para>The name of the queue</para>
-               </section>
-
-               <section id="conf.destination.queue.attributes.jndiName">
-                   <title>JNDIName</title>
-                   <para>The JNDI name where the queue is bound</para>
-               </section>
-
-               <section id="conf.destination.queue.attributes.dlq">
-                    <title>DLQ</title>
-                    <para>The DLQ used for this queue. Overrides any value set on the ServerPeer config</para>
-               </section>
-
-               <section id="conf.destination.queue.attributes.expiryqueue">
-                    <title>ExpiryQueue</title>
-                    <para>The Expiry queue used for this queue. Overrides any value set on the ServerPeer config</para>
-               </section>
-
-               <section id="conf.destination.queue.attributes.redeliverydelay">
-                    <title>RedeliveryDelay</title>
-                    <para>The redlivery delay to be used for this queue. Overrides any value set on the ServerPeer config</para>
-               </section>
-
-              <section id="conf.destination.queue.attributes.security">
-               <title>Destination Security Configuration</title>
-
-                 <para>
-                    <literal>SecurityConfig</literal> - allows you to determine which roles are allowed
-                    to read, write and create on the destination. It has exactly the same syntax and
-                    semantics as the security configuration in JBossMQ destinations.
-                 </para>
-
-                 <para>
-                    The <literal>SecurityConfig</literal> element should contain one
-                    <literal>&lt;security&gt;</literal> element. The <literal>&lt;security&gt;</literal>
-                    element can contain multiple <literal>&lt;role&gt;</literal> elements.
-                    Each <literal>&lt;role&gt;</literal> element defines the access for that
-                    particular role.
-                 </para>
-
-                 <para>
-                    If the <literal>read</literal> attribute is <literal>true</literal> then that role
-                    will be able to read (create consumers, receive messaages or browse) this destination.
-                 </para>
-
-                 <para>
-                    If the <literal>write</literal> attribute is <literal>true</literal> then that role
-                    will be able to write (create producers or send messages) to this destination.
-                 </para>
-
-                 <para>
-                    If the <literal>create</literal> attribute is <literal>true</literal> then that role
-                    will be able to create durable subscriptions on this destination.
-                 </para>
-
-                 <para>
-                    Note that the security configuration for a destination is optional. If a
-                    <literal>SecurityConfig</literal> element is not specifed then the default
-                    security configuration from the Server Peer will be used.
-                 </para>
-              </section>
-
-           <section id="conf.destination.queue.attributes.paging">
-              <title>Destination paging parameters</title>
-
-              <para>
-                 'Pageable Channels' are a sophisticated new feature available in JBoss Messaging.
-              </para>
-
-              <para>
-                 If your application needs to support very large queues or subscriptions containing
-                 potentially millions of messages, then it's not possible to store them all in
-                 memory at once.
-              </para>
-
-              <para>
-                 JBoss Messaging solves this problem but letting you specify the
-                 maximum number of messages that can be stored in memory at any one time,
-                 on a queue-by-queue, or topic-by-topic basis. JBoss Messaging then pages messages
-                 to and from storage transparently in blocks, allowing queues and subscriptions to
-                 grow to very large sizes without any performance degradation as channel size increases.
-              </para>
-
-              <para>
-                 This has been tested with in excess of 10 million 2K messages on very basic hardware
-                 and has the potential to scale to much larger number of messages.
-              </para>
-
-              <para>
-                 The individual parameters are:
-              </para>
-
-              <para>
-                 <literal>FullSize</literal> - this is the maximum number of messages held by the
-                 queue or topic subscriptions in memory at any one time. The actual queue or
-                 subscription can hold many more messages than this but these are paged to and
-                 from storage as necessary as messages are added or consumed.
-              </para>
-
-              <para>
-                 <literal>PageSize</literal> - When loading messages from the queue or subscrition
-                 this is the maximum number of messages to pre-load in one operation.
-              </para>
-
-              <para>
-                 <literal>DownCacheSize</literal> - When paging messages to storage from the queue
-                 they first go into a "Down Cache" before being written to storage. This enables the
-                 write to occur as a single operation thus aiding performance. This setting determines
-                 the max number of messages that the Down Cache will hold before they are flushed
-                 to storage.
-              </para>
-
-              <para>
-                 If no values for <literal>FullSize</literal>, <literal>PageSize</literal>,
-                 or <literal>DownCacheSize</literal> are specified they will default to values
-                 75000, 2000, 2000 respectively.
-              </para>
-
-              <para>
-                 If you want to specify the paging parameters used for temporary queues then you need to specify them
-                 on the appropriate connection factory.
-                 See connection factory configuration for details.
-              </para>
-           </section>
-
-           <section id="conf.destination.queue.attributes.createdprogrammatically">
-               <title>CreatedProgrammatically</title>
-
-               <para>
-                 Returns <literal>true</literal> if the queue was created programmatically
-              </para>
-          </section>
-
-           <section id="conf.destination.queue.attributes.messagecount">
-               <title>MessageCount</title>
-
-               <para>
-                 Returns the total number of messages in the queue = number not being delivered + number being delivered + number being scheduled
-              </para>
-          </section>
-
-           <section id="conf.destination.queue.attributes.scheduledmessagecount">
-               <title>ScheduledMessageCount</title>
-
-               <para>
-                 Returns the  number of scheduled messages in the queue. This is the number of messages scheduled to be delivered at a later date.
-              </para>
-          </section>
-
-           <section id="conf.destination.queue.attributes.maxsize">
-               <title>MaxSize</title>
-
-               <para>
-                 A maximum size (in number of messages) can be specified for a queue. Any messages that arrive beyond this point will be dropped. The default is
-                 <literal>-1</literal> which is unbounded.
-              </para>
-          </section>
-
-           <section id="conf.destination.queue.attributes.clustered">
-               <title>Clustered</title>
-
-               <para>
-                 Clustered destinations must have this set to <literal>true</literal>
-              </para>
-          </section>
-
-           <section id="conf.destination.queue.attributes.messagecounter">
-               <title>MessageCounter</title>
-
-               <para>
-                 Each queue maintains a message counter.
-              </para>
-          </section>
-
-           <section id="conf.destination.queue.attributes.messagecounterstats">
-               <title>MessageCounterStatistics</title>
-
-               <para>
-                 The statistics for the message counter
-              </para>
-          </section>
-
-           <section id="conf.destination.queue.attributes.messagecounterhistorydaylimit">
-               <title>MessageCounterHistoryDayLimit</title>
-
-               <para>
-                 The maximum number of days to hold message counter history for. Overrides any value set on the ServerPeer.
-              </para>
-          </section>
-
-           <section id="conf.destination.queue.attributes.consumercount">
-               <title>ConsumerCount</title>
-
-               <para>
-                 The number of consumers currently consuming from the queue.
-              </para>
-          </section>
-
-     </section>
-
-
-     <section id="conf.destination.queue.operations">
-
-         <title>
-             We now discuss the MBean operations of the Queue MBean
-         </title>
-
-         <section id="conf.destination.queue.operations.removeallmessages">
-             <title>RemoveAllMessages</title>
-
-              <para>
-                Remove (and delete) all messages from the queue.
-                <warning>Use this with caution. It will permanently delete all messages from the queue</warning>
-             </para>
-         </section>
-
-         <section id="conf.destination.queue.operations.listallmessages">
-             <title>ListAllMessages</title>
-
-              <para>
-                List all messages currently in the queue
-             </para>
-             <para>There are two overloaded versions of this operation: One takes a JMS selector as an argument, the other does not. By using the selector
-             you can retrieve a subset of the messages in the queue that match the criteria</para>
-         </section>
-
-         <section id="conf.destination.queue.operations.listdurablemessages">
-             <title>ListDurableMessages</title>
-
-              <para>
-                As listAllMessages but only lists the durable messages
-             </para>
-             <para>There are two overloaded versions of this operation: One takes a JMS selector as an argument, the other does not. By using the selector
-             you can retrieve a subset of the messages in the queue that match the criteria</para>
-         </section>
-
-
-         <section id="conf.destination.queue.operations.listnondurablemessages">
-             <title>ListNonDurableMessages</title>
-
-              <para>
-                As listAllMessages but only lists the non durable messages
-             </para>
-             <para>There are two overloaded versions of this operation: One takes a JMS selector as an argument, the other does not. By using the selector
-             you can retrieve a subset of the messages in the queue that match the criteria</para>
-         </section>
-
-         <section id="conf.destination.queue.operations.resetmessagecounter">
-             <title>ResetMessageCounter</title>
-
-              <para>
-                Resets the message counter to zero.
-             </para>
-         </section>
-
-         <section id="conf.destination.queue.operations.resetmessagecounterhistory">
-             <title>ResetMessageCounterHistory</title>
-
-              <para>
-                Resets the message counter history.
-             </para>
-         </section>
-
-         <section id="conf.destination.queue.operations.listmessagecounterashtml">
-             <title>ListMessageCounterAsHTML</title>
-
-              <para>
-                Lists the message counter in an easy to display HTML format
-             </para>
-         </section>
-
-         <section id="conf.destination.queue.operations.listmessagecounterhistoryashtml">
-             <title>ListMessageCounterHistoryAsHTML</title>
-
-              <para>
-                Lists the message counter history in an easy to display HTML format
-             </para>
-         </section>
-
-
-     </section>
-
-  </section>
-
-
-
-
-  <section id="conf.destination.topics">
-
-       <title>Configuring topics</title>
-
-        <section id="conf.destination.topic.attributes">
-
-            <title>
-            We now discuss the MBean attributes of the Topic MBean
-            </title>
-
-               <section id="conf.destination.topic.attributes.name">
-                  <title>Name</title>
-                  <para>The name of the topic</para>
-               </section>
-
-               <section id="conf.destination.topic.attributes.jndiName">
-                   <title>JNDIName</title>
-                   <para>The JNDI name where the topic is bound</para>
-               </section>
-
-               <section id="conf.destination.topic.attributes.dlq">
-                    <title>DLQ</title>
-                    <para>The DLQ used for this topic. Overrides any value set on the ServerPeer config</para>
-               </section>
-
-               <section id="conf.destination.topic.attributes.expiryqueue">
-                    <title>ExpiryQueue</title>
-                    <para>The Expiry queue used for this topic. Overrides any value set on the ServerPeer config</para>
-               </section>
-
-               <section id="conf.destination.topic.attributes.redeliverydelay">
-                    <title>RedeliveryDelay</title>
-                    <para>The redelivery delay to be used for this topic. Overrides any value set on the ServerPeer config</para>
-               </section>
-
-              <section id="conf.destination.topic.attributes.security">
-               <title>Destination Security Configuration</title>
-
-                 <para>
-                    <literal>SecurityConfig</literal> - allows you to determine which roles are allowed
-                    to read, write and create on the destination. It has exactly the same syntax and
-                    semantics as the security configuration in JBossMQ destinations.
-                 </para>
-
-                 <para>
-                    The <literal>SecurityConfig</literal> element should contain one
-                    <literal>&lt;security&gt;</literal> element. The <literal>&lt;security&gt;</literal>
-                    element can contain multiple <literal>&lt;role&gt;</literal> elements.
-                    Each <literal>&lt;role&gt;</literal> element defines the access for that
-                    particular role.
-                 </para>
-
-                 <para>
-                    If the <literal>read</literal> attribute is <literal>true</literal> then that role
-                    will be able to read (create consumers, receive messaages or browse) this destination.
-                 </para>
-
-                 <para>
-                    If the <literal>write</literal> attribute is <literal>true</literal> then that role
-                    will be able to write (create producers or send messages) to this destination.
-                 </para>
-
-                 <para>
-                    If the <literal>create</literal> attribute is <literal>true</literal> then that role
-                    will be able to create durable subscriptions on this destination.
-                 </para>
-
-                 <para>
-                    Note that the security configuration for a destination is optional. If a
-                    <literal>SecurityConfig</literal> element is not specifed then the default
-                    security configuration from the Server Peer will be used.
-                 </para>
-              </section>
-
-           <section id="conf.destination.topic.attributes.paging">
-              <title>Destination paging parameters</title>
-
-              <para>
-                 'Pageable Channels' are a sophisticated new feature available in JBoss Messaging.
-              </para>
-
-              <para>
-                 If your application needs to support very large queues or subscriptions containing
-                 potentially millions of messages, then it's not possible to store them all in
-                 memory at once.
-              </para>
-
-              <para>
-                 JBoss Messaging solves this problem but letting you specify the
-                 maximum number of messages that can be stored in memory at any one time,
-                 on a queue-by-queue, or topic-by-topic basis. JBoss Messaging then pages messages
-                 to and from storage transparently in blocks, allowing queues and subscriptions to
-                 grow to very large sizes without any performance degradation as channel size increases.
-              </para>
-
-              <para>
-                 This has been tested with in excess of 10 million 2K messages on very basic hardware
-                 and has the potential to scale to much larger number of messages.
-              </para>
-
-              <para>
-                 The individual parameters are:
-              </para>
-
-              <para>
-                 <literal>FullSize</literal> - this is the maximum number of messages held by the
-                 queue or topic subscriptions in memory at any one time. The actual queue or
-                 subscription can hold many more messages than this but these are paged to and
-                 from storage as necessary as messages are added or consumed.
-              </para>
-
-              <para>
-                 <literal>PageSize</literal> - When loading messages from the queue or subscrition
-                 this is the maximum number of messages to pre-load in one operation.
-              </para>
-
-              <para>
-                 <literal>DownCacheSize</literal> - When paging messages to storage from the queue
-                 they first go into a "Down Cache" before being written to storage. This enables the
-                 write to occur as a single operation thus aiding performance. This setting determines
-                 the max number of messages that the Down Cache will hold before they are flushed
-                 to storage.
-              </para>
-
-              <para>
-                 If no values for <literal>FullSize</literal>, <literal>PageSize</literal>,
-                 or <literal>DownCacheSize</literal> are specified they will default to values
-                 75000, 2000, 2000 respectively.
-              </para>
-
-              <para>
-                 If you want to specify the paging parameters used for temporary queues then you need to specify them
-                 on the appropriate connection factory.
-                 See connection factory configuration for details.
-              </para>
-           </section>
-
-           <section id="conf.destination.topic.attributes.createdprogrammatically">
-               <title>CreatedProgrammatically</title>
-
-               <para>
-                 Returns <literal>true</literal> if the topic was created programmatically
-              </para>
-          </section>
-
-           <section id="conf.destination.topic.attributes.maxsize">
-               <title>MaxSize</title>
-
-               <para>
-                 A maximum size (in number of messages) can be specified for a topic subscription. Any messages that arrive beyond this point will be dropped. The default is
-                 <literal>-1</literal> which is unbounded.
-              </para>
-          </section>
-
-           <section id="conf.destination.topic.attributes.clustered">
-               <title>Clustered</title>
-
-               <para>
-                 Clustered destinations must have this set to <literal>true</literal>
-              </para>
-          </section>
-
-           <section id="conf.destination.topic.attributes.messagecounterhistorydaylimit">
-               <title>MessageCounterHistoryDayLimit</title>
-
-               <para>
-                 The maximum number of days to hold message counter history for. Overrides any value set on the ServerPeer.
-              </para>
-          </section>
-
-           <section id="conf.destination.topic.attributes.messagecounters">
-               <title>MessageCounters</title>
-
-               <para>
-                 Return a list of the message counters for the subscriptions of this topic.
-              </para>
-          </section>
-
-           <section id="conf.destination.topic.attributes.allmessagecount">
-               <title>AllMessageCount</title>
-
-               <para>
-                 Return the total number of messages in all subscriptions of this topic.
-              </para>
-          </section>
-
-           <section id="conf.destination.topic.attributes.durablemessagecount">
-               <title>DurableMessageCount</title>
-
-               <para>
-                 Return the total number of durable messages in all subscriptions of this topic.
-              </para>
-
-          </section>
-
-         <section id="conf.destination.topic.attributes.nondurablemessagecount">
-             <title>NonDurableMessageCount</title>
-
-             <para>
-               Return the total number of non durable messages in all subscriptions of this topic.
-            </para>
-          </section>
-
-         <section id="conf.destination.topic.attributes.allsubscriptionscount">
-             <title>AllSubscriptionsCount</title>
-
-             <para>
-               The count of all subscriptions on this topic
-            </para>
-          </section>
-
-         <section id="conf.destination.topic.attributes.durablesubscriptionscount">
-             <title>DurableSubscriptionsCount</title>
-
-             <para>
-               The count of all durable subscriptions on this topic
-            </para>
-          </section>
-
-         <section id="conf.destination.topic.attributesnon.durablesubscriptionscount">
-             <title>NonDurableSubscriptionsCount</title>
-
-             <para>
-               The count of all non durable subscriptions on this topic
-            </para>
-        </section>
-
-
-     </section>
-
-
-     <section id="conf.destination.topic.operations">
-
-         <title>
-             We now discuss the MBean operations of the Topic MBean
-         </title>
-
-         <section id="conf.destination.topic.operations.removeallmessages">
-             <title>RemoveAllMessages</title>
-
-              <para>
-                Remove (and delete) all messages from the subscriptions of this topic.
-                <warning>Use this with caution. It will permanently delete all messages from the topic</warning>
-             </para>
-         </section>
-
-         <section id="conf.destination.topic.operations.listallsubscriptions">
-             <title>ListAllSubscriptions</title>
-
-              <para>
-                List all subscriptions of this topic
-             </para>
-         </section>
-
-         <section id="conf.destination.topic.operations.listdurablesubscriptions">
-             <title>ListDurableSubscriptions</title>
-
-              <para>
-                List all durable subscriptions of this topic
-             </para>
-         </section>
-
-         <section id="conf.destination.topic.operations.listnondurablesubscriptions">
-             <title>ListNonDurableSubscriptions</title>
-
-              <para>
-                List all non durable subscriptions of this topic
-             </para>
-         </section>
-
-         <section id="conf.destination.topic.operations.listallsubscriptionsashtml">
-             <title>ListAllSubscriptionsAsHTML</title>
-
-              <para>
-                List all subscriptions of this topic in an easy to display HTML format
-             </para>
-         </section>
-
-         <section id="conf.destination.topic.operations.listdurablesubscriptionsashtml">
-             <title>ListDurableSubscriptionsAsHTML</title>
-
-              <para>
-                List all durable subscriptions of this topic in an easy to display HTML format
-             </para>
-         </section>
-
-         <section id="conf.destination.topic.operations.listnondurablesubscriptionsashtml">
-             <title>ListNonDurableSubscriptionsAsHTML</title>
-
-              <para>
-                List all non durable subscriptions of this topic in an easy to display HTML format
-             </para>
-         </section>
-
-         <section id="conf.destination.topic.operations.listallmessages">
-             <title>ListAllMessages</title>
-
-              <para>
-                Lists all messages for the specified subscription.
-             </para>
-
-             <para> There are two overloaded versions of this operation. One that takes a selector and one that does not.
-             By specifyingthe selector you can limit the messages returned.
-             </para>
-         </section>
-
-         <section id="conf.destination.topic.operations.listnondurablemessages">
-             <title>ListNonDurableMessages</title>
-
-              <para>
-                Lists all non durable messages for the specified subscription.
-             </para>
-
-             <para> There are two overloaded versions of this operation. One that takes a selector and one that does not.
-             By specifyingthe selector you can limit the messages returned.
-             </para>
-         </section>
-
-         <section id="conf.destination.topic.operations.listdurablemessages">
-             <title>ListDurableMessages</title>
-
-              <para>
-                Lists all durable messages for the specified subscription.
-             </para>
-
-             <para> There are two overloaded versions of this operation. One that takes a selector and one that does not.
-             By specifyingthe selector you can limit the messages returned.
-             </para>
-         </section>
-
-     </section>
-
-  </section>
-
-
-
-     <section id="conf.destination.new">
-        <title>Deploying a new destination</title>
-
-        <para>
-           For a JBoss 4.0.x installation, JBoss Messaging is deployed in its own class
-           loading domain. Because of that you need to deploy a new destinations to use
-           with JBoss Messaging within the same class loading domain.
-       </para>
-
-        <para>
-           To deploy a new destination, create a new deployment descriptor named
-           <filename>myqueue-service.xml</filename> (or anything else that ends in
-           <literal>-service.xml</literal>) and copy it to the JBoss instance deployment
-           directory <filename>$JBOSS_HOME/server/messaging/deploy</filename>.
-        </para>
-
-        <para>
-           An example of a scoped destination deployment descriptor is listed below:
-        </para>
-
-        <programlisting>
-&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
-&lt;server&gt;
-   &lt;loader-repository&gt;jboss.messaging:loader=ScopedLoaderRepository
-   &lt;loader-repository-config&gt;java2ParentDelegation=false&lt;/loader-repository-config&gt;
-   &lt;/loader-repository&gt;
-   &lt;mbean
-      code=&quot;org.jboss.jms.server.destination.Queue&quot;
-     name=&quot;jboss.messaging.destination:service=Queue,name=testQueue&quot;
-     xmbean-dd=&quot;xmdesc/Queue-xmbean.xml&quot;&gt;
-      &lt;depends optional-attribute-name=&quot;ServerPeer&quot;&gt;
-         jboss.messaging:service=ServerPeer
-      &lt;/depends&gt;
-      &lt;attribute name=&quot;SecurityConfig&quot;&gt;
-         &lt;security&gt;
-            &lt;role name=&quot;guest&quot; read=&quot;true&quot;write=&quot;true&quot;/&gt;
-            &lt;role name=&quot;publisher&quot; read=&quot;true&quot; write=&quot;true&quot; create=&quot;false&quot;/&gt;
-            &lt;role name=&quot;noacc&quot; read=&quot;false&quot; write=&quot;false&quot; create=&quot;false&quot;/&gt;
-          &lt;/security&gt;
-      &lt;/attribute&gt;
-      &lt;attribute name=&quot;fullSize&quot;&gt;75000&lt;/attribute&gt;
-      &lt;attribute name=&quot;pageSize&quot;&gt;2000&lt;/attribute&gt;
-      &lt;attribute name=&quot;downCacheSize&quot;&gt;2000&lt;/attribute&gt;
-   &lt;/mbean&gt;
-&lt;/server&gt;
-        </programlisting>
-
-     </section>
-  </section>
-
-  <section id="conf.connections">
-    <title>Configuring Connection Factories</title>
-
-    <para>
-       With the default configuration JBoss Messaging binds just one connection factory in
-       JNDI at start-up. This connection factory has no client ID and is bound into the
-       following JNDI contexts:
-       <literal>/ConnectionFactory, /XAConnectionFactory, java:/ConnectionFactory, java:/XAConnectionFactory</literal>
-    </para>
-
-    <para>
-       You may want to configure additional connection factories, for instance if you want to provide
-       a default client id for a connection factory, or if you want to bind it in different places
-       in JNDI, or if you want different connection factories to use different transports. Deploying
-       a new connection factory is equivalent with adding a new ConnectionFactory MBean
-       configuration to <filename>connection-factories-service.xml</filename>.
-    </para>
-     <para>
-        It is also possible to create an entirely
-        new service deployment descriptor <filename>xxx-service.xml</filename> altogether and
-        deploy it in <filename>$JBOSS_HOME/server/messaging/deploy</filename>.
-    </para>
-
-    <para>
-    Connection factories can either be clustered or non clustered.
-    Clustered connection factories create subsequent connections on different nodes of the cluster according to the load balancing policy.
-    The default load balancing policy is round robin.
-    </para>
-
-    <para>
-       An example connection factory configuration is presented below:
-     </para>
-
-      <programlisting>
-
-&lt;server&gt;
-   &lt;loader-repository&gt;
-      jboss.messaging:loader=ScopedLoaderRepository
-         &lt;loader-repository-config&gt;
-            java2ParentDelegation=false
-         &lt;/loader-repository-config&gt;
-   &lt;/loader-repository&gt;
-   &lt;mbean
-      code=&quot;org.jboss.jms.server.connectionfactory.ConnectionFactory&quot;
-      name=&quot;jboss.messaging.destination:service=ConnectionFactory&quot;
-      xmbean-dd=&quot;xmdesc/ConnectionFactory-xmbean.xml&quot;&gt;
-      &lt;constructor&gt;
-         &lt;arg type=&quot;java.lang.String&quot; value=&quot;myClientID&quot;/&gt;
-      &lt;/constructor&gt;
-      &lt;depends optional-attribute-name=&quot;ServerPeer&quot;&gt;
-         jboss.messaging:service=ServerPeer
-      &lt;/depends&gt;
-      &lt;depends optional-attribute-name=&quot;Connector&quot;&gt;
-         jboss.messaging:service=Connector,transport=socket
-      &lt;/depends&gt;
-      &lt;attribute name=&quot;PrefetchSize&quot;&gt;10&lt;/attribute&gt;
-      &lt;attribute name=&quot;DefaultTempQueueFullSize&quot;&gt;1000&lt;/attribute&gt;
-      &lt;attribute name=&quot;DefaultTempQueuePageSize&quot;&gt;50&lt;/attribute&gt;
-      &lt;attribute name=&quot;DefaultTempQueueDownCacheSize&quot;&gt;50&lt;/attribute&gt;
-      &lt;attribute name=&quot;JNDIBindings&quot;&gt;
-         &lt;bindings&gt;
-            &lt;binding&gt;/MyConnectionFactory1&lt;/binding&gt;
-            &lt;binding&gt;/factories/cf1&lt;/binding>&gt;
-         &lt;/bindings&gt;
-      &lt;/attribute&gt;
-   &lt;/mbean&gt;
-&lt;/server&gt;
-
-    </programlisting>
-
-     <para>
-        The above example would create a connection factory with pre-configured client ID
-        <literal>myClientID</literal> and bind the connection factory in two places in
-        the JNDI tree: <literal>/MyConnectionFactory</literal>
-        and <literal>/factories/cf</literal>. The connection factory will use the default
-        remoting connector. To use a different remoting connector with the connection factory
-        change the <literal>Connector</literal> attribute to specify the service name of the connector you wish to use.
-    </para>
-
-    <section id="conf.connectionfactory.attributes">
-
-       <title>
-           We now discuss the MBean attributes of the ConnectionFactory MBean
-       </title>
-
-       <section id="conf.destination.connectionfactory.attributes.clientid">
-           <title>ClientID</title>
-
-            <para>
-              Connection factories can be pre-configured with a client id. Any connections created using this connection factory will obtain this client id
-           </para>
-       </section>
-
-       <section id="conf.destination.connectionfactory.attributes.jndibindings">
-           <title>JNDIBindings</title>
-
-            <para>
-              Returns a list of the JNDI bindings for this connection factory
-           </para>
-       </section>
-
-     <section id="conf.destination.connectionfactory.attributes.prefetchsize">
-         <title>PrefetchSize</title>
-
-          <para>
-            Each client side consumer maintains a local buffer of messages from which it consumes. The server typically sends messages as fast as it can
-            to the consumer, and when the consumer is full it sends the server a "stop" message to say it is full.
-            When it clears enough space it sends a "start" message to ask the server to continue sending messages.
-            The prefetchSize determines the size of this buffer. Larger values give better throughput.
-         </para>
-       </section>
-
-     <section id="conf.destination.connectionfactory.attributes.tempqueuepaging">
-        <title>Temporary queue paging parameters</title>
-
-       <para>DefaultTempQueueFullSize, DefaultTempQueuePageSize, DefaultTempQueueDownCacheSize are optional attributes that determine the default paging parameters to be used for
-       any temporary destinations scoped to connections created using this connection factory. See the section on paging channels for more information
-       on what these values mean.
-       They will default to values of 200000, 2000 and 2000 respectively if ommitted.
-       </para>
-     </section>
-
-    <section id="conf.destination.connectionfactory.attributes.dupsokbatchsize">
-       <title>DupsOKBatchSize</title>
-
-      <para>When using a session with acknowledge mode of DUPS_OK_ACKNOWLEDGE this setting determines how many acknowledgments it will buffer locally
-      before sending. The default value is <literal>2000</literal>
-      </para>
-   </section>
-
-   <section id="conf.destination.connectionfactory.attributes.connector">
-          <title>Connector</title>
-
-         <para>This specifies which remoting connector this connection factory uses. Different connection factories can use different connectors.
-         </para>
-         <para>For instance you could deploy one connection factory that creates connections that use the HTTP transport to communicate to the server and another
-         that creates connections that use the bisocket transport to communicate.</para>
-   </section>
-
-   </section>
-
-</section>
-
-  <section id="conf.connector">
-      <title>Configuring the remoting connector</title>
-
-      <para>
-         JBoss Messaging uses JBoss Remoting  for all client to server communication.
-         For full details of what JBoss Remoting is capable of and how it is configured please
-         consult the JBoss Remoting documentation.
-      </para>
-
-      <para>
-         The default configuration includes a single remoting connector which is used by the
-         single default connection factory. Each connection factory can be configured to use
-         its own connector.
-      </para>
-
-      <para>
-         The default connector is configured to use the remoting bisocket transport. The bisocket transport is a TCP socket based transport
-         which only listens and accepts connections on the server side. I.e. connections are always initiated from the client side. This means
-         it works well in typical firewall scenarios where only inbound connections are allowed on the server. Or where onlu outbound connections are
-         allowed from the client.
-      </para>
-
-      <para>
-        The bisocket transport can be configured to use SSL where a higher level of security is required.
-        </para>
-
-      <para>
-        The other supported transport is the HTTP transport. This uses the HTTP protocol to communicate between client and server. Data is received on the client
-        by the client periodically polling the server for messages. This transport is well suited to situations where there is a firewall between client and server
-        which only allows incoming HTTP traffic on the server.
-        Please note this transport will not be as performant as the bisocket transport due to the nature of polling and the HTTP protocl. Also please note it is not
-        designed for high load situations.
-      </para>
-
-      <para>No other remoting transports are currently supported by JBoss Messaging</para>
-
-       <para>
-         You can look at remoting configuration under:
-       </para>
-
-       <para>
-          &lt;JBoss&gt;/server/&lt;YourMessagingServer&gt;/deploy/jboss-messaging.sar/remoting-service.xml
-       </para>
-
-       <para>
-          By default JBoss Messaging binds to ${jboss.bind.address} which can be defined by:
-          ./run.sh -c &lt;yourconfig&gt; -b yourIP.
-       </para>
-
-       <para>
-          You can change remoting-service.xml if you want for example use a
-          different communication port.
-       </para>
-
-       <warning>Please be wary of changing other settings as they can have an adverse effect on the system</warning>
-
-  </section>
-
-  <section id="conf.servicebindingmanager">
-     <title>ServiceBindingManager</title>
-
-     <para>If you are using the JBoss AS ServiceBindingManager to provide different servers with different port ranges, then you must make sure that the JBoss Messaging
-     remoting configuration specified in the JBoss Messaging section of the ServiceBindingManager xml file exactly matches that in remoting-service.xml
-    </para>
-  </section>
-
-  <section id="conf.callback">
-      <title>Configuring the callback</title>
-
-      <para>
-         JBoss Messaging uses a callback mechanism from Remoting that needs a Socket for callback operations. These socket properties are passed to the server by a remote call when the connection is being estabilished. As we said before we will support bidirectional protocols in future releases.
-      </para>
-
-      <para>
-         By default JBoss Messaging will execute InetAddress.getLocalHost().getHostAddress() to access your local host IP, but in case you need to setup a different IP, you can define a system property in your java arguments:
-      </para>
-
-      <para>
-      Use java -Djboss.messaging.callback.bind.address=YourHost - That will determine the callBack host in your client.
-      </para>
-
-      <para>
-      The client port will be selected randomly for any non used port. But if you defined -Djboss.messaging.callback.bind.port=NumericPort in your System Properties that number is going to be used for the call back client port.
-      </para>
-
-  </section>
-</chapter>

Deleted: trunk/docs/userguide/en/modules/UG12_gettingstarted.xml
===================================================================
--- trunk/docs/userguide/en/modules/UG12_gettingstarted.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/modules/UG12_gettingstarted.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,130 +0,0 @@
-<chapter id="UG2_gettingstarted">
-   <title>Download Software</title>
-
-   <para>
-      The official releases of JBoss Messaging are available as a free download from
-      <ulink url="http://www.jboss.com/products/messaging">the JBoss Messaging project landing page</ulink>.
-   </para>
-
-   <para>
-       The recommended download location is the JBoss Labs Messaging Project download zone:
-       <ulink url="http://labs.jboss.com/portal/jbossmessaging/downloads">http://labs.jboss.com/portal/jbossmessaging/downloads</ulink>
-       We also maintain an alternate download location on sourceforge.net:
-       <ulink url="http://sourceforge.net/project/showfiles.php?group_id=22866&amp;package_id=157261">http://sourceforge.net/project/showfiles.php?group_id=22866&amp;package_id=157261</ulink>
-   </para>
-
-   <section id="releasebundle">
-      <title>The JBoss Messaging Release Bundle</title>
-
-      <para>
-         The JBoss Messaging release bundle (<filename>jboss-messaging-1.2.x.zip</filename>)
-         will expand in a <filename>jboss-messaging-1.2.x</filename> directory that contains:
-      </para>
-
-      <itemizedlist>
-         <listitem>
-            <filename>jboss-messaging-scoped.sar</filename>
-            - the scoped JBoss service archive that contains JBoss Messaging and its
-            dependencies.
-            <warning>
-               Do not simply attempt to copy the archive under a JBoss instance <filename>deploy</filename> directory,
-               since additional steps (such as un-installing JBossMQ and various other configurations
-               tasks) are required for a successful installation. See <xref linkend="UG2_installation"/> for
-               more details.
-            </warning>
-         </listitem>
-         <listitem>
-            <filename>jboss-messaging-client.jar</filename>
-            - the client-side library that need to be in the classpath of the client that opens
-            a remote connection to the Messaging server.
-
-            <note>
-                <para>
-                This is an important note on the Messaging client jar. JBoss Messaging has an
-                extensive tree of dependencies and bundling all right dependencies in one easy
-                to use archive, so no wrong versions inadvertently get in the class path is, as
-                experience shows, extremely convenient. However, this could cause problems if a
-                different version of a dependency is required by the user's client code.
-                </para>
-                <para>
-                If, for example, the log4j.jar bundled with the release causes problems for being
-                too old, one could just simply build the client-side class path so a newer version
-                of log4j.jar precedes jboss-messaging-client.jar in that class path. This approach
-                may work, but is not guaranteed to work, because we did not run the full test suite
-                with any other log4j.jar version except the one we bundle with the release.
-
-                Soon we will providing an ant task that creates a slimmed down client jar without the extra
-                dependencies bundled.
-                </para>
-
-                <para>
-                 A list of required dependencies for a specific release can be found in the
-                 <filename>build-thirdpary.xml</filename> file that is part of the companion source
-                 bundle that ships with each release. It can also be looked up online in
-                  <ulink url="http://fisheye.jboss.org">http://fisheye.jboss.org</ulink>.
-                </para>
-            </note>
-         </listitem>
-         <listitem>
-            <filename>util</filename>
-            - a collection of <literal>ant</literal> configuration files used to automate
-            installation and release
-            management procedures. See <xref linkend="UG2_installation"/> for
-             more details.
-         </listitem>
-         <listitem>
-            <filename>examples</filename>
-            - a collection of examples that should run out of the box and help you validate the
-            installation. Detailed instructions are provided with each example, which range from
-            very simple JMS queue and topic examples to relatively sophisticated use cases in which
-            EJBs and JCA JMS ConnectionFactories are involved, as well as clustering use cases.
-            The <filename>examples/config</filename> sub-directory contains various configuration
-            file examples.
-         </listitem>
-         <listitem>
-           <filename>docs</filename>
-            - this user's guide.
-         </listitem>
-         <listitem>
-           <filename>src/jboss-messaging-1.2.x-src.zip</filename>
-            - the zipped source directory. The file can be directly installed into and used
-            with a debugger.
-         </listitem>
-         <listitem>
-            <filename>test-results</filename>
-            - the output of the functional testsuite, stress and smoke test runs for this release.
-            All these files have been generated during the release procedure and are bundled here
-            for reference.
-         </listitem>
-         <listitem>
-            <filename>api</filename>
-            - the Messaging API javadoc.
-         </listitem>
-         <listitem>
-            <filename>README.html</filename>
-            - The release intro document that contains pointers to various other resources,
-            including this Guide.
-         </listitem>
-      </itemizedlist>
-
-   </section>
-
-
-   <section id="SVN">
-      <title>SVN Access</title>
-
-      <para>
-         If you want to experiment with the latest developments you may checkout the latest code
-         from the Messaging SVN trunk. Be aware that the information provided in this manual might
-         then not be accurate.
-         For the latest instructions on how to check out and build source code, please go to
-         <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMessagingDevelopment">
-            Messaging Development wiki page</ulink>, specifically
-
-         <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMessagingBuildInstructions">
-          "Building and Running JBoss Messaging"</ulink> section.
-      </para>
-
-   </section>
-
-</chapter>
\ No newline at end of file

Deleted: trunk/docs/userguide/en/modules/UG12_installation.xml
===================================================================
--- trunk/docs/userguide/en/modules/UG12_installation.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/modules/UG12_installation.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,243 +0,0 @@
-<chapter id="UG2_installation">
-  <title>JBoss Messaging Non-Clustered Installation</title>
-
-   <para>
-      This section describes the procedure to perfom a non-clustered installation. At the
-      end of this procedure, you will create a JBoss Messaging configuration that will
-      start a non-clustered messaging server. To find out how you can install JBoss Messaging
-      in a clustered configuration, please proceed to <xref linkend="CLUST_installation"/>.
-   </para>
-
-   <para>
-      By default, a JBoss AS 4.0.x and 4.2.0 instance ships with JBossMQ as default JMS provider.
-      In order to use the JBoss AS instance with JBoss Messaging, you need to perform the
-      installation procedure described below.
-   </para>
-
-   <para>
-      <warning>
-         A JBossMQ and a JBoss Messaging instance cannot coexist, at least not unless special
-         precautions are taken. Do not simply attempt to copy the Messaging release artifact
-         <filename>jboss-messaging-scoped.sar</filename> over to the JBoss instance
-         <filename>deploy</filename> directory. Follow one of the alternate installation procedures
-         outlined below instead.
-      </warning>
-   </para>
-
-
-  <section id="install4">
-     <title>Installing JBoss Messaging with JBoss AS 4.0.x and 4.2.1</title>
-
-      <note>
-          You need Apache ant 1.7.0 or newer pre-installed on your system and available in
-          you path in order to be able to perform the installation process described below.
-      </note>
-
-    <section id="install4.automated">
-     <title>Installation procedure</title>
-
-      <para>
-         Set up the <literal>JBOSS_HOME</literal> environment variable to point to
-         the JBoss 4.x installation you want to use JBoss Messaging with. Run the installation
-         script, available in the  <filename>util</filename> directory of the release bundle.
-      </para>
-
-       <programlisting>
-cd util
-ant -f release-admin.xml
-       </programlisting>
-
-        <para>
-            The installation script will create a <filename>$JBOSS_HOME/server/messaging</filename>
-            configuration.
-        </para>
-
-       <note>
-          If you want to create a JBoss Messaging configuration with a different name, modify
-          the <literal>messaging.config.name</literal> system property declared at the beginning of
-           the installation script accordingly.
-       </note>
-    </section>
-
-  </section>
-
-  <section id="startingtheservice">
-     <title>Starting the Server</title>
-
-
-     <para>
-        To run the server, execute the <filename>run.bat</filename> or <filename>run.sh</filename>
-        script as appropriate for your operating system, in the <filename>$JBOSS_HOME/bin</filename>
-        directory.
-     </para>
-
-   <programlisting>
-cd $JBOSS_HOME/bin
-./run.sh -c messaging
-   </programlisting>
-
-     <para>
-        A successful JBoss Messaging deployment generates logging output similar to:
-     </para>
-
-   <programlisting>
-....
-01:44:48,317 WARN  [JDBCPersistenceManager]
-
-JBoss Messaging Warning: DataSource connection transaction isolation should be
-       READ_COMMITTED, but it is currently NONE.
-       Using an isolation level less strict than READ_COMMITTED may lead to data
-       consistency problems.
-       Using an isolation level more strict than READ_COMMITTED may lead to deadlock.
-
-01:44:50,450 INFO  [ServerPeer] JBoss Messaging 1.2.0.GA server [0] started
-01:44:51,311 INFO  [ConnectionFactory] Connector bisocket://192.168.1.104:4457 has
-leasing enabled, lease period 10000 milliseconds
-01:44:51,311 INFO  [ConnectionFactory] [/ConnectionFactory, /XAConnectionFactory,
-java:/ConnectionFactory, java:/XAConnectionFactory] started
-01:44:51,441 INFO  [ConnectionFactory] Connector bisocket://192.168.1.104:4457 has
-leasing enabled, lease period 10000 milliseconds
-01:44:51,441 INFO  [ConnectionFactory] [/NonClusteredConnectionFactory,
-/NonClusteredXAConnectionFactory, java:/NonClusteredConnectionFactory,
-java:/NonClusteredXAConnectionFactory] started
-01:44:51,681 INFO  [QueueService] Queue[/queue/DLQ] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,681 INFO  [QueueService] Queue[/queue/ExpiryQueue] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,732 INFO  [TopicService] Topic[/topic/testTopic] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,732 INFO  [TopicService] Topic[/topic/securedTopic] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,732 INFO  [TopicService] Topic[/topic/testDurableTopic] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,752 INFO  [QueueService] Queue[/queue/testQueue] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,752 INFO  [QueueService] Queue[/queue/A] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,762 INFO  [QueueService] Queue[/queue/B] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,762 INFO  [QueueService] Queue[/queue/C] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,882 INFO  [QueueService] Queue[/queue/D] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,882 INFO  [QueueService] Queue[/queue/ex] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,882 INFO  [QueueService] Queue[/queue/PrivateDLQ] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,892 INFO  [QueueService] Queue[/queue/PrivateExpiryQueue] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,892 INFO  [QueueService] Queue[/queue/QueueWithOwnDLQAndExpiryQueue] started,
-fullSize=200000, pageSize=2000, downCacheSize=2000
-01:44:51,892 INFO  [TopicService] Topic[/topic/TopicWithOwnDLQAndExpiryQueue] started,
-fullSize=200000, pageSize=2000, downCacheSize=2000
-01:44:51,942 INFO  [QueueService] Queue[/queue/QueueWithOwnRedeliveryDelay] started,
-fullSize=200000, pageSize=2000, downCacheSize=2000
-01:44:51,942 INFO  [TopicService] Topic[/topic/TopicWithOwnRedeliveryDelay] started,
-fullSize=200000, pageSize=2000, downCacheSize=2000
-01:44:51,952 INFO  [QueueService] Queue[/queue/testDistributedQueue] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:51,952 INFO  [TopicService] Topic[/topic/testDistributedTopic] started, fullSize=200000,
-pageSize=2000, downCacheSize=2000
-01:44:52,372 INFO  [ConnectionFactoryBindingService] Bound ConnectionManager
-'jboss.jca:name=JmsXA,service=ConnectionFactoryBinding' to JNDI name 'java:JmsXA'
-....
-   </programlisting>
-
-     <note>
-        The warning message <literal>DataSource connection transaction isolation should be READ_COMMITTED,
-        but it is currently NONE</literal>
-        is there to remind you that by default JBossAS ships with Hypersonic, an in-memory
-        Java-based database engine, which is apropriate for demo purposes, but not for heavy load
-        production environments. The
-        <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=ConfigJBossMQDB">Critique of Hypersonic</ulink>
-        wiki page outlines some of the well-known issues occuring when using this database.
-     </note>
-
-     <warning>
-        Before using Messaging in production, you <emphasis>must</emphasis> configure
-        the Messaging instance to use an enterprise-class database backend such as MySQL or Oracle,
-        otherwise you risk losing your data.
-        See <xref linkend="conf.changingds"/> for details about replacing Hypersonic.
-     </warning>
-  </section>
-
-
-  <section id="inst.validation">
-     <title>Installation Validation</title>
-
-     <para>
-        The release bundle contains a series of examples that should run "out of the box" and
-        could be used to validate a new installation. Such an example sends a persistent JMS message
-        to a queue called <literal>queue/testQueue</literal>.
-     </para>
-
-
-    <para>
-       To run the example and validate the installation,
-       open an new command line window and set the <literal>JBOSS_HOME</literal>
-       environment variable to point to the JBoss AS 4.x installation you've just installed
-       Messaging on. Navigate to the folder where
-       you extracted the release bundle and drill down to <filename>/examples/queue</filename>.
-       Apache Ant must pe present in your path in order to be able to run the example.
-    </para>
-
-   <programlisting>
-
-setenv JBOSS_HOME=&lt;your_JBoss_installation&gt;
-cd .../examples/queue
-$ant
-
-   </programlisting>
-
-     <para>
-        A successfull execution log output looks similar to:
-     </para>
-
-
-        <programlisting>
-$ ant
-Buildfile: build.xml
-
-identify:
-[echo] ###########################################################################
-[echo] #                       Running the QUEUE example                         #
-[echo] ###########################################################################
-[echo] The queue:      testQueue
-[echo] The client jar: ../../../output/lib/jboss-messaging-client.jar
-
-sanity-check:
-
-init:
-[mkdir] Created dir: c:\work\src\svn\messaging\docs\examples\queue\output
-[mkdir] Created dir: c:\work\src\svn\messaging\docs\examples\common\output
-
-compile:
-[javac] Compiling 5 source files to c:\work\src\svn\messaging\docs\examples\common\output
-[javac] Compiling 1 source file to c:\work\src\svn\messaging\docs\examples\queue\output
-
-run:
-   [java] Queue /queue/testQueue exists
-   [java] The message was successfully sent to the testQueue queue
-   [java] Received message: Hello!
-   [java] The example connected to JBoss Messaging version 1.2.0.GA (1.2)
-   [java]
-   [java] #####################
-   [java] ###    SUCCESS!   ###
-   [java] #####################
-
-BUILD SUCCESSFUL
-Total time: 9 seconds
-</programlisting>
-
-
-     <para>
-        It is recommended to run <literal>all</literal> validation examples available in the
-        <filename>example</filename> directory (<filename>queue</filename>,
-        <filename>topic</filename>, <filename>mdb</filename>, <filename>stateless</filename>, etc.).
-         In <xref linkend="UG2_examples"/>, we will have a look at each of those examples.
-     </para>
-
-
-  </section>
-
-</chapter>

Deleted: trunk/docs/userguide/en/modules/UG12_introduction.xml
===================================================================
--- trunk/docs/userguide/en/modules/UG12_introduction.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/modules/UG12_introduction.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,285 +0,0 @@
-<chapter id="UG2_introduction">
-
-   <title>Introduction</title>
-
-   <para>
-      JBoss Messaging provides an open source and standards-based messaging platform that brings
-      enterprise-class messaging to the mass market.
-   </para>
-
-   <para>
-      JBoss Messaging implements a high performance, robust messaging core that is designed to
-      support the largest and most heavily utilized SOAs, enterprise service buses (ESBs) and other
-      integration needs ranging from the simplest to the highest demand networks.
-      It will allow you to smoothly distribute your application load across your cluster,
-      intelligently balancing and utilizing each nodes CPU cycles, with no single point of failure,
-      providing a highly scalable and perform-ant clustering implementation. JBoss Messaging includes
-      a JMS front-end to deliver messaging in a standards-based format as well as being designed to be
-     able to support other messaging protocols in the future.
-   </para>
-
-   <para>
-      JBoss Messaging will soon become an integral component of the JBoss Enterprise Middleware
-      Suite (JEMS). Currently it
-      is available for embedded use within the JBoss Application Server (JBossAS), and as a
-      JBoss Microkernel-based stand-alone server. Work to integrate JBoss Messaging with the new
-      JBoss Microcontainer is under way.
-   </para>
-
-   <para>
-      The large and vibrant JEMS developer community fosters its continued innovation and
-      enterprise quality. JBoss Messaging enables more agile applications in a wide range of
-      scenarios from simple messaging needs to an enterprise-wide messaging foundation and adds
-      flexibility to any SOA initiative.
-   </para>
-
-   <section id="support">
-      <title>JBoss Messaging support cover from Red Hat</title>
-
-      <para>JBoss Messaging 1.2.GA support is available via the......</para>
-
-   </section>
-
-   <section id="features">
-      <title>JBoss Messaging 1.2.0.GA Features</title>
-
-      <para>
-         JBoss Messaging provides:
-      </para>
-
-      <itemizedlist>
-         <listitem>
-            <para>
-               A fully compatible and Sun certified JMS 1.1 implementation, that currently works
-               with a standard JBossAS 4.0.x, 4.2.x and JBoss 5.x installation and also as a JBoss
-               Microkernel-based standalone deployment.
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               A strong focus on performance, reliability and scalability with high throughput and
-               low latency. JBoss Messaging already exceeds JBoss MQ in a number of measured
-               performance metrics. Full results will follow.
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               A foundation for JBoss ESB for SOA initiatives; JBoss ESB uses
-               JBoss Messaging as its foundation.
-            </para>
-         </listitem>
-      </itemizedlist>
-
-      <para>
-         JBoss Messaging consists of two major parts:
-      </para>
-
-      <itemizedlist>
-         <listitem>
-            <para>
-               JBoss Messaging Core – a transactional, reliable messaging transport system.
-            </para>
-            <itemizedlist>
-               <listitem>
-                  <para>
-                     Supports generalized messages (not just JMS)
-                  </para>
-               </listitem>
-               <listitem>
-                  <para>
-                     Enables other messaging protocol façades to be added
-                  </para>
-               </listitem>
-               <listitem>
-                  <para>
-                     Distributed, transactional and reliable
-                  </para>
-               </listitem>
-            </itemizedlist>
-         </listitem>
-
-         <listitem>
-            <para>
-               JMS Façade – the JMS "personality" of JBoss Messaging.
-            </para>
-         </listitem>
-      </itemizedlist>
-
-      <para>
-         Other JBoss Messaging features include:
-      </para>
-
-      <itemizedlist>
-         <listitem>
-            <para>
-               Publish-subscribe and point-to-point messaging models
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               Topics that feed multiple message queues
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               Persistent and non-persistent messages
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               Guaranteed message delivery that ensures that messages arrive once and only once
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               Transactional and reliable  - supporting ACID semantics
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               Customizable security framework based on JAAS
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               Fully integrated with JBoss Transactions (formerly known as Arjuna JTA) for full transaction recoverability.
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               Extensive JMX management interface
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               Support for most major databases including Oracle, Sybase, MS SQL Server, PostgreSQL and MySQL
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               HTTP transport
-            </para>
-         </listitem>
-      </itemizedlist>
-
-      <para>
-         JBoss Messaging 1.2.0.GA Clustering provides the following features:
-      </para>
-
-      <itemizedlist>
-         <listitem>
-            <para>
-               Distributed queues. Messages sent to a distributed queue while attached to a
-               particular node will be routed to a queue instance on a particular node according
-               to a routing policy.
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               Distributed topics. Messages sent to a distributed topic while attached at a
-               particular node will be received by subscriptions on other nodes.
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-               Fully reliable message distribution. Once and only once delivery is fully guaranteed.
-               When sending messages to a topic with multiple durable subscriptions
-               across a cluster we guarantee that message reaches all the subscriptions
-               (or none of them in case of failure).
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-                  Pluggable routing implementation. The policy for routing messages to a queue is fully
-                     pluggable and easily replaceable. The default policy always chooses a queue at the local
-                     node if there is one, and if not, it round robins between queues on different nodes.
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-                  Intelligent message redistribution policy. Messages are automatically distributed between
-                     nodes depending on how fast or slow consumers are on certain nodes. If there are no or slow
-                     consumers on a particular queue node, messages will be pulled from that queue to a queue with
-                     faster consumers on a different node. The policy is fully pluggable.
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-                  Shared durable subscriptions. Consumers can connect to the same durable subscription while
-                     attached to different nodes. This allows processing load from durable subscriptions to be
-                     distributed across the cluster in a similar way to queues.
-            </para>
-         </listitem>
-         <listitem>
-            <para>
-                  High availability and seamless fail-over. If the node you are connected to fails, you
-                     will automatically fail over to another node and will not lose any persistent messages.
-                     You can carry on with your session seamlessly where you left off. Once and only once
-                     delivery of persistent messages is respected at all times.
-         </para>
-         </listitem>
-         <listitem>
-            <para>
-               Message bridge. JBoss Messaging 1.2 contains a message bridge component which enables you to bridge messages between any two JMS1.1 destinations
-               on the same or physical separate locations. (E.g. separated by a WAN)
-         </para>
-         </listitem>
-      </itemizedlist>
-
-
-   </section>
-
-
-   <section id="compatibility">
-      <title>Compatibility with JBossMQ</title>
-
-      <para>
-         JBossMQ is the JMS implementation currently shipped within JBossAS.
-         Since JBoss Messaging is JMS 1.1 and JMS 1.0.2b compatible, the JMS code  written against
-         JBossMQ will run with JBoss Messaging without any changes.
-      </para>
-
-      <important>
-         Even if JBoss Messaging deployment descriptors are very similar to JBoss MQ
-         deployment descriptors, they are <emphasis>not</emphasis> identical, so they will require
-         some simple adjustments to get them to work with JBoss Messaging. Also, the database
-         data model is completely different, so don't attempt to use JBoss Messaging with a JBossMQ
-         data schema and vice-versa.
-      </important>
-   </section>
-
-   <section id="missingfeatures">
-      <title>
-      Features not yet available in the 1.2.0.GA release, but coming soon
-      </title>
-
-      <para>
-    All the final features are available apart from:
-    </para>
-
-    <itemizedlist>
-
-        <listitem>
-           <para>
-              In a very near future, it will be possible to guarantee persistent level reliability
-               guarantee without persistence. By replicating persistent messages between nodes in
-               memory, we can obtain comparable reliability levels to persisting messages to disk,
-               without actually storing them to disk. However, this feature is not available
-               in the 1.2.0.GA release. If you're interested in how this feature will be available,
-               this is the JIRA issue you can use to track it:
-               <ulink url="http://jira.jboss.org/jira/browse/JBMESSAGING-574">http://jira.jboss.org/jira/browse/JBMESSAGING-574</ulink>
-           </para>
-        </listitem>
-
-        <listitem>
-            <para>
-                The "unreliable link scenario"
-                <ulink url="http://jira.jboss.org/jira/browse/JBMESSAGING-676">http://jira.jboss.org/jira/browse/JBMESSAGING-676</ulink>
-                whose development is still on-going on a parallel branch.
-            </para>
-        </listitem>
-
-    </itemizedlist>
-    </section>
-
-</chapter>

Deleted: trunk/docs/userguide/en/modules/UG12_performance.xml
===================================================================
--- trunk/docs/userguide/en/modules/UG12_performance.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/modules/UG12_performance.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,185 +0,0 @@
-<chapter id="UG2_performance">
-
-  <title>Generating Performance Benchmark Results</title>
-
-  <para>
-      As we discussed in <xref linkend="UG2_about"/>, the key advantage of JBoss Messaging is
-      its superior performance. In fact, the JBoss Messaging comes with a set of standard
-      performance test. You can run them on your server and generate your own performance
-      benchmark results. In this chapter, we will show you how to run a JBoss Messaging server
-      and a JBossMQ server side-by-side on a single machine, and compare their performance.
-      To get the performance tests, you have to obtain the JBoss Messaging source code from SVN
-      as described in <xref linkend="UG2_gettingstarted"/>.
-  </para>
-
-  <para>
-    To get the performance tests, you first need to check out the source code and build the project. The location of the framework's source code will be
-    referred to as $PERF_HOME throughout the rest of the document.
-  </para>
-
-  <programlisting>
-svn co https://svn.jboss.org/repos/messaging/projects/perf/trunk messaging-perf
-cd $PERF_HOME
-ant
-  </programlisting>
-
-  <para>The test consists in sending bursts of 1000 0 Kilobytes non-persistent messages to both JBoss Messaging and JBossMQ instances while gradually increasing the send rate (200 messages/sec, 400 messages/sec, etc) and measuring the receive rate. At the end, the framework generates the graph representing the receive rate as function of the send rate for two executions (JBoss Messaging and JBossMQ).</para>
-
-  <section>
-    <title>Run JBoss Messaging and JBossMQ Side-by-side</title>
-
-    <para>
-        To run performance tests side-by-side on the same machine, we assume that you create
-        two JBoss AS configurations with the JBoss Messaging and JBossMQ modules respectively.
-        We assume that the JBoss Messaging module is installed in the
-        <literal>server/messaging</literal> directory (see <xref linkend="UG2_installation"/>),
-        and the default JBossMQ module is installed in <literal>server/jbossmq</literal>
-        directory (just copy the original <literal>default</literal> directory that comes with
-        the server).</para>
-
-    <para>Now, if you run the two configurations on the same server, there will be port conflicts. To avoid that, we use the JBoss <literal>ServiceBindingManager</literal> to increase the port numbers in the <literal>jbossmq</literal> configuration by 100 (i.e., the JNDI service will be available at port 1199 instead of 1099). To do that, un-comment the following line in <literal>server/jbossmq/conf/jboss-service.xml</literal></para>
-
-    <programlisting>
-&lt;mbean code="org.jboss.services.binding.ServiceBindingManager"
-       name="jboss.system:service=ServiceBindingManager">
-
-  &lt;attribute name="ServerName">ports-01&lt;/attribute>WWWr
-  &lt;attribute name="StoreURL">
-    ../docs/examples/binding-manager/sample-bindings.xml
-  &lt;/attribute>
-  &lt;attribute name="StoreFactoryClassName">
-    org.jboss.services.binding.XMLServicesStoreFactory
-  &lt;/attribute>
-&lt;/mbean>
-    </programlisting>
-
-    <para>Now, you can start the <literal>messaging</literal> and <literal>jbossmq</literal> configurations side-by-side for testing.</para>
-
-    <programlisting>
-run -c messaging
-run -c jbossmq
-    </programlisting>
-
-  </section>
-sssssssssssd
-  <section>
-    <title>Setup the Tests</title>
-
-    <para>The performance framework relies on distributed executors to send messages into the providers being tested. The executors can run standalone in their own VM and act as "remote" JMS connections, or colocated, in which case they are deployed as JBoss services and simulate "colocated" JMS connections.</para>
-
-    <para>In order to correctly deploy the colocated executors, the framework relies on the <literal>JBOSS_HOME</literal> environment variable. It assumes directories <literal>$JBOSS_HOME/server/messaging</literal> and <literal>$JBOSS_HOME/server/jbossmq</literal> exist.</para>
-
-    <programlisting>
-ant sar
-ant start-executors
-    </programlisting>
-
-    <para>Next, we need to deploy test message destinations. They are in the <literal>messaging-destinations-service.xml</literal>, <literal>jbossmq-destinations-service.xml</literal> files. Feel free to add your own destinations (must add equivalent ones in both files) and then deploy them via the following command.</para>
-
-    <programlisting>
-ant deploy-destinations
-    </programlisting>
-
-  </section>
-
-  <section>
-    <title>Configure Test Runs</title>
-
-    <para>The <literal>etc/perf.xml</literal> file is used to configure tests. In our setting (i.e., <literal>jbossmq</literal> runs in +100 port range from default), the <literal>&lt;providers></literal> section should look like the following. We can easily run the two JMS server configurations on different machines or in other port ranges. You just need to change the host and port numbers here for tests.</para>
-
-    <programlisting>
-&lt;provider name="JBossMessaging">
-  &lt;factory>org.jnp.interfaces.NamingContextFactory&lt;/factory>
-  &lt;url>jnp://localhost:1099&lt;/url>
-  &lt;pkg>org.jboss.naming:org.jnp.interfaces&lt;/pkg>
-  &lt;executor name="REMOTE" url="rmi://localhost:7777/standalone"/>
-  &lt;executor name="REMOTE2" url="rmi://localhost:7777/standalone2"/>
-  &lt;executor name="COLOCATED" url="rmi://localhost:7777/local-messaging"/>
-  &lt;executor name="COLOCATED2" url="rmi://localhost:7777/local-messaging2"/>
-&lt;/provider>
-
-&lt;provider name="JBossMQ">
-  &lt;factory>org.jnp.interfaces.NamingContextFactory&lt;/factory>
-  &lt;url>jnp://localhost:1199&lt;/url>
-  &lt;pkg>org.jboss.naming:org.jnp.interfaces&lt;/pkg>
-  &lt;executor name="REMOTE" url="rmi://localhost:7777/standalone"/>
-  &lt;executor name="REMOTE2" url="rmi://localhost:7777/standalone2"/>
-  &lt;executor name="COLOCATED" url="rmi://localhost:7777/local-jbossmq"/>
-  &lt;executor name="COLOCATED2" url="rmi://localhost:7777/local-jbossmq2"/>
-&lt;/provider>
-    </programlisting>
-
-    <para>The performance configuration section configures how to ramp up the load from 200 messages / sec to 3000 message / sec. We will gather statistics on the number of processed messages versus the number of sent messages.</para>
-
-    <programlisting>
-&lt;performance-test name="Throughput O KB Message
-   Non-Persistent Non-Transactional, 1 sender, 1 receiver">
-
-  &lt;message-size>0&lt;/message-size>
-  &lt;messages>10000&lt;/messages>
-
-  &lt;drain/>
-
-  &lt;parallel>
-    &lt;send rate="200" executor="COLOCATED"/>
-    &lt;receive executor="COLOCATED2"/>
-  &lt;/parallel>
-
-  &lt;parallel>
-    &lt;send rate="400" executor="COLOCATED"/>
-    &lt;receive executor="COLOCATED2"/>
-  &lt;/parallel>
-
-  &lt;parallel>
-    &lt;send rate="800" executor="COLOCATED"/>
-    &lt;receive executor="COLOCATED2"/>
-  &lt;/parallel>
-
-  &lt;parallel>
-    &lt;send rate="1000" executor="COLOCATED"/>
-    &lt;receive executor="COLOCATED2"/>
-  &lt;/parallel>
-
-  &lt;parallel>
-    &lt;send rate="1500" executor="COLOCATED"/>
-    &lt;receive executor="COLOCATED2"/>
-  &lt;/parallel>
-
-  &lt;parallel>
-    &lt;send rate="2000" executor="COLOCATED"/>
-    &lt;receive executor="COLOCATED2"/>
-  &lt;/parallel>
-
-  &lt;parallel>
-    &lt;send rate="2500" executor="COLOCATED"/>
-    &lt;receive executor="COLOCATED2"/>
-  &lt;/parallel>
-
-  &lt;parallel>
-    &lt;send rate="3000" executor="COLOCATED"/>
-    &lt;receive executor="COLOCATED2"/>
-  &lt;/parallel>
-
-  &lt;execution provider="JBossMessaging"/>
-  &lt;execution provider="JBossMQ"/>
-
-&lt;/performance-test>
-    </programlisting>
-
-  </section>
-
-  <section>
-    <title>Run the Tests</title>
-
-    <para>To run the tests, simply execute <literal>ant run</literal> from the command line. You can access the benchmark result graphs from <literal>output/results/benchmark-results.html</literal>.</para>
-
-    <para>After running the test, you can clean up the executors and test destinations using the following commands.</para>
-
-    <programlisting>
-ant stop-executors
-ant undeploy-destinations
-    </programlisting>
-
-  </section>
-
-</chapter>
\ No newline at end of file

Deleted: trunk/docs/userguide/en/modules/UG12_runningexamples.xml
===================================================================
--- trunk/docs/userguide/en/modules/UG12_runningexamples.xml	2007-03-01 17:41:56 UTC (rev 2534)
+++ trunk/docs/userguide/en/modules/UG12_runningexamples.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -1,777 +0,0 @@
-<chapter id="UG2_examples">
-
-  <title>Running the Examples</title>
-
-  <para>
-      Since JBoss Messaging is a fully compliant JMS 1.1 provider, it supports the entire JMS 1.1 API. So, all
-      JMS applications should work without modification. Integrated inside a JBoss AS, we should
-      also be able access the JMS system from EJBs and write message-driven beans against JMS
-      destinations.
-  </para>
-
-
-  <para>
-      In the following sections, we will look at examples of the various JMS messaging models
-      and message-driven beans. They make use of pre-configured JMS destinations and connection
-      factories that come default with the server. So, no extra configuration is needed to run
-      those examples. Just set JBOSS_HOME and run <literal>ant</literal> in each example
-      directory, as we described in <xref linkend="inst.validation"/>. The example source
-      directories are located in the distribution under <literal>docs/examples</literal>.
-  </para>
-
-  <section id="examples.queue">
-    <title>Sending messages to a queue</title>
-
-    <para>
-    Open an new command line. Set the JBOSS_HOME environment variable to point at a JBossAS 4.x
-    installation. Navigate to the folder where you exploded the main archive and drill down to
-    <literal>/examples/queue</literal>. You need to use Apache <literal>ant</literal> to execute
-    the <literal>build.xml</literal> file.
-    </para>
-
-    <para>
-        Make sure the JBoss server reference by the JBOSS_HOME is started.
-   </para>
-
-    <programlisting>
-public class QueueExample extends ExampleSupport
-{
-
-   public void example() throws Exception
-   {
-      String destinationName = getDestinationJNDIName();
-
-      InitialContext ic = null;
-      ConnectionFactory cf = null;
-      Connection connection =  null;
-
-      try
-      {
-         ic = new InitialContext();
-
-         cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
-         Queue queue = (Queue)ic.lookup(destinationName);
-         log("Queue " + destinationName + " exists");
-
-         connection = cf.createConnection();
-         Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         MessageProducer sender = session.createProducer(queue);
-
-         TextMessage message = session.createTextMessage("Hello!");
-         sender.send(message);
-         log("The message was successfully sent to the " + queue.getQueueName() + " queue");
-
-         MessageConsumer consumer =  session.createConsumer(queue);
-
-         connection.start();
-
-         message = (TextMessage)consumer.receive(2000);
-         log("Received message: " + message.getText());
-         assertEquals("Hello!", message.getText());
-
-         displayProviderInfo(connection.getMetaData());
-
-      }
-      finally
-      {
-         if(ic != null)
-         {
-            try
-            {
-               ic.close();
-            }
-            catch(Exception e)
-            {
-               throw e;
-            }
-         }
-
-         // ALWAYS close your connection in a finally block to avoid leaks.
-         // Closing connection also takes care of closing its related objects e.g. sessions.
-         closeConnection(connection);
-      }
-   }
-
-   private void closeConnection(Connection con)
-   {
-      try
-      {
-         if (con != null)
-         {
-            con.close();
-         }
-      }
-      catch(JMSException jmse)
-      {
-         log("Could not close connection " + con +" exception was " + jmse);
-      }
-   }
-
-   protected boolean isQueueExample()
-   {
-      return true;
-   }
-
-   public static void main(String[] args)
-   {
-      new QueueExample().run();
-   }
-
-}
-    </programlisting>
-
-  </section>
-
-
-  <section id="examples.topic">
-    <title>Sending messages to a topic</title>
-    <para>In this example, a standalone Java client publishes a text-based JMS message to a topic and a single subscriber pulls the message off the queue.
-    </para>
-
-    <para>
-    Open an new command line. Set the JBOSS_HOME environment variable to point at a JBossAS 4.x installation. Navigate to the folder where you exploded the main archive and drill down to <literal>/examples/queue</literal>. You need to use Apache Ant to execute the build.xml file
-    Make sure the JBoss server reference by the JBOSS_HOME is started.
-   </para>
-
-   <programlisting>
-public class TopicExample extends ExampleSupport
-{
-   public void example() throws Exception
-   {
-      String destinationName = getDestinationJNDIName();
-
-      InitialContext ic = null;
-      Connection connection = null;
-
-      try
-      {
-         ic = new InitialContext();
-
-         ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
-         Topic topic = (Topic)ic.lookup(destinationName);
-         log("Topic " + destinationName + " exists");
-
-         connection = cf.createConnection();
-         Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         MessageProducer publisher = session.createProducer(topic);
-         MessageConsumer subscriber = session.createConsumer(topic);
-
-         ExampleListener messageListener = new ExampleListener();
-         subscriber.setMessageListener(messageListener);
-         connection.start();
-
-         TextMessage message = session.createTextMessage("Hello!");
-         publisher.send(message);
-         log("The message was successfully published on the topic");
-
-         messageListener.waitForMessage();
-
-         message = (TextMessage)messageListener.getMessage();
-         log("Received message: " + message.getText());
-         assertEquals("Hello!", message.getText());
-
-         displayProviderInfo(connection.getMetaData());
-
-      }
-      finally
-      {
-         if (ic != null)
-         {
-            try
-            {
-               ic.close();
-            }
-            catch(Exception e)
-            {
-               throw e;
-            }
-         }
-
-         // ALWAYS close your connection in a finally block to avoid leaks.
-         // Closing connection also takes care of closing its related objects e.g. sessions.
-         closeConnection(connection);
-      }
-   }
-
-   private void closeConnection(Connection con) throws JMSException
-   {
-
-      try
-      {
-         if (con != null)
-         {
-            con.close();
-         }
-      }
-      catch(JMSException jmse)
-      {
-         log("Could not close connection " + con +" exception was " + jmse);
-      }
-   }
-
-   protected boolean isQueueExample()
-   {
-      return false;
-   }
-
-   public static void main(String[] args)
-   {
-      new TopicExample().run();
-   }
-
-}
-   </programlisting>
-
-  </section>
-
-  <section id="examples.stateless">
-    <title>Using JMS from an EJB</title>
-    <para>This example deploys a simple Stateless Session Bean that is used as a proxy to send and receive JMS messages in a managed environment.
-    </para>
-
-      <warning>
-         Receiving a JMS message from inside an EJB (or MBean or servlet) method is considered an anti-pattern since it will require the creation
-         of a new JMS consumer on every send - even when using the JCA adaptor. This is likely to make it very slow. (Users of the Spring JMSTemplate be warned that this is what it uses
-         to implement it's receive.)
-         If you want to receive messages as part of a global transaction then use an MDB instead.
-      </warning>
-
-    <programlisting>
-public class StatelessSessionExampleBean implements SessionBean
-{
-
-   private ConnectionFactory cf = null;
-
-   public void drain(String queueName) throws Exception
-   {
-      InitialContext ic = new InitialContext();
-      Queue queue = (Queue)ic.lookup(queueName);
-      ic.close();
-
-      Session session = null;
-      Connection conn = null;
-
-      try
-      {
-         conn = getConnection();
-         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         MessageConsumer consumer = session.createConsumer(queue);
-         Message m = null;
-         do
-         {
-            m = consumer.receiveNoWait();
-         }
-         while(m != null);
-      }
-      finally
-      {
-         if (conn != null)
-         {
-            closeConnection(conn);
-         }
-      }
-   }
-
-   public void send(String txt, String queueName) throws Exception
-   {
-      InitialContext ic = new InitialContext();
-
-      Queue queue = (Queue)ic.lookup(queueName);
-
-      ic.close();
-
-      Session session = null;
-      Connection conn = null;
-
-      try
-      {
-         conn = getConnection();
-
-         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         MessageProducer producer = session.createProducer(queue);
-
-         TextMessage tm = session.createTextMessage(txt);
-
-         producer.send(tm);
-
-         System.out.println("message " + txt + " sent to " + queueName);
-      }
-      finally
-      {
-         if (conn != null)
-         {
-            closeConnection(conn);
-         }
-      }
-   }
-
-   public int browse(String queueName) throws Exception
-   {
-      InitialContext ic = new InitialContext();
-      Queue queue = (Queue)ic.lookup(queueName);
-      ic.close();
-
-      Session session = null;
-      Connection conn = null;
-
-      try
-      {
-         conn = getConnection();
-         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         QueueBrowser browser = session.createBrowser(queue);
-
-         ArrayList list = new ArrayList();
-         for(Enumeration e = browser.getEnumeration(); e.hasMoreElements(); )
-         {
-            list.add(e.nextElement());
-         }
-
-         return list.size();
-      }
-      finally
-      {
-         if (conn != null)
-         {
-            closeConnection(conn);
-         }
-      }
-   }
-
-   public String receive(String queueName) throws Exception
-   {
-      InitialContext ic = new InitialContext();
-      Queue queue = (Queue)ic.lookup(queueName);
-      ic.close();
-
-      Session session = null;
-      Connection conn = null;
-
-      // WARN! this is an anti-pattern - please see above warning
-
-      try
-      {
-         conn = getConnection();
-         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         MessageConsumer consumer = session.createConsumer(queue);
-
-         System.out.println("blocking to receive message from queue " + queueName + " ...");
-         TextMessage tm = (TextMessage)consumer.receive(5000);
-
-         if (tm == null)
-         {
-            throw new Exception("No message!");
-         }
-
-         System.out.println("Message " + tm.getText() + " received");
-
-         return tm.getText();
-      }
-      finally
-      {
-         if (conn != null)
-         {
-            closeConnection(conn);
-         }
-      }
-   }
-
-   public Connection getConnection() throws Exception
-   {
-
-      Connection connection = null;
-
-      try
-      {
-         connection = cf.createConnection();
-
-         connection.start();
-      }
-      catch(Exception e )
-      {
-         if(connection != null)
-         {
-            closeConnection(connection);
-         }
-         System.out.println("Failed to get connection...exception is " + e);
-         throw e;
-      }
-
-      return connection;
-   }
-
-   public void closeConnection(Connection con) throws Exception
-   {
-      try
-      {
-         con.close();
-      }
-      catch(JMSException jmse)
-      {
-         System.out.println("Could not close connection " + con +" exception was " + jmse);
-         throw jmse;
-      }
-   }
-
-   public void setSessionContext(SessionContext ctx) throws EJBException, RemoteException
-   {
-   }
-
-   public void ejbCreate()
-   {
-      try
-      {
-         InitialContext ic = new InitialContext();
-
-         cf = (ConnectionFactory)ic.lookup("java:/JmsXA");
-
-         ic.close();
-      }
-      catch(Exception e)
-      {
-         e.printStackTrace();
-         throw new EJBException("Initalization failure: " + e.getMessage());
-      }
-   }
-
-   public void ejbRemove() throws EJBException
-   {
-      try
-      {
-         if(cf != null)
-         {
-            cf = null;
-         }
-      }
-      catch(Exception e)
-      {
-         throw new EJBException("ejbRemove ", e);
-      }
-   }
-
-   public void ejbActivate() throws EJBException, RemoteException
-   {
-   }
-
-   public void ejbPassivate() throws EJBException, RemoteException
-   {
-   }
-
-}
-    </programlisting>
-
-  </section>
-
-  <section id="examples.mdb.ejb21">
-    <title>Using EJB2.1 Message Driven Beans</title>
-    <para>This example deploys a simple Message Driven Bean that processes messages sent to a test queue.  Once it receives a message and "processes" it, the MDB sends an acknowledgment message to a temporary destination created by the sender for this purpose. The example is considered successful if the sender receives the acknowledgment message.
-    </para>
-
-   <para>The MDB ejb-jar.xml descriptor
-    </para>
-    <programlisting>
-&lt;ejb-jar&gt;
-  &lt;enterprise-beans&gt;
-    &lt;message-driven&gt;
-      &lt;ejb-name&gt;MDBExample&lt;/ejb-name&gt;
-      &lt;ejb-class&gt;org.jboss.example.jms.mdb.MDBExample&lt;/ejb-class&gt;
-      &lt;transaction-type&gt;Container&lt;/transaction-type&gt;
-    &lt;/message-driven&gt;
-  &lt;/enterprise-beans&gt;
-&lt;/ejb-jar&gt;
-    </programlisting>
-
-   <para>The MDB jboss.xml descriptor
-   </para>
-    <programlisting>
-&lt;enterprise-beans&gt;
-  &lt;message-driven&gt;
-    &lt;ejb-name&gt;MDBExample&lt;/ejb-name&gt;
-    &lt;destination-jndi-name&gt;queue/@QUEUE_NAME@&lt;/destination-jndi-name&gt;
-  &lt;/message-driven&gt;
-&lt;/enterprise-beans&gt;
-    </programlisting>
-
-   <programlisting>
-public class MDBExample implements MessageDrivenBean, MessageListener
-{
-   private MessageDrivenContext ctx;
-
-   private ConnectionFactory cf = null;
-
-   public void onMessage(Message m)
-   {
-      Session session = null;
-      Connection conn = null;
-
-      try
-      {
-         TextMessage tm = (TextMessage)m;
-
-         String text = tm.getText();
-         System.out.println("message " + text + " received");
-         String result = process(text);
-         System.out.println("message processed, result: " + result);
-
-         conn = getConnection();
-         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         Destination replyTo = m.getJMSReplyTo();
-         MessageProducer producer = session.createProducer(replyTo);
-         TextMessage reply = session.createTextMessage(result);
-
-         producer.send(reply);
-         producer.close();
-
-      }
-      catch(Exception e)
-      {
-         ctx.setRollbackOnly();
-         e.printStackTrace();
-         System.out.println("The Message Driven Bean failed!");
-      }
-      finally
-      {
-         if (conn != null)
-         {
-            try
-            {
-               closeConnection(conn);
-            }
-            catch(Exception e)
-            {
-               System.out.println("Could not close the connection!" +e);
-            }
-         }
-      }
-   }
-
-   private String process(String s)
-   {
-      // flip the string
-
-      String result = "";
-
-      for (int i = 0; i &lt; text.length(); i++)
-      {
-         result = text.charAt(i) + result;
-      }
-      return result;
-   }
-
-   public Connection getConnection() throws Exception
-   {
-      Connection connection = null;
-
-      try
-      {
-         connection = cf.createConnection();
-         connection.start();
-      }
-      catch(Exception e )
-      {
-         if(connection != null)
-         {
-            closeConnection(connection);
-         }
-         System.out.println("Failed to get connection...exception is " + e);
-         throw e;
-      }
-
-      return connection;
-   }
-
-   public void closeConnection(Connection con) throws Exception
-   {
-      try
-      {
-         con.close();
-      }
-      catch(JMSException e)
-      {
-         System.out.println("Could not close connection " + con + " exception was " + e);
-      }
-   }
-
-   public void ejbCreate()
-   {
-      try
-      {
-         InitialContext ic = new InitialContext();
-
-         cf = (ConnectionFactory)ic.lookup("java:/JmsXA");
-
-         ic.close();
-      }
-      catch(Exception e)
-      {
-         e.printStackTrace();
-         throw new EJBException("Failure to get connection factory: " + e.getMessage());
-      }
-   }
-
-   public void ejbRemove() throws EJBException
-   {
-      try
-      {
-         if(cf != null)
-         {
-            cf = null;
-         }
-      }
-      catch(Exception e)
-      {
-         throw new EJBException("ejbRemove", e);
-      }
-   }
-
-   public void setMessageDrivenContext(MessageDrivenContext ctx)
-   {
-      this.ctx = ctx;
-   }
-
-
-}
-
-   </programlisting>
-
-
-  </section>
-
-
-   <section id="examples.mdb.ejb3">
-     <title>Using EJB3 Message Driven Beans</title>
-
-      <para>
-         This example deploys a simple EJB3 Message Driven Bean that processes messages sent to a
-         test queue.  Once it receives a message and "processes" it, the MDB sends an
-         acknowledgment message to a temporary destination created by the sender for this purpose.
-         The example is considered successful if the sender receives the acknowledgment message.
-      </para>
-
-      <para>
-         This example relies on having access to a running JBoss Messaging instance.
-         The JBoss Messaging instance must be installed and started according to the
-         "Installation" chapter of this document. The example will automatically deploy
-         its own queue, unless a queue with the same name is already deployed.
-      </para>
-
-      <para>
-         This example also relies on having access to the
-         <filename>jboss-messaging-client.jar</filename> archive that comes with the release bundle.
-         If you run this example from an unzipped installation bundle, the example run script
-         is correctly configured to find the client jar. Otherwise, you must modify example's
-         <filename>build.xml</filename> accordingly.
-      </para>
-
-      <para>
-         The example was designed to deploy its server-side artifacts under a JBoss'
-         <literal>messaging</literal> configuration. If you intend to use the script with
-         a JBoss configuration that is named differently, please modify the example's
-         <filename>build.xml</filename> accordingly.
-      </para>
-
-      <important>
-         The JBoss instance that runs the Messaging server must also have EJB3 support
-         previously installed. If the EJB3 support is not installed, the example will fail
-         with an error message similar to:
-
-         <programlisting>
-C:\work\src\cvs\jboss-head\jms\docs\examples\ejb3mdb\build.xml:60: EJB3 does not seem
-to be installed in C:\work\src\jboss-4.0.3-src\build\output\jboss-4.0.3/server/messaging!
-Install it and try again.
-         </programlisting>
-
-         <para>
-            For instructions on how to install EJB3 support,
-            please go to <ulink url="http://docs.jboss.org/ejb3">JBoss EJB3 documentation page</ulink>
-            or use the JBoss Installer.
-         </para>
-      </important>
-
-      <para>
-         The EJB3 Message Driven Bean source code:
-      </para>
-     <programlisting>
- at MessageDriven(activationConfig =
-{
-      @ActivationConfigProperty(propertyName="destinationType", propertyValue="javax.jms.Queue"),
-      @ActivationConfigProperty(propertyName="destination", propertyValue="queue/testQueue"),
-      @ActivationConfigProperty(propertyName="DLQMaxResent", propertyValue="10")
-})
-public class EJB3MDBExample implements MessageListener
-{
-   public void onMessage(Message m)
-   {
-      businessLogic(m);
-   }
-
-   private void businessLogic(Message m)
-   {
-      Connection conn = null;
-      Session session = null;
-
-      try
-      {
-         TextMessage tm = (TextMessage)m;
-
-         String text = tm.getText();
-         System.out.println("message " + text + " received");
-
-         // flip the string
-         String result = "";
-         for(int i = 0; i &lt; text.length(); i++)
-         {
-            result = text.charAt(i) + result;
-         }
-
-         System.out.println("message processed, result: " + result);
-
-
-         InitialContext ic = new InitialContext();
-         ConnectionFactory cf = (ConnectionFactory)ic.lookup("java:/JmsXA");
-         ic.close();
-
-         conn = cf.createConnection();
-         conn.start();
-         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         Destination replyTo = m.getJMSReplyTo();
-         MessageProducer producer = session.createProducer(replyTo);
-         TextMessage reply = session.createTextMessage(result);
-
-         producer.send(reply);
-         producer.close();
-
-      }
-      catch(Exception e)
-      {
-         e.printStackTrace();
-         System.out.println("The Message Driven Bean failed!");
-      }
-      finally
-      {
-         if (conn != null)
-         {
-            try
-            {
-               conn.close();
-            }
-            catch(Exception e)
-            {
-               System.out.println("Could not close the connection!" +e);
-            }
-         }
-      }
-   }
-}
-     </programlisting>
-
-     <para>The basic test examples in this chapter serve as the sanity check for your JBoss Messaging installation. They also provide basic programming examples. To develop your own JMS services, you probably need to configure JBoss Messaging to setup your own destinations and connection factories etc. In <xref linkend="configuration"/>, we will discuss JBoss Messaging configuration files and options.</para>
-
-   </section>
-
-
-
-</chapter>

Copied: trunk/docs/userguide/en/modules/about.xml (from rev 2534, trunk/docs/userguide/en/modules/UG12_about.xml)
===================================================================
--- trunk/docs/userguide/en/modules/about.xml	                        (rev 0)
+++ trunk/docs/userguide/en/modules/about.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -0,0 +1,72 @@
+<chapter id="about">
+
+   <title>Introducing JBoss Messaging Release 1.2.0.GA</title>
+
+   <para>
+       JBoss Messaging is a high performance JMS provider in the JBoss Enterprise Middleware Stack
+       (JEMS). It is a complete rewrite of JBossMQ, which is the current default JMS provider in
+       JBoss AS 4.0.x series and JBoss AS 4.2.0. JBoss Messaging will be the default JMS provider in
+       JBoss AS 4.2.x series, probably starting with 4.2.1, and it is already the default provider
+       in JBoss 5.0.0.Beta.
+   </para>
+
+   <para>JBoss Messaging it is also the backbone of the JBoss ESB infrastructure.</para>
+
+   <para>
+       Compared with JBossMQ, JBoss Messaging offers vastly improved performance in both single node
+       and clustered environments.
+       Please see
+       <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMessagingPerformanceResultsPre1_0">this wiki page</ulink>
+       for performance benchmarks and <xref linkend="performance"/> on how to generate your own
+       performance benchmarks. JBoss Messaging also features a much better modular architecture that
+       will allow us to add more features in the future.
+   </para>
+
+   <para>
+       While JBoss Messaging only becomes the default JMS provider from JBoss AS 4.2.1 and JBoss 5.0,
+       production users on JBoss AS 4.0.x can still take advantage of the performance improvements
+       by easily replacing the JBossMQ module with JBoss Messaging.
+   </para>
+
+   <para>
+       The procedure of swapping JMS providers is presented in detail in this manual.
+       In <xref linkend="installation"/> we discuss how to install and use JBoss Messaging in
+       JBoss 4.0.x production servers. We cover JBoss Messaging-specific configuration options,
+       as well as how to run the build-in sanity / performance tests.
+   </para>
+
+   <para>
+      This guide is work in progress, as new features will be added to the 1.2 baseline at a very
+      quick pace. Please send your suggestions or comments to the
+      <ulink url="http://www.jboss.org/index.html?module=bb&amp;op=viewforum&amp;f=238">JBoss Messaging user forum</ulink>.
+   </para>
+
+   <para>
+      <emphasis role="bold">Team:</emphasis>
+   </para>
+
+   <para>
+      Ovidiu Feodorov, Project Lead
+   </para>
+
+   <para>
+      Tim Fox, Technical Lead
+
+   </para>
+
+    <para>
+       Clebert Suconic, Core Messaging Developer
+    </para>
+
+   <para>
+      Other contributions by: Adrian Brock, Bela Ban, Alex Fu, Luc Texier, Aaron Walker,
+      Rajdeep Dua, Madhusudhan Konda, Juha Lindfors and Ron Sigal.
+   </para>
+
+   <para>
+       This manual was written with help from Luc Texier, Lead Support EMEA and
+       Sam Griffith Jr., JBoss Documentation Team.
+   </para>
+
+
+</chapter>

Copied: trunk/docs/userguide/en/modules/c_configuration.xml (from rev 2534, trunk/docs/userguide/en/modules/CLUST_configuration.xml)
===================================================================
--- trunk/docs/userguide/en/modules/c_configuration.xml	                        (rev 0)
+++ trunk/docs/userguide/en/modules/c_configuration.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -0,0 +1,115 @@
+<chapter id="c_configuration">
+
+   <title>JBoss Messaging Clustering Configuration</title>
+
+   <para>
+      In this chapter we will discuss how to configure JBoss Messaging clustering for different types of applications
+   </para>
+
+   <para>
+      Most of JBoss messaging clustering configuration revolves around the following variable:
+   </para>
+
+   <itemizedlist>
+
+      <listitem>Choosing the cluster router policy</listitem>
+
+      <listitem>Choosing the message redistributon policy</listitem>
+
+   </itemizedlist>
+
+   <section id="clusterrouter">
+
+      <title>Choosing the cluster router policy</title>
+
+      <para>
+
+      When a message is sent to a queue on particular node of the cluster, the system must decide whether the current node will handle it or whether it should send
+      it to another node to handle.
+      </para>
+
+      <para> The same applies if there are shared durable subscriptions on a topic and the message is being sent to a topic
+      </para>
+
+      <para>The correct decision to make depends on your application topology.</para>
+
+      <para>If your application consists of a set of servers with the same MDBs deployed on each server, and you have many well distributed producers sending
+      messages on all the nodes of the cluster, then the best policy is to always favour the local queue, since extra network trips are more expensive and the other
+      nodes are also havng local messages sent to them</para>
+
+      <para>However if your application consists of a set of homogenous MDBs but you have few or badly distributed producers, then always favouring the local producer
+      will mean the other nodes are being starved of messages and not using their CPUs cycles efficiently for messaging processing.</para>
+
+      <para>In this case, a good policy is to use a round robin routing policy where messages are round robin distributed to different nodes as they arrive.</para>
+
+      <para>In general, use the DefaultRoutingPolicy (this always favours the local queue) if you have many well distributed producers, and use the
+      RoundRobinRoutingPolicy if you have few or badly distributed producers.</para>
+
+      <para>This are specified in the clustered post office config, by specifying the following attribute</para>
+
+      <para>To favour the local queue:</para>
+
+      <programlisting>
+       &lt;attribute name="ClusterRouterFactory"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory&lt;/attribute&gt;
+      </programlisting>
+
+      <para>To round robin:</para>
+
+       <programlisting>
+         &lt;attribute name="ClusterRouterFactory"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.RoundRobinRouterFactory&lt;/attribute&gt;
+      </programlisting>
+
+   </section>
+
+
+   <section id="messagepull">
+
+      <title>Choosing the message pull policy</title>
+
+      <para>Once messages have arrived on queues in a cluster, in an ideal world they will all be consumed at the same rate, and there will be consumers on each node.
+      </para>
+
+      <para>However, in some application topologies, consumes may close on queues on a node, leaving messages otherwise stranded, or perhaps consumers
+      on some nodes are fast than consumers on other nodes causing messages to build up on one node or another and adversely effecting latency.
+      </para>
+
+      <para>JBoss Messaging allows messages to pulled from one node to another as load dictates in order to cope with such situations</para>
+
+      <para>Whether or not you should activate message pulling (message redistribution) depends on your application topology</para>
+
+      <para>For an application that consists of a set of servers with a heterogenous bank of MDBs (or other consumers) deployed on each node, consuming at
+      approximately the same rate, then message redistribution is not necessary.
+      </para>
+
+      <para>However, if your application consists of different numbers or rates of consumers on different nodes then message redistribution may help</para>
+
+      <warning>By its nature, message redistribution can result in messages being delivered in an order different to the strict ordering imposed by JMS. I.e.
+      messages can, sometimes be delivered in an order different to that which they were produced by their producer. If this ordering is important to you
+      then don't use message redistribution</warning>
+
+      <para>In general, use message redistribution when your consumers are not well distributed across the cluster or if they have greatly varying rates.</para>
+
+      <para>Message redistribution is set by setting the following attribute in the clustered post office configuration:
+      </para>
+
+      <para>
+      For no message redistribution:
+      </para>
+
+      <programlisting>
+           &lt;attribute name="MessagePullPolicy"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy&lt;/attribute&gt;
+      </programlisting>
+
+      <para>For message redistribution:</para>
+
+       <programlisting>
+           &lt;attribute name="MessagePullPolicy"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.DefaultMessagePullPolicy&lt;/attribute&gt;
+      </programlisting>
+
+      <para>When selecting message redistribution you should also choose a value of <literal>StatsSendPeriod</literal> appropriately.</para>
+
+   </section>
+
+
+
+</chapter>
\ No newline at end of file

Copied: trunk/docs/userguide/en/modules/c_installation.xml (from rev 2534, trunk/docs/userguide/en/modules/CLUST_installation.xml)
===================================================================
--- trunk/docs/userguide/en/modules/c_installation.xml	                        (rev 0)
+++ trunk/docs/userguide/en/modules/c_installation.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -0,0 +1,319 @@
+<chapter id="c_installation">
+
+   <title>JBoss Messaging Clustered Installation</title>
+
+    <note>
+        You need Apache ant 1.7.0 or newer pre-installed on your system and available in
+        you path in order to be able to perform the installation process described below.
+    </note>
+
+   <para>
+      Use the <filename>release-admin.xml</filename> ant script shipped with the release to
+      create individual cluster node configurations.
+   </para>
+
+   <para>
+      The typical usage is:
+   </para>
+
+   <programlisting>
+cd util
+ant -f release-admin.xml [-Did=node-id] [-Dports=port-config-label]
+[-Ddatabase=db-name] cluster-node
+   </programlisting>
+   <para>
+      where:
+      <itemizedlist>
+         <listitem>
+            <filename>node-id</filename> is the unique node ID, an integer that must be unique per
+            cluster. If not specified, it defaults to 0.
+         </listitem>
+         <listitem>
+            <filename>port-config-label</filename> is a binding manager server configuration label.
+
+            The short story behind this parameter is the following: multiple application servers
+            running on the same physical machine need to use different service port ranges to avoid
+            port conflicts. You can configure the whole port range used by a server instance
+            by enabling a special service, the binding management service, and specifiying a
+            "server" configuration in the binding manager's configuration file, which will determine
+            specific port values to use when starting that instance.
+
+            The Messaging installation script can enable the service binding manager and performs
+            all configuration changes automatically. You only need to specify the "server"
+            configuration you want to use, as 'port-config-label'.
+
+            If you plan to run your clustering nodes on different physical machines, this parameter
+            is irrelevant, and you should not use it. However, if you install two (or more) nodes of
+            your cluster on the same physical machine, you need to give the value corresponding to
+            a specific "server" configurations in the binding manager configuration file. JBoss AS
+            ships "out-of-the-box" with several pre-configured port ranges: 'ports-default',
+            'ports-01', 'ports-02', 'ports-03'. Use one of these.
+
+            If -Dports is not specified, the clustered instance created this way will fall over to
+            the default port range for a JBoss instace.
+
+            More details about the binding management service can be found in the Application Server
+            documentation, at the following address
+            <ulink url="http://docs.jboss.com/jbossas/guides/j2eeguide/r2/en/html_single/#ch10.bindingmanager">http://docs.jboss.com/jbossas/guides/j2eeguide/r2/en/html_single/#ch10.bindingmanager</ulink>
+         </listitem>
+         <listitem>
+            <filename>db-name</filename> is the name of the database you want to create the configurations for. Supported database names are: mysql, oracle,
+            postgresql, mssql, and sybase. Notice that if you create database configuration to any database other than MySQL, you will still need to
+            manually install the database JDBC drivers (MySQL drivers are provided as part of the distribution).
+         </listitem>
+      </itemizedlist>
+   </para>
+
+   <para>
+      Notice that you should have environment variable JBOSS_HOME correctly set to point to your JBoss AS distribution directory before executing any of the
+      scripts.
+   </para>
+
+   <para>
+      For example, in order to create the configuration for a four-node cluster intended to run
+      on the same physical machine, use the following sequence:
+   </para>
+
+   <programlisting>
+ant -f release-admin.xml cluster-node
+ant -f release-admin.xml -Did=1 -Dports=ports-01 cluster-node
+ant -f release-admin.xml -Did=2 -Dports=ports-02 cluster-node
+ant -f release-admin.xml -Did=3 -Dports=ports-03 cluster-node
+   </programlisting>
+
+   <para>
+      The sequence will create four cluster node configurations ("messaging-node0",
+      "messaging-node1", "messaging-node2" and "messaging-node3").
+   </para>
+
+   <para>
+      The first command will create a cluster node with ID equals to '0' and using the
+      default JBoss AS port assignments.
+   </para>
+
+   <para>
+      <warning>
+         The configuration that has just been created uses a generic mysql service descriptor.
+
+         Check <filename>$JBOSS_HOME/server/messaging-node&lt;id&gt;/deploy/mysql-ds.xml</filename>
+         and verify that that:
+         <itemizedlist>
+            <listitem>1. Your database is indeed mysql.</listitem>
+         <listitem>2. It is accessible from every physical node you installed Messaging on.</listitem>
+         <listitem>3. Contains a schema (database/tablespace) named 'messaging'.</listitem>
+         <listitem>4. The URL (hostname and port), username and password are correct.</listitem>
+         <listitem>5. The installed mysql-driver.jar's version maches your database.</listitem>
+           </itemizedlist>
+      </warning>
+      </para>
+
+
+   <para>
+      To start the cluster, from four different terminals, run:
+      </para>
+
+   <programlisting>
+cd $JBOSS_HOME/bin
+./run.sh -c messaging-node0
+
+cd $JBOSS_HOME/bin
+./run.sh -c messaging-node1
+
+cd $JBOSS_HOME/bin
+./run.sh -c messaging-node2
+
+cd $JBOSS_HOME/bin
+./run.sh -c messaging-node3
+    </programlisting>
+
+
+   <para>
+      A successful two node cluster startup produces a log similar to:
+   </para>
+
+
+   <para>
+      Node 0:
+   </para>
+
+
+   <programlisting>
+...
+
+00:24:04,796 WARN  [JDBCPersistenceManager]
+
+JBoss Messaging Warning:
+   DataSource connection transaction isolation should be READ_COMMITTED, but it
+   is currently REPEATABLE_READ.
+  Using an isolation level less strict than READ_COMMITTED may lead to data
+   consistency problems.
+  Using an isolation level more strict than READ_COMMITTED may lead to deadlock.
+
+00:24:05,718 INFO  [ServerPeer] JBoss Messaging 1.2.0.CR1 server [0] started
+00:24:06,328 INFO  [STDOUT]
+-------------------------------------------------------
+GMS: address is 127.0.0.1:2452
+-------------------------------------------------------
+00:24:08,406 INFO  [DefaultClusteredPostOffice] ClusteredPostOffice
+[0:Clustered JMS:127.0.0.1:2452] got new view [127.0.0.1:2452|0] [127.0.0.1:2452]
+00:24:08,468 INFO  [STDOUT]
+-------------------------------------------------------
+GMS: address is 127.0.0.1:2455
+-------------------------------------------------------
+00:24:10,906 INFO  [ConnectionFactory] Connector socket://10.11.14.105:4457 has leasing
+enabled, lease period 10000 milliseconds
+00:24:10,921 INFO  [ConnectionFactory] [/ConnectionFactory, /XAConnectionFactory,
+java:/ConnectionFactory, java:/XAConnectionFactory] started
+00:24:10,953 INFO  [QueueService] Queue[/queue/DLQ] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,953 INFO  [QueueService] Queue[/queue/ExpiryQueue] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,953 INFO  [TopicService] Topic[/topic/testTopic] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,953 INFO  [TopicService] Topic[/topic/securedTopic] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,968 INFO  [TopicService] Topic[/topic/testDurableTopic] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,968 INFO  [QueueService] Queue[/queue/testQueue] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,968 INFO  [QueueService] Queue[/queue/A] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,968 INFO  [QueueService] Queue[/queue/B] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,968 INFO  [QueueService] Queue[/queue/C] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,968 INFO  [QueueService] Queue[/queue/D] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,968 INFO  [QueueService] Queue[/queue/ex] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,984 INFO  [QueueService] Queue[/queue/PrivateDLQ] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:10,984 INFO  [QueueService] Queue[/queue/PrivateExpiryQueue] started,
+fullSize=75000, pageSize=2000, downCacheSize=2000
+00:24:10,984 INFO  [QueueService] Queue[/queue/QueueWithOwnDLQAndExpiryQueue] started,
+fullSize=75000, pageSize=2000, downCacheSize=2000
+00:24:10,984 INFO  [TopicService] Topic[/topic/TopicWithOwnDLQAndExpiryQueue] started,
+fullSize=75000, pageSize=2000, downCacheSize=2000
+00:24:10,984 INFO  [QueueService] Queue[/queue/QueueWithOwnRedeliveryDelay] started,
+fullSize=75000, pageSize=2000, downCacheSize=2000
+00:24:10,984 INFO  [TopicService] Topic[/topic/TopicWithOwnRedeliveryDelay] started,
+fullSize=75000, pageSize=2000, downCacheSize=2000
+00:24:11,000 INFO  [QueueService] Queue[/queue/testDistributedQueue] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:11,000 INFO  [TopicService] Topic[/topic/testDistributedTopic] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:24:11,093 INFO  [ConnectionFactoryBindingService] Bound
+ConnectionManager'jboss.jca:name=JmsXA,service=ConnectionFactoryBinding' to JNDI
+name 'java:JmsXA'
+00:24:11,375 INFO  [TomcatDeployer] deploy, ctxPath=/jmx-console,
+warUrl=.../deploy/jmx-console.war/
+00:24:12,171 INFO  [Http11BaseProtocol] Starting Coyote HTTP/1.1 on http-0.0.0.0-8080
+00:24:12,421 INFO  [ChannelSocket] JK: ajp13 listening on /0.0.0.0:8009
+00:24:12,453 INFO  [JkMain] Jk running ID=0 time=0/47  config=null
+00:24:12,515 INFO  [Server] JBoss (MX MicroKernel) [4.0.5.GA (build: CVSTag=Branch_4_0
+date=200611221632)]
+Started in 30s:375ms
+
+00:27:21,343 INFO  [DefaultClusteredPostOffice] ClusteredPostOffice
+[0:Clustered JMS:127.0.0.1:2452] got new view [127.0.0.1:2452|1]
+[127.0.0.1:2452, 127.0.0.1:2474]
+
+</programlisting>
+
+   <para>
+      Node 1:
+   </para>
+
+   <programlisting>
+
+...
+
+00:33:54,468 WARN  [JDBCPersistenceManager]
+
+JBoss Messaging Warning:
+DataSource connection transaction isolation should be READ_COMMITTED, but it is
+currently REPEATABLE_READ.
+Using an isolation level less strict than READ_COMMITTED may lead to data consistency
+problems.
+Using an isolation level more strict than READ_COMMITTED may lead to deadlock.
+
+00:33:55,062 INFO  [ServerPeer] JBoss Messaging 1.2.0.CR1 server [1] started
+00:33:55,609 INFO  [STDOUT]
+-------------------------------------------------------
+GMS: address is 127.0.0.1:2514
+-------------------------------------------------------
+00:33:57,734 INFO  [DefaultClusteredPostOffice]
+ClusteredPostOffice[1:Clustered JMS:127.0.0.1:2514] got new
+view [127.0.0.1:2452|3] [127.0.0.1:2452, 127.0.0.1:2514]
+00:33:57,765 INFO  [STDOUT]
+-------------------------------------------------------
+GMS: address is 127.0.0.1:2519
+-------------------------------------------------------
+00:34:00,203 INFO  [ConnectionFactory] Connector socket://10.11.14.105:4557 has leasing
+enabled, lease period 20000 milliseconds
+00:34:00,203 INFO  [ConnectionFactory] [/ConnectionFactory, /XAConnectionFactory,
+java:/ConnectionFactory, java:/XAConnectionFactory] started
+00:34:00,234 INFO  [QueueService] Queue[/queue/DLQ] started, fullSize=75000, pageSize=2000,
+downCacheSize=2000
+00:34:00,234 INFO  [QueueService] Queue[/queue/ExpiryQueue] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,234 INFO  [TopicService] Topic[/topic/testTopic] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,250 INFO  [TopicService] Topic[/topic/securedTopic] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,250 INFO  [TopicService] Topic[/topic/testDurableTopic] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,250 INFO  [QueueService] Queue[/queue/testQueue] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,250 INFO  [QueueService] Queue[/queue/A] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,250 INFO  [QueueService] Queue[/queue/B] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,250 INFO  [QueueService] Queue[/queue/C] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,250 INFO  [QueueService] Queue[/queue/D] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,250 INFO  [QueueService] Queue[/queue/ex] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,265 INFO  [QueueService] Queue[/queue/PrivateDLQ] started, fullSize=75000,
+pageSize=2000, downCacheSize=2000
+00:34:00,265 INFO  [QueueService] Queue[/queue/PrivateExpiryQueue] started,
+fullSize=75000, pageSize=2000, downCacheSize=2000
+00:34:00,265 INFO  [QueueService] Queue[/queue/QueueWithOwnDLQAndExpiryQueue]
+started, fullSize=75000, pageSize=2000, downCacheSize=2000
+00:34:00,265 INFO  [TopicService] Topic[/topic/TopicWithOwnDLQAndExpiryQueue]
+started, fullSize=75000, pageSize=2000, downCacheSize=2000
+00:34:00,265 INFO  [QueueService] Queue[/queue/QueueWithOwnRedeliveryDelay]
+started, fullSize=75000, pageSize=2000, downCacheSize=2000
+00:34:00,265 INFO  [TopicService] Topic[/topic/TopicWithOwnRedeliveryDelay]
+started, fullSize=75000, pageSize=2000, downCacheSize=2000
+00:34:00,296 INFO  [QueueService] Queue[/queue/testDistributedQueue]
+started, fullSize=75000, pageSize=2000, downCacheSize=2000
+00:34:00,296 INFO  [TopicService] Topic[/topic/testDistributedTopic]
+started, fullSize=75000, pageSize=2000, downCacheSize=2000
+00:34:00,343 INFO  [ConnectionFactoryBindingService] Bound
+ConnectionManager 'jboss.jca:name=JmsXA,
+service=ConnectionFactoryBinding' to JNDI name 'java:JmsXA'
+00:34:00,453 INFO  [TomcatDeployer] deploy, ctxPath=/jmx-console,
+warUrl=.../deploy/jmx-console.war/
+00:34:00,796 INFO  [Http11BaseProtocol] Starting Coyote HTTP/1.1 on http-0.0.0.0-8180
+00:34:01,078 INFO  [ChannelSocket] JK: ajp13 listening on /0.0.0.0:8109
+00:34:01,125 INFO  [JkMain] Jk running ID=0 time=0/125  config=null
+00:34:01,125 INFO  [Server] JBoss (MX MicroKernel)
+[4.0.5.GA (build: CVSTag=Branch_4_0 date=200611221632)] Started in 22s:547ms
+
+
+   </programlisting>
+
+
+   <note>
+      The installation script may fail while installing Messaging with source-generated
+      JBoss 4.0.5.GA-ejb3 instance. This is because release-admin.xml relies on finding
+      <filename>$JBOSS_HOME/docs/examples/binding-manager/sample-bindings.xml</filename>.
+      4.0.5.GA-ejb3 installations seem not to have a "docs" sub-directory. A very simple work-around
+      for this situation is to recursively copy the "docs" sub-directory available under a regular
+      (non-EJB3) source-generated 4.0.5.GA instance and retry the installation process.
+   </note>
+
+
+</chapter>

Copied: trunk/docs/userguide/en/modules/c_overview.xml (from rev 2534, trunk/docs/userguide/en/modules/CLUST_overview.xml)
===================================================================
--- trunk/docs/userguide/en/modules/c_overview.xml	                        (rev 0)
+++ trunk/docs/userguide/en/modules/c_overview.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -0,0 +1,146 @@
+<chapter id="c_overview">
+
+
+   <title>JBoss Messaging Clustering</title>
+
+    <para>
+      This section of the userguide gives a brief overview of the features available in
+        JBoss Messaging Clustering 1.2.0.GA. It gives a high level explanation of how
+        clustering works.
+     </para>
+
+   <section id="clustering_overview">
+      <title>JBoss Messaging Clustering Overview</title>
+
+      <para>
+      Here's a brief overview of how clustering works in JBoss Messaging 1.2.
+      </para>
+
+
+      <para>
+      Clustered destinations (queues and topics) can be deployed at all or none of the nodes of
+      the cluster.
+      A JMS client uses HA JNDI to lookup the connection factory. A client side load balancing
+      policy will automatically chose a node to connect to (This is similar to
+      how EJB clustering chooses a node).
+      </para>
+
+      <para>
+      The JMS client has now made a connection to a node where it can create sessions, message
+      producers and message consumers and browsers and send or consume messages,
+      using the standard JMS api.
+      When a distributed queue is deployed across the cluster, individual partial queues are
+      deployed on each node.
+      </para>
+
+      <para>
+      When a message is sent from a message producer attached to a particular node to a
+      distributed queue, a routing policy determines which partial queue will receive
+      the message.
+      By default the router will always pass the message to a local queue, if there is one,
+      this is so we avoid unnecessary network traffic.
+      If there is no local queue then a partial queue on a different node will be chosen by the
+      router, by default this will be round robin between remote partial queues.
+      </para>
+
+      <para>
+      When a message is sent to a distributed topic while attached to a node, there may be
+      multiple subscriptions on different nodes that need to receive the
+      message. Depending on the number and location of subscriptions, the message may be multicast
+      or unicast across the cluster so the other nodes can pick it up.
+      (All group communication, unicast, multicast and group management is handled by JGroups.)
+      </para>
+
+      <para>
+      In the case of shared durable subscriptions, if a durable subscription with the same name
+      exists on more than node, then only one of the instances needs to receive the message.
+      Which one is determined by the same routing policy used to route messages to partial queues.
+      All of this is accomplished without losing the reliability guarantees required by JMS.
+      </para>
+
+      <para>
+      Subscriptions (both durable and non durable) can be created on all nodes and will receive messages sent via any node.
+      What happens if the consumers on one queue/subscription are faster/slower than consumers on another?
+      Normally this would result in messages building up on that queue and fast consumers being starved of work on another, thus wasting CPU cycles on the node that
+      could be put to good use.
+      The most degenerate example is of a queue containing many messages then the consumers being closed on that queue.
+      The messages might potentially remain stranded on the queue until another consumer attaches.
+      A routing policy is no use here, since the messages have already been routed to the queuee and the consumers closed / slowed down
+      after they were routed there.
+      JBoss Messaging can deal with this problem by intelligently pulling messages from other less
+      busy nodes, if it detects idle consumers on the fast node and slow consumers
+      on another node.
+      </para>
+
+      <para>
+      Normally, persistent messages are persisted in a shared database which is shared by all nodes
+      in the cluster.
+
+      JBoss Messaging 1.2.1 will contain
+      an option where you can choose to not persist persistent messages in a database, but instead to replicate them between nodes of the cluster.
+
+      The idea here is the network IO on a fast network should be much faster than persisting to disk.
+      This solution should also be more scalable since different nodes replicate their messages onto
+      different other nodes - there is no "master node".
+
+      If the messages are replicated onto sufficient nodes and the hardware is set-up with UPS, then we believe a comparable reliability guarantee to persisting messages to disk
+      can be achieved. Of course, this won't be suitable for all situations, but you use the best tool for the job.
+      </para>
+
+   </section>
+
+
+    <section id="clustering_architectural_overview">
+        <title>Clustering Architectural Overview</title>
+
+        <para>
+           One of the fundamental Messaging Core building blocks is the "Post Office". A JBoss Messaging
+           Post Office is message routing component, which accepts messages for delivery and synchronously
+           forwards them to their destination queues or topic subscriptions.
+        </para>
+
+        <para>
+           There is a single Post Office instance per JBoss Messaging server (cluster node). Both queues
+           and topics deployed on a JBoss Messaging node are "plugged" into that Post Office instance.
+           Internally JBoss Messaging only deals  with the concepts of queues, and considers a topic to
+           just be a set of queues (one for each subscription). Depending on the type of subscription -
+           durable or non-durable - the corresponding queue saves messages to persistent storage or
+           it just holds messages in memory and discards them when the non-durable subscription is closed.
+        </para>
+
+        <para>
+           Therefore, for a JMS queue, the Post Office routes messages to one and only one core queue,
+           depending on the queue name, whereas for a JMS topic, the Post Office routes a message
+           to a set of core queues, one for each topic subscription, depending on the topic name.
+        </para>
+
+        <para>
+           Clustering across multiple address spaces is achieved by clustering Post Office instances. Each
+           JBoss Messaging cluster node runs a Clustered Post Office instance, which is aware of the presence
+           of all other clustered Post Offices in the cluster. There is an one-to-one relationship between cluster
+           nodes and clustered Post Office instances. So, naturally, the most important piece of clustering
+           configuration is the <emphasis>clustered Post Office service configuration</emphasis>,
+           covered in detail below.
+        </para>
+
+        <para>
+           Clustered Post Office instances connect to each other via JGroups and they heavily rely on JGroups
+           group management and notification mechanisms. <emphasis>JGroups stack configuration</emphasis>
+           is an essential part of JBoss Messaging clustering configuration. JGroups configuration is only
+           briefly addressed in this guide. Detailed information on JGroups can be found in JGroups
+           release documentation or on-line at <ulink url="http://www.jgroups.org">http://www.jgroups.org</ulink>
+           or <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups">http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups</ulink>
+        </para>
+
+        <para>
+           When routing messages, a clustered Post Office  has a choice of forwarding the message to local
+           queues or remote queues, plugged into remote Post Office instances that are part of the same
+           cluster. Local queues are usually preferred, but if a local queue is part of a distributed queue, has
+           no consumers, and other local queues part of the same distributed queue have consumers, messages
+           can be automatically redistributed, subject of the message redistribution policy in effect. This allows
+           us to create distributed queues and distributed topics.  <emphasis>Message redistribution
+           configuration</emphasis> is another subject that we will insist on.
+        </para>
+
+    </section>
+</chapter>

Copied: trunk/docs/userguide/en/modules/configuration.xml (from rev 2534, trunk/docs/userguide/en/modules/UG12_configuration.xml)
===================================================================
--- trunk/docs/userguide/en/modules/configuration.xml	                        (rev 0)
+++ trunk/docs/userguide/en/modules/configuration.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -0,0 +1,2285 @@
+<chapter id="configuration">
+  <title>Configuration</title>
+
+  <para>
+      The JMS API specifies how a messaging client interacts with a messaging server. The exact
+      definition and implementation of messaging services, such as message destinations and
+      connection factories, are specific to JMS providers. JBoss Messaging has its own
+      configuration files to configure services. If you are migrating services from JBossMQ
+      (or other JMS provider) to JBoss Messaging, you will need to understand those
+      configuration files.
+  </para>
+
+  <para>
+      In this chapter, we discuss how to configure various services inside JBoss Messaging,
+      which work together to provide JMS API level services to client applications.
+  </para>
+
+   <para>
+      Starting with the JBoss Messaging 1.0.1 release, the service configuration is spread among
+      several configuration files (the 1.0.0 release used to have all configuration information
+      lumped together in the SAR's deployment descriptor
+      <filename>jboss-messaging.sar/META-INF/jboss-service.xml</filename>).
+      Depending on the functionality provided by the services it configures, the configuration
+      data is distributed between
+      <filename>messaging-service.xml</filename>,
+      <filename>remoting-service.xml</filename>,
+      <filename>xxx-persistence-service.xml</filename>
+       (or <filename>clustered-xxx-persistence-service.xml</filename> for a clustered configuration,
+       more about clusterered configuration in <xref linkend="c_configuration"/>),
+      <filename>connection-factories-service.xml</filename> and
+      <filename>destinations-service.xml</filename>.
+   </para>
+
+   <para>
+      The AOP client-side and server-side interceptor stacks are configured in
+      <filename>aop-messaging-client.xml</filename> and <filename>aop-messaging-server.xml</filename>.
+      Normally you will not want to change them, but you can some of the interceptors can be removed
+      to give a small performance increase, if you don't need them. Be very careful you have considered the security implications before removing the
+      security interceptor.
+   </para>
+
+  <section id="conf.serverpeer">
+    <title>Configuring the ServerPeer</title>
+
+    <para>
+       The Server Peer is the "heart" of the JBoss Messaging JMS facade. The server's configuration,
+       resides in <filename>messaging-service.xml</filename> configuration file.
+    </para>
+
+    <para>All JBoss Messaging services are rooted at the server peer</para>
+
+     <para>An example of a Server Peer configuration is presented below. Note that not all values for the server peer's attributes are
+     specified in the example</para>
+
+     <programlisting>
+ &lt;mbean code="org.jboss.jms.server.ServerPeer"
+        name="jboss.messaging:service=ServerPeer"
+        xmbean-dd="xmdesc/ServerPeer-xmbean.xml"&gt;
+
+   &lt;constructor&gt;
+     &lt;!-- ServerPeerID --&gt;
+     &lt;arg type="int" value="0"/&gt;
+     &lt;!-- DefaultQueueJNDIContext --&gt;
+     &lt;arg type="java.lang.String" value="/queue"/&gt;
+     &lt;!-- DefaultTopicJNDIContext --&gt;
+     &lt;arg type="java.lang.String" value="/topic"/&gt;
+   &lt;/constructor&gt;
+
+   &lt;attribute name="PostOffice"&gt;jboss.messaging:service=PostOffice&lt;/attribute&gt;
+   &lt;attribute name="SecurityDomain"&gt;java:/jaas/messaging&lt;/attribute&gt;
+   &lt;attribute name="DefaultSecurityConfig"&gt;
+      &lt;security&gt;
+        &lt;role name="guest" read="true" write="true" create="true"/&gt;
+      &lt;/security&gt;
+   &lt;/attribute&gt;
+   &lt;attribute name="DefaultDLQ"&gt;
+       jboss.messaging.destination:service=Queue,name=DLQ&lt;/attribute&gt;
+   &lt;attribute name="DefaultMaxDeliveryAttempts"&gt;10&lt;/attribute&gt;
+   &lt;attribute name="DefaultExpiryQueue"&gt;
+       jboss.messaging.destination:service=Queue,name=ExpiryQueue&lt;/attribute&gt;
+   &lt;attribute name="DefaultRedeliveryDelay"&gt;0&lt;/attribute&gt;
+   &lt;attribute name="QueueStatsSamplePeriod"&gt;5000&lt;/attribute&gt;
+   &lt;attribute name="FailoverStartTimeout"&gt;60000&lt;/attribute&gt;
+   &lt;attribute name="FailoverCompleteTimeout"&gt;300000&lt;/attribute&gt;
+   &lt;attribute name="DefaultMessageCounterHistoryDayLimit"&gt;-1&lt;/attribute&gt;
+
+   &lt;depends optional-attribute-name="PersistenceManager"&gt;
+       jboss.messaging:service=PersistenceManager&lt;/depends&gt;
+   &lt;depends optional-attribute-name="JMSUserManager"&gt;
+       jboss.messaging:service=JMSUserManager&lt;/depends&gt;
+   &lt;depends&gt;jboss.messaging:service=Connector,transport=bisocket&lt;/depends&gt;
+
+ &lt;/mbean&gt;
+     </programlisting>
+
+     <section id="conf.serverpeer.attributes">
+
+       <title>
+             We now discuss the MBean attributes of the ServerPeer MBean
+        </title>
+
+       <section id="conf.serverpeer.attributes.persistencemanager">
+           <title>PersistenceManager</title>
+
+           <para>
+              This is the persistence manager that the ServerPeer uses. You will not normally need to change this attribute.
+           </para>
+        </section>
+
+       <section id="conf.serverpeer.attributes.postoffice">
+           <title>PostOffice</title>
+
+           <para>
+              This is the post office that the ServerPeer uses. You will not normally need to change this attribute.
+              The post office is responsible for routing messages to queues and maintaining the mapping between addresses and queues.
+           </para>
+        </section>
+
+       <section id="conf.serverpeer.attributes.jmsusermanager">
+           <title>JMSUserManager</title>
+
+           <para>
+              This is the JMS user manager that the ServerPeer uses. You will not normally need to change this attribute.
+           </para>
+        </section>
+
+       <section id="conf.serverpeer.attributes.defaultdlq">
+           <title>DefaultDLQ</title>
+
+           <para>
+              This is the name of the default DLQ (Dead Letter Queue) the server peer will use for destinations. The DLQ can be overridden on a per
+              destination basis - see the destination MBean configuration for more details.
+
+              A DLQ is a special destination where messages are sent when the server has attempted to deliver them unsuccessfully more than a certain number of
+              times.
+
+              If the DLQ is not specified at all then the message will be removed after the maximum number of delivery attempts.
+
+              The maximum number of delivery attempts can be specified using the attribute DefaultMaxDeliveryAttempts for a global default or individually
+              on a per destination basis.
+
+           </para>
+        </section>
+
+       <section id="conf.serverpeer.attributes.defaultexpiryqueue">
+           <title>DefaultExpiryQueue</title>
+
+           <para>
+              This is the name of the default expiry queue the server peer will use for destinations. The expiry can be overridden on a per
+              destination basis - see the destination MBean configuration for more details.
+
+              An expiry queue is a special destination where messages are sent when they have expired. Message expiry is determined by the value of
+              Message::getJMSExpiration()
+
+              If the expiry queue is not specified at all then the message will be removed after it is expired.
+
+           </para>
+        </section>
+
+
+        <section id="conf.serverpeer.attributes.serverpeerid">
+           <title>ServerPeerID</title>
+
+           <para>
+              The unique id of the server. In a cluster each server MUST have a unique id.
+           </para>
+        </section>
+
+        <section id="conf.serverpeer.attributes.defaultqueuejndicontext">
+           <title>DefaultQueueJNDIContext</title>
+
+           <para>
+              The default JNDI context to use when binding queues. Defaults to /queue.
+           </para>
+        </section>
+
+        <section id="conf.serverpeer.attributes.defaultopicjndicontext">
+           <title>DefaultTopicJNDIContext</title>
+
+           <para>
+              The default JNDI context to use when binding topics. Defaults to /topic.
+           </para>
+        </section>
+
+        <section id="conf.serverpeer.attributes.destinations">
+           <title>Destinations</title>
+
+           <para>
+              Returns a list of the destinations (queues and topics) currently deployed.
+           </para>
+        </section>
+
+        <section id="conf.serverpeer.attributes.defaultmaxdeliveryattempts">
+           <title>DefaultMaxDeliveryAttempts</title>
+
+           <para>
+              The default for the maximum number of times delivery of a message will be attempted before sending the message to the DLQ, if configured.
+           </para>
+           <para>
+              The default value is <literal>10</literal >
+           </para>
+           <para>This value can also be overridden on a per destination basis</para>
+        </section>
+
+        <section id="conf.serverpeer.attributes.failoverstarttimeout">
+           <title>FailoverStartTimeout</title>
+
+           <para>
+              The maximum number of milliseconds the client will wait for failover to start on the server side when a problem is detected.
+           </para>
+           <para>
+              The default value is <literal>60000</literal> (one minute)
+           </para>
+
+        </section>
+
+        <section id="conf.serverpeer.attributes.failovercompletetimeout">
+           <title>FailoverCompleteTimeout</title>
+
+           <para>
+              The maximum number of milliseconds the client will wait for failover to complete on the server side after it has started.
+           </para>
+           <para>
+              The default value is <literal>300000</literal> (five minutes)
+           </para>
+        </section>
+
+        <section id="conf.serverpeer.attributes.defaultredliverydelay">
+           <title>DefaultRedeliveryDelay</title>
+
+           <para>
+              When redelivering a message after failure of previous delivery it is often beneficial to introduce a delay perform redelivery in order
+              to prevent thrashing of delivery-failure, delivery-failure etc
+           </para>
+           <para>
+              The default value is <literal>0</literal> which means there will be no delay.
+           </para>
+           <para>Change this if your application could benefit with a delay before redelivery. This value can also be overridden on a per destination basis</para>
+        </section>
+
+        <section id="conf.serverpeer.attributes.queuestatssampleperiod">
+           <title>QueueStatsSamplePeriod</title>
+
+           <para>
+              Periodically the server will query each queue to gets its message statistics. This is the period.
+           </para>
+           <para>
+              The default value is <literal>10000</literal> milliseconds
+           </para>
+        </section>
+
+
+        <section id="conf.serverpeer.attributes.defaultmessagecounterhistorydaylimit">
+              <title>DefaultMessageCounterHistoryDayLimit</title>
+
+              <para>
+                 JBoss Messaging provides a message counter history which shows the number of messages arriving on each queue of a certain number of
+                 days. This attribute represents the maxiumum number of days for which to store message counter history. It can be overridden on a per
+                 destination basis
+           </para>
+        </section>
+
+        <section id="conf.serverpeer.attributes.messagecounters">
+              <title>MessageCounters</title>
+
+              <para>
+                 JBoss Messaging provides a message counter for each queue.
+           </para>
+        </section>
+
+        <section id="conf.serverpeer.attributes.messagecounterstatistics">
+              <title>MessageCountersStatistics</title>
+
+              <para>
+                 JBoss Messaging provides statistics for each message counter for each queue.
+           </para>
+        </section>
+
+        <section id="conf.serverpeer.attributes.defaultsecurity">
+           <title>DefaultSecurityConfig</title>
+
+           <para>
+              Default security configuration is used when the security configuration for a specific
+              queue or topic has not been overridden in the destination's deployment descriptor.
+              It has exactly the same syntax and semantics as in JBossMQ.
+           </para>
+
+           <para>
+              The <literal>DefaultSecurityConfig</literal> attribute element should contain
+              one <literal>&lt;security&gt;</literal> element.
+              The <literal>&lt;security&gt;</literal> element can contain multiple
+              <literal>&lt;role&gt;</literal> elements. Each <literal>&lt;role&gt;</literal>
+              element defines the default access for that particular role.
+           </para>
+
+           <para>
+              If the <literal>read</literal> attribute is <literal>true</literal> then that role
+              will be able to read (create consumers, receive messaages or browse) destinations
+              by default.
+           </para>
+
+           <para>
+              If the <literal>write</literal> attribute is <literal>true</literal> then that role
+              will be able to write (create producers or send messages) to destinations by default.
+           </para>
+
+           <para>
+              If the <literal>create</literal> attribute is <literal>true</literal> then that role
+              will be able to create durable subscriptions on topics by default.
+           </para>
+        </section>
+     </section>
+
+
+     <section id="conf.serverpeer.operations">
+
+        <title>
+             We now discuss the MBean operations of the ServerPeer MBean
+        </title>
+
+        <section id="conf.serverpeer.operations.deployQueue">
+           <title>DeployQueue</title>
+
+           <para>
+              This operation lets you programmatically deploy a queue.
+           </para>
+
+           <para>There are two overloaded versions of this operation</para>
+
+           <para>If the queue already exists but is undeployed it is deployed. Otherwise it is created and deployed</para>
+
+           <para>The <literal>name</literal> parameter represents the name of the destination to deploy.</para>
+           <para>The <literal>jndiName</literal> parameter (optional) represents the full jndi name where to bind the destination. If this is not specified
+           then the destination will be bound in &lt;DefaultQueueJNDIContext&gt;/&lt;name&gt;</para>
+
+           <para>The first version of this operation deploys the destination with the default paging parameters. The second overloaded version deploys
+           the destination with the specified paging parameters. See the section on configuring destinations for a discussion of what the
+           paging parameters mean</para>
+
+        </section>
+
+       <section id="conf.serverpeer.operations.undeployQueue">
+           <title>UndeployQueue</title>
+
+           <para>
+              This operation lets you programmatically undeploy a queue.
+           </para>
+
+           <para>The queue is undeployed but is NOT removed from persistent storage.</para>
+
+           <para>This operation returns <literal>true</literal> if the queue was successfull undeployed. otherwise it returns <literal>false</literal></para>
+
+        </section>
+
+       <section id="conf.serverpeer.operations.destroyQueue">
+           <title>DestroyQueue</title>
+
+           <para>
+              This operation lets you programmatically destroy a queue.
+           </para>
+
+           <para>The queue is undeployed and then all its data is destroyed from the database</para>
+
+           <warning>Be careful when using this method since it will delete all data for the queue</warning>
+
+           <para>This operation returns <literal>true</literal> if the queue was successfully destroyed. otherwise it returns <literal>false</literal></para>
+
+        </section>
+
+        <section id="conf.serverpeer.operations.deployTopic">
+           <title>DeployTopic</title>
+
+           <para>
+              This operation lets you programmatically deploy a topic.
+           </para>
+
+           <para>There are two overloaded versions of this operation</para>
+
+           <para>If the topic already exists but is undeployed it is deployed. Otherwise it is created and deployed</para>
+
+           <para>The <literal>name</literal> parameter represents the name of the destination to deploy.</para>
+           <para>The <literal>jndiName</literal> parameter (optional) represents the full jndi name where to bind the destination. If this is not specified
+           then the destination will be bound in &lt;DefaultTopicJNDIContext&gt;/&lt;name&gt;</para>
+
+           <para>The first version of this operation deploys the destination with the default paging parameters. The second overloaded version deploys
+           the destination with the specified paging parameters. See the section on configuring destinations for a discussion of what the
+           paging parameters mean</para>
+
+        </section>
+
+       <section id="conf.serverpeer.operations.undeployTopic">
+           <title>UndeployTopic</title>
+
+           <para>
+              This operation lets you programmatically undeploy a topic.
+           </para>
+
+           <para>The queue is undeployed but is NOT removed from persistent storage.</para>
+
+           <para>This operation returns <literal>true</literal> if the topic was successfully undeployed. otherwise it returns <literal>false</literal></para>
+
+        </section>
+
+       <section id="conf.serverpeer.operations.destroyTopic">
+           <title>DestroyTopic</title>
+
+           <para>
+              This operation lets you programmatically destroy a topic.
+           </para>
+
+           <para>The topic is undeployed and then all its data is destroyed from the database</para>
+
+           <warning>Be careful when using this method since it will delete all data for the topic</warning>
+
+           <para>This operation returns <literal>true</literal> if the topic was successfully destroyed. otherwise it returns <literal>false</literal></para>
+
+        </section>
+
+       <section id="conf.serverpeer.operations.listmessagecountersashtml">
+           <title>ListMessageCountersHTML</title>
+
+           <para>
+              This operation returns message counters in an easy to display HTML format.
+           </para>
+        </section>
+
+       <section id="conf.serverpeer.operations.resetallmessagecounters">
+           <title>ResetAllMesageCounters</title>
+
+           <para>
+              This operation resets all message counters to zero.
+           </para>
+        </section>
+
+
+       <section id="conf.serverpeer.operations.resetallmessagecounterhistories">
+           <title>ResetAllMesageCounters</title>
+
+           <para>
+              This operation resets all message counter histories to zero.
+           </para>
+        </section>
+
+       <section id="conf.serverpeer.operations.enablemessagecounters">
+           <title>EnableMessageCounters</title>
+
+           <para>
+              This operation enables all message counters for all destinations. Message counters are disabled by default.
+           </para>
+        </section>
+
+       <section id="conf.serverpeer.operations.disablemessagecounters">
+           <title>DisableMessageCounters</title>
+
+           <para>
+              This operation disables all message counters for all destinations. Message counters are disabled by default.
+           </para>
+        </section>
+
+       <section id="conf.serverpeer.operations.retrievepreparedtransactions">
+           <title>RetrievePreparedTransactions</title>
+
+           <para>
+              Retrieves a list of the Xids for all transactions currently in a prepared state on the node.
+           </para>
+      </section>
+
+       <section id="conf.serverpeer.operations.showpreparedtransactions">
+           <title>ShowPreparedTransactions</title>
+
+           <para>
+              Retrieves a list of the Xids for all transactions currently in a prepared state on the node in an easy to display HTML format.
+           </para>
+      </section>
+
+
+     </section>
+
+  </section>
+
+     <section id="conf.changingds">
+        <title>Changing the Database</title>
+
+        <para>
+               Several JBoss Messaging services interact with persistent storage. They include: The Persistence Manager,
+               The PostOffice and the JMS User Manager.
+               The Persistence Manager is used to handle the message-related persistence.
+               The Post Office handles binding related persistence.
+               The JMS User manager handles user related persistence
+               The configuration for all these MBeans is handled in the <filename>xxx-persistence-service.xml</filename> file
+        </para>
+
+        <para>
+           If the database you want to switch to is one of MySQL, Oracle, PostgreSQL, MS SQL Sever or Sybase,
+           persistence configuration files are already available in
+           the <filename>examples/config</filename> directory of the release bundle.
+        </para>
+
+        <para>
+           In order to enable support for one of these databases, just replace the default
+           <filename>hsqldb-persistence-service.xml</filename> configuration file with the
+           database-specific configuration file and restart the server.
+        </para>
+
+        <para>
+           Also, be aware that by default, the Messaging services relying on a datastore
+           are referencing <literal>"java:/DefaultDS"</literal> for the datasource.
+           If you are deploying a datasource with a different JNDI name, you need to update
+           all the <literal>DataSource</literal> attribute in the persistence configuration file.
+
+           Example data source configurations for each of the popular databases are available in the distribution.
+        </para>
+
+     </section>
+
+
+  <section id="conf.postoffice">
+    <title>Configuring the Post office</title>
+
+    <para>It is the job of the post office to route messages to their destination(s).
+    </para>
+
+    <para>The post office maintains the mappings between addresses to which messages can be sent and their final queues.</para>
+
+    <para>For example when sending a message with an address that represents a JMS queue name, the post office will route this to a single
+    queue - the JMS queue. When sending a message with an address that repesents a JMS topic name, the post office will route this to a set of
+    queues - one for each JMS subscription.</para>
+
+    <para>The post office also handles the persistence for the mapping of addresses</para>
+
+    <para>JBoss Messaging comes with two different post office implementations - depending on whether you want clustering or not. The clustered post office
+    has the ability to route messages to other nodes in the cluster</para>
+
+    <para>Whether you use the clustered post office or not depends on whether you deploy the <literal>clustered-xxx-persistence-service.xml</literal> MBean config
+    or just the non clustered <literal>xxx-persistence-service.xml</literal> file.</para>
+
+    <para>It is likely that in future releases of JBoss Messaging the clustered and non clustered post offices will be combined into a single post office for
+    ease of configuration</para>
+
+    <section id="conf.postoffice.nonclustered">
+       <title>Non clustered post office</title>
+
+       <para>The non clustered post office should be used where clustering is not required. It will be used when the
+       non clustered <literal>xxx-persistence-service.xml</literal> file is deployed.</para>
+
+       <para>Here is an example of a non clustered post office configuration:</para>
+
+       <programlisting>
+
+&lt;mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
+      name="jboss.messaging:service=PostOffice"
+      xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
+      &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
+      &lt;attribute name="PostOfficeName"&gt;JMS&lt;/attribute&gt;
+      &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
+      &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
+      &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
+CREATE_POSTOFFICE_TABLE=CREATE TABLE JBM_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, CLUSTERED CHAR(1))
+INSERT_BINDING=INSERT INTO JBM_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED) VALUES (?, ?, ?, ?, ?, ?, ?)
+DELETE_BINDING=DELETE FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
+LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
+      ]]&gt;&lt;/attribute&gt;
+   &lt;/mbean&gt;
+
+       </programlisting>
+
+       <section id="conf.postoffice.nonclustered.attributes">
+
+       <title>The non clustered post office has the following attributes</title>
+
+          <section id="conf.postoffice.nonclustered.attributes.datasource">
+             <title>DataSource</title>
+             <para>The datasource the postoffice should use for persisting its mapping data</para>
+          </section>
+
+          <section id="conf.postoffice.nonclustered.attributes.sqlproperties">
+              <title>SQLProperties</title>
+              <para>
+                            This is where the DDL and DML for the particular database is specified.
+                            If a particular DDL or DML statement is not overridden, the default Hypersonic
+                            configuration will be used for that statement.
+           </para>
+          </section>
+
+          <section id="conf.postoffice.nonclustered.attributes.createtables">
+               <title>CreateTablesOnStartup</title>
+
+               <para>
+                  Set this to <literal>true</literal> if you wish the post office to attempt
+                  to create the tables (and indexes) when it starts. If the tables (or indexes)
+                  already exist a <literal>SQLException</literal> will be thrown by the JDBC driver and
+                  ignored by the Persistence Manager, allowing it to continue.
+               </para>
+               <para>
+                  By default the value of <literal>CreateTablesOnStartup</literal> attribute
+                  is set to <literal>true</literal>
+               </para>
+         </section>
+
+          <section id="conf.postoffice.nonclustered.attributes.postofficename">
+               <title>PostOfficeName</title>
+
+               <para>
+                  The name of the post office
+               </para>
+         </section>
+      </section>
+   </section>
+
+
+   <section id="conf.postoffice.clustered">
+       <title>Clustered post office</title>
+
+       <para>The clustered post office should be used where clustering is required. It will be used when the
+       clustered <literal>clustered-xxx-persistence-service.xml</literal> file is deployed.</para>
+
+       <para>Here is an example of a clustered post office configuration:</para>
+
+       <programlisting>
+
+&lt;mbean code="org.jboss.messaging.core.plugin.ClusteredPostOfficeService"
+      name="jboss.messaging:service=PostOffice"
+      xmbean-dd="xmdesc/ClusteredPostOffice-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
+      &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
+      &lt;attribute name="PostOfficeName"&gt;Clustered JMS&lt;/attribute&gt;
+      &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
+      &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
+      &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
+CREATE_POSTOFFICE_TABLE=CREATE TABLE JBM_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, CLUSTERED CHAR(1))
+INSERT_BINDING=INSERT INTO JBM_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED) VALUES (?, ?, ?, ?, ?, ?, ?)
+DELETE_BINDING=DELETE FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
+LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
+      ]]&gt;&lt;/attribute&gt;
+      &lt;attribute name="GroupName"&gt;DefaultPostOffice&lt;/attribute&gt;
+      &lt;attribute name="StateTimeout"&gt;5000&lt;/attribute&gt;
+      &lt;attribute name="CastTimeout"&gt;5000&lt;/attribute&gt;
+      &lt;attribute name="StatsSendPeriod"&gt;10000&lt;/attribute&gt;
+      &lt;attribute name="MessagePullPolicy"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy&lt;/attribute&gt;
+      &lt;attribute name="ClusterRouterFactory"&gt;org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory&lt;/attribute&gt;
+
+
+      &lt;attribute name="ChannelFactoryName"&gt;jgroups.mux:name=Multiplexer&lt;/attribute&gt;
+      &lt;attribute name="SyncChannelName"&gt;udp-sync&lt;/attribute&gt;
+      &lt;attribute name="AsyncChannelName"&gt;udp&lt;/attribute&gt;
+      &lt;attribute name="ChannelPartitionName"&gt;${jboss.partition.name:DefaultPartition}-JMS&lt;/attribute&gt;
+
+      &lt;attribute name="AsyncChannelConfig"&gt;
+         &lt;config&gt;
+            &lt;UDP mcast_recv_buf_size="500000" down_thread="false" ip_mcast="true" mcast_send_buf_size="32000"
+           mcast_port="45567" ucast_recv_buf_size="500000" use_incoming_packet_handler="false"
+           mcast_addr="228.8.8.8" use_outgoing_packet_handler="true" loopback="true" ucast_send_buf_size="32000" ip_ttl="32" bind_addr="127.0.0.1"/&gt;
+            &lt;AUTOCONF down_thread="false" up_thread="false"/&gt;
+            &lt;PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/&gt;
+            &lt;MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/&gt;
+            &lt;FD_SOCK down_thread="false" up_thread="false"/&gt;
+            &lt;FD timeout="20000" max_tries="3" down_thread="false" up_thread="false" shun="true"/&gt;
+            &lt;VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/&gt;
+            &lt;pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
+                         retransmit_timeout="100,200,600,1200,2400,4800"/&gt;
+            &lt;UNICAST timeout="1200,2400,3600" down_thread="false" up_thread="false"/&gt;
+            &lt;pbcast.STABLE stability_delay="1000" desired_avg_gossip="20000" down_thread="false" max_bytes="0" up_thread="false"/&gt;
+            &lt;FRAG frag_size="8192" down_thread="false" up_thread="false"/&gt;
+            &lt;VIEW_SYNC avg_send_interval="60000" down_thread="false" up_thread="false" /&gt;
+            &lt;pbcast.GMS print_local_addr="true" join_timeout="3000" down_thread="false" join_retry_timeout="2000" up_thread="false" shun="true"/&gt;
+         &lt;/config&gt;
+      &lt;/attribute&gt;
+
+      &lt;attribute name="SyncChannelConfig"&gt;
+         &lt;config&gt;
+            &lt;UDP mcast_recv_buf_size="500000" down_thread="false" ip_mcast="true" mcast_send_buf_size="32000"
+           mcast_port="45568" ucast_recv_buf_size="500000" use_incoming_packet_handler="false"
+           mcast_addr="228.8.8.8" use_outgoing_packet_handler="true" loopback="true" ucast_send_buf_size="32000" ip_ttl="32" bind_addr="127.0.0.1"/&gt;
+            &lt;AUTOCONF down_thread="false" up_thread="false"/&gt;
+            &lt;PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/&gt;
+            &lt;MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/&gt;
+            &lt;FD_SOCK down_thread="false" up_thread="false"/&gt;
+            &lt;FD timeout="20000" max_tries="3" down_thread="false" up_thread="false" shun="true"/&gt;
+            &lt;VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/&gt;
+            &lt;pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
+                         retransmit_timeout="100,200,600,1200,2400,4800"/&gt;
+            &lt;UNICAST timeout="1200,2400,3600" down_thread="false" up_thread="false"/&gt;
+            &lt;pbcast.STABLE stability_delay="1000" desired_avg_gossip="20000" down_thread="false" max_bytes="0" up_thread="false"/&gt;
+            &lt;FRAG frag_size="8192" down_thread="false" up_thread="false"/&gt;
+            &lt;VIEW_SYNC avg_send_interval="60000" down_thread="false" up_thread="false" /&gt;
+            &lt;pbcast.GMS print_local_addr="true" join_timeout="3000" down_thread="false" join_retry_timeout="2000" up_thread="false" shun="true"/&gt;
+            &lt;pbcast.STATE_TRANSFER down_thread="false" up_thread="false"/&gt;
+         &lt;/config&gt;
+      &lt;/attribute&gt;
+   &lt;/mbean&gt;
+
+       </programlisting>
+
+       <section id="conf.postoffice.clustered.attributes">
+
+       <title>The nclustered post office has the following attributes</title>
+
+          <section id="conf.postoffice.clustered.attributes.datasource">
+             <title>DataSource</title>
+             <para>The datasource the postoffice should use for persisting its mapping data</para>
+          </section>
+
+          <section id="conf.postoffice.clustered.attributes.sqlproperties">
+              <title>SQLProperties</title>
+              <para>
+                            This is where the DDL and DML for the particular database is specified.
+                            If a particular DDL or DML statement is not overridden, the default Hypersonic
+                            configuration will be used for that statement.
+           </para>
+          </section>
+
+          <section id="conf.postoffice.clustered.attributes.createtables">
+               <title>CreateTablesOnStartup</title>
+
+               <para>
+                  Set this to <literal>true</literal> if you wish the post office to attempt
+                  to create the tables (and indexes) when it starts. If the tables (or indexes)
+                  already exist a <literal>SQLException</literal> will be thrown by the JDBC driver and
+                  ignored by the Persistence Manager, allowing it to continue.
+               </para>
+               <para>
+                  By default the value of <literal>CreateTablesOnStartup</literal> attribute
+                  is set to <literal>true</literal>
+               </para>
+         </section>
+
+          <section id="conf.postoffice.clustered.attributes.postofficename">
+               <title>PostOfficeName</title>
+
+               <para>
+                  The name of the post office
+               </para>
+         </section>
+
+          <section id="conf.postoffice.clustered.attributes.nodeidview">
+               <title>NodeIDView</title>
+
+               <para>
+                  This returns set containing the node ids of all the nodes in the cluster
+               </para>
+         </section>
+
+          <section id="conf.postoffice.clustered.attributes.groupname">
+               <title>GroupName</title>
+
+               <para>
+                  All post offices in the cluster with the same group name will form a cluster together. Make sure the group name matches with
+                  all the nodes in the cluster you want to form a cluster with.
+               </para>
+         </section>
+
+          <section id="conf.postoffice.clustered.attributes.messagepullpolicy">
+               <title>MessagePullPolicy</title>
+               <para>
+                  JBoss Messaging has the ability for queues on one node to pull messages from other nodes when they have exhausted their local messages.
+               </para>
+               <para>This prevents messages from getting stranded on nodes with slow or no consumers, and balances out message processing across the cluster.</para>
+               <para>How, if and when messages are pulled from one node to another is determined by the MessagePullPolicy</para>
+               <para>By default this set to <literal>org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy</literal> which is a dummy
+               implementation which never pulls messages from one node to another.</para>
+               <para>Whether you need message redistribution or not depends on your application topology - please see the section on clustering configuration for
+               more details</para>
+               <para>If you require message redistribution then set this value to <literal>org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy</literal>
+               </para>
+               <warning>Enabling message redistribution can result in the strict JMS message ordering guarantee being lost (i.e. the order of receipt of messages from
+               a particular producer is retained). If this is not acceptable then do not enable message redistribution.</warning>
+         </section>
+
+          <section id="conf.postoffice.clustered.attributes.clusterrouterfactory">
+               <title>ClusterRouterFactory</title>
+               <para>
+                  When a message arrives on a node - JBoss Messaging needs to decide whether to route it to a local queue or a remote queue on a different node.
+               </para>
+               <para>This setting allows you to specify the factory that determines this routing</para>
+               <para>By default this set to <literal>org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory</literal> which always favours
+               a local queue if one is available otherwise it round robins amongst other queues.</para>
+               <para>The particular router factory you require depends on your application topology - please see the section on clustering configuration for
+               more details</para>
+               <para>Other values this attribute can be set to are <literal>org.jboss.messaging.core.plugin.postoffice.cluster.RoundRobinRouterFactory</literal>
+               if you do not want to favour the local queue.
+               </para>
+         </section>
+
+          <section id="conf.postoffice.clustered.attributes.statetimeout">
+               <title>StateTimeout</title>
+               <para>
+                  The maximum time to wait when waiting for the group state to arrive when a node joins a pre-existing cluster.
+               </para>
+               <para>The default value is <literal>5000</literal> milliseconds
+               </para>
+         </section>
+
+          <section id="conf.postoffice.clustered.attributes.casttimeout">
+               <title>CastTimeout</title>
+               <para>
+                  The maximum time to wait for a reply casting message synchronously
+               </para>
+               <para>The default value is <literal>5000</literal> milliseconds
+               </para>
+         </section>
+
+         <section id="conf.postoffice.clustered.attributes.statssendperiod">
+               <title>StatsSendPeriod</title>
+               <para>
+                       When clustering, each node in the cluster will broadcast statistics periodically to inform the other nodes of their queues and the number of
+                       messages in them. This data is then used by the message redistribution policy to redistribute messages if necessary.
+                       This value represents the number of milliseconds between statistics broadcasts.
+              </para>
+              <para>
+                       The default value is <literal>10000</literal> milliseconds
+              </para>
+         </section>
+
+         <section id="conf.postoffice.clustered.attributes.syncchannelconfig">
+               <title>SyncChannelConfig</title>
+               <para>
+                    JBoss Messaging uses JGroups for all group management. This contains the JGroups stack configuration for the synchronous channel.
+              </para>
+              <para>The synchronous channel is used for sending request/reeciving responses from other nodes in the cluster</para>
+              <para>
+               The details of the JGroups configuration won't be discussed here since it is standard JGroups configuration.
+                       Detailed information on JGroups can be found in JGroups release documentation or on-line at
+                       <ulink url="http://www.jgroups.org">http://www.jgroups.org</ulink> or
+                 <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups">http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups</ulink>
+              </para>
+         </section>
+
+         <section id="conf.postoffice.clustered.attributes.asyncchannelconfig">
+               <title>AsyncChannelConfig</title>
+               <para>
+                    JBoss Messaging uses JGroups for all group management. This contains the JGroups stack configuration for the asynchronous channel.
+              </para>
+              <para>The asynchronous channel is used for sending sending/receiving messages from other nodes in the cluster</para>
+              <para>
+               The details of the JGroups configuration won't be discussed here since it is standard JGroups configuration.
+                       Detailed information on JGroups can be found in JGroups release documentation or on-line at
+                       <ulink url="http://www.jgroups.org">http://www.jgroups.org</ulink> or
+                 <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups">http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups</ulink>
+              </para>
+         </section>
+
+         <section id="conf.postoffice.clustered.attributes.threadpoolsize">
+               <title>ThreadPoolSize</title>
+               <para>
+                    The post office uses a thread pool for dispatching requests/handling responses from the cluster. This attribute represents the maximum size of
+                    that pool
+              </para>
+              <para>The default value of this is <literal>50</literal> threads</para>
+         </section>
+
+      </section>
+   </section>
+   </section>
+
+
+
+  <section id="conf.persistencemanager">
+    <title>Configuring the Persistence Manager</title>
+
+    <para>It is the job of the persistence manager to manage all message related persistence.
+    </para>
+
+
+    <para>
+       JBoss Messaging ships with a JDBC Persistence Manager used for handling persistence of
+       message data in a relational database accessed via JDBC. The Persistence Manager
+       implementation is pluggable (the Persistence Manager is a Messaging server plug-in),
+       this making possible to provide other implementations for persisting message data in
+       non relational stores, file stores etc.
+    </para>
+
+     <para>
+        The configuration of "persistent" services is grouped in a
+        <filename>xxx-persistence-service.xml</filename> file, where the actual file prefix is
+        usually inferred from its corresponding database JDBC connection string. By default,
+        Messaging ships with a <filename>hsqldb-persistence-service.xml</filename>, which configures
+        the Messaging server to use the in-VM Hypersonic database instance that comes by default
+        with any JBossAS instance.
+     </para>
+
+     <warning>
+        <para>
+        The default Persistence Manager configuration is works out of the box with Hypersonic,
+        however it must be stressed that Hypersonic should not be used in a production environment
+        mainly due to its limited support for transaction isolation and its propensity to behave
+        erratically under high load.
+        </para>
+        <para>
+           The
+           <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=ConfigJBossMQDB">Critique of Hypersonic</ulink>
+           wiki page outlines some of the well-known issues occuring when using this database.
+        </para>
+     </warning>
+
+     <para>
+        JBoss Messaging also ships with pre-made Persistence Manager configurations for MySQL,
+        Oracle, PostgreSQL, Sybase and MS SQL Server. The example <filename>mysql-persistence-service.xml</filename>,
+        <filename>oracle-persistence-service.xml</filename>,
+        <filename>postgres-persistence-service.xml</filename> and
+        <filename>sybase-persistence-service.xml</filename> and
+        <filename>mssql-persistence-service.xml</filename> configuration files are available
+        in the <filename>examples/config</filename> directory of the release bundle.
+     </para>
+
+     <para>
+        Users are encouraged to contribute their own configuration files where we will thoroughly test them before certifying them for suppported use
+        with JBoss Messaging. The JDBC Persistence Manager has been designed
+        to use standard SQL for the DML so writing a JDBC Persistence Manager configuration for another
+        database is usually only a fairly simple matter of changing DDL in the configuration
+        which is likely to be different for different databases.
+     </para>
+
+     <para>
+        The default Hypersonic persistence configuration file is listed below:
+     </para>
+
+   <programlisting>
+
+      &lt;server&gt;
+
+         &lt;mbean code="org.jboss.messaging.core.plugin.JDBCPersistenceManagerService"
+            name="jboss.messaging:service=PersistenceManager"
+            xmbean-dd="xmdesc/JDBCPersistenceManager-xmbean.xml"&gt;
+            &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
+            &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
+            &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
+            &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
+            &lt;attribute name="UsingBatchUpdates"&gt;false&lt;/attribute&gt;
+            &lt;attribute name="MaxParams"&gt;500&lt;/attribute&gt;
+         &lt;/mbean&gt;
+
+         &lt;mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
+            name="jboss.messaging:service=PostOffice"
+            xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml"&gt;
+            &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+            &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
+            &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
+            &lt;attribute name="PostOfficeName"&gt;JMS&lt;/attribute&gt;
+            &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
+            &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
+         &lt;/mbean&gt;
+
+         &lt;mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
+            name="jboss.messaging:service=JMSUserManager"
+            xmbean-dd="xmdesc/JMSUserManager-xmbean.xml"&gt;
+            &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
+            &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
+            &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
+            &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
+            &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
+      POPULATE.TABLES.1=INSERT INTO JBM_USER (USER_ID,PASSWD,CLIENTID) VALUES ('dilbert','dogbert','dilbert-id')
+            ]]&gt;&lt;/attribute&gt;
+         &lt;/mbean&gt;
+
+      &lt;/server&gt;
+
+   </programlisting>
+
+     <para>
+        An example of a Persistence Manager configuration for a MySQL database follows:
+     </para>
+
+  <programlisting>
+
+   &lt;server&gt;
+
+      &lt;mbean code="org.jboss.messaging.core.plugin.JDBCPersistenceManagerService"
+            name="jboss.messaging:service=PersistenceManager"
+            xmbean-dd="xmdesc/JDBCPersistenceManager-xmbean.xml"&gt;
+            &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
+            &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
+            &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
+            &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
+            &lt;attribute name="UsingBatchUpdates"&gt;true&lt;/attribute&gt;
+            &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
+      CREATE_MESSAGE_REFERENCE=CREATE TABLE JBM_MSG_REF (CHANNEL_ID BIGINT, MESSAGE_ID BIGINT, TRANSACTION_ID BIGINT, STATE CHAR(1), ORD BIGINT, PAGE_ORD BIGINT, DELIVERY_COUNT INTEGER, SCHED_DELIVERY BIGINT, PRIMARY KEY(CHANNEL_ID, MESSAGE_ID))
+      CREATE_IDX_MESSAGE_REF_TX=CREATE INDEX JBM_MSG_REF_TX ON JBM_MSG_REF (TRANSACTION_ID)
+      CREATE_IDX_MESSAGE_REF_ORD=CREATE INDEX JBM_MSG_REF_ORD ON JBM_MSG_REF (ORD)
+      CREATE_IDX_MESSAGE_REF_PAGE_ORD=CREATE INDEX JBM_MSG_REF_PAGE_ORD ON JBM_MSG_REF (PAGE_ORD)
+      CREATE_IDX_MESSAGE_REF_MESSAGE_ID=CREATE INDEX JBM_MSG_REF_MESSAGE_ID ON JBM_MSG_REF (MESSAGE_ID)
+      CREATE_IDX_MESSAGE_REF_SCHED_DELIVERY=CREATE INDEX JBM_MSG_REF_SCHED_DELIVERY ON JBM_MSG_REF (SCHED_DELIVERY)
+      CREATE_MESSAGE=CREATE TABLE JBM_MSG (MESSAGE_ID BIGINT, RELIABLE CHAR(1), EXPIRATION BIGINT, TIMESTAMP BIGINT, PRIORITY TINYINT, HEADERS MEDIUMBLOB, PAYLOAD LONGBLOB, CHANNEL_COUNT INTEGER, TYPE TINYINT, PRIMARY KEY (MESSAGE_ID))
+      CREATE_TRANSACTION=CREATE TABLE JBM_TX (TRANSACTION_ID BIGINT, BRANCH_QUAL VARBINARY(254), FORMAT_ID INTEGER, GLOBAL_TXID VARBINARY(254), PRIMARY KEY (TRANSACTION_ID))
+      CREATE_COUNTER=CREATE TABLE JBM_COUNTER (NAME VARCHAR(255), NEXT_ID BIGINT, PRIMARY KEY(NAME))
+      INSERT_MESSAGE_REF=INSERT INTO JBM_MSG_REF (CHANNEL_ID, MESSAGE_ID, TRANSACTION_ID, STATE, ORD, PAGE_ORD, DELIVERY_COUNT, SCHED_DELIVERY) VALUES (?, ?, ?, ?, ?, ?, ?, ?)
+      DELETE_MESSAGE_REF=DELETE FROM JBM_MSG_REF WHERE MESSAGE_ID=? AND CHANNEL_ID=? AND STATE='C'
+      UPDATE_MESSAGE_REF=UPDATE JBM_MSG_REF SET TRANSACTION_ID=?, STATE='-' WHERE MESSAGE_ID=? AND CHANNEL_ID=? AND STATE='C'
+      UPDATE_PAGE_ORDER=UPDATE JBM_MSG_REF SET PAGE_ORD = ? WHERE MESSAGE_ID=? AND CHANNEL_ID=?
+      COMMIT_MESSAGE_REF1=UPDATE JBM_MSG_REF SET STATE='C', TRANSACTION_ID = NULL WHERE TRANSACTION_ID=? AND STATE='+'
+      COMMIT_MESSAGE_REF2=DELETE FROM JBM_MSG_REF WHERE TRANSACTION_ID=? AND STATE='-'
+      ROLLBACK_MESSAGE_REF1=DELETE FROM JBM_MSG_REF WHERE TRANSACTION_ID=? AND STATE='+'
+      ROLLBACK_MESSAGE_REF2=UPDATE JBM_MSG_REF SET STATE='C', TRANSACTION_ID = NULL WHERE TRANSACTION_ID=? AND STATE='-'
+      LOAD_PAGED_REFS=SELECT MESSAGE_ID, DELIVERY_COUNT, PAGE_ORD, SCHED_DELIVERY FROM JBM_MSG_REF WHERE CHANNEL_ID = ? AND PAGE_ORD BETWEEN ? AND ? ORDER BY PAGE_ORD
+      LOAD_UNPAGED_REFS=SELECT MESSAGE_ID, DELIVERY_COUNT, SCHED_DELIVERY FROM JBM_MSG_REF WHERE STATE = 'C' AND CHANNEL_ID = ? AND PAGE_ORD IS NULL ORDER BY ORD
+      LOAD_REFS=SELECT MESSAGE_ID, DELIVERY_COUNT, SCHED_DELIVERY FROM JBM_MSG_REF WHERE STATE = 'C' AND CHANNEL_ID = ? ORDER BY ORD
+      UPDATE_REFS_NOT_PAGED=UPDATE JBM_MSG_REF SET PAGE_ORD = NULL WHERE PAGE_ORD BETWEEN ? AND ? AND CHANNEL_ID=?
+      SELECT_MIN_MAX_PAGE_ORD=SELECT MIN(PAGE_ORD), MAX(PAGE_ORD) FROM JBM_MSG_REF WHERE CHANNEL_ID = ?
+      SELECT_EXISTS_REF=SELECT MESSAGE_ID FROM JBM_MSG_REF WHERE CHANNEL_ID = ? AND MESSAGE_ID = ?
+      SELECT_EXISTS_REF_MESSAGE_ID=SELECT MESSAGE_ID FROM JBM_MSG_REF WHERE MESSAGE_ID = ?
+      UPDATE_DELIVERY_COUNT=UPDATE JBM_MSG_REF SET DELIVERY_COUNT = ? WHERE CHANNEL_ID = ? AND MESSAGE_ID = ?
+      UPDATE_CHANNEL_ID=UPDATE JBM_MSG_REF SET CHANNEL_ID = ? WHERE CHANNEL_ID = ?
+      LOAD_MESSAGES=SELECT MESSAGE_ID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, HEADERS, PAYLOAD, TYPE FROM JBM_MSG
+      INSERT_MESSAGE=INSERT INTO JBM_MSG (MESSAGE_ID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, HEADERS, PAYLOAD, CHANNEL_COUNT, TYPE) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)
+      INC_CHANNEL_COUNT=UPDATE JBM_MSG SET CHANNEL_COUNT = CHANNEL_COUNT + 1 WHERE MESSAGE_ID=?
+      DEC_CHANNEL_COUNT=UPDATE JBM_MSG SET CHANNEL_COUNT = CHANNEL_COUNT - 1 WHERE MESSAGE_ID=?
+      DELETE_MESSAGE=DELETE FROM JBM_MSG WHERE MESSAGE_ID=? AND CHANNEL_COUNT=0
+      MESSAGE_ID_COLUMN=MESSAGE_ID
+      MESSAGE_EXISTS=SELECT MESSAGE_ID FROM JBM_MSG WHERE MESSAGE_ID = ? FOR UPDATE
+      INSERT_TRANSACTION=INSERT INTO JBM_TX (TRANSACTION_ID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID) VALUES(?, ?, ?, ?)
+      DELETE_TRANSACTION=DELETE FROM JBM_TX WHERE TRANSACTION_ID = ?
+      SELECT_PREPARED_TRANSACTIONS=SELECT TRANSACTION_ID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID FROM JBM_TX
+      SELECT_MESSAGE_ID_FOR_REF=SELECT MESSAGE_ID, CHANNEL_ID FROM JBM_MSG_REF WHERE TRANSACTION_ID = ? AND STATE = '+' ORDER BY ORD
+      SELECT_MESSAGE_ID_FOR_ACK=SELECT MESSAGE_ID, CHANNEL_ID FROM JBM_MSG_REF WHERE TRANSACTION_ID = ? AND STATE = '-' ORDER BY ORD
+      UPDATE_COUNTER=UPDATE JBM_COUNTER SET NEXT_ID = ? WHERE NAME=?
+      SELECT_COUNTER=SELECT NEXT_ID FROM JBM_COUNTER WHERE NAME=? FOR UPDATE
+      INSERT_COUNTER=INSERT INTO JBM_COUNTER (NAME, NEXT_ID) VALUES (?, ?)
+      SELECT_ALL_CHANNELS=SELECT DISTINCT(CHANNEL_ID) FROM JBM_MSG_REF
+            ]]&gt;&lt;/attribute&gt;
+            &lt;attribute name="MaxParams"&gt;500&lt;/attribute&gt;
+      &lt;/mbean&gt;
+
+      &lt;mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
+         name="jboss.messaging:service=PostOffice"
+         xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml"&gt;
+         &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+         &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
+         &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
+         &lt;attribute name="PostOfficeName"&gt;JMS&lt;/attribute&gt;
+         &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
+         &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
+         &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
+   CREATE_POSTOFFICE_TABLE=CREATE TABLE JBM_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, CLUSTERED CHAR(1))
+   INSERT_BINDING=INSERT INTO JBM_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED) VALUES (?, ?, ?, ?, ?, ?, ?)
+   DELETE_BINDING=DELETE FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
+   LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, CLUSTERED FROM JBM_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
+         ]]&gt;&lt;/attribute&gt;
+      &lt;/mbean&gt;
+
+      &lt;mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
+         name="jboss.messaging:service=JMSUserManager"
+         xmbean-dd="xmdesc/JMSUserManager-xmbean.xml"&gt;
+         &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
+         &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
+         &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
+         &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
+         &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
+   CREATE_USER_TABLE=CREATE TABLE JBM_USER (USER_ID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128), PRIMARY KEY(USER_ID))
+   CREATE_ROLE_TABLE=CREATE TABLE JBM_ROLE (ROLE_ID VARCHAR(32) NOT NULL, USER_ID VARCHAR(32) NOT NULL, PRIMARY KEY(USER_ID, ROLE_ID))
+   SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JBM_USER WHERE USER_ID=?
+   POPULATE.TABLES.1=INSERT INTO JBM_USER (USER_ID,PASSWD,CLIENTID) VALUES ('dilbert','dogbert','dilbert-id')
+         ]]&gt;&lt;/attribute&gt;
+      &lt;/mbean&gt;
+
+   &lt;/server&gt;
+
+  </programlisting>
+
+     <section id="conf.persistencemanager.attributes">
+
+
+        <title>
+        We now discuss the MBean attributes of the PersistenceManager MBean
+        </title>
+
+        <section id="conf.persistencemanager.attributes.createtables">
+           <title>CreateTablesOnStartup</title>
+
+           <para>
+              Set this to <literal>true</literal> if you wish the Persistence Manager to attempt
+              to create the tables (and indexes) when it starts. If the tables (or indexes)
+              already exist a <literal>SQLException</literal> will be thrown by the JDBC driver and
+              ignored by the Persistence Manager, allowing it to continue.
+           </para>
+           <para>
+              By default the value of <literal>CreateTablesOnStartup</literal> attribute
+              is set to <literal>true</literal>
+           </para>
+     </section>
+
+      <section id="conf.persistencemanager.attributes.batchupdates">
+           <title>UsingBatchUpdates</title>
+
+           <para>
+              Set this to <literal>true</literal> if the database supports JDBC batch updates.
+              The JDBC Persistence Manager will then group multiple database updates in batches
+              to aid performance.
+           </para>
+         <para>
+            By default the value of <literal>UsingBatchUpdates</literal> attribute
+            is set to <literal>false</literal>
+         </para>
+       </section>
+
+      <section id="conf.persistencemanager.attributes.binarystream">
+           <title>UsingBinaryStream</title>
+
+           <para>
+              Set this to <literal>true</literal> if you want messages to be store and read using a JDBC binary stream rather than using
+              getBytes(), setBytes(). Some database has limits on the maximum number of bytes that can be get/set using getBytes()/setBytes().
+           </para>
+         <para>
+            By default the value of <literal>UsingBinaryStream</literal> attribute
+            is set to <literal>true</literal>
+         </para>
+       </section>
+
+      <section id="conf.persistencemanager.attributes.trailingbyte">
+           <title>UsingTrailingByte</title>
+
+           <para>
+              Certain version of Sybase are known to truncate blobs if they have trailing zeros. To prevent this if this attribute is set to
+              <literal>true</literal> then a trailing non zero byte will be added and removed to each blob before and after persistence to prevent
+              the database from truncating it. Currently this is only known to be necessary for Sybase.
+           </para>
+         <para>
+            By default the value of <literal>UsingTrailingByte</literal> attribute
+            is set to <literal>false</literal>
+         </para>
+       </section>
+
+       <section id="conf.persistencemanager.attributes.sqlproperties">
+           <title>SQLProperties</title>
+
+           <para>
+              This is where the DDL and DML for the particular database is specified.
+              If a particular DDL or DML statement is not overridden, the default Hypersonic
+              configuration will be used for that statement.
+           </para>
+        </section>
+
+        <section id="conf.persistencemanager.attributes.maxparams">
+          <title>MaxParams</title>
+
+          <para>
+             When loading messages the persistence manager will generate prepared statements with many parameters. This value tells the persistence
+             manager what the absolute maximum number of parameters are allowable per prepared statement.
+
+          </para>
+          <para>
+           By default the value of <literal>MaxParams</literal> attribute
+           is set to <literal>100</literal>
+        </para>
+       </section>
+
+    </section>
+
+   </section>
+
+
+ <section id="conf.jmsusermanager">
+   <title>Configuring the JMS user manager</title>
+
+      <para>The JMS user manager handles the mapping of pre-configured client IDs to users and also managers the user and role tables which may or
+      may not be used depending on which login module you have configured</para>
+
+      <para>Here is an example JMSUserManager configuration</para>
+
+      <programlisting>
+
+   &lt;mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
+      name="jboss.messaging:service=JMSUserManager"
+      xmbean-dd="xmdesc/JMSUserManager-xmbean.xml"&gt;
+      &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;
+      &lt;depends optional-attribute-name="TransactionManager"&gt;jboss:service=TransactionManager&lt;/depends&gt;
+      &lt;attribute name="DataSource"&gt;java:/DefaultDS&lt;/attribute&gt;
+      &lt;attribute name="CreateTablesOnStartup"&gt;true&lt;/attribute&gt;
+      &lt;attribute name="SqlProperties"&gt;&lt;![CDATA[
+CREATE_USER_TABLE=CREATE TABLE JBM_USER (USER_ID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128), PRIMARY KEY(USER_ID))
+CREATE_ROLE_TABLE=CREATE TABLE JBM_ROLE (ROLE_ID VARCHAR(32) NOT NULL, USER_ID VARCHAR(32) NOT NULL, PRIMARY KEY(USER_ID, ROLE_ID))
+SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JBM_USER WHERE USER_ID=?
+POPULATE.TABLES.1=INSERT INTO JBM_USER (USER_ID,PASSWD,CLIENTID) VALUES ('dilbert','dogbert','dilbert-id')
+      ]]&gt;&lt;/attribute&gt;
+   &lt;/mbean&gt;
+
+      </programlisting>
+
+        <section id="conf.jmsusermanager.attributes">
+
+
+        <title>
+        We now discuss the MBean attributes of the PersistenceManager MBean
+        </title>
+
+        <section id="conf.jmsusermanager.attributes.createtables">
+           <title>CreateTablesOnStartup</title>
+
+           <para>
+              Set this to <literal>true</literal> if you wish the JMS user manager to attempt
+              to create the tables (and indexes) when it starts. If the tables (or indexes)
+              already exist a <literal>SQLException</literal> will be thrown by the JDBC driver and
+              ignored by the Persistence Manager, allowing it to continue.
+           </para>
+           <para>
+              By default the value of <literal>CreateTablesOnStartup</literal> attribute
+              is set to <literal>true</literal>
+           </para>
+     </section>
+
+      <section id="conf.jmsusermanager.attributes.batchupdates">
+           <title>UsingBatchUpdates</title>
+
+           <para>
+              Set this to <literal>true</literal> if the database supports JDBC batch updates.
+              The JDBC Persistence Manager will then group multiple database updates in batches
+              to aid performance.
+           </para>
+         <para>
+            By default the value of <literal>UsingBatchUpdates</literal> attribute
+            is set to <literal>false</literal>
+         </para>
+       </section>
+
+
+       <section id="conf.jmsusermanager.attributes.sqlproperties">
+           <title>SQLProperties</title>
+
+           <para>
+              This is where the DDL and DML for the particular database is specified.
+              If a particular DDL or DML statement is not overridden, the default Hypersonic
+              configuration will be used for that statement.
+           </para>
+
+           <para>
+           Default user and role data can also be specified here. Any data to be inserted must be specified with property names starting with
+           <literal>POPULATE.TABLES</literal> as in the above example.
+           </para>
+        </section>
+
+
+     </section>
+
+  </section>
+
+
+  <section id="conf.destination">
+    <title>Configuring Destinations</title>
+
+<section id="conf.preconf.destinations">
+        <title>Pre-configured destinations</title>
+
+        <para>
+           JBoss Messaging  ships with a default set of pre-configured destinations that will be
+           deployed during the server start up. The file that contains configuration for these
+           destinations is <filename>destinations-service.xml</filename>. A section of
+           this file is listed below:
+        </para>
+
+        <programlisting>
+   &lt;!--
+      The Default Dead Letter Queue. This destination is a dependency of an EJB MDB container.
+   --&gt;
+
+   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
+      name="jboss.messaging.destination:service=Queue,name=DLQ"
+      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+   &lt;/mbean&gt;
+
+
+   &lt;mbean code="org.jboss.jms.server.destination.TopicService"
+      name="jboss.messaging.destination:service=Topic,name=testTopic"
+      xmbean-dd="xmdesc/Topic-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+      &lt;attribute name="SecurityConfig"&gt;
+         &lt;security&gt;
+            &lt;role name="guest" read="true" write="true"/&gt;
+            &lt;role name="publisher" read="true" write="true" create="false"/&gt;
+            &lt;role name="durpublisher" read="true" write="true" create="true"/&gt;
+         &lt;/security&gt;
+      &lt;/attribute&gt;
+   &lt;/mbean&gt;
+
+   &lt;mbean code="org.jboss.jms.server.destination.TopicService"
+      name="jboss.messaging.destination:service=Topic,name=securedTopic"
+      xmbean-dd="xmdesc/Topic-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+      &lt;attribute name="SecurityConfig"&gt;
+         &lt;security&gt;
+            &lt;role name="publisher" read="true" write="true" create="false"/&gt;
+         &lt;/security&gt;
+      &lt;/attribute&gt;
+   &lt;/mbean&gt;
+
+
+   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
+      name="jboss.messaging.destination:service=Queue,name=testQueue"
+      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+      &lt;attribute name="SecurityConfig"&gt;
+         &lt;security&gt;
+            &lt;role name="guest" read="true" write="true"/&gt;
+            &lt;role name="publisher" read="true" write="true" create="false"/&gt;
+            &lt;role name="noacc" read="false" write="false" create="false"/&gt;
+         &lt;/security&gt;
+      &lt;/attribute&gt;
+   &lt;/mbean&gt;
+
+   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
+      name="jboss.messaging.destination:service=Queue,name=A"
+      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+   &lt;/mbean&gt;
+
+
+   &lt;!-- It's possible for indiviual queues and topics to use a specific queue for
+   an expiry or DLQ --&gt;
+
+   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
+      name="jboss.messaging.destination:service=Queue,name=PrivateDLQ"
+      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+   &lt;/mbean&gt;
+
+   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
+      name="jboss.messaging.destination:service=Queue,name=PrivateExpiryQueue"
+      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+   &lt;/mbean&gt;
+
+   &lt;mbean code="org.jboss.jms.server.destination.QueueService"
+      name="jboss.messaging.destination:service=Queue,name=QueueWithOwnDLQAndExpiryQueue"
+      xmbean-dd="xmdesc/Queue-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+      &lt;attribute name="DLQ"&gt;jboss.messaging.destination:service=Queue,name=PrivateDLQ&lt;/attribute&gt;
+      &lt;attribute name="ExpiryQueue"&gt;jboss.messaging.destination:service=Queue,name=PrivateExpiryQueue&lt;/attribute&gt;
+   &lt;/mbean&gt;
+
+   &lt;mbean code="org.jboss.jms.server.destination.TopicService"
+      name="jboss.messaging.destination:service=Topic,name=TopicWithOwnDLQAndExpiryQueue"
+      xmbean-dd="xmdesc/Topic-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+      &lt;attribute name="DLQ"&gt;jboss.messaging.destination:service=Queue,name=PrivateDLQ&lt;/attribute&gt;
+      &lt;attribute name="ExpiryQueue"&gt;jboss.messaging.destination:service=Queue,name=PrivateExpiryQueue&lt;/attribute&gt;
+   &lt;/mbean&gt;
+
+
+   &lt;mbean code="org.jboss.jms.server.destination.TopicService"
+      name="jboss.messaging.destination:service=Topic,name=TopicWithOwnRedeliveryDelay"
+      xmbean-dd="xmdesc/Topic-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+      &lt;attribute name="RedeliveryDelay"&gt;5000&lt;/attribute&gt;
+   &lt;/mbean&gt;
+
+
+   &lt;mbean code="org.jboss.jms.server.destination.TopicService"
+      name="jboss.messaging.destination:service=Topic,name=testDistributedTopic"
+      xmbean-dd="xmdesc/Topic-xmbean.xml"&gt;
+      &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
+      &lt;depends&gt;jboss.messaging:service=PostOffice&lt;/depends&gt;
+      &lt;attribute name="Clustered"&gt;true&lt;/attribute&gt;
+   &lt;/mbean&gt;
+....
+        </programlisting>
+
+    </section>
+
+
+    <section id="conf.destination.queue">
+
+       <title>Configuring queues</title>
+
+        <section id="conf.destination.queue.attributes">
+
+            <title>
+            We now discuss the MBean attributes of the Queue MBean
+            </title>
+
+               <section id="conf.destination.queue.attributes.name">
+                  <title>Name</title>
+                  <para>The name of the queue</para>
+               </section>
+
+               <section id="conf.destination.queue.attributes.jndiName">
+                   <title>JNDIName</title>
+                   <para>The JNDI name where the queue is bound</para>
+               </section>
+
+               <section id="conf.destination.queue.attributes.dlq">
+                    <title>DLQ</title>
+                    <para>The DLQ used for this queue. Overrides any value set on the ServerPeer config</para>
+               </section>
+
+               <section id="conf.destination.queue.attributes.expiryqueue">
+                    <title>ExpiryQueue</title>
+                    <para>The Expiry queue used for this queue. Overrides any value set on the ServerPeer config</para>
+               </section>
+
+               <section id="conf.destination.queue.attributes.redeliverydelay">
+                    <title>RedeliveryDelay</title>
+                    <para>The redlivery delay to be used for this queue. Overrides any value set on the ServerPeer config</para>
+               </section>
+
+              <section id="conf.destination.queue.attributes.security">
+               <title>Destination Security Configuration</title>
+
+                 <para>
+                    <literal>SecurityConfig</literal> - allows you to determine which roles are allowed
+                    to read, write and create on the destination. It has exactly the same syntax and
+                    semantics as the security configuration in JBossMQ destinations.
+                 </para>
+
+                 <para>
+                    The <literal>SecurityConfig</literal> element should contain one
+                    <literal>&lt;security&gt;</literal> element. The <literal>&lt;security&gt;</literal>
+                    element can contain multiple <literal>&lt;role&gt;</literal> elements.
+                    Each <literal>&lt;role&gt;</literal> element defines the access for that
+                    particular role.
+                 </para>
+
+                 <para>
+                    If the <literal>read</literal> attribute is <literal>true</literal> then that role
+                    will be able to read (create consumers, receive messaages or browse) this destination.
+                 </para>
+
+                 <para>
+                    If the <literal>write</literal> attribute is <literal>true</literal> then that role
+                    will be able to write (create producers or send messages) to this destination.
+                 </para>
+
+                 <para>
+                    If the <literal>create</literal> attribute is <literal>true</literal> then that role
+                    will be able to create durable subscriptions on this destination.
+                 </para>
+
+                 <para>
+                    Note that the security configuration for a destination is optional. If a
+                    <literal>SecurityConfig</literal> element is not specifed then the default
+                    security configuration from the Server Peer will be used.
+                 </para>
+              </section>
+
+           <section id="conf.destination.queue.attributes.paging">
+              <title>Destination paging parameters</title>
+
+              <para>
+                 'Pageable Channels' are a sophisticated new feature available in JBoss Messaging.
+              </para>
+
+              <para>
+                 If your application needs to support very large queues or subscriptions containing
+                 potentially millions of messages, then it's not possible to store them all in
+                 memory at once.
+              </para>
+
+              <para>
+                 JBoss Messaging solves this problem but letting you specify the
+                 maximum number of messages that can be stored in memory at any one time,
+                 on a queue-by-queue, or topic-by-topic basis. JBoss Messaging then pages messages
+                 to and from storage transparently in blocks, allowing queues and subscriptions to
+                 grow to very large sizes without any performance degradation as channel size increases.
+              </para>
+
+              <para>
+                 This has been tested with in excess of 10 million 2K messages on very basic hardware
+                 and has the potential to scale to much larger number of messages.
+              </para>
+
+              <para>
+                 The individual parameters are:
+              </para>
+
+              <para>
+                 <literal>FullSize</literal> - this is the maximum number of messages held by the
+                 queue or topic subscriptions in memory at any one time. The actual queue or
+                 subscription can hold many more messages than this but these are paged to and
+                 from storage as necessary as messages are added or consumed.
+              </para>
+
+              <para>
+                 <literal>PageSize</literal> - When loading messages from the queue or subscrition
+                 this is the maximum number of messages to pre-load in one operation.
+              </para>
+
+              <para>
+                 <literal>DownCacheSize</literal> - When paging messages to storage from the queue
+                 they first go into a "Down Cache" before being written to storage. This enables the
+                 write to occur as a single operation thus aiding performance. This setting determines
+                 the max number of messages that the Down Cache will hold before they are flushed
+                 to storage.
+              </para>
+
+              <para>
+                 If no values for <literal>FullSize</literal>, <literal>PageSize</literal>,
+                 or <literal>DownCacheSize</literal> are specified they will default to values
+                 75000, 2000, 2000 respectively.
+              </para>
+
+              <para>
+                 If you want to specify the paging parameters used for temporary queues then you need to specify them
+                 on the appropriate connection factory.
+                 See connection factory configuration for details.
+              </para>
+           </section>
+
+           <section id="conf.destination.queue.attributes.createdprogrammatically">
+               <title>CreatedProgrammatically</title>
+
+               <para>
+                 Returns <literal>true</literal> if the queue was created programmatically
+              </para>
+          </section>
+
+           <section id="conf.destination.queue.attributes.messagecount">
+               <title>MessageCount</title>
+
+               <para>
+                 Returns the total number of messages in the queue = number not being delivered + number being delivered + number being scheduled
+              </para>
+          </section>
+
+           <section id="conf.destination.queue.attributes.scheduledmessagecount">
+               <title>ScheduledMessageCount</title>
+
+               <para>
+                 Returns the  number of scheduled messages in the queue. This is the number of messages scheduled to be delivered at a later date.
+              </para>
+          </section>
+
+           <section id="conf.destination.queue.attributes.maxsize">
+               <title>MaxSize</title>
+
+               <para>
+                 A maximum size (in number of messages) can be specified for a queue. Any messages that arrive beyond this point will be dropped. The default is
+                 <literal>-1</literal> which is unbounded.
+              </para>
+          </section>
+
+           <section id="conf.destination.queue.attributes.clustered">
+               <title>Clustered</title>
+
+               <para>
+                 Clustered destinations must have this set to <literal>true</literal>
+              </para>
+          </section>
+
+           <section id="conf.destination.queue.attributes.messagecounter">
+               <title>MessageCounter</title>
+
+               <para>
+                 Each queue maintains a message counter.
+              </para>
+          </section>
+
+           <section id="conf.destination.queue.attributes.messagecounterstats">
+               <title>MessageCounterStatistics</title>
+
+               <para>
+                 The statistics for the message counter
+              </para>
+          </section>
+
+           <section id="conf.destination.queue.attributes.messagecounterhistorydaylimit">
+               <title>MessageCounterHistoryDayLimit</title>
+
+               <para>
+                 The maximum number of days to hold message counter history for. Overrides any value set on the ServerPeer.
+              </para>
+          </section>
+
+           <section id="conf.destination.queue.attributes.consumercount">
+               <title>ConsumerCount</title>
+
+               <para>
+                 The number of consumers currently consuming from the queue.
+              </para>
+          </section>
+
+     </section>
+
+
+     <section id="conf.destination.queue.operations">
+
+         <title>
+             We now discuss the MBean operations of the Queue MBean
+         </title>
+
+         <section id="conf.destination.queue.operations.removeallmessages">
+             <title>RemoveAllMessages</title>
+
+              <para>
+                Remove (and delete) all messages from the queue.
+                <warning>Use this with caution. It will permanently delete all messages from the queue</warning>
+             </para>
+         </section>
+
+         <section id="conf.destination.queue.operations.listallmessages">
+             <title>ListAllMessages</title>
+
+              <para>
+                List all messages currently in the queue
+             </para>
+             <para>There are two overloaded versions of this operation: One takes a JMS selector as an argument, the other does not. By using the selector
+             you can retrieve a subset of the messages in the queue that match the criteria</para>
+         </section>
+
+         <section id="conf.destination.queue.operations.listdurablemessages">
+             <title>ListDurableMessages</title>
+
+              <para>
+                As listAllMessages but only lists the durable messages
+             </para>
+             <para>There are two overloaded versions of this operation: One takes a JMS selector as an argument, the other does not. By using the selector
+             you can retrieve a subset of the messages in the queue that match the criteria</para>
+         </section>
+
+
+         <section id="conf.destination.queue.operations.listnondurablemessages">
+             <title>ListNonDurableMessages</title>
+
+              <para>
+                As listAllMessages but only lists the non durable messages
+             </para>
+             <para>There are two overloaded versions of this operation: One takes a JMS selector as an argument, the other does not. By using the selector
+             you can retrieve a subset of the messages in the queue that match the criteria</para>
+         </section>
+
+         <section id="conf.destination.queue.operations.resetmessagecounter">
+             <title>ResetMessageCounter</title>
+
+              <para>
+                Resets the message counter to zero.
+             </para>
+         </section>
+
+         <section id="conf.destination.queue.operations.resetmessagecounterhistory">
+             <title>ResetMessageCounterHistory</title>
+
+              <para>
+                Resets the message counter history.
+             </para>
+         </section>
+
+         <section id="conf.destination.queue.operations.listmessagecounterashtml">
+             <title>ListMessageCounterAsHTML</title>
+
+              <para>
+                Lists the message counter in an easy to display HTML format
+             </para>
+         </section>
+
+         <section id="conf.destination.queue.operations.listmessagecounterhistoryashtml">
+             <title>ListMessageCounterHistoryAsHTML</title>
+
+              <para>
+                Lists the message counter history in an easy to display HTML format
+             </para>
+         </section>
+
+
+     </section>
+
+  </section>
+
+
+
+
+  <section id="conf.destination.topics">
+
+       <title>Configuring topics</title>
+
+        <section id="conf.destination.topic.attributes">
+
+            <title>
+            We now discuss the MBean attributes of the Topic MBean
+            </title>
+
+               <section id="conf.destination.topic.attributes.name">
+                  <title>Name</title>
+                  <para>The name of the topic</para>
+               </section>
+
+               <section id="conf.destination.topic.attributes.jndiName">
+                   <title>JNDIName</title>
+                   <para>The JNDI name where the topic is bound</para>
+               </section>
+
+               <section id="conf.destination.topic.attributes.dlq">
+                    <title>DLQ</title>
+                    <para>The DLQ used for this topic. Overrides any value set on the ServerPeer config</para>
+               </section>
+
+               <section id="conf.destination.topic.attributes.expiryqueue">
+                    <title>ExpiryQueue</title>
+                    <para>The Expiry queue used for this topic. Overrides any value set on the ServerPeer config</para>
+               </section>
+
+               <section id="conf.destination.topic.attributes.redeliverydelay">
+                    <title>RedeliveryDelay</title>
+                    <para>The redelivery delay to be used for this topic. Overrides any value set on the ServerPeer config</para>
+               </section>
+
+              <section id="conf.destination.topic.attributes.security">
+               <title>Destination Security Configuration</title>
+
+                 <para>
+                    <literal>SecurityConfig</literal> - allows you to determine which roles are allowed
+                    to read, write and create on the destination. It has exactly the same syntax and
+                    semantics as the security configuration in JBossMQ destinations.
+                 </para>
+
+                 <para>
+                    The <literal>SecurityConfig</literal> element should contain one
+                    <literal>&lt;security&gt;</literal> element. The <literal>&lt;security&gt;</literal>
+                    element can contain multiple <literal>&lt;role&gt;</literal> elements.
+                    Each <literal>&lt;role&gt;</literal> element defines the access for that
+                    particular role.
+                 </para>
+
+                 <para>
+                    If the <literal>read</literal> attribute is <literal>true</literal> then that role
+                    will be able to read (create consumers, receive messaages or browse) this destination.
+                 </para>
+
+                 <para>
+                    If the <literal>write</literal> attribute is <literal>true</literal> then that role
+                    will be able to write (create producers or send messages) to this destination.
+                 </para>
+
+                 <para>
+                    If the <literal>create</literal> attribute is <literal>true</literal> then that role
+                    will be able to create durable subscriptions on this destination.
+                 </para>
+
+                 <para>
+                    Note that the security configuration for a destination is optional. If a
+                    <literal>SecurityConfig</literal> element is not specifed then the default
+                    security configuration from the Server Peer will be used.
+                 </para>
+              </section>
+
+           <section id="conf.destination.topic.attributes.paging">
+              <title>Destination paging parameters</title>
+
+              <para>
+                 'Pageable Channels' are a sophisticated new feature available in JBoss Messaging.
+              </para>
+
+              <para>
+                 If your application needs to support very large queues or subscriptions containing
+                 potentially millions of messages, then it's not possible to store them all in
+                 memory at once.
+              </para>
+
+              <para>
+                 JBoss Messaging solves this problem but letting you specify the
+                 maximum number of messages that can be stored in memory at any one time,
+                 on a queue-by-queue, or topic-by-topic basis. JBoss Messaging then pages messages
+                 to and from storage transparently in blocks, allowing queues and subscriptions to
+                 grow to very large sizes without any performance degradation as channel size increases.
+              </para>
+
+              <para>
+                 This has been tested with in excess of 10 million 2K messages on very basic hardware
+                 and has the potential to scale to much larger number of messages.
+              </para>
+
+              <para>
+                 The individual parameters are:
+              </para>
+
+              <para>
+                 <literal>FullSize</literal> - this is the maximum number of messages held by the
+                 queue or topic subscriptions in memory at any one time. The actual queue or
+                 subscription can hold many more messages than this but these are paged to and
+                 from storage as necessary as messages are added or consumed.
+              </para>
+
+              <para>
+                 <literal>PageSize</literal> - When loading messages from the queue or subscrition
+                 this is the maximum number of messages to pre-load in one operation.
+              </para>
+
+              <para>
+                 <literal>DownCacheSize</literal> - When paging messages to storage from the queue
+                 they first go into a "Down Cache" before being written to storage. This enables the
+                 write to occur as a single operation thus aiding performance. This setting determines
+                 the max number of messages that the Down Cache will hold before they are flushed
+                 to storage.
+              </para>
+
+              <para>
+                 If no values for <literal>FullSize</literal>, <literal>PageSize</literal>,
+                 or <literal>DownCacheSize</literal> are specified they will default to values
+                 75000, 2000, 2000 respectively.
+              </para>
+
+              <para>
+                 If you want to specify the paging parameters used for temporary queues then you need to specify them
+                 on the appropriate connection factory.
+                 See connection factory configuration for details.
+              </para>
+           </section>
+
+           <section id="conf.destination.topic.attributes.createdprogrammatically">
+               <title>CreatedProgrammatically</title>
+
+               <para>
+                 Returns <literal>true</literal> if the topic was created programmatically
+              </para>
+          </section>
+
+           <section id="conf.destination.topic.attributes.maxsize">
+               <title>MaxSize</title>
+
+               <para>
+                 A maximum size (in number of messages) can be specified for a topic subscription. Any messages that arrive beyond this point will be dropped. The default is
+                 <literal>-1</literal> which is unbounded.
+              </para>
+          </section>
+
+           <section id="conf.destination.topic.attributes.clustered">
+               <title>Clustered</title>
+
+               <para>
+                 Clustered destinations must have this set to <literal>true</literal>
+              </para>
+          </section>
+
+           <section id="conf.destination.topic.attributes.messagecounterhistorydaylimit">
+               <title>MessageCounterHistoryDayLimit</title>
+
+               <para>
+                 The maximum number of days to hold message counter history for. Overrides any value set on the ServerPeer.
+              </para>
+          </section>
+
+           <section id="conf.destination.topic.attributes.messagecounters">
+               <title>MessageCounters</title>
+
+               <para>
+                 Return a list of the message counters for the subscriptions of this topic.
+              </para>
+          </section>
+
+           <section id="conf.destination.topic.attributes.allmessagecount">
+               <title>AllMessageCount</title>
+
+               <para>
+                 Return the total number of messages in all subscriptions of this topic.
+              </para>
+          </section>
+
+           <section id="conf.destination.topic.attributes.durablemessagecount">
+               <title>DurableMessageCount</title>
+
+               <para>
+                 Return the total number of durable messages in all subscriptions of this topic.
+              </para>
+
+          </section>
+
+         <section id="conf.destination.topic.attributes.nondurablemessagecount">
+             <title>NonDurableMessageCount</title>
+
+             <para>
+               Return the total number of non durable messages in all subscriptions of this topic.
+            </para>
+          </section>
+
+         <section id="conf.destination.topic.attributes.allsubscriptionscount">
+             <title>AllSubscriptionsCount</title>
+
+             <para>
+               The count of all subscriptions on this topic
+            </para>
+          </section>
+
+         <section id="conf.destination.topic.attributes.durablesubscriptionscount">
+             <title>DurableSubscriptionsCount</title>
+
+             <para>
+               The count of all durable subscriptions on this topic
+            </para>
+          </section>
+
+         <section id="conf.destination.topic.attributesnon.durablesubscriptionscount">
+             <title>NonDurableSubscriptionsCount</title>
+
+             <para>
+               The count of all non durable subscriptions on this topic
+            </para>
+        </section>
+
+
+     </section>
+
+
+     <section id="conf.destination.topic.operations">
+
+         <title>
+             We now discuss the MBean operations of the Topic MBean
+         </title>
+
+         <section id="conf.destination.topic.operations.removeallmessages">
+             <title>RemoveAllMessages</title>
+
+              <para>
+                Remove (and delete) all messages from the subscriptions of this topic.
+                <warning>Use this with caution. It will permanently delete all messages from the topic</warning>
+             </para>
+         </section>
+
+         <section id="conf.destination.topic.operations.listallsubscriptions">
+             <title>ListAllSubscriptions</title>
+
+              <para>
+                List all subscriptions of this topic
+             </para>
+         </section>
+
+         <section id="conf.destination.topic.operations.listdurablesubscriptions">
+             <title>ListDurableSubscriptions</title>
+
+              <para>
+                List all durable subscriptions of this topic
+             </para>
+         </section>
+
+         <section id="conf.destination.topic.operations.listnondurablesubscriptions">
+             <title>ListNonDurableSubscriptions</title>
+
+              <para>
+                List all non durable subscriptions of this topic
+             </para>
+         </section>
+
+         <section id="conf.destination.topic.operations.listallsubscriptionsashtml">
+             <title>ListAllSubscriptionsAsHTML</title>
+
+              <para>
+                List all subscriptions of this topic in an easy to display HTML format
+             </para>
+         </section>
+
+         <section id="conf.destination.topic.operations.listdurablesubscriptionsashtml">
+             <title>ListDurableSubscriptionsAsHTML</title>
+
+              <para>
+                List all durable subscriptions of this topic in an easy to display HTML format
+             </para>
+         </section>
+
+         <section id="conf.destination.topic.operations.listnondurablesubscriptionsashtml">
+             <title>ListNonDurableSubscriptionsAsHTML</title>
+
+              <para>
+                List all non durable subscriptions of this topic in an easy to display HTML format
+             </para>
+         </section>
+
+         <section id="conf.destination.topic.operations.listallmessages">
+             <title>ListAllMessages</title>
+
+              <para>
+                Lists all messages for the specified subscription.
+             </para>
+
+             <para> There are two overloaded versions of this operation. One that takes a selector and one that does not.
+             By specifyingthe selector you can limit the messages returned.
+             </para>
+         </section>
+
+         <section id="conf.destination.topic.operations.listnondurablemessages">
+             <title>ListNonDurableMessages</title>
+
+              <para>
+                Lists all non durable messages for the specified subscription.
+             </para>
+
+             <para> There are two overloaded versions of this operation. One that takes a selector and one that does not.
+             By specifyingthe selector you can limit the messages returned.
+             </para>
+         </section>
+
+         <section id="conf.destination.topic.operations.listdurablemessages">
+             <title>ListDurableMessages</title>
+
+              <para>
+                Lists all durable messages for the specified subscription.
+             </para>
+
+             <para> There are two overloaded versions of this operation. One that takes a selector and one that does not.
+             By specifyingthe selector you can limit the messages returned.
+             </para>
+         </section>
+
+     </section>
+
+  </section>
+
+
+
+     <section id="conf.destination.new">
+        <title>Deploying a new destination</title>
+
+        <para>
+           For a JBoss 4.0.x installation, JBoss Messaging is deployed in its own class
+           loading domain. Because of that you need to deploy a new destinations to use
+           with JBoss Messaging within the same class loading domain.
+       </para>
+
+        <para>
+           To deploy a new destination, create a new deployment descriptor named
+           <filename>myqueue-service.xml</filename> (or anything else that ends in
+           <literal>-service.xml</literal>) and copy it to the JBoss instance deployment
+           directory <filename>$JBOSS_HOME/server/messaging/deploy</filename>.
+        </para>
+
+        <para>
+           An example of a scoped destination deployment descriptor is listed below:
+        </para>
+
+        <programlisting>
+&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
+&lt;server&gt;
+   &lt;loader-repository&gt;jboss.messaging:loader=ScopedLoaderRepository
+   &lt;loader-repository-config&gt;java2ParentDelegation=false&lt;/loader-repository-config&gt;
+   &lt;/loader-repository&gt;
+   &lt;mbean
+      code=&quot;org.jboss.jms.server.destination.Queue&quot;
+     name=&quot;jboss.messaging.destination:service=Queue,name=testQueue&quot;
+     xmbean-dd=&quot;xmdesc/Queue-xmbean.xml&quot;&gt;
+      &lt;depends optional-attribute-name=&quot;ServerPeer&quot;&gt;
+         jboss.messaging:service=ServerPeer
+      &lt;/depends&gt;
+      &lt;attribute name=&quot;SecurityConfig&quot;&gt;
+         &lt;security&gt;
+            &lt;role name=&quot;guest&quot; read=&quot;true&quot;write=&quot;true&quot;/&gt;
+            &lt;role name=&quot;publisher&quot; read=&quot;true&quot; write=&quot;true&quot; create=&quot;false&quot;/&gt;
+            &lt;role name=&quot;noacc&quot; read=&quot;false&quot; write=&quot;false&quot; create=&quot;false&quot;/&gt;
+          &lt;/security&gt;
+      &lt;/attribute&gt;
+      &lt;attribute name=&quot;fullSize&quot;&gt;75000&lt;/attribute&gt;
+      &lt;attribute name=&quot;pageSize&quot;&gt;2000&lt;/attribute&gt;
+      &lt;attribute name=&quot;downCacheSize&quot;&gt;2000&lt;/attribute&gt;
+   &lt;/mbean&gt;
+&lt;/server&gt;
+        </programlisting>
+
+     </section>
+  </section>
+
+  <section id="conf.connections">
+    <title>Configuring Connection Factories</title>
+
+    <para>
+       With the default configuration JBoss Messaging binds just one connection factory in
+       JNDI at start-up. This connection factory has no client ID and is bound into the
+       following JNDI contexts:
+       <literal>/ConnectionFactory, /XAConnectionFactory, java:/ConnectionFactory, java:/XAConnectionFactory</literal>
+    </para>
+
+    <para>
+       You may want to configure additional connection factories, for instance if you want to provide
+       a default client id for a connection factory, or if you want to bind it in different places
+       in JNDI, or if you want different connection factories to use different transports. Deploying
+       a new connection factory is equivalent with adding a new ConnectionFactory MBean
+       configuration to <filename>connection-factories-service.xml</filename>.
+    </para>
+     <para>
+        It is also possible to create an entirely
+        new service deployment descriptor <filename>xxx-service.xml</filename> altogether and
+        deploy it in <filename>$JBOSS_HOME/server/messaging/deploy</filename>.
+    </para>
+
+    <para>
+    Connection factories can either be clustered or non clustered.
+    Clustered connection factories create subsequent connections on different nodes of the cluster according to the load balancing policy.
+    The default load balancing policy is round robin.
+    </para>
+
+    <para>
+       An example connection factory configuration is presented below:
+     </para>
+
+      <programlisting>
+
+&lt;server&gt;
+   &lt;loader-repository&gt;
+      jboss.messaging:loader=ScopedLoaderRepository
+         &lt;loader-repository-config&gt;
+            java2ParentDelegation=false
+         &lt;/loader-repository-config&gt;
+   &lt;/loader-repository&gt;
+   &lt;mbean
+      code=&quot;org.jboss.jms.server.connectionfactory.ConnectionFactory&quot;
+      name=&quot;jboss.messaging.destination:service=ConnectionFactory&quot;
+      xmbean-dd=&quot;xmdesc/ConnectionFactory-xmbean.xml&quot;&gt;
+      &lt;constructor&gt;
+         &lt;arg type=&quot;java.lang.String&quot; value=&quot;myClientID&quot;/&gt;
+      &lt;/constructor&gt;
+      &lt;depends optional-attribute-name=&quot;ServerPeer&quot;&gt;
+         jboss.messaging:service=ServerPeer
+      &lt;/depends&gt;
+      &lt;depends optional-attribute-name=&quot;Connector&quot;&gt;
+         jboss.messaging:service=Connector,transport=socket
+      &lt;/depends&gt;
+      &lt;attribute name=&quot;PrefetchSize&quot;&gt;10&lt;/attribute&gt;
+      &lt;attribute name=&quot;DefaultTempQueueFullSize&quot;&gt;1000&lt;/attribute&gt;
+      &lt;attribute name=&quot;DefaultTempQueuePageSize&quot;&gt;50&lt;/attribute&gt;
+      &lt;attribute name=&quot;DefaultTempQueueDownCacheSize&quot;&gt;50&lt;/attribute&gt;
+      &lt;attribute name=&quot;JNDIBindings&quot;&gt;
+         &lt;bindings&gt;
+            &lt;binding&gt;/MyConnectionFactory1&lt;/binding&gt;
+            &lt;binding&gt;/factories/cf1&lt;/binding>&gt;
+         &lt;/bindings&gt;
+      &lt;/attribute&gt;
+   &lt;/mbean&gt;
+&lt;/server&gt;
+
+    </programlisting>
+
+     <para>
+        The above example would create a connection factory with pre-configured client ID
+        <literal>myClientID</literal> and bind the connection factory in two places in
+        the JNDI tree: <literal>/MyConnectionFactory</literal>
+        and <literal>/factories/cf</literal>. The connection factory will use the default
+        remoting connector. To use a different remoting connector with the connection factory
+        change the <literal>Connector</literal> attribute to specify the service name of the connector you wish to use.
+    </para>
+
+    <section id="conf.connectionfactory.attributes">
+
+       <title>
+           We now discuss the MBean attributes of the ConnectionFactory MBean
+       </title>
+
+       <section id="conf.destination.connectionfactory.attributes.clientid">
+           <title>ClientID</title>
+
+            <para>
+              Connection factories can be pre-configured with a client id. Any connections created using this connection factory will obtain this client id
+           </para>
+       </section>
+
+       <section id="conf.destination.connectionfactory.attributes.jndibindings">
+           <title>JNDIBindings</title>
+
+            <para>
+              Returns a list of the JNDI bindings for this connection factory
+           </para>
+       </section>
+
+     <section id="conf.destination.connectionfactory.attributes.prefetchsize">
+         <title>PrefetchSize</title>
+
+          <para>
+            Each client side consumer maintains a local buffer of messages from which it consumes. The server typically sends messages as fast as it can
+            to the consumer, and when the consumer is full it sends the server a "stop" message to say it is full.
+            When it clears enough space it sends a "start" message to ask the server to continue sending messages.
+            The prefetchSize determines the size of this buffer. Larger values give better throughput.
+         </para>
+       </section>
+
+     <section id="conf.destination.connectionfactory.attributes.tempqueuepaging">
+        <title>Temporary queue paging parameters</title>
+
+       <para>DefaultTempQueueFullSize, DefaultTempQueuePageSize, DefaultTempQueueDownCacheSize are optional attributes that determine the default paging parameters to be used for
+       any temporary destinations scoped to connections created using this connection factory. See the section on paging channels for more information
+       on what these values mean.
+       They will default to values of 200000, 2000 and 2000 respectively if ommitted.
+       </para>
+     </section>
+
+    <section id="conf.destination.connectionfactory.attributes.dupsokbatchsize">
+       <title>DupsOKBatchSize</title>
+
+      <para>When using a session with acknowledge mode of DUPS_OK_ACKNOWLEDGE this setting determines how many acknowledgments it will buffer locally
+      before sending. The default value is <literal>2000</literal>
+      </para>
+   </section>
+
+   <section id="conf.destination.connectionfactory.attributes.connector">
+          <title>Connector</title>
+
+         <para>This specifies which remoting connector this connection factory uses. Different connection factories can use different connectors.
+         </para>
+         <para>For instance you could deploy one connection factory that creates connections that use the HTTP transport to communicate to the server and another
+         that creates connections that use the bisocket transport to communicate.</para>
+   </section>
+
+   </section>
+
+</section>
+
+  <section id="conf.connector">
+      <title>Configuring the remoting connector</title>
+
+      <para>
+         JBoss Messaging uses JBoss Remoting  for all client to server communication.
+         For full details of what JBoss Remoting is capable of and how it is configured please
+         consult the JBoss Remoting documentation.
+      </para>
+
+      <para>
+         The default configuration includes a single remoting connector which is used by the
+         single default connection factory. Each connection factory can be configured to use
+         its own connector.
+      </para>
+
+      <para>
+         The default connector is configured to use the remoting bisocket transport. The bisocket transport is a TCP socket based transport
+         which only listens and accepts connections on the server side. I.e. connections are always initiated from the client side. This means
+         it works well in typical firewall scenarios where only inbound connections are allowed on the server. Or where onlu outbound connections are
+         allowed from the client.
+      </para>
+
+      <para>
+        The bisocket transport can be configured to use SSL where a higher level of security is required.
+        </para>
+
+      <para>
+        The other supported transport is the HTTP transport. This uses the HTTP protocol to communicate between client and server. Data is received on the client
+        by the client periodically polling the server for messages. This transport is well suited to situations where there is a firewall between client and server
+        which only allows incoming HTTP traffic on the server.
+        Please note this transport will not be as performant as the bisocket transport due to the nature of polling and the HTTP protocl. Also please note it is not
+        designed for high load situations.
+      </para>
+
+      <para>No other remoting transports are currently supported by JBoss Messaging</para>
+
+       <para>
+         You can look at remoting configuration under:
+       </para>
+
+       <para>
+          &lt;JBoss&gt;/server/&lt;YourMessagingServer&gt;/deploy/jboss-messaging.sar/remoting-service.xml
+       </para>
+
+       <para>
+          By default JBoss Messaging binds to ${jboss.bind.address} which can be defined by:
+          ./run.sh -c &lt;yourconfig&gt; -b yourIP.
+       </para>
+
+       <para>
+          You can change remoting-service.xml if you want for example use a
+          different communication port.
+       </para>
+
+       <warning>Please be wary of changing other settings as they can have an adverse effect on the system</warning>
+
+  </section>
+
+  <section id="conf.servicebindingmanager">
+     <title>ServiceBindingManager</title>
+
+     <para>If you are using the JBoss AS ServiceBindingManager to provide different servers with different port ranges, then you must make sure that the JBoss Messaging
+     remoting configuration specified in the JBoss Messaging section of the ServiceBindingManager xml file exactly matches that in remoting-service.xml
+    </para>
+  </section>
+
+  <section id="conf.callback">
+      <title>Configuring the callback</title>
+
+      <para>
+         JBoss Messaging uses a callback mechanism from Remoting that needs a Socket for callback operations. These socket properties are passed to the server by a remote call when the connection is being estabilished. As we said before we will support bidirectional protocols in future releases.
+      </para>
+
+      <para>
+         By default JBoss Messaging will execute InetAddress.getLocalHost().getHostAddress() to access your local host IP, but in case you need to setup a different IP, you can define a system property in your java arguments:
+      </para>
+
+      <para>
+      Use java -Djboss.messaging.callback.bind.address=YourHost - That will determine the callBack host in your client.
+      </para>
+
+      <para>
+      The client port will be selected randomly for any non used port. But if you defined -Djboss.messaging.callback.bind.port=NumericPort in your System Properties that number is going to be used for the call back client port.
+      </para>
+
+  </section>
+</chapter>

Copied: trunk/docs/userguide/en/modules/gettingstarted.xml (from rev 2534, trunk/docs/userguide/en/modules/UG12_gettingstarted.xml)
===================================================================
--- trunk/docs/userguide/en/modules/gettingstarted.xml	                        (rev 0)
+++ trunk/docs/userguide/en/modules/gettingstarted.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -0,0 +1,130 @@
+<chapter id="gettingstarted">
+   <title>Download Software</title>
+
+   <para>
+      The official releases of JBoss Messaging are available as a free download from
+      <ulink url="http://www.jboss.com/products/messaging">the JBoss Messaging project landing page</ulink>.
+   </para>
+
+   <para>
+       The recommended download location is the JBoss Labs Messaging Project download zone:
+       <ulink url="http://labs.jboss.com/portal/jbossmessaging/downloads">http://labs.jboss.com/portal/jbossmessaging/downloads</ulink>
+       We also maintain an alternate download location on sourceforge.net:
+       <ulink url="http://sourceforge.net/project/showfiles.php?group_id=22866&amp;package_id=157261">http://sourceforge.net/project/showfiles.php?group_id=22866&amp;package_id=157261</ulink>
+   </para>
+
+   <section id="releasebundle">
+      <title>The JBoss Messaging Release Bundle</title>
+
+      <para>
+         The JBoss Messaging release bundle (<filename>jboss-messaging-1.2.x.zip</filename>)
+         will expand in a <filename>jboss-messaging-1.2.x</filename> directory that contains:
+      </para>
+
+      <itemizedlist>
+         <listitem>
+            <filename>jboss-messaging-scoped.sar</filename>
+            - the scoped JBoss service archive that contains JBoss Messaging and its
+            dependencies.
+            <warning>
+               Do not simply attempt to copy the archive under a JBoss instance <filename>deploy</filename> directory,
+               since additional steps (such as un-installing JBossMQ and various other configurations
+               tasks) are required for a successful installation. See <xref linkend="installation"/> for
+               more details.
+            </warning>
+         </listitem>
+         <listitem>
+            <filename>jboss-messaging-client.jar</filename>
+            - the client-side library that need to be in the classpath of the client that opens
+            a remote connection to the Messaging server.
+
+            <note>
+                <para>
+                This is an important note on the Messaging client jar. JBoss Messaging has an
+                extensive tree of dependencies and bundling all right dependencies in one easy
+                to use archive, so no wrong versions inadvertently get in the class path is, as
+                experience shows, extremely convenient. However, this could cause problems if a
+                different version of a dependency is required by the user's client code.
+                </para>
+                <para>
+                If, for example, the log4j.jar bundled with the release causes problems for being
+                too old, one could just simply build the client-side class path so a newer version
+                of log4j.jar precedes jboss-messaging-client.jar in that class path. This approach
+                may work, but is not guaranteed to work, because we did not run the full test suite
+                with any other log4j.jar version except the one we bundle with the release.
+
+                Soon we will providing an ant task that creates a slimmed down client jar without the extra
+                dependencies bundled.
+                </para>
+
+                <para>
+                 A list of required dependencies for a specific release can be found in the
+                 <filename>build-thirdpary.xml</filename> file that is part of the companion source
+                 bundle that ships with each release. It can also be looked up online in
+                  <ulink url="http://fisheye.jboss.org">http://fisheye.jboss.org</ulink>.
+                </para>
+            </note>
+         </listitem>
+         <listitem>
+            <filename>util</filename>
+            - a collection of <literal>ant</literal> configuration files used to automate
+            installation and release
+            management procedures. See <xref linkend="installation"/> for
+             more details.
+         </listitem>
+         <listitem>
+            <filename>examples</filename>
+            - a collection of examples that should run out of the box and help you validate the
+            installation. Detailed instructions are provided with each example, which range from
+            very simple JMS queue and topic examples to relatively sophisticated use cases in which
+            EJBs and JCA JMS ConnectionFactories are involved, as well as clustering use cases.
+            The <filename>examples/config</filename> sub-directory contains various configuration
+            file examples.
+         </listitem>
+         <listitem>
+           <filename>docs</filename>
+            - this user's guide.
+         </listitem>
+         <listitem>
+           <filename>src/jboss-messaging-1.2.x-src.zip</filename>
+            - the zipped source directory. The file can be directly installed into and used
+            with a debugger.
+         </listitem>
+         <listitem>
+            <filename>test-results</filename>
+            - the output of the functional testsuite, stress and smoke test runs for this release.
+            All these files have been generated during the release procedure and are bundled here
+            for reference.
+         </listitem>
+         <listitem>
+            <filename>api</filename>
+            - the Messaging API javadoc.
+         </listitem>
+         <listitem>
+            <filename>README.html</filename>
+            - The release intro document that contains pointers to various other resources,
+            including this Guide.
+         </listitem>
+      </itemizedlist>
+
+   </section>
+
+
+   <section id="SVN">
+      <title>SVN Access</title>
+
+      <para>
+         If you want to experiment with the latest developments you may checkout the latest code
+         from the Messaging SVN trunk. Be aware that the information provided in this manual might
+         then not be accurate.
+         For the latest instructions on how to check out and build source code, please go to
+         <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMessagingDevelopment">
+            Messaging Development wiki page</ulink>, specifically
+
+         <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMessagingBuildInstructions">
+          "Building and Running JBoss Messaging"</ulink> section.
+      </para>
+
+   </section>
+
+</chapter>
\ No newline at end of file

Copied: trunk/docs/userguide/en/modules/installation.xml (from rev 2534, trunk/docs/userguide/en/modules/UG12_installation.xml)
===================================================================
--- trunk/docs/userguide/en/modules/installation.xml	                        (rev 0)
+++ trunk/docs/userguide/en/modules/installation.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -0,0 +1,243 @@
+<chapter id="installation">
+  <title>JBoss Messaging Non-Clustered Installation</title>
+
+   <para>
+      This section describes the procedure to perfom a non-clustered installation. At the
+      end of this procedure, you will create a JBoss Messaging configuration that will
+      start a non-clustered messaging server. To find out how you can install JBoss Messaging
+      in a clustered configuration, please proceed to <xref linkend="c_installation"/>.
+   </para>
+
+   <para>
+      By default, a JBoss AS 4.0.x and 4.2.0 instance ships with JBossMQ as default JMS provider.
+      In order to use the JBoss AS instance with JBoss Messaging, you need to perform the
+      installation procedure described below.
+   </para>
+
+   <para>
+      <warning>
+         A JBossMQ and a JBoss Messaging instance cannot coexist, at least not unless special
+         precautions are taken. Do not simply attempt to copy the Messaging release artifact
+         <filename>jboss-messaging-scoped.sar</filename> over to the JBoss instance
+         <filename>deploy</filename> directory. Follow one of the alternate installation procedures
+         outlined below instead.
+      </warning>
+   </para>
+
+
+  <section id="install4">
+     <title>Installing JBoss Messaging with JBoss AS 4.0.x and 4.2.1</title>
+
+      <note>
+          You need Apache ant 1.7.0 or newer pre-installed on your system and available in
+          you path in order to be able to perform the installation process described below.
+      </note>
+
+    <section id="install4.automated">
+     <title>Installation procedure</title>
+
+      <para>
+         Set up the <literal>JBOSS_HOME</literal> environment variable to point to
+         the JBoss 4.x installation you want to use JBoss Messaging with. Run the installation
+         script, available in the  <filename>util</filename> directory of the release bundle.
+      </para>
+
+       <programlisting>
+cd util
+ant -f release-admin.xml
+       </programlisting>
+
+        <para>
+            The installation script will create a <filename>$JBOSS_HOME/server/messaging</filename>
+            configuration.
+        </para>
+
+       <note>
+          If you want to create a JBoss Messaging configuration with a different name, modify
+          the <literal>messaging.config.name</literal> system property declared at the beginning of
+           the installation script accordingly.
+       </note>
+    </section>
+
+  </section>
+
+  <section id="startingtheservice">
+     <title>Starting the Server</title>
+
+
+     <para>
+        To run the server, execute the <filename>run.bat</filename> or <filename>run.sh</filename>
+        script as appropriate for your operating system, in the <filename>$JBOSS_HOME/bin</filename>
+        directory.
+     </para>
+
+   <programlisting>
+cd $JBOSS_HOME/bin
+./run.sh -c messaging
+   </programlisting>
+
+     <para>
+        A successful JBoss Messaging deployment generates logging output similar to:
+     </para>
+
+   <programlisting>
+....
+01:44:48,317 WARN  [JDBCPersistenceManager]
+
+JBoss Messaging Warning: DataSource connection transaction isolation should be
+       READ_COMMITTED, but it is currently NONE.
+       Using an isolation level less strict than READ_COMMITTED may lead to data
+       consistency problems.
+       Using an isolation level more strict than READ_COMMITTED may lead to deadlock.
+
+01:44:50,450 INFO  [ServerPeer] JBoss Messaging 1.2.0.GA server [0] started
+01:44:51,311 INFO  [ConnectionFactory] Connector bisocket://192.168.1.104:4457 has
+leasing enabled, lease period 10000 milliseconds
+01:44:51,311 INFO  [ConnectionFactory] [/ConnectionFactory, /XAConnectionFactory,
+java:/ConnectionFactory, java:/XAConnectionFactory] started
+01:44:51,441 INFO  [ConnectionFactory] Connector bisocket://192.168.1.104:4457 has
+leasing enabled, lease period 10000 milliseconds
+01:44:51,441 INFO  [ConnectionFactory] [/NonClusteredConnectionFactory,
+/NonClusteredXAConnectionFactory, java:/NonClusteredConnectionFactory,
+java:/NonClusteredXAConnectionFactory] started
+01:44:51,681 INFO  [QueueService] Queue[/queue/DLQ] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,681 INFO  [QueueService] Queue[/queue/ExpiryQueue] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,732 INFO  [TopicService] Topic[/topic/testTopic] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,732 INFO  [TopicService] Topic[/topic/securedTopic] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,732 INFO  [TopicService] Topic[/topic/testDurableTopic] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,752 INFO  [QueueService] Queue[/queue/testQueue] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,752 INFO  [QueueService] Queue[/queue/A] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,762 INFO  [QueueService] Queue[/queue/B] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,762 INFO  [QueueService] Queue[/queue/C] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,882 INFO  [QueueService] Queue[/queue/D] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,882 INFO  [QueueService] Queue[/queue/ex] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,882 INFO  [QueueService] Queue[/queue/PrivateDLQ] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,892 INFO  [QueueService] Queue[/queue/PrivateExpiryQueue] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,892 INFO  [QueueService] Queue[/queue/QueueWithOwnDLQAndExpiryQueue] started,
+fullSize=200000, pageSize=2000, downCacheSize=2000
+01:44:51,892 INFO  [TopicService] Topic[/topic/TopicWithOwnDLQAndExpiryQueue] started,
+fullSize=200000, pageSize=2000, downCacheSize=2000
+01:44:51,942 INFO  [QueueService] Queue[/queue/QueueWithOwnRedeliveryDelay] started,
+fullSize=200000, pageSize=2000, downCacheSize=2000
+01:44:51,942 INFO  [TopicService] Topic[/topic/TopicWithOwnRedeliveryDelay] started,
+fullSize=200000, pageSize=2000, downCacheSize=2000
+01:44:51,952 INFO  [QueueService] Queue[/queue/testDistributedQueue] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:51,952 INFO  [TopicService] Topic[/topic/testDistributedTopic] started, fullSize=200000,
+pageSize=2000, downCacheSize=2000
+01:44:52,372 INFO  [ConnectionFactoryBindingService] Bound ConnectionManager
+'jboss.jca:name=JmsXA,service=ConnectionFactoryBinding' to JNDI name 'java:JmsXA'
+....
+   </programlisting>
+
+     <note>
+        The warning message <literal>DataSource connection transaction isolation should be READ_COMMITTED,
+        but it is currently NONE</literal>
+        is there to remind you that by default JBossAS ships with Hypersonic, an in-memory
+        Java-based database engine, which is apropriate for demo purposes, but not for heavy load
+        production environments. The
+        <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=ConfigJBossMQDB">Critique of Hypersonic</ulink>
+        wiki page outlines some of the well-known issues occuring when using this database.
+     </note>
+
+     <warning>
+        Before using Messaging in production, you <emphasis>must</emphasis> configure
+        the Messaging instance to use an enterprise-class database backend such as MySQL or Oracle,
+        otherwise you risk losing your data.
+        See <xref linkend="conf.changingds"/> for details about replacing Hypersonic.
+     </warning>
+  </section>
+
+
+  <section id="inst.validation">
+     <title>Installation Validation</title>
+
+     <para>
+        The release bundle contains a series of examples that should run "out of the box" and
+        could be used to validate a new installation. Such an example sends a persistent JMS message
+        to a queue called <literal>queue/testQueue</literal>.
+     </para>
+
+
+    <para>
+       To run the example and validate the installation,
+       open an new command line window and set the <literal>JBOSS_HOME</literal>
+       environment variable to point to the JBoss AS 4.x installation you've just installed
+       Messaging on. Navigate to the folder where
+       you extracted the release bundle and drill down to <filename>/examples/queue</filename>.
+       Apache Ant must pe present in your path in order to be able to run the example.
+    </para>
+
+   <programlisting>
+
+setenv JBOSS_HOME=&lt;your_JBoss_installation&gt;
+cd .../examples/queue
+$ant
+
+   </programlisting>
+
+     <para>
+        A successfull execution log output looks similar to:
+     </para>
+
+
+        <programlisting>
+$ ant
+Buildfile: build.xml
+
+identify:
+[echo] ###########################################################################
+[echo] #                       Running the QUEUE example                         #
+[echo] ###########################################################################
+[echo] The queue:      testQueue
+[echo] The client jar: ../../../output/lib/jboss-messaging-client.jar
+
+sanity-check:
+
+init:
+[mkdir] Created dir: c:\work\src\svn\messaging\docs\examples\queue\output
+[mkdir] Created dir: c:\work\src\svn\messaging\docs\examples\common\output
+
+compile:
+[javac] Compiling 5 source files to c:\work\src\svn\messaging\docs\examples\common\output
+[javac] Compiling 1 source file to c:\work\src\svn\messaging\docs\examples\queue\output
+
+run:
+   [java] Queue /queue/testQueue exists
+   [java] The message was successfully sent to the testQueue queue
+   [java] Received message: Hello!
+   [java] The example connected to JBoss Messaging version 1.2.0.GA (1.2)
+   [java]
+   [java] #####################
+   [java] ###    SUCCESS!   ###
+   [java] #####################
+
+BUILD SUCCESSFUL
+Total time: 9 seconds
+</programlisting>
+
+
+     <para>
+        It is recommended to run <literal>all</literal> validation examples available in the
+        <filename>example</filename> directory (<filename>queue</filename>,
+        <filename>topic</filename>, <filename>mdb</filename>, <filename>stateless</filename>, etc.).
+         In <xref linkend="examples"/>, we will have a look at each of those examples.
+     </para>
+
+
+  </section>
+
+</chapter>

Copied: trunk/docs/userguide/en/modules/introduction.xml (from rev 2534, trunk/docs/userguide/en/modules/UG12_introduction.xml)
===================================================================
--- trunk/docs/userguide/en/modules/introduction.xml	                        (rev 0)
+++ trunk/docs/userguide/en/modules/introduction.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -0,0 +1,285 @@
+<chapter id="introduction">
+
+   <title>Introduction</title>
+
+   <para>
+      JBoss Messaging provides an open source and standards-based messaging platform that brings
+      enterprise-class messaging to the mass market.
+   </para>
+
+   <para>
+      JBoss Messaging implements a high performance, robust messaging core that is designed to
+      support the largest and most heavily utilized SOAs, enterprise service buses (ESBs) and other
+      integration needs ranging from the simplest to the highest demand networks.
+      It will allow you to smoothly distribute your application load across your cluster,
+      intelligently balancing and utilizing each nodes CPU cycles, with no single point of failure,
+      providing a highly scalable and perform-ant clustering implementation. JBoss Messaging includes
+      a JMS front-end to deliver messaging in a standards-based format as well as being designed to be
+     able to support other messaging protocols in the future.
+   </para>
+
+   <para>
+      JBoss Messaging will soon become an integral component of the JBoss Enterprise Middleware
+      Suite (JEMS). Currently it
+      is available for embedded use within the JBoss Application Server (JBossAS), and as a
+      JBoss Microkernel-based stand-alone server. Work to integrate JBoss Messaging with the new
+      JBoss Microcontainer is under way.
+   </para>
+
+   <para>
+      The large and vibrant JEMS developer community fosters its continued innovation and
+      enterprise quality. JBoss Messaging enables more agile applications in a wide range of
+      scenarios from simple messaging needs to an enterprise-wide messaging foundation and adds
+      flexibility to any SOA initiative.
+   </para>
+
+   <section id="support">
+      <title>JBoss Messaging support cover from Red Hat</title>
+
+      <para>JBoss Messaging 1.2.GA support is available via the......</para>
+
+   </section>
+
+   <section id="features">
+      <title>JBoss Messaging 1.2.0.GA Features</title>
+
+      <para>
+         JBoss Messaging provides:
+      </para>
+
+      <itemizedlist>
+         <listitem>
+            <para>
+               A fully compatible and Sun certified JMS 1.1 implementation, that currently works
+               with a standard JBossAS 4.0.x, 4.2.x and JBoss 5.x installation and also as a JBoss
+               Microkernel-based standalone deployment.
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               A strong focus on performance, reliability and scalability with high throughput and
+               low latency. JBoss Messaging already exceeds JBoss MQ in a number of measured
+               performance metrics. Full results will follow.
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               A foundation for JBoss ESB for SOA initiatives; JBoss ESB uses
+               JBoss Messaging as its foundation.
+            </para>
+         </listitem>
+      </itemizedlist>
+
+      <para>
+         JBoss Messaging consists of two major parts:
+      </para>
+
+      <itemizedlist>
+         <listitem>
+            <para>
+               JBoss Messaging Core – a transactional, reliable messaging transport system.
+            </para>
+            <itemizedlist>
+               <listitem>
+                  <para>
+                     Supports generalized messages (not just JMS)
+                  </para>
+               </listitem>
+               <listitem>
+                  <para>
+                     Enables other messaging protocol façades to be added
+                  </para>
+               </listitem>
+               <listitem>
+                  <para>
+                     Distributed, transactional and reliable
+                  </para>
+               </listitem>
+            </itemizedlist>
+         </listitem>
+
+         <listitem>
+            <para>
+               JMS Façade – the JMS "personality" of JBoss Messaging.
+            </para>
+         </listitem>
+      </itemizedlist>
+
+      <para>
+         Other JBoss Messaging features include:
+      </para>
+
+      <itemizedlist>
+         <listitem>
+            <para>
+               Publish-subscribe and point-to-point messaging models
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               Topics that feed multiple message queues
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               Persistent and non-persistent messages
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               Guaranteed message delivery that ensures that messages arrive once and only once
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               Transactional and reliable  - supporting ACID semantics
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               Customizable security framework based on JAAS
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               Fully integrated with JBoss Transactions (formerly known as Arjuna JTA) for full transaction recoverability.
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               Extensive JMX management interface
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               Support for most major databases including Oracle, Sybase, MS SQL Server, PostgreSQL and MySQL
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               HTTP transport
+            </para>
+         </listitem>
+      </itemizedlist>
+
+      <para>
+         JBoss Messaging 1.2.0.GA Clustering provides the following features:
+      </para>
+
+      <itemizedlist>
+         <listitem>
+            <para>
+               Distributed queues. Messages sent to a distributed queue while attached to a
+               particular node will be routed to a queue instance on a particular node according
+               to a routing policy.
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               Distributed topics. Messages sent to a distributed topic while attached at a
+               particular node will be received by subscriptions on other nodes.
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+               Fully reliable message distribution. Once and only once delivery is fully guaranteed.
+               When sending messages to a topic with multiple durable subscriptions
+               across a cluster we guarantee that message reaches all the subscriptions
+               (or none of them in case of failure).
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+                  Pluggable routing implementation. The policy for routing messages to a queue is fully
+                     pluggable and easily replaceable. The default policy always chooses a queue at the local
+                     node if there is one, and if not, it round robins between queues on different nodes.
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+                  Intelligent message redistribution policy. Messages are automatically distributed between
+                     nodes depending on how fast or slow consumers are on certain nodes. If there are no or slow
+                     consumers on a particular queue node, messages will be pulled from that queue to a queue with
+                     faster consumers on a different node. The policy is fully pluggable.
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+                  Shared durable subscriptions. Consumers can connect to the same durable subscription while
+                     attached to different nodes. This allows processing load from durable subscriptions to be
+                     distributed across the cluster in a similar way to queues.
+            </para>
+         </listitem>
+         <listitem>
+            <para>
+                  High availability and seamless fail-over. If the node you are connected to fails, you
+                     will automatically fail over to another node and will not lose any persistent messages.
+                     You can carry on with your session seamlessly where you left off. Once and only once
+                     delivery of persistent messages is respected at all times.
+         </para>
+         </listitem>
+         <listitem>
+            <para>
+               Message bridge. JBoss Messaging 1.2 contains a message bridge component which enables you to bridge messages between any two JMS1.1 destinations
+               on the same or physical separate locations. (E.g. separated by a WAN)
+         </para>
+         </listitem>
+      </itemizedlist>
+
+
+   </section>
+
+
+   <section id="compatibility">
+      <title>Compatibility with JBossMQ</title>
+
+      <para>
+         JBossMQ is the JMS implementation currently shipped within JBossAS.
+         Since JBoss Messaging is JMS 1.1 and JMS 1.0.2b compatible, the JMS code  written against
+         JBossMQ will run with JBoss Messaging without any changes.
+      </para>
+
+      <important>
+         Even if JBoss Messaging deployment descriptors are very similar to JBoss MQ
+         deployment descriptors, they are <emphasis>not</emphasis> identical, so they will require
+         some simple adjustments to get them to work with JBoss Messaging. Also, the database
+         data model is completely different, so don't attempt to use JBoss Messaging with a JBossMQ
+         data schema and vice-versa.
+      </important>
+   </section>
+
+   <section id="missingfeatures">
+      <title>
+      Features not yet available in the 1.2.0.GA release, but coming soon
+      </title>
+
+      <para>
+    All the final features are available apart from:
+    </para>
+
+    <itemizedlist>
+
+        <listitem>
+           <para>
+              In a very near future, it will be possible to guarantee persistent level reliability
+               guarantee without persistence. By replicating persistent messages between nodes in
+               memory, we can obtain comparable reliability levels to persisting messages to disk,
+               without actually storing them to disk. However, this feature is not available
+               in the 1.2.0.GA release. If you're interested in how this feature will be available,
+               this is the JIRA issue you can use to track it:
+               <ulink url="http://jira.jboss.org/jira/browse/JBMESSAGING-574">http://jira.jboss.org/jira/browse/JBMESSAGING-574</ulink>
+           </para>
+        </listitem>
+
+        <listitem>
+            <para>
+                The "unreliable link scenario"
+                <ulink url="http://jira.jboss.org/jira/browse/JBMESSAGING-676">http://jira.jboss.org/jira/browse/JBMESSAGING-676</ulink>
+                whose development is still on-going on a parallel branch.
+            </para>
+        </listitem>
+
+    </itemizedlist>
+    </section>
+
+</chapter>

Copied: trunk/docs/userguide/en/modules/performance.xml (from rev 2534, trunk/docs/userguide/en/modules/UG12_performance.xml)
===================================================================
--- trunk/docs/userguide/en/modules/performance.xml	                        (rev 0)
+++ trunk/docs/userguide/en/modules/performance.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -0,0 +1,185 @@
+<chapter id="performance">
+
+  <title>Generating Performance Benchmark Results</title>
+
+  <para>
+      As we discussed in <xref linkend="about"/>, the key advantage of JBoss Messaging is
+      its superior performance. In fact, the JBoss Messaging comes with a set of standard
+      performance test. You can run them on your server and generate your own performance
+      benchmark results. In this chapter, we will show you how to run a JBoss Messaging server
+      and a JBossMQ server side-by-side on a single machine, and compare their performance.
+      To get the performance tests, you have to obtain the JBoss Messaging source code from SVN
+      as described in <xref linkend="gettingstarted"/>.
+  </para>
+
+  <para>
+    To get the performance tests, you first need to check out the source code and build the project. The location of the framework's source code will be
+    referred to as $PERF_HOME throughout the rest of the document.
+  </para>
+
+  <programlisting>
+svn co https://svn.jboss.org/repos/messaging/projects/perf/trunk messaging-perf
+cd $PERF_HOME
+ant
+  </programlisting>
+
+  <para>The test consists in sending bursts of 1000 0 Kilobytes non-persistent messages to both JBoss Messaging and JBossMQ instances while gradually increasing the send rate (200 messages/sec, 400 messages/sec, etc) and measuring the receive rate. At the end, the framework generates the graph representing the receive rate as function of the send rate for two executions (JBoss Messaging and JBossMQ).</para>
+
+  <section>
+    <title>Run JBoss Messaging and JBossMQ Side-by-side</title>
+
+    <para>
+        To run performance tests side-by-side on the same machine, we assume that you create
+        two JBoss AS configurations with the JBoss Messaging and JBossMQ modules respectively.
+        We assume that the JBoss Messaging module is installed in the
+        <literal>server/messaging</literal> directory (see <xref linkend="installation"/>),
+        and the default JBossMQ module is installed in <literal>server/jbossmq</literal>
+        directory (just copy the original <literal>default</literal> directory that comes with
+        the server).</para>
+
+    <para>Now, if you run the two configurations on the same server, there will be port conflicts. To avoid that, we use the JBoss <literal>ServiceBindingManager</literal> to increase the port numbers in the <literal>jbossmq</literal> configuration by 100 (i.e., the JNDI service will be available at port 1199 instead of 1099). To do that, un-comment the following line in <literal>server/jbossmq/conf/jboss-service.xml</literal></para>
+
+    <programlisting>
+&lt;mbean code="org.jboss.services.binding.ServiceBindingManager"
+       name="jboss.system:service=ServiceBindingManager">
+
+  &lt;attribute name="ServerName">ports-01&lt;/attribute>WWWr
+  &lt;attribute name="StoreURL">
+    ../docs/examples/binding-manager/sample-bindings.xml
+  &lt;/attribute>
+  &lt;attribute name="StoreFactoryClassName">
+    org.jboss.services.binding.XMLServicesStoreFactory
+  &lt;/attribute>
+&lt;/mbean>
+    </programlisting>
+
+    <para>Now, you can start the <literal>messaging</literal> and <literal>jbossmq</literal> configurations side-by-side for testing.</para>
+
+    <programlisting>
+run -c messaging
+run -c jbossmq
+    </programlisting>
+
+  </section>
+sssssssssssd
+  <section>
+    <title>Setup the Tests</title>
+
+    <para>The performance framework relies on distributed executors to send messages into the providers being tested. The executors can run standalone in their own VM and act as "remote" JMS connections, or colocated, in which case they are deployed as JBoss services and simulate "colocated" JMS connections.</para>
+
+    <para>In order to correctly deploy the colocated executors, the framework relies on the <literal>JBOSS_HOME</literal> environment variable. It assumes directories <literal>$JBOSS_HOME/server/messaging</literal> and <literal>$JBOSS_HOME/server/jbossmq</literal> exist.</para>
+
+    <programlisting>
+ant sar
+ant start-executors
+    </programlisting>
+
+    <para>Next, we need to deploy test message destinations. They are in the <literal>messaging-destinations-service.xml</literal>, <literal>jbossmq-destinations-service.xml</literal> files. Feel free to add your own destinations (must add equivalent ones in both files) and then deploy them via the following command.</para>
+
+    <programlisting>
+ant deploy-destinations
+    </programlisting>
+
+  </section>
+
+  <section>
+    <title>Configure Test Runs</title>
+
+    <para>The <literal>etc/perf.xml</literal> file is used to configure tests. In our setting (i.e., <literal>jbossmq</literal> runs in +100 port range from default), the <literal>&lt;providers></literal> section should look like the following. We can easily run the two JMS server configurations on different machines or in other port ranges. You just need to change the host and port numbers here for tests.</para>
+
+    <programlisting>
+&lt;provider name="JBossMessaging">
+  &lt;factory>org.jnp.interfaces.NamingContextFactory&lt;/factory>
+  &lt;url>jnp://localhost:1099&lt;/url>
+  &lt;pkg>org.jboss.naming:org.jnp.interfaces&lt;/pkg>
+  &lt;executor name="REMOTE" url="rmi://localhost:7777/standalone"/>
+  &lt;executor name="REMOTE2" url="rmi://localhost:7777/standalone2"/>
+  &lt;executor name="COLOCATED" url="rmi://localhost:7777/local-messaging"/>
+  &lt;executor name="COLOCATED2" url="rmi://localhost:7777/local-messaging2"/>
+&lt;/provider>
+
+&lt;provider name="JBossMQ">
+  &lt;factory>org.jnp.interfaces.NamingContextFactory&lt;/factory>
+  &lt;url>jnp://localhost:1199&lt;/url>
+  &lt;pkg>org.jboss.naming:org.jnp.interfaces&lt;/pkg>
+  &lt;executor name="REMOTE" url="rmi://localhost:7777/standalone"/>
+  &lt;executor name="REMOTE2" url="rmi://localhost:7777/standalone2"/>
+  &lt;executor name="COLOCATED" url="rmi://localhost:7777/local-jbossmq"/>
+  &lt;executor name="COLOCATED2" url="rmi://localhost:7777/local-jbossmq2"/>
+&lt;/provider>
+    </programlisting>
+
+    <para>The performance configuration section configures how to ramp up the load from 200 messages / sec to 3000 message / sec. We will gather statistics on the number of processed messages versus the number of sent messages.</para>
+
+    <programlisting>
+&lt;performance-test name="Throughput O KB Message
+   Non-Persistent Non-Transactional, 1 sender, 1 receiver">
+
+  &lt;message-size>0&lt;/message-size>
+  &lt;messages>10000&lt;/messages>
+
+  &lt;drain/>
+
+  &lt;parallel>
+    &lt;send rate="200" executor="COLOCATED"/>
+    &lt;receive executor="COLOCATED2"/>
+  &lt;/parallel>
+
+  &lt;parallel>
+    &lt;send rate="400" executor="COLOCATED"/>
+    &lt;receive executor="COLOCATED2"/>
+  &lt;/parallel>
+
+  &lt;parallel>
+    &lt;send rate="800" executor="COLOCATED"/>
+    &lt;receive executor="COLOCATED2"/>
+  &lt;/parallel>
+
+  &lt;parallel>
+    &lt;send rate="1000" executor="COLOCATED"/>
+    &lt;receive executor="COLOCATED2"/>
+  &lt;/parallel>
+
+  &lt;parallel>
+    &lt;send rate="1500" executor="COLOCATED"/>
+    &lt;receive executor="COLOCATED2"/>
+  &lt;/parallel>
+
+  &lt;parallel>
+    &lt;send rate="2000" executor="COLOCATED"/>
+    &lt;receive executor="COLOCATED2"/>
+  &lt;/parallel>
+
+  &lt;parallel>
+    &lt;send rate="2500" executor="COLOCATED"/>
+    &lt;receive executor="COLOCATED2"/>
+  &lt;/parallel>
+
+  &lt;parallel>
+    &lt;send rate="3000" executor="COLOCATED"/>
+    &lt;receive executor="COLOCATED2"/>
+  &lt;/parallel>
+
+  &lt;execution provider="JBossMessaging"/>
+  &lt;execution provider="JBossMQ"/>
+
+&lt;/performance-test>
+    </programlisting>
+
+  </section>
+
+  <section>
+    <title>Run the Tests</title>
+
+    <para>To run the tests, simply execute <literal>ant run</literal> from the command line. You can access the benchmark result graphs from <literal>output/results/benchmark-results.html</literal>.</para>
+
+    <para>After running the test, you can clean up the executors and test destinations using the following commands.</para>
+
+    <programlisting>
+ant stop-executors
+ant undeploy-destinations
+    </programlisting>
+
+  </section>
+
+</chapter>
\ No newline at end of file

Copied: trunk/docs/userguide/en/modules/runningexamples.xml (from rev 2534, trunk/docs/userguide/en/modules/UG12_runningexamples.xml)
===================================================================
--- trunk/docs/userguide/en/modules/runningexamples.xml	                        (rev 0)
+++ trunk/docs/userguide/en/modules/runningexamples.xml	2007-03-01 17:59:50 UTC (rev 2535)
@@ -0,0 +1,777 @@
+<chapter id="examples">
+
+  <title>Running the Examples</title>
+
+  <para>
+      Since JBoss Messaging is a fully compliant JMS 1.1 provider, it supports the entire JMS 1.1 API. So, all
+      JMS applications should work without modification. Integrated inside a JBoss AS, we should
+      also be able access the JMS system from EJBs and write message-driven beans against JMS
+      destinations.
+  </para>
+
+
+  <para>
+      In the following sections, we will look at examples of the various JMS messaging models
+      and message-driven beans. They make use of pre-configured JMS destinations and connection
+      factories that come default with the server. So, no extra configuration is needed to run
+      those examples. Just set JBOSS_HOME and run <literal>ant</literal> in each example
+      directory, as we described in <xref linkend="inst.validation"/>. The example source
+      directories are located in the distribution under <literal>docs/examples</literal>.
+  </para>
+
+  <section id="examples.queue">
+    <title>Sending messages to a queue</title>
+
+    <para>
+    Open an new command line. Set the JBOSS_HOME environment variable to point at a JBossAS 4.x
+    installation. Navigate to the folder where you exploded the main archive and drill down to
+    <literal>/examples/queue</literal>. You need to use Apache <literal>ant</literal> to execute
+    the <literal>build.xml</literal> file.
+    </para>
+
+    <para>
+        Make sure the JBoss server reference by the JBOSS_HOME is started.
+   </para>
+
+    <programlisting>
+public class QueueExample extends ExampleSupport
+{
+
+   public void example() throws Exception
+   {
+      String destinationName = getDestinationJNDIName();
+
+      InitialContext ic = null;
+      ConnectionFactory cf = null;
+      Connection connection =  null;
+
+      try
+      {
+         ic = new InitialContext();
+
+         cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+         Queue queue = (Queue)ic.lookup(destinationName);
+         log("Queue " + destinationName + " exists");
+
+         connection = cf.createConnection();
+         Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageProducer sender = session.createProducer(queue);
+
+         TextMessage message = session.createTextMessage("Hello!");
+         sender.send(message);
+         log("The message was successfully sent to the " + queue.getQueueName() + " queue");
+
+         MessageConsumer consumer =  session.createConsumer(queue);
+
+         connection.start();
+
+         message = (TextMessage)consumer.receive(2000);
+         log("Received message: " + message.getText());
+         assertEquals("Hello!", message.getText());
+
+         displayProviderInfo(connection.getMetaData());
+
+      }
+      finally
+      {
+         if(ic != null)
+         {
+            try
+            {
+               ic.close();
+            }
+            catch(Exception e)
+            {
+               throw e;
+            }
+         }
+
+         // ALWAYS close your connection in a finally block to avoid leaks.
+         // Closing connection also takes care of closing its related objects e.g. sessions.
+         closeConnection(connection);
+      }
+   }
+
+   private void closeConnection(Connection con)
+   {
+      try
+      {
+         if (con != null)
+         {
+            con.close();
+         }
+      }
+      catch(JMSException jmse)
+      {
+         log("Could not close connection " + con +" exception was " + jmse);
+      }
+   }
+
+   protected boolean isQueueExample()
+   {
+      return true;
+   }
+
+   public static void main(String[] args)
+   {
+      new QueueExample().run();
+   }
+
+}
+    </programlisting>
+
+  </section>
+
+
+  <section id="examples.topic">
+    <title>Sending messages to a topic</title>
+    <para>In this example, a standalone Java client publishes a text-based JMS message to a topic and a single subscriber pulls the message off the queue.
+    </para>
+
+    <para>
+    Open an new command line. Set the JBOSS_HOME environment variable to point at a JBossAS 4.x installation. Navigate to the folder where you exploded the main archive and drill down to <literal>/examples/queue</literal>. You need to use Apache Ant to execute the build.xml file
+    Make sure the JBoss server reference by the JBOSS_HOME is started.
+   </para>
+
+   <programlisting>
+public class TopicExample extends ExampleSupport
+{
+   public void example() throws Exception
+   {
+      String destinationName = getDestinationJNDIName();
+
+      InitialContext ic = null;
+      Connection connection = null;
+
+      try
+      {
+         ic = new InitialContext();
+
+         ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+         Topic topic = (Topic)ic.lookup(destinationName);
+         log("Topic " + destinationName + " exists");
+
+         connection = cf.createConnection();
+         Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageProducer publisher = session.createProducer(topic);
+         MessageConsumer subscriber = session.createConsumer(topic);
+
+         ExampleListener messageListener = new ExampleListener();
+         subscriber.setMessageListener(messageListener);
+         connection.start();
+
+         TextMessage message = session.createTextMessage("Hello!");
+         publisher.send(message);
+         log("The message was successfully published on the topic");
+
+         messageListener.waitForMessage();
+
+         message = (TextMessage)messageListener.getMessage();
+         log("Received message: " + message.getText());
+         assertEquals("Hello!", message.getText());
+
+         displayProviderInfo(connection.getMetaData());
+
+      }
+      finally
+      {
+         if (ic != null)
+         {
+            try
+            {
+               ic.close();
+            }
+            catch(Exception e)
+            {
+               throw e;
+            }
+         }
+
+         // ALWAYS close your connection in a finally block to avoid leaks.
+         // Closing connection also takes care of closing its related objects e.g. sessions.
+         closeConnection(connection);
+      }
+   }
+
+   private void closeConnection(Connection con) throws JMSException
+   {
+
+      try
+      {
+         if (con != null)
+         {
+            con.close();
+         }
+      }
+      catch(JMSException jmse)
+      {
+         log("Could not close connection " + con +" exception was " + jmse);
+      }
+   }
+
+   protected boolean isQueueExample()
+   {
+      return false;
+   }
+
+   public static void main(String[] args)
+   {
+      new TopicExample().run();
+   }
+
+}
+   </programlisting>
+
+  </section>
+
+  <section id="examples.stateless">
+    <title>Using JMS from an EJB</title>
+    <para>This example deploys a simple Stateless Session Bean that is used as a proxy to send and receive JMS messages in a managed environment.
+    </para>
+
+      <warning>
+         Receiving a JMS message from inside an EJB (or MBean or servlet) method is considered an anti-pattern since it will require the creation
+         of a new JMS consumer on every send - even when using the JCA adaptor. This is likely to make it very slow. (Users of the Spring JMSTemplate be warned that this is what it uses
+         to implement it's receive.)
+         If you want to receive messages as part of a global transaction then use an MDB instead.
+      </warning>
+
+    <programlisting>
+public class StatelessSessionExampleBean implements SessionBean
+{
+
+   private ConnectionFactory cf = null;
+
+   public void drain(String queueName) throws Exception
+   {
+      InitialContext ic = new InitialContext();
+      Queue queue = (Queue)ic.lookup(queueName);
+      ic.close();
+
+      Session session = null;
+      Connection conn = null;
+
+      try
+      {
+         conn = getConnection();
+         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer consumer = session.createConsumer(queue);
+         Message m = null;
+         do
+         {
+            m = consumer.receiveNoWait();
+         }
+         while(m != null);
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            closeConnection(conn);
+         }
+      }
+   }
+
+   public void send(String txt, String queueName) throws Exception
+   {
+      InitialContext ic = new InitialContext();
+
+      Queue queue = (Queue)ic.lookup(queueName);
+
+      ic.close();
+
+      Session session = null;
+      Connection conn = null;
+
+      try
+      {
+         conn = getConnection();
+
+         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageProducer producer = session.createProducer(queue);
+
+         TextMessage tm = session.createTextMessage(txt);
+
+         producer.send(tm);
+
+         System.out.println("message " + txt + " sent to " + queueName);
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            closeConnection(conn);
+         }
+      }
+   }
+
+   public int browse(String queueName) throws Exception
+   {
+      InitialContext ic = new InitialContext();
+      Queue queue = (Queue)ic.lookup(queueName);
+      ic.close();
+
+      Session session = null;
+      Connection conn = null;
+
+      try
+      {
+         conn = getConnection();
+         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         QueueBrowser browser = session.createBrowser(queue);
+
+         ArrayList list = new ArrayList();
+         for(Enumeration e = browser.getEnumeration(); e.hasMoreElements(); )
+         {
+            list.add(e.nextElement());
+         }
+
+         return list.size();
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            closeConnection(conn);
+         }
+      }
+   }
+
+   public String receive(String queueName) throws Exception
+   {
+      InitialContext ic = new InitialContext();
+      Queue queue = (Queue)ic.lookup(queueName);
+      ic.close();
+
+      Session session = null;
+      Connection conn = null;
+
+      // WARN! this is an anti-pattern - please see above warning
+
+      try
+      {
+         conn = getConnection();
+         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageConsumer consumer = session.createConsumer(queue);
+
+         System.out.println("blocking to receive message from queue " + queueName + " ...");
+         TextMessage tm = (TextMessage)consumer.receive(5000);
+
+         if (tm == null)
+         {
+            throw new Exception("No message!");
+         }
+
+         System.out.println("Message " + tm.getText() + " received");
+
+         return tm.getText();
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            closeConnection(conn);
+         }
+      }
+   }
+
+   public Connection getConnection() throws Exception
+   {
+
+      Connection connection = null;
+
+      try
+      {
+         connection = cf.createConnection();
+
+         connection.start();
+      }
+      catch(Exception e )
+      {
+         if(connection != null)
+         {
+            closeConnection(connection);
+         }
+         System.out.println("Failed to get connection...exception is " + e);
+         throw e;
+      }
+
+      return connection;
+   }
+
+   public void closeConnection(Connection con) throws Exception
+   {
+      try
+      {
+         con.close();
+      }
+      catch(JMSException jmse)
+      {
+         System.out.println("Could not close connection " + con +" exception was " + jmse);
+         throw jmse;
+      }
+   }
+
+   public void setSessionContext(SessionContext ctx) throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbCreate()
+   {
+      try
+      {
+         InitialContext ic = new InitialContext();
+
+         cf = (ConnectionFactory)ic.lookup("java:/JmsXA");
+
+         ic.close();
+      }
+      catch(Exception e)
+      {
+         e.printStackTrace();
+         throw new EJBException("Initalization failure: " + e.getMessage());
+      }
+   }
+
+   public void ejbRemove() throws EJBException
+   {
+      try
+      {
+         if(cf != null)
+         {
+            cf = null;
+         }
+      }
+      catch(Exception e)
+      {
+         throw new EJBException("ejbRemove ", e);
+      }
+   }
+
+   public void ejbActivate() throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbPassivate() throws EJBException, RemoteException
+   {
+   }
+
+}
+    </programlisting>
+
+  </section>
+
+  <section id="examples.mdb.ejb21">
+    <title>Using EJB2.1 Message Driven Beans</title>
+    <para>This example deploys a simple Message Driven Bean that processes messages sent to a test queue.  Once it receives a message and "processes" it, the MDB sends an acknowledgment message to a temporary destination created by the sender for this purpose. The example is considered successful if the sender receives the acknowledgment message.
+    </para>
+
+   <para>The MDB ejb-jar.xml descriptor
+    </para>
+    <programlisting>
+&lt;ejb-jar&gt;
+  &lt;enterprise-beans&gt;
+    &lt;message-driven&gt;
+      &lt;ejb-name&gt;MDBExample&lt;/ejb-name&gt;
+      &lt;ejb-class&gt;org.jboss.example.jms.mdb.MDBExample&lt;/ejb-class&gt;
+      &lt;transaction-type&gt;Container&lt;/transaction-type&gt;
+    &lt;/message-driven&gt;
+  &lt;/enterprise-beans&gt;
+&lt;/ejb-jar&gt;
+    </programlisting>
+
+   <para>The MDB jboss.xml descriptor
+   </para>
+    <programlisting>
+&lt;enterprise-beans&gt;
+  &lt;message-driven&gt;
+    &lt;ejb-name&gt;MDBExample&lt;/ejb-name&gt;
+    &lt;destination-jndi-name&gt;queue/@QUEUE_NAME@&lt;/destination-jndi-name&gt;
+  &lt;/message-driven&gt;
+&lt;/enterprise-beans&gt;
+    </programlisting>
+
+   <programlisting>
+public class MDBExample implements MessageDrivenBean, MessageListener
+{
+   private MessageDrivenContext ctx;
+
+   private ConnectionFactory cf = null;
+
+   public void onMessage(Message m)
+   {
+      Session session = null;
+      Connection conn = null;
+
+      try
+      {
+         TextMessage tm = (TextMessage)m;
+
+         String text = tm.getText();
+         System.out.println("message " + text + " received");
+         String result = process(text);
+         System.out.println("message processed, result: " + result);
+
+         conn = getConnection();
+         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         Destination replyTo = m.getJMSReplyTo();
+         MessageProducer producer = session.createProducer(replyTo);
+         TextMessage reply = session.createTextMessage(result);
+
+         producer.send(reply);
+         producer.close();
+
+      }
+      catch(Exception e)
+      {
+         ctx.setRollbackOnly();
+         e.printStackTrace();
+         System.out.println("The Message Driven Bean failed!");
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            try
+            {
+               closeConnection(conn);
+            }
+            catch(Exception e)
+            {
+               System.out.println("Could not close the connection!" +e);
+            }
+         }
+      }
+   }
+
+   private String process(String s)
+   {
+      // flip the string
+
+      String result = "";
+
+      for (int i = 0; i &lt; text.length(); i++)
+      {
+         result = text.charAt(i) + result;
+      }
+      return result;
+   }
+
+   public Connection getConnection() throws Exception
+   {
+      Connection connection = null;
+
+      try
+      {
+         connection = cf.createConnection();
+         connection.start();
+      }
+      catch(Exception e )
+      {
+         if(connection != null)
+         {
+            closeConnection(connection);
+         }
+         System.out.println("Failed to get connection...exception is " + e);
+         throw e;
+      }
+
+      return connection;
+   }
+
+   public void closeConnection(Connection con) throws Exception
+   {
+      try
+      {
+         con.close();
+      }
+      catch(JMSException e)
+      {
+         System.out.println("Could not close connection " + con + " exception was " + e);
+      }
+   }
+
+   public void ejbCreate()
+   {
+      try
+      {
+         InitialContext ic = new InitialContext();
+
+         cf = (ConnectionFactory)ic.lookup("java:/JmsXA");
+
+         ic.close();
+      }
+      catch(Exception e)
+      {
+         e.printStackTrace();
+         throw new EJBException("Failure to get connection factory: " + e.getMessage());
+      }
+   }
+
+   public void ejbRemove() throws EJBException
+   {
+      try
+      {
+         if(cf != null)
+         {
+            cf = null;
+         }
+      }
+      catch(Exception e)
+      {
+         throw new EJBException("ejbRemove", e);
+      }
+   }
+
+   public void setMessageDrivenContext(MessageDrivenContext ctx)
+   {
+      this.ctx = ctx;
+   }
+
+
+}
+
+   </programlisting>
+
+
+  </section>
+
+
+   <section id="examples.mdb.ejb3">
+     <title>Using EJB3 Message Driven Beans</title>
+
+      <para>
+         This example deploys a simple EJB3 Message Driven Bean that processes messages sent to a
+         test queue.  Once it receives a message and "processes" it, the MDB sends an
+         acknowledgment message to a temporary destination created by the sender for this purpose.
+         The example is considered successful if the sender receives the acknowledgment message.
+      </para>
+
+      <para>
+         This example relies on having access to a running JBoss Messaging instance.
+         The JBoss Messaging instance must be installed and started according to the
+         "Installation" chapter of this document. The example will automatically deploy
+         its own queue, unless a queue with the same name is already deployed.
+      </para>
+
+      <para>
+         This example also relies on having access to the
+         <filename>jboss-messaging-client.jar</filename> archive that comes with the release bundle.
+         If you run this example from an unzipped installation bundle, the example run script
+         is correctly configured to find the client jar. Otherwise, you must modify example's
+         <filename>build.xml</filename> accordingly.
+      </para>
+
+      <para>
+         The example was designed to deploy its server-side artifacts under a JBoss'
+         <literal>messaging</literal> configuration. If you intend to use the script with
+         a JBoss configuration that is named differently, please modify the example's
+         <filename>build.xml</filename> accordingly.
+      </para>
+
+      <important>
+         The JBoss instance that runs the Messaging server must also have EJB3 support
+         previously installed. If the EJB3 support is not installed, the example will fail
+         with an error message similar to:
+
+         <programlisting>
+C:\work\src\cvs\jboss-head\jms\docs\examples\ejb3mdb\build.xml:60: EJB3 does not seem
+to be installed in C:\work\src\jboss-4.0.3-src\build\output\jboss-4.0.3/server/messaging!
+Install it and try again.
+         </programlisting>
+
+         <para>
+            For instructions on how to install EJB3 support,
+            please go to <ulink url="http://docs.jboss.org/ejb3">JBoss EJB3 documentation page</ulink>
+            or use the JBoss Installer.
+         </para>
+      </important>
+
+      <para>
+         The EJB3 Message Driven Bean source code:
+      </para>
+     <programlisting>
+ at MessageDriven(activationConfig =
+{
+      @ActivationConfigProperty(propertyName="destinationType", propertyValue="javax.jms.Queue"),
+      @ActivationConfigProperty(propertyName="destination", propertyValue="queue/testQueue"),
+      @ActivationConfigProperty(propertyName="DLQMaxResent", propertyValue="10")
+})
+public class EJB3MDBExample implements MessageListener
+{
+   public void onMessage(Message m)
+   {
+      businessLogic(m);
+   }
+
+   private void businessLogic(Message m)
+   {
+      Connection conn = null;
+      Session session = null;
+
+      try
+      {
+         TextMessage tm = (TextMessage)m;
+
+         String text = tm.getText();
+         System.out.println("message " + text + " received");
+
+         // flip the string
+         String result = "";
+         for(int i = 0; i &lt; text.length(); i++)
+         {
+            result = text.charAt(i) + result;
+         }
+
+         System.out.println("message processed, result: " + result);
+
+
+         InitialContext ic = new InitialContext();
+         ConnectionFactory cf = (ConnectionFactory)ic.lookup("java:/JmsXA");
+         ic.close();
+
+         conn = cf.createConnection();
+         conn.start();
+         session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         Destination replyTo = m.getJMSReplyTo();
+         MessageProducer producer = session.createProducer(replyTo);
+         TextMessage reply = session.createTextMessage(result);
+
+         producer.send(reply);
+         producer.close();
+
+      }
+      catch(Exception e)
+      {
+         e.printStackTrace();
+         System.out.println("The Message Driven Bean failed!");
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch(Exception e)
+            {
+               System.out.println("Could not close the connection!" +e);
+            }
+         }
+      }
+   }
+}
+     </programlisting>
+
+     <para>The basic test examples in this chapter serve as the sanity check for your JBoss Messaging installation. They also provide basic programming examples. To develop your own JMS services, you probably need to configure JBoss Messaging to setup your own destinations and connection factories etc. In <xref linkend="configuration"/>, we will discuss JBoss Messaging configuration files and options.</para>
+
+   </section>
+
+
+
+</chapter>




More information about the jboss-cvs-commits mailing list