[jboss-remoting-commits] JBoss Remoting SVN: r4426 - remoting2/branches/2.x/docs/guide/en.

jboss-remoting-commits at lists.jboss.org jboss-remoting-commits at lists.jboss.org
Tue Jul 22 02:43:55 EDT 2008


Author: trustin
Date: 2008-07-22 02:43:54 -0400 (Tue, 22 Jul 2008)
New Revision: 4426

Modified:
   remoting2/branches/2.x/docs/guide/en/chap3.xml
   remoting2/branches/2.x/docs/guide/en/chap5.xml
Log:
Fixed overflowing programlistings in the chapter 3 & 5 (6, 9, 10 & 11 needs work too)



Modified: remoting2/branches/2.x/docs/guide/en/chap3.xml
===================================================================
--- remoting2/branches/2.x/docs/guide/en/chap3.xml	2008-07-22 06:38:28 UTC (rev 4425)
+++ remoting2/branches/2.x/docs/guide/en/chap3.xml	2008-07-22 06:43:54 UTC (rev 4426)
@@ -42,14 +42,17 @@
   <classname>org.jboss.test.remoting.locator.InvokerLocatorTestCase</classname>:
   </para>
 
-  <para><code>new InvokerLocator("http://localhost:1234/services/uri:Test").equals(new InvokerLocator("http://localhost:1234"))</code> returns false</para>
+  <para><literallayout><code>new InvokerLocator("http://localhost:1234/services/uri:Test").equals(
+        new InvokerLocator("http://localhost:1234"))</code> returns <constant>false</constant>
 
-  <para><code>new InvokerLocator("http://localhost:1234/services/uri:Test").equals(new InvokerLocator("http://127.0.0.1:1234"))</code> returns false</para>
+<code>new InvokerLocator("http://localhost:1234/services/uri:Test").equals(
+        new InvokerLocator("http://127.0.0.1:1234"))</code> returns <constant>false</constant>
 
-  <para><code>new InvokerLocator("http://localhost:1234/services/uri:Test").isSameEndpoint(new InvokerLocator("http://localhost:1234"))</code> returns true </para>
+<code>new InvokerLocator("http://localhost:1234/services/uri:Test").isSameEndpoint(
+        new InvokerLocator("http://localhost:1234"))</code> returns <constant>true</constant>
 
-  <para><code>new InvokerLocator("http://localhost:1234/services/uri:Test").isSameEndpoint(new InvokerLocator("http://127.0.0.1:1234"))</code> returns false</para>
-
+<code>new InvokerLocator("http://localhost:1234/services/uri:Test").isSameEndpoint(
+        new InvokerLocator("http://127.0.0.1:1234"))</code> returns <constant>false</constant></literallayout></para>
   <para><emphasis role="bold">N.B.</emphasis> As of version 2.4,
   <classname>InvokerLocator</classname> uses the class
   <classname>java.net.URI</classname>, rather than its original ad hoc parsing
@@ -226,14 +229,14 @@
     <code>org.jboss.remoting.transport.socket.TransportServerFactory</code>.
     The API for org.jboss.remoting.transport.ClientFactory is:</para>
 
-    <programlisting>   public ClientInvoker createClientInvoker(InvokerLocator locator, Map config) throws IOException;
-   public boolean supportsSSL();
+    <programlisting>public ClientInvoker createClientInvoker(InvokerLocator locator, Map config) throws IOException;
+public boolean supportsSSL();
 </programlisting>
 
     <para>The API for org.jboss.remoting.transport.ServerFactory is:</para>
 
-    <programlisting>   public ServerInvoker createServerInvoker(InvokerLocator locator, Map config) throws IOException;
-   public boolean supportsSSL();
+    <programlisting>public ServerInvoker createServerInvoker(InvokerLocator locator, Map config) throws IOException;
+public boolean supportsSSL();
 </programlisting>
 
     <para>An example of a transport client factory for the socket transport
@@ -269,4 +272,4 @@
     with the following transports: socket, sslsocket, http, https, multiplex,
     sslmultiplex, servlet, sslservlet, rmi, sslrmi.</para>
   </section>
-</chapter>
\ No newline at end of file
+</chapter>

Modified: remoting2/branches/2.x/docs/guide/en/chap5.xml
===================================================================
--- remoting2/branches/2.x/docs/guide/en/chap5.xml	2008-07-22 06:38:28 UTC (rev 4425)
+++ remoting2/branches/2.x/docs/guide/en/chap5.xml	2008-07-22 06:43:54 UTC (rev 4426)
@@ -59,17 +59,15 @@
         <classname>Connector</classname> constructor. For example, the code
         fragment</para>
 
-        <programlisting>
-             String locatorURI = "socket://test.somedomain.com:8084";
-             String params = "/?clientLeasePeriod=10000&amp;timeout=120000";
-             locatorURI += params;
-             InvokerLocator locator = new InvokerLocator(locatorURI);
-             Connector connector = new Connector(locator);
-             connector.create();
-             SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
-             connector.addInvocationHandler("sample", invocationHandler);
-             connector.start();
-           </programlisting>
+        <programlisting>String locatorURI = "socket://test.somedomain.com:8084";
+String params = "/?clientLeasePeriod=10000&amp;timeout=120000";
+locatorURI += params;
+InvokerLocator locator = new InvokerLocator(locatorURI);
+Connector connector = new Connector(locator);
+connector.create();
+SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
+connector.addInvocationHandler("sample", invocationHandler);
+connector.start();</programlisting>
 
         <para>creates a server invoker based on the socket transport, directs
         it to listen for invocations on port 8084 of host test.somedomain.com,
@@ -87,20 +85,18 @@
         configuration map. It also passes in a non-string object, a
         <classname>ServerSocketFactory</classname>:</para>
 
-        <programlisting>
-             String locatorURI = "socket://test.somedomain.com:8084";
-             String params = "/?clientLeasePeriod=10000";
-             locatorURI += params;
-             InvokerLocator locator = new InvokerLocator(locatorURI);
-             HashMap config = new HashMap();
-             config.put(ServerInvoker.TIMEOUT, 120000);
-             config.put(ServerInvoker.SERVER_SOCKET_FACTORY, new MyServerSocketFactory());
-             Connector connector = new Connector(locator, config);
-             connector.create();
-             SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
-             connector.addInvocationHandler("sample", invocationHandler);
-             connector.start();
-          </programlisting>
+        <programlisting>String locatorURI = "socket://test.somedomain.com:8084";
+String params = "/?clientLeasePeriod=10000";
+locatorURI += params;
+InvokerLocator locator = new InvokerLocator(locatorURI);
+HashMap config = new HashMap();
+config.put(ServerInvoker.TIMEOUT, 120000);
+config.put(ServerInvoker.SERVER_SOCKET_FACTORY, new MyServerSocketFactory());
+Connector connector = new Connector(locator, config);
+connector.create();
+SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
+connector.addInvocationHandler("sample", invocationHandler);
+connector.start();</programlisting>
 
         <para>Note that the value of <code>ServerInvoker.TIMEOUT</code> is
         "timeout", and the value of
@@ -118,22 +114,20 @@
         <classname>ServerSocketFactory</classname> is passed to it by way of a
         setter method:</para>
 
-        <programlisting>
-             String locatorURI = "socket://test.somedomain.com:8084";
-             String params = "/?clientLeasePeriod=10000";
-             locatorURI += params;
-             InvokerLocator locator = new InvokerLocator(locatorURI);
-             HashMap config = new HashMap();
-             config.put(ServerInvoker.TIMEOUT, 120000);
-             Connector connector = new Connector(locator, config);
-             connector.create();
-             ServerInvoker serverInvoker = connector.getServerInvoker();
-             ServerSocketFactory ssf = new MyServerSocketFactory();
-             serverInvoker.setServerSocketFactory(ssf);
-             SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
-             connector.addInvocationHandler("sample", invocationHandler);
-             connector.start();
-          </programlisting>
+        <programlisting>String locatorURI = "socket://test.somedomain.com:8084";
+String params = "/?clientLeasePeriod=10000";
+locatorURI += params;
+InvokerLocator locator = new InvokerLocator(locatorURI);
+HashMap config = new HashMap();
+config.put(ServerInvoker.TIMEOUT, 120000);
+Connector connector = new Connector(locator, config);
+connector.create();
+ServerInvoker serverInvoker = connector.getServerInvoker();
+ServerSocketFactory ssf = new MyServerSocketFactory();
+serverInvoker.setServerSocketFactory(ssf);
+SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
+connector.addInvocationHandler("sample", invocationHandler);
+connector.start();</programlisting>
 
         <para><emphasis role="bold">Note.</emphasis> The
         <classname>Connector</classname> creates the server invoker during the
@@ -149,34 +143,33 @@
         fragment duplicates the behavior of the first and second examples
         above.</para>
 
-        <programlisting>
-             HashMap config = new HashMap();
-             config.put(ServerInvoker.TIMEOUT, 120000);
-             Connector connector = new Connector(config);
-         
-             // Set xml configuration element.
-             StringBuffer buf = new StringBuffer();
-             buf.append("&lt;?xml version=\"1.0\"?&gt;\n");
-             buf.append("&lt;config&gt;");
-             buf.append("   &lt;invoker transport=\"socket\"&gt;");
-             buf.append("      &lt;attribute name=\"serverBindAddress\"&gt;test.somedomain.com&lt;/attribute&gt;");
-             buf.append("      &lt;attribute name=\"serverBindPort\"&gt;8084&lt;/attribute&gt;");
-             buf.append("      &lt;attribute name=\"clientLeasePeriod\"&gt;10000&lt;/attribute&gt;");
-             buf.append("   &lt;/invoker&gt;");
-             buf.append("   &lt;handlers&gt;");
-             buf.append("      &lt;handler subsystem=\"mock\"&gt;");
-             buf.append("         org.jboss.remoting.transport.mock.SampleInvocationHandler");
-             buf.append("      &lt;/handler&gt;");
-             buf.append("   &lt;/handlers&gt;");
-             buf.append("&lt;/config&gt;");
-             ByteArrayInputStream bais = new ByteArrayInputStream(buf.toString().getBytes());
-             Document xml = DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(bais);
-             connector.setConfiguration(xml.getDocumentElement());
-             
-             connector.create();
-             connector.start();
-          </programlisting>
+        <programlisting>HashMap config = new HashMap();
+config.put(ServerInvoker.TIMEOUT, 120000);
+Connector connector = new Connector(config);
 
+// Set xml configuration element.
+StringBuffer buf = new StringBuffer();
+buf.append("&lt;?xml version=\"1.0\"?&gt;\n");
+buf.append("&lt;config&gt;");
+buf.append("   &lt;invoker transport=\"socket\"&gt;");
+buf.append("      &lt;attribute name=\"serverBindAddress\"&gt;test.somedomain.com&lt;/attribute&gt;");
+buf.append("      &lt;attribute name=\"serverBindPort\"&gt;8084&lt;/attribute&gt;");
+buf.append("      &lt;attribute name=\"clientLeasePeriod\"&gt;10000&lt;/attribute&gt;");
+buf.append("   &lt;/invoker&gt;");
+buf.append("   &lt;handlers&gt;");
+buf.append("      &lt;handler subsystem=\"mock\"&gt;");
+buf.append("         org.jboss.remoting.transport.mock.SampleInvocationHandler");
+buf.append("      &lt;/handler&gt;");
+buf.append("   &lt;/handlers&gt;");
+buf.append("&lt;/config&gt;");
+
+ByteArrayInputStream bais = new ByteArrayInputStream(buf.toString().getBytes());
+Document xml = DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(bais);
+connector.setConfiguration(xml.getDocumentElement());
+
+connector.create();
+connector.start();</programlisting>
+
         <para>Note that there is no <classname>InvokerLocator</classname> in
         this example. If the <classname>Connector</classname> gets an
         <classname>InvokerLocator</classname>, it ignores the presence of the
@@ -195,34 +188,32 @@
         The following fragment duplicates the behavior of the first and second
         examples above.</para>
         
-        <programlisting>
-             HashMap config = new HashMap();
-             config.put(ServerInvoker.TIMEOUT, 120000);
-             Connector connector = new Connector(config);
-         
-             // Create ServerConfiguration object for socket transport
-             ServerConfiguration serverConfig = new ServerConfiguration("socket");
-            
-             // Add invokerLocatorParameters (applicable to client and server)
-             Map locatorConfig = new HashMap();
-             locatorConfig.put("serverBindAddress", "test.somedomain.com");
-             locatorConfig.put("serverBindPort", "8084");
-             serverConfig.setInvokerLocatorParameters(locatorConfig);
-            
-             // Add serverParameters (applicable to server)
-             Map serverParameters = new HashMap();
-             locatorConfig.put("clientLeasePeriod", "10000");
-             serverConfig.setServerParameters(serverParameters);
-                   
-             // Add invocation handlers
-             Map handlers = new HashMap();
-             handlers.put("mock", "org.jboss.remoting.transport.mock.SampleInvocationHandler");
-             serverConfig.setInvocationHandlers(handlers);
+        <programlisting>HashMap config = new HashMap();
+config.put(ServerInvoker.TIMEOUT, 120000);
+Connector connector = new Connector(config);
 
-             connector.setServerConfiguration(serverConfig);
-             connector.create();
-             connector.start();
-          </programlisting>
+// Create ServerConfiguration object for socket transport
+ServerConfiguration serverConfig = new ServerConfiguration("socket");
+
+// Add invokerLocatorParameters (applicable to client and server)
+Map locatorConfig = new HashMap();
+locatorConfig.put("serverBindAddress", "test.somedomain.com");
+locatorConfig.put("serverBindPort", "8084");
+serverConfig.setInvokerLocatorParameters(locatorConfig);
+
+// Add serverParameters (applicable to server)
+Map serverParameters = new HashMap();
+locatorConfig.put("clientLeasePeriod", "10000");
+serverConfig.setServerParameters(serverParameters);
+
+// Add invocation handlers
+Map handlers = new HashMap();
+handlers.put("mock", "org.jboss.remoting.transport.mock.SampleInvocationHandler");
+serverConfig.setInvocationHandlers(handlers);
+
+connector.setServerConfiguration(serverConfig);
+connector.create();
+connector.start();</programlisting>
           
         <para>For more information about <classname>ServerConfiguration</classname>,
         see the section "Declarative configuration: POJOs".</para>
@@ -250,24 +241,22 @@
         invoker that is listening on port 8084 on the test.somedomain.com
         address would be:</para>
 
-        <programlisting>
-            &lt;mbean code="org.jboss.remoting.transport.Connector"
-                  name="jboss.remoting:service=Connector,transport=Socket"
-                  display-name="Socket transport Connector"&gt;
-               &lt;attribute name="<emphasis role="bold">InvokerLocator</emphasis>"&gt;
-                  &lt;![CDATA[<emphasis role="bold">socket://test.somedomain.com:8084</emphasis>]]&gt;
-               &lt;/attribute&gt;
-               &lt;attribute name="Configuration"&gt;
-                  &lt;config&gt;
-                     &lt;handlers&gt;
-                        &lt;handler <emphasis role="bold">subsystem</emphasis>="mock"&gt;
-                           <emphasis role="bold">org.jboss.remoting.transport.mock.MockServerInvocationHandler</emphasis>
-                        &lt;/handler&gt;
-                     &lt;/handlers&gt;
-                  &lt;/config&gt;
-               &lt;/attribute&gt;
-            &lt;/mbean&gt;
-         </programlisting>
+        <programlisting>&lt;mbean code="org.jboss.remoting.transport.Connector"
+       name="jboss.remoting:service=Connector,transport=Socket"
+       display-name="Socket transport Connector"&gt;
+   &lt;attribute name="<emphasis role="bold">InvokerLocator</emphasis>"&gt;
+      &lt;![CDATA[<emphasis role="bold">socket://test.somedomain.com:8084</emphasis>]]&gt;
+   &lt;/attribute&gt;
+   &lt;attribute name="Configuration"&gt;
+      &lt;config&gt;
+         &lt;handlers&gt;
+            &lt;handler <emphasis role="bold">subsystem</emphasis>="mock"&gt;
+               <emphasis role="bold">org.jboss.remoting.transport.mock.MockServerInvocationHandler</emphasis>
+            &lt;/handler&gt;
+         &lt;/handlers&gt;
+      &lt;/config&gt;
+   &lt;/attribute&gt;
+&lt;/mbean&gt;</programlisting>
 
         <para>Note that all the server side socket invoker configurations will
         be set to their default values in this case. Also, it is important to
@@ -286,37 +275,35 @@
         attribute needs to be used by the client. An example using this form
         of configuration is as follows:</para>
 
-        <programlisting> 
-            &lt;mbean code="org.jboss.remoting.transport.Connector"
-                  name="jboss.remoting:service=Connector,transport=Socket"
-                  display-name="Socket transport Connector"&gt;
+        <programlisting>&lt;mbean code="org.jboss.remoting.transport.Connector"
+       name="jboss.remoting:service=Connector,transport=Socket"
+       display-name="Socket transport Connector"&gt;
    
-               &lt;attribute name="Configuration"&gt;
-                  &lt;config&gt;
-                  <emphasis role="bold"> 
-                     &lt;invoker transport="socket"&gt;
-                        &lt;attribute name="numAcceptThreads"&gt;1&lt;/attribute&gt;
-                        &lt;attribute name="maxPoolSize"&gt;303&lt;/attribute&gt;
-                        &lt;attribute name="clientMaxPoolSize" isParam="true"&gt;304&lt;/attribute&gt;
-                        &lt;attribute name="socketTimeout"&gt;60000&lt;/attribute&gt;
-                        &lt;attribute name="serverBindAddress"&gt;192.168.0.82&lt;/attribute&gt;
-                        &lt;attribute name="serverBindPort"&gt;6666&lt;/attribute&gt;
-                        &lt;attribute name="clientConnectAddress"&gt;216.23.33.2&lt;/attribute&gt;
-                        &lt;attribute name="clientConnectPort"&gt;7777&lt;/attribute&gt;
-                        &lt;attribute name="enableTcpNoDelay" isParam="true"&gt;false&lt;/attribute&gt;
-                        &lt;attribute name="backlog"&gt;200&lt;/attribute&gt;
-                     &lt;/invoker&gt;
-                  </emphasis>
-                     &lt;handlers&gt;
-                        &lt;handler subsystem="mock"&gt;
-                           org.jboss.remoting.transport.mock.MockServerInvocationHandler
-                        &lt;/handler&gt;
-                     &lt;/handlers&gt;
-                  &lt;/config&gt;
-               &lt;/attribute&gt;
+   &lt;attribute name="Configuration"&gt;
+      &lt;config&gt;
+         <emphasis role="bold"> 
+         &lt;invoker transport="socket"&gt;
+            &lt;attribute name="numAcceptThreads"&gt;1&lt;/attribute&gt;
+            &lt;attribute name="maxPoolSize"&gt;303&lt;/attribute&gt;
+            &lt;attribute name="clientMaxPoolSize" isParam="true"&gt;304&lt;/attribute&gt;
+            &lt;attribute name="socketTimeout"&gt;60000&lt;/attribute&gt;
+            &lt;attribute name="serverBindAddress"&gt;192.168.0.82&lt;/attribute&gt;
+            &lt;attribute name="serverBindPort"&gt;6666&lt;/attribute&gt;
+            &lt;attribute name="clientConnectAddress"&gt;216.23.33.2&lt;/attribute&gt;
+            &lt;attribute name="clientConnectPort"&gt;7777&lt;/attribute&gt;
+            &lt;attribute name="enableTcpNoDelay" isParam="true"&gt;false&lt;/attribute&gt;
+            &lt;attribute name="backlog"&gt;200&lt;/attribute&gt;
+         &lt;/invoker&gt;
+         </emphasis>
+         &lt;handlers&gt;
+            &lt;handler subsystem="mock"&gt;
+               org.jboss.remoting.transport.mock.MockServerInvocationHandler
+            &lt;/handler&gt;
+         &lt;/handlers&gt;
+      &lt;/config&gt;
+   &lt;/attribute&gt;
    
-            &lt;/mbean&gt;
-         </programlisting>
+&lt;/mbean&gt;</programlisting>
 
         <para>Also note that <code>${jboss.bind.address}</code> can be used
         for any of the bind address properties, which will be replaced with
@@ -333,24 +320,22 @@
         express a locator uri path of 'foo/bar' via the InvokerLocator
         attribute as:</para>
 
-        <programlisting>            &lt;attribute name="InvokerLocator"&gt;&lt;![CDATA[socket://test.somedomain.com:8084/<emphasis
-            role="bold">foo/bar</emphasis>]]&gt;&lt;/attribute&gt;
-   </programlisting>
+        <programlisting>&lt;attribute name="InvokerLocator"&gt;
+   &lt;![CDATA[socket://test.somedomain.com:8084/<emphasis role="bold">foo/bar</emphasis>]]&gt;
+&lt;/attribute&gt;</programlisting>
 
         <para>To include the path using the Configuration attribute, can
         include a specific 'path' attribute. So the same InvokerLocator can be
         expressed as follows with the Configuration attribute:</para>
 
-        <programlisting>
-               &lt;attribute name="Configuration"&gt;
-                  &lt;config&gt;
-                    &lt;invoker transport="socket"&gt;
-                      &lt;attribute name="serverBindAddress"&gt;test.somedomain.com&lt;/attribute&gt;
-                      &lt;attribute name="serverBindPort"&gt;8084&lt;/attribute&gt;
-                      <emphasis role="bold">&lt;attribute name="path"&gt;foo/bar&lt;/attribute&gt;</emphasis>
-                    &lt;/invoker&gt;
-                    ...
-         </programlisting>
+        <programlisting>&lt;attribute name="Configuration"&gt;
+   &lt;config&gt;
+      &lt;invoker transport="socket"&gt;
+         &lt;attribute name="serverBindAddress"&gt;test.somedomain.com&lt;/attribute&gt;
+         &lt;attribute name="serverBindPort"&gt;8084&lt;/attribute&gt;
+         <emphasis role="bold">&lt;attribute name="path"&gt;foo/bar&lt;/attribute&gt;</emphasis>
+      &lt;/invoker&gt;
+      ...</programlisting>
 
         <para>Note: The value for the 'path' attribute should NOT start or end
         with a / (slash).</para>
@@ -390,55 +375,58 @@
           </listitem>
         </itemizedlist>
         
-        <para>An sample remoting-beans.xml file which duplicates the example in the
+        <para>A sample remoting-beans.xml file which duplicates the example in the
         previous sections is:</para>
                                        
-        <programlisting>
-          &lt;?xml version="1.0" encoding="UTF-8"?&gt;
-          &lt;deployment xmlns="urn:jboss:bean-deployer:2.0"&gt;
+        <programlisting>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
+&lt;deployment xmlns="urn:jboss:bean-deployer:2.0"&gt;
             
-             &lt;bean name="remoting:invocationHandler" class="org.jboss.remoting.transport.mock.SampleInvocationHandler"/&gt;
+   &lt;bean name="remoting:invocationHandler"
+         class="org.jboss.remoting.transport.mock.SampleInvocationHandler"/&gt;
              
-             &lt;bean name="remoting:serverConfiguration" class="org.jboss.remoting.ServerConfiguration"&gt;
-                &lt;constructor&gt;
-                   &lt;parameter&gt;socket&lt;/parameter&gt;
-                &lt;/constructor&gt;
-                &lt;property name="invokerLocatorParameters"&gt;
-                   &lt;map keyClass="java.lang.String" valueClass="java.lang.String"&gt;
-                      &lt;entry&gt;
-                         &lt;key&gt;serverBindAddress&lt;/key&gt;
-                         &lt;value&gt;test.somedomain.com&lt;/value&gt;
-                      &lt;/entry&gt;
-                      &lt;entry&gt;
-                         &lt;key&gt;serverBindPort&lt;/key&gt;
-                         &lt;value&gt;8084&lt;/value&gt;
-                      &lt;/entry&gt;
-                   &lt;/map&gt;
-                &lt;/property&gt;
-                &lt;property name="serverParameters"&gt;
-                   &lt;map keyClass="java.lang.String" valueClass="java.lang.String"&gt;
-                      &lt;entry&gt;
-                         &lt;key&gt;clientLeasePeriod&lt;/key&gt;
-                         &lt;value&gt;10000&lt;/value&gt;
-                      &lt;/entry&gt;
-                   &lt;/map&gt;
-                &lt;/property&gt;
-                &lt;property name="invocationHandlers"&gt;
-                   &lt;map keyClass="java.lang.String" valueClass="org.jboss.remoting.ServerInvocationHandler"&gt;
-                      &lt;entry&gt;
-                         &lt;key&gt;mock&lt;/key&gt;
-                         &lt;value&gt;&lt;inject bean="remoting:invocationHandler"/&gt;&lt;/value&gt;
-                      &lt;/entry&gt;
-                   &lt;/map&gt;
-                &lt;/property&gt;
-             &lt;/bean&gt;
+   &lt;bean name="remoting:serverConfiguration"
+         class="org.jboss.remoting.ServerConfiguration"&gt;
+      &lt;constructor&gt;
+         &lt;parameter&gt;socket&lt;/parameter&gt;
+      &lt;/constructor&gt;
+      &lt;property name="invokerLocatorParameters"&gt;
+         &lt;map keyClass="java.lang.String" valueClass="java.lang.String"&gt;
+            &lt;entry&gt;
+               &lt;key&gt;serverBindAddress&lt;/key&gt;
+               &lt;value&gt;test.somedomain.com&lt;/value&gt;
+            &lt;/entry&gt;
+            &lt;entry&gt;
+               &lt;key&gt;serverBindPort&lt;/key&gt;
+               &lt;value&gt;8084&lt;/value&gt;
+            &lt;/entry&gt;
+         &lt;/map&gt;
+      &lt;/property&gt;
+      &lt;property name="serverParameters"&gt;
+         &lt;map keyClass="java.lang.String" valueClass="java.lang.String"&gt;
+            &lt;entry&gt;
+               &lt;key&gt;clientLeasePeriod&lt;/key&gt;
+               &lt;value&gt;10000&lt;/value&gt;
+            &lt;/entry&gt;
+         &lt;/map&gt;
+      &lt;/property&gt;
+      &lt;property name="invocationHandlers"&gt;
+         &lt;map keyClass="java.lang.String" 
+              valueClass="org.jboss.remoting.ServerInvocationHandler"&gt;
+            &lt;entry&gt;
+               &lt;key&gt;mock&lt;/key&gt;
+               &lt;value&gt;&lt;inject bean="remoting:invocationHandler"/&gt;&lt;/value&gt;
+            &lt;/entry&gt;
+         &lt;/map&gt;
+      &lt;/property&gt;
+   &lt;/bean&gt;
              
-             &lt;bean name="remoting:connector" class="org.jboss.remoting.transport.Connector"&gt;
-                &lt;property name="serverConfiguration"&gt;&lt;inject bean="remoting:serverConfiguration"/&gt;&lt;/property&gt;
-             &lt;/bean&gt;
+   &lt;bean name="remoting:connector" class="org.jboss.remoting.transport.Connector"&gt;
+      &lt;property name="serverConfiguration"&gt;
+         &lt;inject bean="remoting:serverConfiguration"/&gt;
+      &lt;/property&gt;
+   &lt;/bean&gt;
              
-          &lt;/deployment&gt;
-        </programlisting>
+&lt;/deployment&gt;</programlisting>
         
         <para>For more information about using the JBoss Microcontainer, see
         <ulink url="http://www.jboss.org/jbossmc/">
@@ -484,14 +472,12 @@
       the configuration parameters on the
       <classname>InvokerLocator</classname>. For example, the fragment</para>
 
-      <programlisting>
-          String locatorURI = "socket://test.somedomain.com:8084";
-          String params = "/?clientMaxPoolSize=10&amp;timeout=360000";
-          locatorURI += params;
-          InvokerLocator locator = new InvokerLocator(locatorURI);
-          Client client = new Client(locator);
-          client.connect();
-       </programlisting>
+      <programlisting>String locatorURI = "socket://test.somedomain.com:8084";
+String params = "/?clientMaxPoolSize=10&amp;timeout=360000";
+locatorURI += params;
+InvokerLocator locator = new InvokerLocator(locatorURI);
+Client client = new Client(locator);
+client.connect();</programlisting>
 
       <para>creates a <classname>Client</classname> using the socket transport
       to connect to a server on host test.somedomain.com, listening on port
@@ -505,17 +491,15 @@
       configuration map. It also passes in a non-string object, a
       <classname>SocketFactory</classname>:</para>
 
-      <programlisting>
-          String locatorURI = "socket://test.somedomain.com:8084";
-          String params = "/?clientMaxPoolSize=10";
-          locatorURI += params;
-          InvokerLocator locator = new InvokerLocator(locatorURI);
-          HashMap config = new HashMap();
-          config.put(ServerInvoker.TIMEOUT, 360000);
-          config.put(Remoting.CUSTOM_SOCKET_FACTORY, new MySocketFactory());
-          Client client = new Client(locator, config);
-          client.connect();
-       </programlisting>
+      <programlisting>String locatorURI = "socket://test.somedomain.com:8084";
+String params = "/?clientMaxPoolSize=10";
+locatorURI += params;
+InvokerLocator locator = new InvokerLocator(locatorURI);
+HashMap config = new HashMap();
+config.put(ServerInvoker.TIMEOUT, 360000);
+config.put(Remoting.CUSTOM_SOCKET_FACTORY, new MySocketFactory());
+Client client = new Client(locator, config);
+client.connect();</programlisting>
 
       <para>Note that the value of <code>ServerInvoker.TIMEOUT</code> is
       "timeout", and the value of <code>Remoting.CUSTOM_SOCKET_FACTORY</code>
@@ -531,19 +515,17 @@
       <classname>SocketFactory</classname> is passed to it by way of a setter
       method:</para>
 
-      <programlisting>
-          String locatorURI = "socket://test.somedomain.com:8084";
-          String params = "/?clientMaxPoolSize=10";
-          locatorURI += params;
-          InvokerLocator locator = new InvokerLocator(locatorURI);
-          HashMap config = new HashMap();
-          config.put(ServerInvoker.TIMEOUT, 360000);
-          Client client = new Client(locator, config);
-          client.connect();
-          SocketFactory sf = new MySocketFactory();
-          ClientInvoker clientInvoker = client.getInvoker();
-          clientInvoker.setSocketFactory(sf);
-       </programlisting>
+      <programlisting>String locatorURI = "socket://test.somedomain.com:8084";
+String params = "/?clientMaxPoolSize=10";
+locatorURI += params;
+InvokerLocator locator = new InvokerLocator(locatorURI);
+HashMap config = new HashMap();
+config.put(ServerInvoker.TIMEOUT, 360000);
+Client client = new Client(locator, config);
+client.connect();
+SocketFactory sf = new MySocketFactory();
+ClientInvoker clientInvoker = client.getInvoker();
+clientInvoker.setSocketFactory(sf);</programlisting>
 
       <para><emphasis role="bold">Note.</emphasis> The
       <classname>Client</classname> creates the client invoker during the call
@@ -568,40 +550,36 @@
     ServerInvocationHandler handler)</code>. For example (from
     <code>org.jboss.remoting.samples.simple.SimpleServer</code>):</para>
 
-    <programlisting>
-            InvokerLocator locator = new InvokerLocator(locatorURI);
-            Connector connector = new Connector();
-            connector.setInvokerLocator(locator.getLocatorURI());
-            connector.create();
+    <programlisting>InvokerLocator locator = new InvokerLocator(locatorURI);
+Connector connector = new Connector();
+connector.setInvokerLocator(locator.getLocatorURI());
+connector.create();
 
-            SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
-            // first parameter is sub-system name. can be any String value.
-            connector.addInvocationHandler("sample", invocationHandler);
+SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
+// first parameter is sub-system name. can be any String value.
+connector.addInvocationHandler("sample", invocationHandler);
 
-            connector.start();
-         </programlisting>
+connector.start();</programlisting>
 
     <para>To pass the handler by ObjectName, call
     <code>Connector::addInvocationHandler(String subsystem, ObjectName
     handlerObjectName)</code> . For example (from
     <code>org.jboss.test.remoting.handler.mbean.ServerTest</code>):</para>
 
-    <programlisting>
-            MBeanServer server = MBeanServerFactory.createMBeanServer();
-            InvokerLocator locator = new InvokerLocator(locatorURI);
-            Connector connector = new Connector();
-            connector.setInvokerLocator(locator.getLocatorURI());
-            connector.start();
+    <programlisting>MBeanServer server = MBeanServerFactory.createMBeanServer();
+InvokerLocator locator = new InvokerLocator(locatorURI);
+Connector connector = new Connector();
+connector.setInvokerLocator(locator.getLocatorURI());
+connector.start();
 
-            server.registerMBean(connector, new ObjectName("test:type=connector,transport=socket"));
+server.registerMBean(connector, new ObjectName("test:type=connector,transport=socket"));
 
-            // now create Mbean handler and register with mbean server
-            MBeanHandler handler = new MBeanHandler();
-            ObjectName objName = new ObjectName("test:type=handler");
-            server.registerMBean(handler, objName);
+// now create Mbean handler and register with mbean server
+MBeanHandler handler = new MBeanHandler();
+ObjectName objName = new ObjectName("test:type=handler");
+server.registerMBean(handler, objName);
 
-            connector.addInvocationHandler("test", objName);
-         </programlisting>
+connector.addInvocationHandler("test", objName);</programlisting>
 
     <para>Is important to note that if not starting the Connector via the
     service configuration, will need to explicitly register it with the
@@ -612,13 +590,11 @@
     for the handler, which will instantiate the handler instance upon startup
     (which requires there be a void parameter constructor), such as:</para>
 
-    <programlisting>           
-            &lt;handlers&gt;
-              &lt;handler subsystem="mock"&gt;
-                org.jboss.remoting.transport.mock.MockServerInvocationHandler
-              &lt;/handler&gt;
-            &lt;/handlers&gt;
-         </programlisting>
+    <programlisting>&lt;handlers&gt;
+   &lt;handler subsystem="mock"&gt;
+      org.jboss.remoting.transport.mock.MockServerInvocationHandler
+   &lt;/handler&gt;
+&lt;/handlers&gt;</programlisting>
 
     <para>where MockServerInvocationHandler will be constructed upon startup
     and registered with the Connector as a handler.</para>
@@ -629,11 +605,9 @@
     <code>mbeanhandler-service.xml</code> under remoting tests for full
     example):</para>
 
-    <programlisting>          
-            &lt;handlers&gt;
-              &lt;handler subsystem="mock"&gt;test:type=handler&lt;/handler&gt;
-            &lt;/handlers&gt;
-         </programlisting>
+    <programlisting>&lt;handlers&gt;
+   &lt;handler subsystem="mock"&gt;test:type=handler&lt;/handler&gt;
+&lt;/handlers&gt;</programlisting>
 
     <para>The only requirement for this configuration is that the handler
     MBean must already be created and registered with the MBeanServer at the
@@ -808,12 +782,10 @@
     add the configuration attribute to the service xml) with the following xml
     element:</para>
 
-    <programlisting>    
-          &lt;domains&gt;
-            &lt;domain&gt;domain1&lt;/domain&gt;
-            &lt;domain&gt;domain2&lt;/domain&gt;
-          &lt;/domains&gt;
-         </programlisting>
+    <programlisting>&lt;domains&gt;
+   &lt;domain&gt;domain1&lt;/domain&gt;
+   &lt;domain&gt;domain2&lt;/domain&gt;
+&lt;/domains&gt;</programlisting>
 
     <para>where <code>domain1</code> and <code>domain2</code> are the two
     domains you would like the detector to accept. This will cause the
@@ -824,10 +796,8 @@
     (or add the configuration attribute to the service xml) with the following
     xml element:</para>
 
-    <programlisting>
-          &lt;domains&gt;
-          &lt;/domains&gt;
-      </programlisting>
+    <programlisting>&lt;domains&gt;
+&lt;/domains&gt;</programlisting>
 
     <para>This will cause the detector to accept all detections from any
     domain.</para>
@@ -839,29 +809,27 @@
     messages from local server invokers. This will be false by default, so
     maintains the same behavior as previous releases. For example:</para>
 
-    <programlisting>        &lt;domains&gt;
-            &lt;domain&gt;domain1&lt;/domain&gt;
-            &lt;domain&gt;domain2&lt;/domain&gt;
-        &lt;/domains&gt;
-        &lt;local/&gt; </programlisting>
+    <programlisting>&lt;domains&gt;
+   &lt;domain&gt;domain1&lt;/domain&gt;
+   &lt;domain&gt;domain2&lt;/domain&gt;
+&lt;/domains&gt;
+&lt;local/&gt;</programlisting>
 
     <para>An example entry of a Multicast detector in the jboss-service.xml
     that accepts detections only from the roxanne and sparky domains using
     port 5555, including servers in the same jvm, is as follows:</para>
 
-    <programlisting>
-         &lt;mbean code="org.jboss.remoting.detection.multicast.MulticastDetector"
-               name="jboss.remoting:service=Detector,transport=multicast"&gt;
-            &lt;attribute name="Port"&gt;5555&lt;/attribute&gt;
-            &lt;attribute name="Configuration"&gt;
-              &lt;domains&gt;
-                &lt;domain&gt;roxanne&lt;/domain&gt;
-                &lt;domain&gt;sparky&lt;/domain&gt;
-              &lt;/domains&gt;
-              &lt;local/&gt;
-            &lt;/attribute&gt;
-         &lt;/mbean&gt;
-      </programlisting>
+    <programlisting>&lt;mbean code="org.jboss.remoting.detection.multicast.MulticastDetector"
+       name="jboss.remoting:service=Detector,transport=multicast"&gt;
+   &lt;attribute name="Port"&gt;5555&lt;/attribute&gt;
+   &lt;attribute name="Configuration"&gt;
+      &lt;domains&gt;
+         &lt;domain&gt;roxanne&lt;/domain&gt;
+         &lt;domain&gt;sparky&lt;/domain&gt;
+      &lt;/domains&gt;
+      &lt;local/&gt;
+   &lt;/attribute&gt;
+&lt;/mbean&gt;</programlisting>
 
     <bridgehead>Global Detector Configuration</bridgehead>
 
@@ -905,13 +873,11 @@
     attribute within the remoting-service.xml (or anywhere else the service is
     defined). For example:</para>
 
-    <programlisting>
-         &lt;mbean code="org.jboss.remoting.detection.jndi.JNDIDetector"
-               name="jboss.remoting:service=Detector,transport=jndi"&gt;
-            &lt;attribute name="Host"&gt;localhost&lt;/attribute&gt;
-            &lt;attribute name="Port"&gt;5555&lt;/attribute&gt;
-         &lt;/mbean&gt;
-      </programlisting>
+    <programlisting>&lt;mbean code="org.jboss.remoting.detection.jndi.JNDIDetector"
+       name="jboss.remoting:service=Detector,transport=jndi"&gt;
+   &lt;attribute name="Host"&gt;localhost&lt;/attribute&gt;
+   &lt;attribute name="Port"&gt;5555&lt;/attribute&gt;
+&lt;/mbean&gt;</programlisting>
 
     <para>If the JNDIDetector is started without the Host attribute being set,
     it will try to start a local JNP instance (the JBoss JNDI server
@@ -999,7 +965,8 @@
         connect to addresses different than the bind addresses, and a set of connect
         addresses may be specified with a "connecthomes" parameter:</para>
         
-        <programlisting>socket://multihome/?homes=10.32.4.2:6500!192.168.4.2:6501&amp;connecthomes=10.32.42.2:7500!192.168.42.2:7501</programlisting>
+        <programlisting>socket://multihome/?homes=10.32.4.2:6500!192.168.4.2:6501
+       &amp;connecthomes=10.32.42.2:7500!192.168.42.2:7501</programlisting>
      
         <para>specifies a server that binds to 10.32.4.2:6500 and 192.168.4.2:6501,
         as before, but now a client connects to it using the addresses
@@ -1009,32 +976,30 @@
         files and *-beans.xml POJO files. The following MBean definition is
         equivalent to the preceding locator:</para>
         
-        <programlisting> 
-           &lt;mbean code="org.jboss.remoting.transport.Connector"
-               name="jboss.remoting:service=Connector,transport=Socket"
-               display-name="Socket transport Connector"&gt;
+        <programlisting>&lt;mbean code="org.jboss.remoting.transport.Connector"
+       name="jboss.remoting:service=Connector,transport=Socket"
+       display-name="Socket transport Connector"&gt;
     
-              &lt;attribute name="Configuration"&gt;
-                 &lt;config&gt;
-                    &lt;invoker transport="socket"&gt;
-                       <emphasis role="bold">
-                       &lt;attribute name="homes"&gt;
-                          &lt;home&gt;10.32.4.2:6500&lt;/home&gt;
-                          &lt;home&gt;192.168.4.2:6501&lt;/home&gt;
-                       &lt;/attribute&gt;
-                       &lt;attribute name="connecthomes"&gt;
-                          &lt;connecthome&gt;10.32.42.2:7500&lt;/connecthome&gt;
-                          &lt;connecthome&gt;192.168.42.2:7501&lt;/connecthome&gt;
-                       &lt;/attribute&gt;
-                       </emphasis>
-                    &lt;/invoker&gt;
-                    &lt;handlers&gt;
-                       ...
-                    &lt;/handlers&gt;
-                 &lt;/config&gt;
-              &lt;/attribute&gt;
-           &lt;/mbean&gt;
-        </programlisting>
+   &lt;attribute name="Configuration"&gt;
+      &lt;config&gt;
+         &lt;invoker transport="socket"&gt;
+            <emphasis role="bold">
+            &lt;attribute name="homes"&gt;
+               &lt;home&gt;10.32.4.2:6500&lt;/home&gt;
+               &lt;home&gt;192.168.4.2:6501&lt;/home&gt;
+            &lt;/attribute&gt;
+            &lt;attribute name="connecthomes"&gt;
+               &lt;connecthome&gt;10.32.42.2:7500&lt;/connecthome&gt;
+               &lt;connecthome&gt;192.168.42.2:7501&lt;/connecthome&gt;
+            &lt;/attribute&gt;
+            </emphasis>
+         &lt;/invoker&gt;
+         &lt;handlers&gt;
+            ...
+         &lt;/handlers&gt;
+      &lt;/config&gt;
+   &lt;/attribute&gt;
+&lt;/mbean&gt;</programlisting>
         
         <para>The "serverBindPort" and "clientConnectPort" attributes may be used to
         give default values for bind ports and connect ports, respectively.</para>
@@ -1042,27 +1007,25 @@
         <para>The same server may be configured with the
         <classname>org.jboss.remoting.ServerInvocation</classname> object as well.
         For example,</para>    
-        <programlisting>
-             Connector connector = new Connector();
+        <programlisting>Connector connector = new Connector();
          
-             // Create ServerConfiguration object for socket transport
-             ServerConfiguration serverConfig = new ServerConfiguration("socket");
+// Create ServerConfiguration object for socket transport
+ServerConfiguration serverConfig = new ServerConfiguration("socket");
             
-             // Add invokerLocatorParameters (applicable to client and server)
-             Map locatorConfig = new HashMap();
-             <emphasis role="bold">
-             locatorConfig.put("homes", "10.32.4.2:6500!192.168.4.2:6501");
-             locatorConfig.put("connecthomes", "10.32.42.2:7500!192.168.42.2:7501");
-             </emphasis>
-             serverConfig.setInvokerLocatorParameters(locatorConfig);
+// Add invokerLocatorParameters (applicable to client and server)
+Map locatorConfig = new HashMap();
+<emphasis role="bold">
+locatorConfig.put("homes", "10.32.4.2:6500!192.168.4.2:6501");
+locatorConfig.put("connecthomes", "10.32.42.2:7500!192.168.42.2:7501");
+</emphasis>
+serverConfig.setInvokerLocatorParameters(locatorConfig);
                    
-             // Add invocation handlers
-             ...
+// Add invocation handlers
+...
              
-             connector.setServerConfiguration(serverConfig);
-             connector.create();
-             connector.start();
-          </programlisting>
+connector.setServerConfiguration(serverConfig);
+connector.create();
+connector.start();</programlisting>
               
         <para>is equivalent to the preceding MBean definition.</para>
         
@@ -1083,19 +1046,17 @@
          <classname>org.jboss.remoting.socketfactory.SocketCreationListener</classname>
          </para>
          
-         <programlisting>
-            public interface SocketCreationListener
-            {
-               /**
-                * Called when a socket has been created.
-                * 
-                * @param socket socket that has been created
-                * @param source SocketFactory or ServerSocket that created the socket
-                * @throws IOException
-                */
-               void socketCreated(Socket socket, Object source) throws IOException;
-            }
-         </programlisting>
+         <programlisting>public interface SocketCreationListener
+{
+   /**
+    * Called when a socket has been created.
+    * 
+    * @param socket socket that has been created
+    * @param source SocketFactory or ServerSocket that created the socket
+    * @throws IOException
+    */
+   void socketCreated(Socket socket, Object source) throws IOException;
+}</programlisting>
          
          <para>Socket creation listeners can be configured through the use of
          the keys
@@ -1124,9 +1085,7 @@
          <methodname>org.jboss.remoting.Client.getAddressSeenByServer()</methodname>,
          with signature</para>
          
-         <programlisting>
-            public InetAddress getAddressSeenByServer() throws Throwable
-         </programlisting>
+         <programlisting>public InetAddress getAddressSeenByServer() throws Throwable</programlisting>
          
          <para>returns the IP address of the client as seen by the server. On
          the server side, the same IP address is placed in the request payload
@@ -1136,14 +1095,12 @@
          <classname>org.jboss.remoting.ServerInvocationHandler</classname> as
          follows:</para>
          
-         <programlisting>
-            public Object invoke(InvocationRequest invocation throws Throwable
-            {
-               ...
-               InetAddress address = invocation.getRequestPayload().get(Remoting.CLIENT_ADDRESS);
-               ...
-            }
-         </programlisting>
+         <programlisting>public Object invoke(InvocationRequest invocation throws Throwable
+{
+   ...
+   InetAddress address = invocation.getRequestPayload().get(Remoting.CLIENT_ADDRESS);
+   ...
+}</programlisting>
       </section>
       
       
@@ -1153,13 +1110,11 @@
          <para><classname>org.jboss.remoting.InvokerLocator</classname> will now
          accept IPv6 IP addresses. For example,</para>
          
-         <programlisting>
-            socket://[::1]:3333/?timeout=10000
-            socket://[::]:4444/?timeout=10000
-            socket://[::ffff:127.0.0.1]:5555/?timeout=10000
-            socket://[fe80::205:9aff:fe3c:7800%7]:6666/?timeout=10000
-            socket://multihome/?homes=[fe80::205:9aff:fe3c:7800%7]:7777![fe80::214:22ff:feef:68bb%4]:8888
-         </programlisting>
+         <programlisting>socket://[::1]:3333/?timeout=10000
+socket://[::]:4444/?timeout=10000
+socket://[::ffff:127.0.0.1]:5555/?timeout=10000
+socket://[fe80::205:9aff:fe3c:7800%7]:6666/?timeout=10000
+socket://multihome/?homes=[fe80::205:9aff:fe3c:7800%7]:7777![fe80::214:22ff:feef:68bb%4]:8888</programlisting>
       </section>
       
       <section>
@@ -1167,11 +1122,9 @@
          
          <para>Multiple clients may share a single client invoker.  For example, in the code</para>
          
-         <programlisting>
-            InvokerLocator locator = new InvokerLocator("socket://127.0.0.1:5555");
-            Client client1 = new Client(locator);
-            Client client2 = new Client(locator);
-         </programlisting>
+         <programlisting>InvokerLocator locator = new InvokerLocator("socket://127.0.0.1:5555");
+Client client1 = new Client(locator);
+Client client2 = new Client(locator);</programlisting>
          
          <para><code>client1</code> and <code>client2</code> will both
          communicate with the server through a single
@@ -1185,13 +1138,12 @@
          <code>Client.INVOKER_DESTRUCTION_DELAY</code> (actual value
          "invokerDestructionDelay").  For example,</para>
          
-         <programlisting>
-            InvokerLocator locator = new InvokerLocator("socket://127.0.0.1:5555/?invokerDestructionDelay=5000");
-            Client client = new Client(locator);
-            client.connect();
-               ...
-            client.disconnect();
-         </programlisting>
+         <programlisting>InvokerLocator locator =
+        new InvokerLocator("socket://127.0.0.1:5555/?invokerDestructionDelay=5000");
+Client client = new Client(locator);
+client.connect();
+...
+client.disconnect();</programlisting>
          
          <para>will cause <code>client</code> to delay the destruction of its
          client invoker (assuming <code>client</code> is the only user), by 5000
@@ -1285,37 +1237,27 @@
       in the InvokerLocator, the server will bind to the address of the local
       host, as determined by the call</para>
       
-      <programlisting>
-         InetAddress.getLocalHost().getHostAddress();
-      </programlisting>
+      <programlisting>InetAddress.getLocalHost().getHostAddress();</programlisting>
       
-      <para>In other words, the logic is
- 		</para>
+      <para>In other words, the logic is</para>
+      <programlisting>if (serverBindAddress is set)
+   use it
+else if (the host is present in the InvokerLocator and clientConnectAddress is not set)
+   use host from InvokerLocator
+else
+   use local host address</programlisting>
 
-		<programlisting>
-         if (serverBindAddress is set)
-            use it
-         else if (the host is present in the InvokerLocator and clientConnectAddress is not set)
-            use host from InvokerLocator
-         else
-            use local host address	
-      </programlisting>
-
       <para>There is one other exception.  If the InvokerLocator address is
       0.0.0.0 and the system property called 'remoting.bind_by_host' is set to
       true, then the local host name will be used, as determined by the call</para>
       
-      <programlisting>
-         InetAddress.getLocalHost().getHostName();
-      </programlisting>
+      <programlisting>InetAddress.getLocalHost().getHostName();</programlisting>
       
       <para>If 'remoting.bind_by_host' is set to false, then local host address will
       be used.  To facilitate setting this property, the following static variable is
       defined in <classname>InvokerLocator</classname>:</para>
 
-      <programlisting>
-         public static final String BIND_BY_HOST = "remoting.bind_by_host";
-      </programlisting>
+      <programlisting>public static final String BIND_BY_HOST = "remoting.bind_by_host";</programlisting>
 
       <para>If the serverBindPort property is set, it will be used. If this
       value is 0 or a negative number, then the next available port will be
@@ -1804,9 +1746,7 @@
       <para>If a request on the HTTP transport is made with the
       <classname>org.jboss.remoting.Client</classname> method</para>
       
-      <programlisting>
-         public Object invoke(Object param, Map metadata) throws Throwable
-      </programlisting>
+      <programlisting>public Object invoke(Object param, Map metadata) throws Throwable</programlisting>
       
       <para>then
       <classname>org.jboss.remoting.transport.http.HTTPClientInvoker</classname>
@@ -1816,13 +1756,11 @@
       (actual value "ResponseHeaders"). For example, the response header "Date"
       can be retrieved as follows:</para>
       
-      <programlisting>
-        Object payload = ... ;
-        HashMap metadata = new HashMap();
-        client.invoke(payload, metadata);
-        Map responseHeaders = (Map) metadata.get(HTTPMetadataConstants.RESPONSE_HEADERS);
-        String date = (String) responseHeaders.get("Date");
-      </programlisting>
+      <programlisting>Object payload = ... ;
+HashMap metadata = new HashMap();
+client.invoke(payload, metadata);
+Map responseHeaders = (Map) metadata.get(HTTPMetadataConstants.RESPONSE_HEADERS);
+String date = (String) responseHeaders.get("Date");</programlisting>
       
       <bridgehead>CR/LF in HTTP transport</bridgehead>
     
@@ -1870,18 +1808,16 @@
 
       <para>An example would be:</para>
 
-      <programlisting>
-               Map metadata = new HashMap();
-               ...
+      <programlisting>Map metadata = new HashMap();
+...
 
-               // proxy info
-               metadata.put("http.proxyHost", "ginger");
-               metadata.put("http.proxyPort", "80");
+// proxy info
+metadata.put("http.proxyHost", "ginger");
+metadata.put("http.proxyPort", "80");
 
-               ...
+...
 
-               response = client.invoke(payload, metadata);
-            </programlisting>
+response = client.invoke(payload, metadata);</programlisting>
 
       <para>The http.proxyPort property is not required and if not present,
       will use default of 80. Note: setting the proxy config in this way can
@@ -1993,26 +1929,24 @@
       existing service xml or creating a new one. The following is an example
       of how to declare a Connector that uses the servlet invoker:</para>
 
-      <programlisting>
-           &lt;mbean code="org.jboss.remoting.transport.Connector"
-                  name="jboss.remoting:service=Connector,transport=Servlet"
-                  display-name="Servlet transport Connector"&gt;
+      <programlisting>&lt;mbean code="org.jboss.remoting.transport.Connector"
+       name="jboss.remoting:service=Connector,transport=Servlet"
+       display-name="Servlet transport Connector"&gt;
 
-              &lt;attribute name="InvokerLocator"&gt;
-                 servlet://localhost:8080/servlet-invoker/ServerInvokerServlet
-              &lt;/attribute&gt;
+   &lt;attribute name="InvokerLocator"&gt;
+      servlet://localhost:8080/servlet-invoker/ServerInvokerServlet
+   &lt;/attribute&gt;
 
-              &lt;attribute name="Configuration"&gt;
-                 &lt;config&gt;
-                    &lt;handlers&gt;
-                       &lt;handler subsystem="test"&gt;
-                          org.jboss.test.remoting.transport.web.WebInvocationHandler
-                       &lt;/handler&gt;
-                    &lt;/handlers&gt;
-                 &lt;/config&gt;
-              &lt;/attribute&gt;
-           &lt;/mbean&gt;
-        </programlisting>
+   &lt;attribute name="Configuration"&gt;
+      &lt;config&gt;
+         &lt;handlers&gt;
+            &lt;handler subsystem="test"&gt;
+               org.jboss.test.remoting.transport.web.WebInvocationHandler
+            &lt;/handler&gt;
+         &lt;/handlers&gt;
+      &lt;/config&gt;
+   &lt;/attribute&gt;
+&lt;/mbean&gt;</programlisting>
 
       <para>An important point of configuration to note is that the value for
       the InvokerLocator attribute is the exact url used to access the servlet
@@ -2032,36 +1966,41 @@
       the WEB-INF directory is located the web.xml file. This is a standard
       web configuration file and should look like:</para>
 
-      <programlisting> &lt;?xml version="1.0" encoding="UTF-8"?&gt;
- &lt;!DOCTYPE web-app PUBLIC
-    "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
-    "http://java.sun.com/dtd/web-app_2_3.dtd"&gt;
+      <programlisting>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
+&lt;!DOCTYPE web-app PUBLIC
+   "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
+   "http://java.sun.com/dtd/web-app_2_3.dtd"&gt;
 
- &lt;web-app&gt;
-     &lt;servlet&gt;
-         &lt;servlet-name&gt;ServerInvokerServlet&lt;/servlet-name&gt;
-         &lt;description&gt;The ServerInvokerServlet receives requests via HTTP
-            protocol from within a web container and passes it onto the
-            ServletServerInvoker for processing.
-         &lt;/description&gt;
-         &lt;servlet-class&gt;org.jboss.remoting.transport.servlet.web.ServerInvokerServlet&lt;/servlet-class&gt;
-         &lt;init-param&gt;
-             &lt;param-name&gt;invokerName&lt;/param-name&gt;
-             &lt;param-value&gt;jboss.remoting:service=invoker,transport=servlet&lt;/param-value&gt;
-             &lt;description&gt;The servlet server invoker&lt;/description&gt;
-            &lt;!--
-             &lt;param-name&gt;locatorUrl&lt;/param-name&gt;
-             &lt;param-value&gt;servlet://localhost:8080/servlet-invoker/ServerInvokerServlet&lt;/param-value&gt;
-             &lt;description&gt;The servlet server invoker locator url&lt;/description&gt;
-            --&gt;
-         &lt;/init-param&gt;
-         &lt;load-on-startup&gt;1&lt;/load-on-startup&gt;
-     &lt;/servlet&gt;
-     &lt;servlet-mapping&gt;
-         &lt;servlet-name&gt;ServerInvokerServlet&lt;/servlet-name&gt;
-         &lt;url-pattern&gt;/ServerInvokerServlet/*&lt;/url-pattern&gt;
-     &lt;/servlet-mapping&gt;
- &lt;/web-app&gt;</programlisting>
+&lt;web-app&gt;
+   &lt;servlet&gt;
+      &lt;servlet-name&gt;ServerInvokerServlet&lt;/servlet-name&gt;
+      &lt;description&gt;
+         The ServerInvokerServlet receives requests via HTTP protocol from 
+         within a web container and passes it onto the ServletServerInvoker 
+         for processing.
+      &lt;/description&gt;
+      &lt;servlet-class&gt;
+         org.jboss.remoting.transport.servlet.web.ServerInvokerServlet
+      &lt;/servlet-class&gt;
+      &lt;init-param&gt;
+         &lt;param-name&gt;invokerName&lt;/param-name&gt;
+         &lt;param-value&gt;jboss.remoting:service=invoker,transport=servlet&lt;/param-value&gt;
+         &lt;description&gt;The servlet server invoker&lt;/description&gt;
+         &lt;!--
+         &lt;param-name&gt;locatorUrl&lt;/param-name&gt;
+         &lt;param-value&gt;
+            servlet://localhost:8080/servlet-invoker/ServerInvokerServlet
+         &lt;/param-value&gt;
+         &lt;description&gt;The servlet server invoker locator url&lt;/description&gt;
+         --&gt;
+      &lt;/init-param&gt;
+      &lt;load-on-startup&gt;1&lt;/load-on-startup&gt;
+   &lt;/servlet&gt;
+   &lt;servlet-mapping&gt;
+      &lt;servlet-name&gt;ServerInvokerServlet&lt;/servlet-name&gt;
+      &lt;url-pattern&gt;/ServerInvokerServlet/*&lt;/url-pattern&gt;
+   &lt;/servlet-mapping&gt;
+&lt;/web-app&gt;</programlisting>
 
       <para>There are two ways in which the servlet can obtain a reference to
       the servlet server invoker it needs to pass its request onto. The first
@@ -2120,54 +2059,60 @@
       <para>An example of the mbean service xml for deploying the ssl servlet
       server invoker would be:</para>
 
-      <programlisting> &lt;?xml version="1.0" encoding="UTF-8"?&gt;
-
- &lt;server&gt;
+      <programlisting>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
+&lt;server&gt;
    &lt;mbean code="org.jboss.remoting.transport.Connector"
           name="jboss.remoting:service=Connector,transport=SSLServlet"
           display-name="SSL Servlet transport Connector"&gt;
 
-              &lt;attribute name="InvokerLocator"&gt;
-                 sslservlet://localhost:8443/servlet-invoker/ServerInvokerServlet
-              &lt;/attribute&gt;
-              &lt;attribute name="Configuration"&gt;
-                 &lt;config&gt;
-                    &lt;handlers&gt;
-                       &lt;handler subsystem="test"&gt;org.jboss.test.remoting.transport.web.WebInvocationHandler&lt;/handler&gt;
-                    &lt;/handlers&gt;
-                 &lt;/config&gt;
-              &lt;/attribute&gt;
+      &lt;attribute name="InvokerLocator"&gt;
+         sslservlet://localhost:8443/servlet-invoker/ServerInvokerServlet
+      &lt;/attribute&gt;
+      &lt;attribute name="Configuration"&gt;
+         &lt;config&gt;
+            &lt;handlers&gt;
+               &lt;handler subsystem="test"&gt;
+                  org.jboss.test.remoting.transport.web.WebInvocationHandler
+               &lt;/handler&gt;
+            &lt;/handlers&gt;
+         &lt;/config&gt;
+      &lt;/attribute&gt;
    &lt;/mbean&gt;
- &lt;/server&gt; </programlisting>
+&lt;/server&gt;</programlisting>
 
       <para>An example of servlet-invoker.war/WEB-INF/web.xml for the ssl
       server invoker servlet would be:</para>
 
-      <programlisting> &lt;?xml version="1.0" encoding="UTF-8"?&gt;
- &lt;!DOCTYPE web-app PUBLIC
+      <programlisting>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
+&lt;!DOCTYPE web-app PUBLIC
     "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
     "http://java.sun.com/dtd/web-app_2_3.dtd"&gt;
 
- &lt;web-app&gt;
-     &lt;servlet&gt;
-         &lt;servlet-name&gt;ServerInvokerServlet&lt;/servlet-name&gt;
-         &lt;description&gt;The ServerInvokerServlet receives requests via HTTP
-            protocol from within a web container and passes it onto the
-            ServletServerInvoker for processing.
-         &lt;/description&gt;
-         &lt;servlet-class&gt;org.jboss.remoting.transport.servlet.web.ServerInvokerServlet&lt;/servlet-class&gt;
-         &lt;init-param&gt;
-             &lt;param-name&gt;locatorUrl&lt;/param-name&gt;
-             &lt;param-value&gt;sslservlet://localhost:8443/servlet-invoker/ServerInvokerServlet&lt;/param-value&gt;
-             &lt;description&gt;The servlet server invoker locator url&lt;/description&gt;
-         &lt;/init-param&gt;
-         &lt;load-on-startup&gt;1&lt;/load-on-startup&gt;
-     &lt;/servlet&gt;
-    &lt;servlet-mapping&gt;
-         &lt;servlet-name&gt;ServerInvokerServlet&lt;/servlet-name&gt;
-         &lt;url-pattern&gt;/ServerInvokerServlet/*&lt;/url-pattern&gt;
-     &lt;/servlet-mapping&gt;
- &lt;/web-app&gt; </programlisting>
+&lt;web-app&gt;
+   &lt;servlet&gt;
+      &lt;servlet-name&gt;ServerInvokerServlet&lt;/servlet-name&gt;
+      &lt;description&gt;
+         The ServerInvokerServlet receives requests via HTTP protocol from 
+         within a web container and passes it onto the ServletServerInvoker
+         for processing.
+      &lt;/description&gt;
+      &lt;servlet-class&gt;
+         org.jboss.remoting.transport.servlet.web.ServerInvokerServlet
+      &lt;/servlet-class&gt;
+      &lt;init-param&gt;
+         &lt;param-name&gt;locatorUrl&lt;/param-name&gt;
+         &lt;param-value&gt;
+            sslservlet://localhost:8443/servlet-invoker/ServerInvokerServlet
+         &lt;/param-value&gt;
+         &lt;description&gt;The servlet server invoker locator url&lt;/description&gt;
+      &lt;/init-param&gt;
+      &lt;load-on-startup&gt;1&lt;/load-on-startup&gt;
+   &lt;/servlet&gt;
+   &lt;servlet-mapping&gt;
+      &lt;servlet-name&gt;ServerInvokerServlet&lt;/servlet-name&gt;
+      &lt;url-pattern&gt;/ServerInvokerServlet/*&lt;/url-pattern&gt;
+   &lt;/servlet-mapping&gt;
+&lt;/web-app&gt;</programlisting>
     </section>
 
     <section>
@@ -2196,9 +2141,7 @@
       <classname>org.jboss.remoting.Client</classname> is created, or it may be
       included in the metadata map passed to</para>
       
-      <programlisting>
-         public Object invoke(Object param, Map metadata) throws Throwable;
-      </programlisting>
+      <programlisting>public Object invoke(Object param, Map metadata) throws Throwable;</programlisting>
       .
       <para>This will cause the http client invoker to not throw an exception,
       but instead return the data from the web server error stream. In the case
@@ -2646,8 +2589,8 @@
     side). This can be done by the following method call within the
     MarshalFactory:</para>
 
-    <programlisting>public static void addMarshaller(String dataType, Marshaller marshaller, UnMarshaller unMarshaller)
-      </programlisting>
+    <programlisting>public static void addMarshaller(
+        String dataType, Marshaller marshaller, UnMarshaller unMarshaller)</programlisting>
 
     <para>The dataType passed can be any String value desired. For example,
     could add custom InvocationMarshaller and InvocationUnMarshaller with the
@@ -2684,29 +2627,25 @@
     simply add the datatype, marshaller, and unmarshaller parameters to the
     defined InvokerLocator attribute value. For example:</para>
 
-    <programlisting>
-         &lt;attribute name="InvokerLocator"&gt;
-            &lt;![CDATA[socket://${jboss.bind.address}:8084/?datatype=invocation&amp;
-            marshaller=org.jboss.invocation.unified.marshall.InvocationMarshaller&amp;
-            unmarshaller=org.jboss.invocation.unified.marshall.InvocationUnMarshaller]]&gt;
-         &lt;/attribute&gt;
-      </programlisting>
+    <programlisting>&lt;attribute name="InvokerLocator"&gt;
+   &lt;![CDATA[socket://${jboss.bind.address}:8084/?datatype=invocation&amp;
+      marshaller=org.jboss.invocation.unified.marshall.InvocationMarshaller&amp;
+      unmarshaller=org.jboss.invocation.unified.marshall.InvocationUnMarshaller]]&gt;
+&lt;/attribute&gt;</programlisting>
 
     <para>If were using config element to declare the invoker, will need to
     add an attribute for each and include the isParam attribute set to true.
     For example:</para>
 
-    <programlisting>
-         &lt;invoker transport="socket"&gt;
-            &lt;attribute name="dataType" isParam="true"&gt;invocation&lt;/attribute&gt;
-            &lt;attribute name="marshaller" isParam="true"&gt;
-               org.jboss.invocation.unified.marshall.InvocationMarshaller
-            &lt;/attribute&gt;
-            &lt;attribute name="unmarshaller" isParam="true"&gt;
-                  org.jboss.invocation.unified.marshall.InvocationUnMarshaller
-            &lt;/attribute&gt;
-         &lt;/invoker&gt;
-      </programlisting>
+    <programlisting>&lt;invoker transport="socket"&gt;
+   &lt;attribute name="dataType" isParam="true"&gt;invocation&lt;/attribute&gt;
+   &lt;attribute name="marshaller" isParam="true"&gt;
+      org.jboss.invocation.unified.marshall.InvocationMarshaller
+   &lt;/attribute&gt;
+   &lt;attribute name="unmarshaller" isParam="true"&gt;
+      org.jboss.invocation.unified.marshall.InvocationUnMarshaller
+   &lt;/attribute&gt;
+&lt;/invoker&gt;</programlisting>
 
     <para>This configuration is fine if the classes are present within the
     client's classpath. If they are not, can provide configuration for
@@ -2714,18 +2653,16 @@
     this, can use the parameter 'loaderport' with the value of the port you
     would like your marshal loader to run on. For example:</para>
 
-    <programlisting>
-         &lt;invoker transport="socket"&gt;
-            &lt;attribute name="dataType" isParam="true"&gt;invocation&lt;/attribute&gt;
-            &lt;attribute name="marshaller" isParam="true"&gt;
-               org.jboss.invocation.unified.marshall.InvocationMarshaller
-            &lt;/attribute&gt;
-            &lt;attribute name="unmarshaller" isParam="true"&gt;
-               org.jboss.invocation.unified.marshall.InvocationUnMarshaller
-            &lt;/attribute&gt;
-            &lt;attribute name="loaderport" isParam="true"&gt;5401&lt;/attribute&gt;
-         &lt;/invoker&gt;
-      </programlisting>
+    <programlisting>&lt;invoker transport="socket"&gt;
+   &lt;attribute name="dataType" isParam="true"&gt;invocation&lt;/attribute&gt;
+   &lt;attribute name="marshaller" isParam="true"&gt;
+      org.jboss.invocation.unified.marshall.InvocationMarshaller
+   &lt;/attribute&gt;
+   &lt;attribute name="unmarshaller" isParam="true"&gt;
+      org.jboss.invocation.unified.marshall.InvocationUnMarshaller
+   &lt;/attribute&gt;
+   &lt;attribute name="loaderport" isParam="true"&gt;5401&lt;/attribute&gt;
+&lt;/invoker&gt;</programlisting>
 
     <para>When this parameter is supplied, the Connector will recognize this
     at startup and create a marshal loader connector automatically, which will
@@ -2794,9 +2731,7 @@
           creation of a callback connection results in a server side call to the
         </para>
         
-        <programlisting>
-          public void addListener(InvokerCallbackHandler callbackHandler);
-        </programlisting>
+        <programlisting>public void addListener(InvokerCallbackHandler callbackHandler);</programlisting>
         
         <para>
           method of the application's
@@ -2867,9 +2802,7 @@
           One way to transmit a callback is by invoking the
         </para>
         
-        <programlisting>
-          public void handleCallback(Callback callback) throws HandleCallbackException;
-        </programlisting>
+        <programlisting>public void handleCallback(Callback callback) throws HandleCallbackException;</programlisting>
         
         <para>
           method of <classname>InvokerCallbackHandler</classname>. The
@@ -2890,11 +2823,10 @@
           <methodname>handleCallbackOneway()</methodname> methods
         </para>
         
-        <programlisting>
-          public void handleCallbackOneway(Callback callback) throws HandleCallbackException;
+        <programlisting>public void handleCallbackOneway(Callback callback) throws HandleCallbackException;
   
-          public void handleCallbackOneway(Callback callback, boolean serverSide)) throws HandleCallbackException;
-        </programlisting>
+public void handleCallbackOneway(Callback callback, boolean serverSide)
+        throws HandleCallbackException;</programlisting>
         
         <para>
           of <classname>AsynchInvokerCallbackHandler</classname>. (Note that all
@@ -2909,9 +2841,7 @@
           <code>clientSide</code> parameter in the
         </para>
         
-        <programlisting>
-           public void invokeOneway(final Object param, final Map sendPayload, boolean clientSide) throws Throwable;
-        </programlisting>
+        <programlisting>public void invokeOneway(Object param, Map sendPayload, boolean clientSide) throws Throwable;</programlisting>
           
         <para>
           method of <classname>org.jboss.remoting.Client</classname>. That is,
@@ -3047,17 +2977,16 @@
           <classname>org.jboss.remoting.callback.CallbackListener</classname> interface
         </para>
         
-        <programlisting>
-        public interface CallbackListener
-        {
-           /**
-            * @param callbackHandler InvokerCallbackHandler that handled this callback
-            * @param callbackId id of callback being acknowledged
-            * @param response either (1) response sent with acknowledgement or (2) null
-            */
-           void acknowledgeCallback(InvokerCallbackHandler callbackHandler, Object callbackId, Object response);
-        }
-        </programlisting>
+        <programlisting>public interface CallbackListener
+{
+   /**
+    * @param callbackHandler InvokerCallbackHandler that handled this callback
+    * @param callbackId id of callback being acknowledged
+    * @param response either (1) response sent with acknowledgement or (2) null
+    */
+   void acknowledgeCallback(
+           InvokerCallbackHandler callbackHandler, Object callbackId, Object response);
+}</programlisting>
           
         <para>
           may be registered to receive an acknowledgement for a particular
@@ -3098,15 +3027,17 @@
           <methodname>acknowledgeCallbacks()</methodname> methods
         </para>
         
-        <programlisting>
-           public int acknowledgeCallback(InvokerCallbackHandler callbackHandler, Callback callback) throws Throwable;
+        <programlisting>public int acknowledgeCallback(
+        InvokerCallbackHandler callbackHandler, Callback callback) throws Throwable;
            
-           public int acknowledgeCallback(InvokerCallbackHandler callbackHandler, Callback callback, Object response) throws Throwable;
+public int acknowledgeCallback(
+        InvokerCallbackHandler callbackHandler, Callback callback, Object response) throws Throwable;
            
-           public int acknowledgeCallbacks(InvokerCallbackHandler callbackHandler, List callbacks) throws Throwable;
+public int acknowledgeCallbacks(
+        InvokerCallbackHandler callbackHandler, List callbacks) throws Throwable;
            
-           public int acknowledgeCallbacks(InvokerCallbackHandler callbackHandler, List callbacks, List responses) throws Throwable;
-        </programlisting>
+public int acknowledgeCallbacks(
+        InvokerCallbackHandler callbackHandler, List callbacks, List responses) throws Throwable;</programlisting>
         
         <para>
           of the <classname>Client</classname> class. In each case the
@@ -3169,13 +3100,15 @@
          <classname>Client</classname> class:
        </para>
         
-        <programlisting>
-          public void addListener(InvokerCallbackHandler) throws Throwable;
+        <programlisting>public void addListener(
+        InvokerCallbackHandler) throws Throwable;
           
-          public void addListener(InvokerCallbackHandler callbackHandler, InvokerLocator clientLocator) throws Throwable;
+public void addListener(
+        InvokerCallbackHandler callbackHandler, InvokerLocator clientLocator) throws Throwable;
           
-          public void addListener(InvokerCallbackHandler callbackHandler,  InvokerLocator clientLocator, Object callbackHandlerObject) throws Throwable;
-        </programlisting>
+public void addListener(
+        InvokerCallbackHandler callbackHandler,  InvokerLocator clientLocator,
+        Object callbackHandlerObject) throws Throwable;</programlisting>
         
         <para>
           where, in the latter two cases, the <code>clientLocator</code> parameter is set to null.  
@@ -3185,9 +3118,7 @@
           The callbacks stored for a pull callback connection may be retrieved by calling the
         </para>
         
-        <programlisting>
-          public List getCallbacks(InvokerCallbackHandler callbackHandler) throws Throwable
-        </programlisting>
+        <programlisting>public List getCallbacks(InvokerCallbackHandler callbackHandler) throws Throwable</programlisting>
         
         <para>
           method of the <classname>Client</classname> class. Note that for pull
@@ -3217,9 +3148,8 @@
         or <classname>ServerInvoker.NONBLOCKING</classname> (actual value
         "nonblocking") in the metadata map passed to</para>
         
-        <programlisting>
-          public List getCallbacks(InvokerCallbackHandler callbackHandler, Map metadata) throws Throwable;
-        </programlisting>
+        <programlisting>public List getCallbacks(
+        InvokerCallbackHandler callbackHandler, Map metadata) throws Throwable;</programlisting>
         
         <para>in <classname>org.jboss.remoting.Client</classname>. The default
         value is <code>ServerInvoker.NONBLOCKING</code>. The blocking timeout value
@@ -3303,11 +3233,12 @@
           <methodname>addListener()</methodname>:
         </para>
         
-        <programlisting>
-          public void addListener(InvokerCallbackHandler callbackHandler, InvokerLocator clientLocator) throws Throwable;
+        <programlisting>public void addListener(
+        InvokerCallbackHandler callbackHandler, InvokerLocator clientLocator) throws Throwable;
           
-          public void addListener(InvokerCallbackHandler callbackHandler,InvokerLocator clientLocator, Object callbackHandlerObject) throws Throwable;
-        </programlisting>
+public void addListener(
+        InvokerCallbackHandler callbackHandler,InvokerLocator clientLocator,
+        Object callbackHandlerObject) throws Throwable;</programlisting>
         
         <para>
           Because there is a <classname>Connector</classname>, explicit configuration always results in true push callbacks.
@@ -3320,13 +3251,16 @@
          <methodname>addListener()</methodname> is used:
         </para>
                 
-        <programlisting>
-          public void addListener(InvokerCallbackHandler callbackhandler, Map metadata) throws Throwable;
+        <programlisting>public void addListener(
+        InvokerCallbackHandler callbackhandler, Map metadata) throws Throwable;
           
-          public void addListener(InvokerCallbackHandler callbackhandler, Map metadata, Object callbackHandlerObject) throws Throwable;
+public void addListener(
+        InvokerCallbackHandler callbackhandler, Map metadata,
+        Object callbackHandlerObject) throws Throwable;
           
-          public void addListener(InvokerCallbackHandler callbackhandler, Map metadata, Object callbackHandlerObject, boolean serverToClient) throws Throwable;
-        </programlisting>   
+public void addListener(
+        InvokerCallbackHandler callbackhandler, Map metadata,
+        Object callbackHandlerObject, boolean serverToClient) throws Throwable;</programlisting>   
   
         <para>
           Note that the latter three methods are distinguished from the first
@@ -3377,11 +3311,9 @@
           methods. For example,
         </para>
         
-        <programlisting>
-        InvokerCallbackHandler callbackHandler = new SampleCallbackHandler();
-        client.addListener(callbackHandler, new HashMap(), null, true);
-        client.addListener(callbackHandler, new HashMap(), null, true);
-        </programlisting>
+        <programlisting>InvokerCallbackHandler callbackHandler = new SampleCallbackHandler();
+client.addListener(callbackHandler, new HashMap(), null, true);
+client.addListener(callbackHandler, new HashMap(), null, true);</programlisting>
         
         <para>
           would result in a set of two callback
@@ -3391,23 +3323,19 @@
           <classname>Client</classname> method
         </para>
         
-        <programlisting>
-        public Set getCallbackConnectors(InvokerCallbackHandler callbackHandler);
-        </programlisting>
+        <programlisting>public Set getCallbackConnectors(InvokerCallbackHandler callbackHandler);</programlisting>
         
         <para>
           A callback <classname>Connector</classname> could be reused as in the
           following code:
         </para>
         
-        <programlisting>
-        InvokerCallbackHandler callbackHandler1 = new SampleCallbackHandler();
-        client.addListener(callbackHandler1, new HashMap(), null, true);
-        Set callbackConnectors = client.getCallbackConnectors(callbackHandler1);
-        Connector callbackConnector = (Connector) callbackConnectors.iterator().next();
-        InvokerCallbackHandler callbackHandler2 = new SampleCallbackHandler();
-        client.addListener(callbackHandler2, callbackConnector.getLocator());
-        </programlisting>
+        <programlisting>InvokerCallbackHandler callbackHandler1 = new SampleCallbackHandler();
+client.addListener(callbackHandler1, new HashMap(), null, true);
+Set callbackConnectors = client.getCallbackConnectors(callbackHandler1);
+Connector callbackConnector = (Connector) callbackConnectors.iterator().next();
+InvokerCallbackHandler callbackHandler2 = new SampleCallbackHandler();
+client.addListener(callbackHandler2, callbackConnector.getLocator());</programlisting>
         
         <para>
           which would result in the implicitly created callback
@@ -3417,13 +3345,11 @@
           the following:
         </para>
         
-        <programlisting>
-        InvokerCallbackHandler callbackHandler1 = new SampleCallbackHandler();
-        client.addListener(callbackHandler1, new HashMap(), null, true);
-        Set callbackConnectors = client.getCallbackConnectors(callbackHandler1);
-        Connector callbackConnector = (Connector) callbackConnectors.iterator().next();
-        client.addListener(callbackHandler1, callbackConnector.getLocator());
-        </programlisting>
+        <programlisting>InvokerCallbackHandler callbackHandler1 = new SampleCallbackHandler();
+client.addListener(callbackHandler1, new HashMap(), null, true);
+Set callbackConnectors = client.getCallbackConnectors(callbackHandler1);
+Connector callbackConnector = (Connector) callbackConnectors.iterator().next();
+client.addListener(callbackHandler1, callbackConnector.getLocator());</programlisting>
         
         <para>
           then only one callback connection would be created, because a single
@@ -3571,9 +3497,7 @@
         Callback connections are torn down through a call to the method
       </para>
       
-      <programlisting>
-        public void removeListener(InvokerCallbackHandler callbackHandler) throws Throwable;
-      </programlisting>
+      <programlisting>public void removeListener(InvokerCallbackHandler callbackHandler) throws Throwable;</programlisting>
       
       <para>
         in the <classname>org.jboss.remoting.Client</classname> class. A
@@ -3648,90 +3572,87 @@
       objects written to disk. The default value is 'ser'.</para>
 
       <bridgehead>Sample service configuration</bridgehead>
-
-      <para>Socket transport with callback store specified by class name and
+<para>Socket transport with callback store specified by class name and
       memory ceiling set to 30%:</para>
 
-      <programlisting>
-           &lt;mbean code="org.jboss.remoting.transport.Connector"
-                 name="jboss.remoting:service=Connector,transport=Socket"
-                 display-name="Socket transport Connector"&gt;
+      <programlisting>&lt;mbean code="org.jboss.remoting.transport.Connector"
+       name="jboss.remoting:service=Connector,transport=Socket"
+       display-name="Socket transport Connector"&gt;
 
-              &lt;attribute name="Configuration"&gt;
-                 &lt;config&gt;
-                    &lt;invoker transport="socket"&gt;
-                       &lt;attribute name="callbackStore"&gt;org.jboss.remoting.callback.CallbackStore&lt;/attribute&gt;
-                       &lt;attribute name="callbackMemCeiling"&gt;30&lt;/attribute&gt;
-                    &lt;/invoker&gt;
-                    &lt;handlers&gt;
-                       &lt;handler subsystem="test"&gt;
-                          org.jboss.remoting.callback.pull.memory.CallbackInvocationHandler
-                       &lt;/handler&gt;
-                    &lt;/handlers&gt;
-                 &lt;/config&gt;
-              &lt;/attribute&gt;
-           &lt;/mbean&gt;
-        </programlisting>
+   &lt;attribute name="Configuration"&gt;
+      &lt;config&gt;
+         &lt;invoker transport="socket"&gt;
+            &lt;attribute name="callbackStore"&gt;
+               org.jboss.remoting.callback.CallbackStore
+            &lt;/attribute&gt;
+            &lt;attribute name="callbackMemCeiling"&gt;30&lt;/attribute&gt;
+         &lt;/invoker&gt;
+         &lt;handlers&gt;
+            &lt;handler subsystem="test"&gt;
+               org.jboss.remoting.callback.pull.memory.CallbackInvocationHandler
+            &lt;/handler&gt;
+         &lt;/handlers&gt;
+      &lt;/config&gt;
+   &lt;/attribute&gt;
+&lt;/mbean&gt;</programlisting>
 
       <para>Socket transport with callback store specified by MBean ObjectName
       and declaration of CallbackStore as service:</para>
 
-      <programlisting>
-           &lt;mbean code="org.jboss.remoting.callback.CallbackStore"
-                 name="jboss.remoting:service=CallbackStore,type=Serializable"
-                 display-name="Persisted Callback Store"&gt;
+      <programlisting>&lt;mbean code="org.jboss.remoting.callback.CallbackStore"
+       name="jboss.remoting:service=CallbackStore,type=Serializable"
+       display-name="Persisted Callback Store"&gt;
 
-              &lt;!-- the directory to store the persisted callbacks into --&gt;
-              &lt;attribute name="StoreFilePath"&gt;callback_store&lt;/attribute&gt;
-              &lt;!-- the file suffix to use for each callback persisted to disk --&gt;
-              &lt;attribute name="StoreFileSuffix"&gt;cbk&lt;/attribute&gt;
-           &lt;/mbean&gt;
+   &lt;!-- the directory to store the persisted callbacks into --&gt;
+   &lt;attribute name="StoreFilePath"&gt;callback_store&lt;/attribute&gt;
+   &lt;!-- the file suffix to use for each callback persisted to disk --&gt;
+   &lt;attribute name="StoreFileSuffix"&gt;cbk&lt;/attribute&gt;
+&lt;/mbean&gt;
 
-           &lt;mbean code="org.jboss.remoting.transport.Connector"
-                 name="jboss.remoting:service=Connector,transport=Socket"
-                 display-name="Socket transport Connector"&gt;
+&lt;mbean code="org.jboss.remoting.transport.Connector"
+       name="jboss.remoting:service=Connector,transport=Socket"
+       display-name="Socket transport Connector"&gt;
 
-              &lt;attribute name="Configuration"&gt;
-                 &lt;config&gt;
-                    &lt;invoker transport="socket"&gt;
-                       &lt;attribute name="callbackStore"&gt;
-                          jboss.remoting:service=CallbackStore,type=Serializable
-                       &lt;/attribute&gt;
-                    &lt;/invoker&gt;
-                    &lt;handlers&gt;
-                       &lt;handler subsystem="test"&gt;
-                          org.jboss.remoting.callback.pull.memory.CallbackInvocationHandler
-                       &lt;/handler&gt;
-                    &lt;/handlers&gt;
-                 &lt;/config&gt;
-              &lt;/attribute&gt;
-           &lt;/mbean&gt;
-        </programlisting>
+   &lt;attribute name="Configuration"&gt;
+      &lt;config&gt;
+         &lt;invoker transport="socket"&gt;
+            &lt;attribute name="callbackStore"&gt;
+               jboss.remoting:service=CallbackStore,type=Serializable
+            &lt;/attribute&gt;
+         &lt;/invoker&gt;
+         &lt;handlers&gt;
+            &lt;handler subsystem="test"&gt;
+               org.jboss.remoting.callback.pull.memory.CallbackInvocationHandler
+            &lt;/handler&gt;
+         &lt;/handlers&gt;
+      &lt;/config&gt;
+   &lt;/attribute&gt;
+&lt;/mbean&gt;</programlisting>
 
       <para>Socket transport with callback store specified by class name and
       the callback store's file path and file suffix defined:</para>
 
-      <programlisting>
-           &lt;mbean code="org.jboss.remoting.transport.Connector"
-                 name="jboss.remoting:service=Connector,transport=Socket"
-                 display-name="Socket transport Connector"&gt;
+      <programlisting>&lt;mbean code="org.jboss.remoting.transport.Connector"
+       name="jboss.remoting:service=Connector,transport=Socket"
+       display-name="Socket transport Connector"&gt;
 
-              &lt;attribute name="Configuration"&gt;
-                 &lt;config&gt;
-                    &lt;invoker transport="socket"&gt;
-                       &lt;attribute name="callbackStore"&gt;org.jboss.remoting.callback.CallbackStore&lt;/attribute&gt;
-                       &lt;attribute name="StoreFilePath"&gt;callback&lt;/attribute&gt;
-                       &lt;attribute name="StoreFileSuffix"&gt;cst&lt;/attribute&gt;
-                    &lt;/invoker&gt;
-                    &lt;handlers&gt;
-                       &lt;handler subsystem="test"&gt;
-                          org.jboss.remoting.callback.pull.memory.CallbackInvocationHandler
-                       &lt;/handler&gt;
-                    &lt;/handlers&gt;
-                 &lt;/config&gt;
-              &lt;/attribute&gt;
-           &lt;/mbean&gt;
-        </programlisting>
+   &lt;attribute name="Configuration"&gt;
+      &lt;config&gt;
+         &lt;invoker transport="socket"&gt;
+            &lt;attribute name="callbackStore"&gt;
+               org.jboss.remoting.callback.CallbackStore
+            &lt;/attribute&gt;
+            &lt;attribute name="StoreFilePath"&gt;callback&lt;/attribute&gt;
+            &lt;attribute name="StoreFileSuffix"&gt;cst&lt;/attribute&gt;
+         &lt;/invoker&gt;
+         &lt;handlers&gt;
+            &lt;handler subsystem="test"&gt;
+               org.jboss.remoting.callback.pull.memory.CallbackInvocationHandler
+            &lt;/handler&gt;
+         &lt;/handlers&gt;
+      &lt;/config&gt;
+   &lt;/attribute&gt;
+&lt;/mbean&gt;</programlisting>
     </section>
 
     <section>
@@ -3864,20 +3785,19 @@
             <code>&lt;serverSocketFactory&gt;</code> attribute to the name of
             a <classname>ServerSocketFactoryMBean</classname> and pass the
             document to <methodname>Connector.setConfiguration()</methodname>.
-            For example: <programlisting>
-                        StringBuffer buf = new StringBuffer();
-                        buf.append("&lt;?xml version=\"1.0\"?&gt;\n");
-                        buf.append("&lt;config&gt;");
-                        buf.append("   &lt;invoker transport=\"sslsocket\"&gt;");
-                        buf.append("      &lt;attribute name=\"serverBindAddress\"&gt;" + getHostName() + "&lt;/attribute&gt;");
-                        buf.append("      &lt;attribute name=\"serverBindPort\"&gt;" + freeport + "&lt;/attribute&gt;");
-                        buf.append("      &lt;attribute name=\"serverSocketFactory\"&gt;" + socketFactoryObjName + "&lt;/attribute&gt;");
-                        buf.append("   &lt;/invoker&gt;");
-                        buf.append("&lt;/config&gt;");
-                        ByteArrayInputStream bais = new ByteArrayInputStream(buf.toString().getBytes());
-                        Document xml = DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(bais);
-                        connector.setConfiguration(xml.getDocumentElement());
-                     </programlisting></para>
+            For example: <programlisting>StringBuffer buf = new StringBuffer();
+buf.append("&lt;?xml version=\"1.0\"?&gt;\n");
+buf.append("&lt;config&gt;");
+buf.append("   &lt;invoker transport=\"sslsocket\"&gt;");
+buf.append("      &lt;attribute name=\"serverBindAddress\"&gt;" + getHostName() + "&lt;/attribute&gt;");
+buf.append("      &lt;attribute name=\"serverBindPort\"&gt;" + freeport + "&lt;/attribute&gt;");
+buf.append("      &lt;attribute name=\"serverSocketFactory\"&gt;" + socketFactoryObjName + "&lt;/attribute&gt;");
+buf.append("   &lt;/invoker&gt;");
+buf.append("&lt;/config&gt;");
+
+ByteArrayInputStream bais = new ByteArrayInputStream(buf.toString().getBytes());
+Document xml = DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(bais);
+connector.setConfiguration(xml.getDocumentElement());</programlisting></para>
           </listitem>
 
           <listitem>
@@ -4030,20 +3950,19 @@
             <code>&lt;socketFactory&gt;</code> attribute to the class name of
             a <classname>SocketFactory</classname> and pass the document to
             <methodname>Connector.setConfiguration()</methodname>. For
-            example: <programlisting>
-                        StringBuffer buf = new StringBuffer();
-                        buf.append("&lt;?xml version=\"1.0\"?&gt;\n");
-                        buf.append("&lt;config&gt;");
-                        buf.append("   &lt;invoker transport=\"sslsocket\"&gt;");
-                        buf.append("      &lt;attribute name=\"serverBindAddress\"&gt;" + getHostName() + "&lt;/attribute&gt;");
-                        buf.append("      &lt;attribute name=\"serverBindPort\"&gt;" + freeport + "&lt;/attribute&gt;");
-                        buf.append("      &lt;attribute name=\"socketFactory\"&gt;" + socketFactoryClassname + "&lt;/attribute&gt;");
-                        buf.append("   &lt;/invoker&gt;");
-                        buf.append("&lt;/config&gt;");
-                        ByteArrayInputStream bais = new ByteArrayInputStream(buf.toString().getBytes());
-                        Document xml = DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(bais);
-                        connector.setConfiguration(xml.getDocumentElement());
-                     </programlisting> The
+            example: <programlisting>StringBuffer buf = new StringBuffer();
+buf.append("&lt;?xml version=\"1.0\"?&gt;\n");
+buf.append("&lt;config&gt;");
+buf.append("   &lt;invoker transport=\"sslsocket\"&gt;");
+buf.append("      &lt;attribute name=\"serverBindAddress\"&gt;" + getHostName() + "&lt;/attribute&gt;");
+buf.append("      &lt;attribute name=\"serverBindPort\"&gt;" + freeport + "&lt;/attribute&gt;");
+buf.append("      &lt;attribute name=\"socketFactory\"&gt;" + socketFactoryClassname + "&lt;/attribute&gt;");
+buf.append("   &lt;/invoker&gt;");
+buf.append("&lt;/config&gt;");
+
+ByteArrayInputStream bais = new ByteArrayInputStream(buf.toString().getBytes());
+Document xml = DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(bais);
+connector.setConfiguration(xml.getDocumentElement());</programlisting> The
             <classname>SocketFactory</classname> class must have a default
             constructor, which will be used to create a
             <classname>SocketFactory</classname>.</para>
@@ -4152,20 +4071,19 @@
             <code>&lt;serverSocketFactory&gt;</code> attribute to the class
             name of a <classname>ServerSocketFactory</classname> and pass the
             document to <methodname>Connector.setConfiguration()</methodname>.
-            For example: <programlisting>
-                        StringBuffer buf = new StringBuffer();
-                        buf.append("&lt;?xml version=\"1.0\"?&gt;\n");
-                        buf.append("&lt;config&gt;");
-                        buf.append("   &lt;invoker transport=\"sslsocket\"&gt;");
-                        buf.append("      &lt;attribute name=\"serverBindAddress\"&gt;" + getHostName() + "&lt;/attribute&gt;");
-                        buf.append("      &lt;attribute name=\"serverBindPort\"&gt;" + freeport + "&lt;/attribute&gt;");
-                        buf.append("      &lt;attribute name=\"serverSocketFactory\"&gt;" + serverSocketFactoryClassname + "&lt;/attribute&gt;");
-                        buf.append("   &lt;/invoker&gt;");
-                        buf.append("&lt;/config&gt;");
-                        ByteArrayInputStream bais = new ByteArrayInputStream(buf.toString().getBytes());
-                        Document xml = DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(bais);
-                        connector.setConfiguration(xml.getDocumentElement());
-                     </programlisting> The
+            For example: <programlisting>StringBuffer buf = new StringBuffer();
+buf.append("&lt;?xml version=\"1.0\"?&gt;\n");
+buf.append("&lt;config&gt;");
+buf.append("   &lt;invoker transport=\"sslsocket\"&gt;");
+buf.append("      &lt;attribute name=\"serverBindAddress\"&gt;" + getHostName() + "&lt;/attribute&gt;");
+buf.append("      &lt;attribute name=\"serverBindPort\"&gt;" + freeport + "&lt;/attribute&gt;");
+buf.append("      &lt;attribute name=\"serverSocketFactory\"&gt;" + serverSocketFactoryClassname + "&lt;/attribute&gt;");
+buf.append("   &lt;/invoker&gt;");
+buf.append("&lt;/config&gt;");
+
+ByteArrayInputStream bais = new ByteArrayInputStream(buf.toString().getBytes());
+Document xml = DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(bais);
+connector.setConfiguration(xml.getDocumentElement());</programlisting> The
             <classname>ServerSocketFactory</classname> class must have a
             default constructor, which will be used to create a
             <classname>ServerSocketFactory</classname>.</para>
@@ -4368,19 +4286,18 @@
 
       <para>An example of the first case would be:</para>
 
-      <programlisting>
-            &lt;mbean code="org.jboss.remoting.transport.Connector"
-                  name="jboss.remoting:service=Connector,transport=Socket"
-                  display-name="Socket transport Connector"&gt;
+      <programlisting>&lt;mbean code="org.jboss.remoting.transport.Connector"
+       name="jboss.remoting:service=Connector,transport=Socket"
+       display-name="Socket transport Connector"&gt;
 
-               &lt;attribute name="Configuration"&gt;
-                  &lt;config&gt;
-                     &lt;invoker transport="sslsocket"&gt;
-                        &lt;attribute name="serverSocketFactory"&gt;
-                           jboss.remoting:service=ServerSocketFactory,type=SSL
-                        &lt;/attribute&gt;
-                        &lt;attribute name="numAcceptThreads"&gt;1&lt;/attribute&gt;
-         </programlisting>
+   &lt;attribute name="Configuration"&gt;
+      &lt;config&gt;
+         &lt;invoker transport="sslsocket"&gt;
+            &lt;attribute name="serverSocketFactory"&gt;
+               jboss.remoting:service=ServerSocketFactory,type=SSL
+            &lt;/attribute&gt;
+            &lt;attribute name="numAcceptThreads"&gt;1&lt;/attribute&gt;
+            ...</programlisting>
 
       <para>The <code>serverSocketFactory</code> attribute is processed as
       follows:</para>
@@ -4431,9 +4348,7 @@
       is accessible by way of its <classname>ObjectName</classname>, which has
       the form</para>
 
-      <programlisting>
-            jboss.remoting:service=invoker,transport=socket,host=www.jboss.com,port=8765
-         </programlisting>
+      <programlisting>jboss.remoting:service=invoker,transport=socket,host=www.jboss.com,port=8765</programlisting>
 
       <para>for example, followed by additional parameter=value pairs. (See
       the jmx-console for a running instance of JBossAS at
@@ -4442,13 +4357,11 @@
       in a <code>*-service.xml</code> file to be dependent on the server
       invoker MBean, e.g.</para>
 
-      <programlisting>
-            &lt;mbean code="org.jboss.BlueMonkey" name="jboss.remoting:bluemonkey,name=diamond"&gt;
-               &lt;depends optional-attribute-name="serverInvoker"&gt;
-                   jboss.remoting:service=invoker,transport=socket,host=www.jboss.com,port=8765
-               &lt;/depends&gt;
-            &lt;/mbean&gt;
-         </programlisting>
+      <programlisting>&lt;mbean code="org.jboss.BlueMonkey" name="jboss.remoting:bluemonkey,name=diamond"&gt;
+   &lt;depends optional-attribute-name="serverInvoker"&gt;
+      jboss.remoting:service=invoker,transport=socket,host=www.jboss.com,port=8765
+   &lt;/depends&gt;
+&lt;/mbean&gt;</programlisting>
 
       <para>then <methodname>org.jboss.BlueMonkey.create()</methodname> will
       have access to the designated server invoker after the invoker has been
@@ -4471,19 +4384,17 @@
         <code>org.jboss.remoting.socketfactory</code> package:
       </para>
       
-      <programlisting>
-      public interface SocketCreationListener
-      {
-         /**
-          * Called when a socket has been created.
-          * 
-          * @param socket socket that has been created
-          * @param source SocketFactory or ServerSocket that created the socket
-          * @throws IOException
-          */
-         void socketCreated(Socket socket, Object source) throws IOException;
-      }
-      </programlisting>
+      <programlisting>public interface SocketCreationListener
+{
+   /**
+    * Called when a socket has been created.
+    * 
+    * @param socket socket that has been created
+    * @param source SocketFactory or ServerSocket that created the socket
+    * @throws IOException
+    */
+   void socketCreated(Socket socket, Object source) throws IOException;
+}</programlisting>
       
       <para>
         Socket creation listeners can be registered to be informed every time a
@@ -4497,19 +4408,17 @@
        <classname>org.jboss.remoting.Remoting</classname>:
       </para>
       
-      <programlisting>
-      /**
-       * Key for the configuration map passed to a Client or Connector to indicate
-       * a socket creation listener for sockets created by a SocketFactory.
-       */
-      public static final String SOCKET_CREATION_CLIENT_LISTENER = "socketCreationClientListener";
+      <programlisting>/**
+ * Key for the configuration map passed to a Client or Connector to indicate
+ * a socket creation listener for sockets created by a SocketFactory.
+ */
+public static final String SOCKET_CREATION_CLIENT_LISTENER = "socketCreationClientListener";
       
-      /**
-       * Key for the configuration map passed to a Client or Connector to indicate
-       * a socket creation listener for sockets created by a ServerSocket.
-       */
-      public static final String SOCKET_CREATION_SERVER_LISTENER = "socketCreationServerListener";
-      </programlisting>
+/**
+ * Key for the configuration map passed to a Client or Connector to indicate
+ * a socket creation listener for sockets created by a ServerSocket.
+ */
+public static final String SOCKET_CREATION_SERVER_LISTENER = "socketCreationServerListener";</programlisting>
       
       <para>
         The value associated with either of these keys can be an actual object,
@@ -4580,27 +4489,33 @@
       <para>An example of setting up https via service.xml configuration would
       be:</para>
 
-      <programlisting>     &lt;mbean code="org.jboss.remoting.transport.Connector"
-         name="jboss.remoting:service=Connector,transport=HTTPS"
-         display-name="HTTPS transport Connector"&gt;
+      <programlisting>&lt;mbean code="org.jboss.remoting.transport.Connector"
+       name="jboss.remoting:service=Connector,transport=HTTPS"
+       display-name="HTTPS transport Connector"&gt;
 
-         &lt;attribute name="Configuration"&gt;
-            &lt;config&gt;
-               &lt;invoker transport="https"&gt;
-                  &lt;attribute name="serverSocketFactory"&gt;jboss.remoting:service=ServerSocketFactory,type=SSL&lt;/attribute&gt;
-                  &lt;attribute name="SSLImplementation"&gt;org.jboss.remoting.transport.coyote.ssl.RemotingSSLImplementation&lt;/attribute&gt;
-                  &lt;attribute name="serverBindAddress"&gt;${jboss.bind.address}&lt;/attribute&gt;
-                  &lt;attribute name="serverBindPort"&gt;6669&lt;/attribute&gt;
-               &lt;/invoker&gt;
-               &lt;handlers&gt;
-                  &lt;handler subsystem="mock"&gt;org.jboss.test.remoting.transport.mock.MockServerInvocationHandler&lt;/handler&gt;
-               &lt;/handlers&gt;
-            &lt;/config&gt;
-         &lt;/attribute&gt;
-         &lt;!-- This depends is included because need to make sure this mbean is running before configure invoker. --&gt;
-         &lt;depends&gt;jboss.remoting:service=ServerSocketFactory,type=SSL&lt;/depends&gt;
-      &lt;/mbean&gt;
-   </programlisting>
+   &lt;attribute name="Configuration"&gt;
+      &lt;config&gt;
+         &lt;invoker transport="https"&gt;
+            &lt;attribute name="serverSocketFactory"&gt;
+               jboss.remoting:service=ServerSocketFactory,type=SSL
+            &lt;/attribute&gt;
+            &lt;attribute name="SSLImplementation"&gt;
+               org.jboss.remoting.transport.coyote.ssl.RemotingSSLImplementation
+            &lt;/attribute&gt;
+            &lt;attribute name="serverBindAddress"&gt;${jboss.bind.address}&lt;/attribute&gt;
+            &lt;attribute name="serverBindPort"&gt;6669&lt;/attribute&gt;
+         &lt;/invoker&gt;
+         &lt;handlers&gt;
+            &lt;handler subsystem="mock"&gt;
+               org.jboss.test.remoting.transport.mock.MockServerInvocationHandler
+            &lt;/handler&gt;
+         &lt;/handlers&gt;
+      &lt;/config&gt;
+   &lt;/attribute&gt;
+   &lt;!-- This depends is included because need to make sure
+        this mbean is running before configure invoker. --&gt;
+   &lt;depends&gt;jboss.remoting:service=ServerSocketFactory,type=SSL&lt;/depends&gt;
+&lt;/mbean&gt;</programlisting>
 
       <para>See section <xref
       linkend="section-SSLServerSocketFactoryService" /> below for a
@@ -4655,9 +4570,7 @@
       <para>Also, the sslsocket server invoker inherits from the socket server
       invoker a method with signature</para>
 
-      <programlisting>
-            public void setNewServerSocketFactory(ServerSocketFactory serverSocketFactory)
-         </programlisting>
+      <programlisting>public void setNewServerSocketFactory(ServerSocketFactory serverSocketFactory)</programlisting>
 
       <para>which supports dynamic replacement of server socket factories. The
       principal motivation for this facility is to be able to swap in a new
@@ -5051,20 +4964,18 @@
       <classname>SSLSocketBuilder</classname> and using it to create a custom
       <classname>SSLSocketFactory</classname>:</para>
 
-      <programlisting>
-         protected SSLSocketFactory getSocketFactory() throws Exception
-         {
-            HashMap config = new HashMap();
-            config.put(SSLSocketBuilder.REMOTING_KEY_STORE_TYPE, "JKS");
-            String keyStoreFilePath = getKeystoreFilePath();
-            config.put(SSLSocketBuilder.REMOTING_KEY_STORE_FILE_PATH, keyStoreFilePath);
-            config.put(SSLSocketBuilder.REMOTING_KEY_STORE_PASSWORD, "unit-tests-server");
-            config.put(SSLSocketBuilder.REMOTING_SSL_PROTOCOL, "SSL");
-            SSLSocketBuilder builder = new SSLSocketBuilder(config);
-            builder.setUseSSLSocketFactory(false);
-            return builder.createSSLSocketFactory();
-         }
-         </programlisting>
+      <programlisting>protected SSLSocketFactory getSocketFactory() throws Exception
+{
+   HashMap config = new HashMap();
+   config.put(SSLSocketBuilder.REMOTING_KEY_STORE_TYPE, "JKS");
+   String keyStoreFilePath = getKeystoreFilePath();
+   config.put(SSLSocketBuilder.REMOTING_KEY_STORE_FILE_PATH, keyStoreFilePath);
+   config.put(SSLSocketBuilder.REMOTING_KEY_STORE_PASSWORD, "unit-tests-server");
+   config.put(SSLSocketBuilder.REMOTING_SSL_PROTOCOL, "SSL");
+   SSLSocketBuilder builder = new SSLSocketBuilder(config);
+   builder.setUseSSLSocketFactory(false);
+   return builder.createSSLSocketFactory();
+}</programlisting>
 
       <para>More examples of configuring
       <classname>SSLSocketBuilder</classname> can be found in the class
@@ -5074,43 +4985,41 @@
       <para>The following is an example of configuring
       <classname>SSLSocketBuilder</classname> in a *-service.xml file:</para>
 
-      <programlisting>
-            &lt;!-- This service is used to build the SSL Server socket factory --&gt;
-            &lt;!-- This will be where all the store/trust information will be set. --&gt;
-            &lt;!-- If do not need to make any custom configurations, no extra attributes --&gt;
-            &lt;!-- need to be set for the SSLSocketBuilder and just need to set the --&gt;
-            &lt;!-- javax.net.ssl.keyStore and javax.net.ssl.keyStorePassword system properties. --&gt;
-            &lt;!-- This can be done by just adding something like the following to the run --&gt;
-            &lt;!-- script for JBoss --&gt;
-            &lt;!-- (this one is for run.bat): --&gt;
-            &lt;!-- set JAVA_OPTS=-Djavax.net.ssl.keyStore=.keystore --&gt;
-            &lt;!-- -Djavax.net.ssl.keyStorePassword=opensource %JAVA_OPTS% --&gt;
-            &lt;!-- Otherwise, if want to customize the attributes for SSLSocketBuilder, --&gt;
-            &lt;!-- will need to uncomment them below. --&gt;
-            &lt;mbean code="org.jboss.remoting.security.SSLSocketBuilder"
-                  name="jboss.remoting:service=SocketBuilder,type=SSL"
-                  display-name="SSL Server Socket Factory Builder"&gt;
-               &lt;!-- IMPORTANT - If making ANY customizations, this MUST be set to false. --&gt;
-               &lt;!-- Otherwise, will used default settings and the following attributes will be ignored. --&gt;
-               &lt;attribute name="UseSSLServerSocketFactory"&gt;false&lt;/attribute&gt;
-               &lt;!-- This is the url string to the key store to use --&gt;
-               &lt;attribute name="KeyStoreURL"&gt;.keystore&lt;/attribute&gt;
-               &lt;!-- The password for the key store --&gt;
-               &lt;attribute name="KeyStorePassword"&gt;opensource&lt;/attribute&gt;
-               &lt;!-- The password for the keys (will use KeystorePassword if this is not set explicitly. --&gt;
-               &lt;attribute name="KeyPassword"&gt;opensource&lt;/attribute&gt;
-               &lt;!-- The protocol for the SSLContext. Default is TLS. --&gt;
-               &lt;attribute name="SecureSocketProtocol"&gt;TLS&lt;/attribute&gt;
-               &lt;!-- The algorithm for the key manager factory. Default is SunX509. --&gt;
-               &lt;attribute name="KeyManagementAlgorithm"&gt;SunX509&lt;/attribute&gt;
-               &lt;!-- The type to be used for the key store. --&gt;
-               &lt;!-- Defaults to JKS. Some acceptable values are JKS (Java Keystore - Sun's keystore format), --&gt;
-               &lt;!-- JCEKS (Java Cryptography Extension keystore - More secure version of JKS), and --&gt;
-               &lt;!-- PKCS12 (Public-Key Cryptography Standards #12 keystore - RSA's Personal Information Exchange Syntax Standard). --&gt;
-               &lt;!-- These are not case sensitive. --&gt;
-               &lt;attribute name="KeyStoreType"&gt;JKS&lt;/attribute&gt;
-            &lt;/mbean&gt;
-         </programlisting>
+      <programlisting>&lt;!-- This service is used to build the SSL Server socket factory --&gt;
+&lt;!-- This will be where all the store/trust information will be set. --&gt;
+&lt;!-- If do not need to make any custom configurations, no extra attributes --&gt;
+&lt;!-- need to be set for the SSLSocketBuilder and just need to set the --&gt;
+&lt;!-- javax.net.ssl.keyStore and javax.net.ssl.keyStorePassword system properties. --&gt;
+&lt;!-- This can be done by just adding something like the following to the run --&gt;
+&lt;!-- script for JBoss --&gt;
+&lt;!-- (this one is for run.bat): --&gt;
+&lt;!-- set JAVA_OPTS=-Djavax.net.ssl.keyStore=.keystore --&gt;
+&lt;!-- -Djavax.net.ssl.keyStorePassword=opensource %JAVA_OPTS% --&gt;
+&lt;!-- Otherwise, if want to customize the attributes for SSLSocketBuilder, --&gt;
+&lt;!-- will need to uncomment them below. --&gt;
+&lt;mbean code="org.jboss.remoting.security.SSLSocketBuilder"
+       name="jboss.remoting:service=SocketBuilder,type=SSL"
+       display-name="SSL Server Socket Factory Builder"&gt;
+   &lt;!-- IMPORTANT - If making ANY customizations, this MUST be set to false. --&gt;
+   &lt;!-- Otherwise, will used default settings and the following attributes will be ignored. --&gt;
+   &lt;attribute name="UseSSLServerSocketFactory"&gt;false&lt;/attribute&gt;
+   &lt;!-- This is the url string to the key store to use --&gt;
+   &lt;attribute name="KeyStoreURL"&gt;.keystore&lt;/attribute&gt;
+   &lt;!-- The password for the key store --&gt;
+   &lt;attribute name="KeyStorePassword"&gt;opensource&lt;/attribute&gt;
+   &lt;!-- The password for the keys (will use KeystorePassword if this is not set explicitly. --&gt;
+   &lt;attribute name="KeyPassword"&gt;opensource&lt;/attribute&gt;
+   &lt;!-- The protocol for the SSLContext. Default is TLS. --&gt;
+   &lt;attribute name="SecureSocketProtocol"&gt;TLS&lt;/attribute&gt;
+   &lt;!-- The algorithm for the key manager factory. Default is SunX509. --&gt;
+   &lt;attribute name="KeyManagementAlgorithm"&gt;SunX509&lt;/attribute&gt;
+   &lt;!-- The type to be used for the key store. --&gt;
+   &lt;!-- Defaults to JKS. Some acceptable values are JKS (Java Keystore - Sun's keystore format), --&gt;
+   &lt;!-- JCEKS (Java Cryptography Extension keystore - More secure version of JKS), and --&gt;
+   &lt;!-- PKCS12 (Public-Key Cryptography Standards #12 keystore - RSA's Personal Information Exchange Syntax Standard). --&gt;
+   &lt;!-- These are not case sensitive. --&gt;
+   &lt;attribute name="KeyStoreType"&gt;JKS&lt;/attribute&gt;
+&lt;/mbean&gt;</programlisting>
 
       <para>It is also possible to set the default socket factory to be used
       when not using customized settings (meaning UseSSLSocketFactory property
@@ -5143,16 +5052,14 @@
       <classname>SSLSocketBuilder</classname> MBean defined in the xml
       fragment above:</para>
 
-      <programlisting>
-         &lt;!-- This service provides the exact same API as the ServerSocketFactory, so --&gt;
-         &lt;!-- can be set as an attribute of that type on any MBean requiring an ServerSocketFactory. --&gt;
-         &lt;mbean code="org.jboss.remoting.security.SSLServerSocketFactoryService"
-               name="jboss.remoting:service=ServerSocketFactory,type=SSL"
-               display-name="SSL Server Socket Factory"&gt;
-            &lt;depends optional-attribute-name="SSLSocketBuilder"
-               proxy-type="attribute"&gt;jboss.remoting:service=SocketBuilder,type=SSL&lt;/depends&gt;
-         &lt;/mbean&gt;
-      </programlisting>
+      <programlisting>&lt;!-- This service provides the exact same API as the ServerSocketFactory, so --&gt;
+&lt;!-- can be set as an attribute of that type on any MBean requiring an ServerSocketFactory. --&gt;
+&lt;mbean code="org.jboss.remoting.security.SSLServerSocketFactoryService"
+       name="jboss.remoting:service=ServerSocketFactory,type=SSL"
+       display-name="SSL Server Socket Factory"&gt;
+   &lt;depends optional-attribute-name="SSLSocketBuilder"
+            proxy-type="attribute"&gt;jboss.remoting:service=SocketBuilder,type=SSL&lt;/depends&gt;
+&lt;/mbean&gt;</programlisting>
     </section>
 
     <section>
@@ -5169,27 +5076,25 @@
 
       <para>Generating key entry into keystore:</para>
 
-      <programlisting>
-               C:\tmp\ssl&gt;keytool -genkey -alias remoting -keyalg RSA
-               Enter keystore password: opensource
-               What is your first and last name?
-               [Unknown]: Tom Elrod
-               What is the name of your organizational unit?
-               [Unknown]: Development
-               What is the name of your organization?
-               [Unknown]: JBoss Inc
-               What is the name of your City or Locality?
-               [Unknown]: Atlanta
-               What is the name of your State or Province?
-               [Unknown]: GA
-               What is the two-letter country code for this unit?
-               [Unknown]: US
-               Is CN=Tom Elrod, OU=Development, O=JBoss Inc, L=Atlanta, ST=GA, C=US correct?
-               [no]: yes
+      <programlisting>C:\tmp\ssl&gt;keytool -genkey -alias remoting -keyalg RSA
+Enter keystore password: opensource
+What is your first and last name?
+[Unknown]: Tom Elrod
+What is the name of your organizational unit?
+[Unknown]: Development
+What is the name of your organization?
+[Unknown]: JBoss Inc
+What is the name of your City or Locality?
+[Unknown]: Atlanta
+What is the name of your State or Province?
+[Unknown]: GA
+What is the two-letter country code for this unit?
+[Unknown]: US
+Is CN=Tom Elrod, OU=Development, O=JBoss Inc, L=Atlanta, ST=GA, C=US correct?
+[no]: yes
 
-               Enter key password for &lt;remoting&gt;
-               (RETURN if same as keystore password):
-            </programlisting>
+Enter key password for &lt;remoting&gt;
+(RETURN if same as keystore password):</programlisting>
 
       <para>Since did not specify the -keystore filename parameter, created
       the keystore in $HOME/.keystore (or C:\Documents and
@@ -5197,27 +5102,23 @@
 
       <para>Export the RSA certificate (without the private key)</para>
 
-      <programlisting>
-               C:\tmp\ssl&gt;keytool -export -alias remoting -file remoting.cer
-               Enter keystore password: opensource
-               Certificate stored in file &lt;remoting.cer&gt;
-            </programlisting>
+      <programlisting>C:\tmp\ssl&gt;keytool -export -alias remoting -file remoting.cer
+Enter keystore password: opensource
+Certificate stored in file &lt;remoting.cer&gt;</programlisting>
 
       <para>Import the RSE certificate into a new truststore file.</para>
 
-      <programlisting>
-               C:\tmp\ssl&gt;keytool -import -alias remoting -keystore .truststore -file remoting.cer
-               Enter keystore password: opensource
-               Owner: CN=Tom Elrod, OU=Development, O=JBoss Inc, L=Atlanta, ST=GA, C=US
-               Issuer: CN=Tom Elrod, OU=Development, O=JBoss Inc, L=Atlanta, ST=GA, C=US
-               Serial number: 426f1ee3
-               Valid from: Wed Apr 27 01:10:59 EDT 2005 until: Tue Jul 26 01:10:59 EDT 2005
-               Certificate fingerprints:
-               MD5: CF:D0:A8:7D:20:49:30:67:44:03:98:5F:8E:01:4A:6A
-               SHA1: C6:76:3B:6C:79:3B:8D:FD:FB:4F:33:3B:25:C9:01:9D:50:BF:9F:8A
-               Trust this certificate? [no]: yes
-               Certificate was added to keystore
-            </programlisting>
+      <programlisting>C:\tmp\ssl&gt;keytool -import -alias remoting -keystore .truststore -file remoting.cer
+Enter keystore password: opensource
+Owner: CN=Tom Elrod, OU=Development, O=JBoss Inc, L=Atlanta, ST=GA, C=US
+Issuer: CN=Tom Elrod, OU=Development, O=JBoss Inc, L=Atlanta, ST=GA, C=US
+Serial number: 426f1ee3
+Valid from: Wed Apr 27 01:10:59 EDT 2005 until: Tue Jul 26 01:10:59 EDT 2005
+Certificate fingerprints:
+MD5: CF:D0:A8:7D:20:49:30:67:44:03:98:5F:8E:01:4A:6A
+SHA1: C6:76:3B:6C:79:3B:8D:FD:FB:4F:33:3B:25:C9:01:9D:50:BF:9F:8A
+Trust this certificate? [no]: yes
+Certificate was added to keystore</programlisting>
 
       <para>Now have two files, .keystore for the server and .truststore for
       the client.</para>
@@ -5228,7 +5129,8 @@
 
       <para>Common errors when using server socket factory:</para>
 
-      <programlisting>javax.net.ssl.SSLException: No available certificate corresponds to the SSL cipher suites which are enabled.</programlisting>
+      <programlisting>javax.net.ssl.SSLException: No available certificate corresponds to the SSL cipher suites
+                            which are enabled.</programlisting>
 
       <para>The 'javax.net.ssl.keyStore' system property has not been set and
       are using the default SSLServerSocketFactory.</para>
@@ -5238,7 +5140,8 @@
       <para>The 'javax.net.ssl.keyStorePassword' system property has not been
       set and are using the default SSLServerSocketFactory.</para>
 
-      <programlisting>java.io.IOException: Can not create SSL Server Socket Factory due to the url to the key store not being set.</programlisting>
+      <programlisting>java.io.IOException: Can not create SSL Server Socket Factory due to the url to the key store
+                     not being set.</programlisting>
 
       <para>The default SSLServerSocketFactory is NOT being used (so custom
       configuration for the server socket factory) and the key store url has
@@ -5275,11 +5178,9 @@
         invokers also have the getter/setter methods 
       </para>
       
-      <programlisting>
-      public int getTimeout();
-                 
-      public void setTimeout(int timeout);
-      </programlisting>
+      <programlisting>public int getTimeout();
+
+public void setTimeout(int timeout);</programlisting>
       
       <para>
         where the values are given in milliseconds.  The default timeout value
@@ -5299,11 +5200,9 @@
         the invocation's metadata map, using the key "timeout". For example,
       </para>
       
-      <programlisting>
-        HashMap metadata = new HashMap();
-        metadata.put("timeout", "2000");
-        client.invoke("testInvocation", metadata);
-      </programlisting>
+      <programlisting>HashMap metadata = new HashMap();
+metadata.put("timeout", "2000");
+client.invoke("testInvocation", metadata);</programlisting>
       
       <para>
         will allow approximately 2 seconds for this particular invocation, after
@@ -5386,9 +5285,7 @@
           <classname>HTTPClientInvoker</classname> method
         </para>
         
-        <programlisting>
-        public void setTimeoutThreadPool(org.jboss.util.threadpool.ThreadPool pool);
-        </programlisting>
+        <programlisting>public void setTimeoutThreadPool(org.jboss.util.threadpool.ThreadPool pool);</programlisting>
         
         <para>
           where the <methodname>ThreadPool</methodname> interface is available
@@ -5470,9 +5367,7 @@
           <classname>Client</classname> method
         </para>
         
-        <programlisting>
-        public void setDisconnectTimeout(int disconnectTimeout);
-        </programlisting>
+        <programlisting>public void setDisconnectTimeout(int disconnectTimeout);</programlisting>
         
         <para>
           to set the disconnect timeout value to a nonnegative value.
@@ -5525,30 +5420,28 @@
      <code>java.net.ServerSocket.accept()</code> has been replaced by
      org.jboss.remoting.utility.SecurityUtility.accept():</para>
      
-     <programlisting>
-       static public Socket accept(final ServerSocket ss) throws IOException
-       {
-          if (skipAccessControl)
-          {
-             return ss.accept();
-          }
-          
-          try
-          {
-              return (Socket)AccessController.doPrivileged( new PrivilegedExceptionAction()
-              {
-                 public Object run() throws Exception
-                 {
-                     return ss.accept();
-                 }
-              });
-          }
-          catch (PrivilegedActionException e)
-          {
-              throw (IOException) e.getCause();
-          }
-       }
-     </programlisting>
+     <programlisting>static public Socket accept(final ServerSocket ss) throws IOException
+{
+   if (skipAccessControl)
+   {
+      return ss.accept();
+   }
+
+   try
+   {
+      return (Socket)AccessController.doPrivileged( new PrivilegedExceptionAction()
+      {
+         public Object run() throws Exception
+         {
+            return ss.accept();
+         }
+      });
+   }
+   catch (PrivilegedActionException e)
+   {
+      throw (IOException) e.getCause();
+   }
+}</programlisting>
      
      <para>Note that the
      <methodname>AccessController.doPrivileged()</methodname> call, with its
@@ -5578,12 +5471,10 @@
      code and to give it all possible permissions in a file that looks
      like</para>
      
-     <programlisting>
-        grant codeBase "file:${remoting.dir}/jboss-remoting.jar"
-        {
-          permission java.security.AllPermission;
-        };
-     </programlisting>
+     <programlisting>grant codeBase "file:${remoting.dir}/jboss-remoting.jar"
+{
+   permission java.security.AllPermission;
+};</programlisting>
   
      <para>This file grants all permissions to any class loaded from
      jboss-remoting.jar. Alternatively, a more precisely tailored set of
@@ -5801,8 +5692,8 @@
     not have access to, could create a invoker locator such as:</para>
 
     <programlisting>socket://myhost:6500/?datatype=test&amp;loaderport=6501&amp;
-marshaller=org.jboss.test.remoting.marshall.dynamic.remote.http.TestMarshaller&amp;
-unmarshaller=org.jboss.test.remoting.marshall.dynamic.remote.http.TestUnMarshaller</programlisting>
+        marshaller=org.jboss.test.remoting.marshall.dynamic.remote.http.TestMarshaller&amp;
+        unmarshaller=org.jboss.test.remoting.marshall.dynamic.remote.http.TestUnMarshaller</programlisting>
 
     <para>When the client invoker begins to make an invocation, will try to
     look up marshaller and unmarshaller based on type ('test' in this case)
@@ -5879,8 +5770,12 @@
     <para>The following three configuration properties are only useful when
     using one of the following Client methods:</para>
 
-    <programlisting>public void addListener(InvokerCallbackHandler callbackhandler, Map metadata, Object callbackHandlerObject) throws Throwable
-public void addListener(InvokerCallbackHandler callbackhandler, Map metadata, Object callbackHandlerObject, boolean serverToClient) throws Throwable</programlisting>
+    <programlisting>public void addListener(
+        InvokerCallbackHandler callbackhandler, Map metadata,
+        Object callbackHandlerObject) throws Throwable
+public void addListener(
+        InvokerCallbackHandler callbackhandler, Map metadata,
+        Object callbackHandlerObject, boolean serverToClient) throws Throwable</programlisting>
 
     <para><emphasis role="bold">CALLBACK_SERVER_PROTOCOL</emphasis> (actual
     value is 'callbackServerProtocol') - key for the configuration when adding
@@ -6173,8 +6068,12 @@
      configuration is only necessary when using one of the
     following Client methods:</para>
 
-    <programlisting>public void addListener(InvokerCallbackHandler callbackhandler, Map metadata, Object callbackHandlerObject) throws Throwable
-public void addListener(InvokerCallbackHandler callbackhandler, Map metadata, Object callbackHandlerObject, boolean serverToClient) throws Throwable</programlisting>
+    <programlisting>public void addListener(
+        InvokerCallbackHandler callbackhandler, Map metadata,
+        Object callbackHandlerObject) throws Throwable
+public void addListener(
+        InvokerCallbackHandler callbackhandler, Map metadata,
+        Object callbackHandlerObject, boolean serverToClient) throws Throwable</programlisting>
 
     <para>The keys should be among the entries in the metadata Map passed. This
     will also only apply when the underlying transport is uni-directional
@@ -6353,10 +6252,10 @@
     org.jboss.remoting.ServerInvocationHandler implementation. For
     example:</para>
 
-    <programlisting>   public Object invoke(InvocationRequest invocation) throws Throwable
-   {
-      Map headers = invocation.getRequestPayload();
-</programlisting>
+    <programlisting>public Object invoke(InvocationRequest invocation) throws Throwable
+{
+   Map headers = invocation.getRequestPayload();
+   ...</programlisting>
 
     <para>where variable 'headers' will contain entries for the following
     keys.</para>
@@ -6368,15 +6267,14 @@
     org.jboss.remoting.ServerInvocationHandler implementation. For
     example:</para>
 
-    <programlisting>   public Object invoke(InvocationRequest invocation) throws Throwable
+    <programlisting>public Object invoke(InvocationRequest invocation) throws Throwable
+{
+   Map headers = invocation.getRequestPayload();
+   String methodType = (String) headers.get(HTTPMetadataConstants.METHODTYPE);
+   if(methodType != null)
    {
-      Map headers = invocation.getRequestPayload();
-      String methodType = (String) headers.get(HTTPMetadataConstants.METHODTYPE);
-      if(methodType != null)
-      {
-         if(methodType.equals("GET"))
-         ...
-    </programlisting>
+      if(methodType.equals("GET"))
+      ...</programlisting>
 
     <para><emphasis role="bold">PATH</emphasis> (actual value is 'Path') - key
     for getting the path from the url request from the calling client. This
@@ -6385,12 +6283,11 @@
     org.jboss.remoting.ServerInvocationHandler implementation. For
     example:</para>
 
-    <programlisting>   public Object invoke(InvocationRequest invocation) throws Throwable
-   {
-      Map headers = invocation.getRequestPayload();
-      String path = (String) headers.get(HTTPMetadataConstants.PATH);
-      ...
-    </programlisting>
+    <programlisting>public Object invoke(InvocationRequest invocation) throws Throwable
+{
+   Map headers = invocation.getRequestPayload();
+   String path = (String) headers.get(HTTPMetadataConstants.PATH);
+   ...</programlisting>
 
     <para><emphasis role="bold">HTTPVERSION</emphasis> (actual value is
     'HttpVersion') - key for getting the HTTP version from the calling client
@@ -6408,17 +6305,15 @@
 
     <programlisting>Map metadata = new HashMap();
 Object response = remotingClient.invoke(myPayloadObject, metadata);
-Integer responseCode = (Integer) metadata.get(HTTPMetadataConstants.RESPONSE_CODE);
-    </programlisting>
+Integer responseCode = (Integer) metadata.get(HTTPMetadataConstants.RESPONSE_CODE);</programlisting>
 
     <para>Will be used as key to put the response code in the return payload
     map from invocation handler. For example:</para>
 
-    <programlisting>   public Object invoke(InvocationRequest invocation) throws Throwable
-   {
-      Map responseHeaders = invocation.getReturnPayload();
-      responseHeaders.put(HTTPMetadataConstants.RESPONSE_CODE,  new Integer(202));
-    </programlisting>
+    <programlisting>public Object invoke(InvocationRequest invocation) throws Throwable
+{
+   Map responseHeaders = invocation.getReturnPayload();
+   responseHeaders.put(HTTPMetadataConstants.RESPONSE_CODE, new Integer(202)); </programlisting>
 
     <para><emphasis role="bold">RESPONSE_CODE_MESSAGE</emphasis> (actual value
     is 'ResponseCodeMessage') - key for getting and setting the HTTP response
@@ -6428,17 +6323,17 @@
 
     <programlisting>Map metadata = new HashMap();
 Object response = remotingClient.invoke(myPayloadObject, metadata);
-String responseCodeMessage = (String) metadata.get(HTTPMetadataConstants.RESPONSE_CODE_MESSAGE);
-</programlisting>
+String responseCodeMessage = (String) metadata.get(HTTPMetadataConstants.RESPONSE_CODE_MESSAGE);</programlisting>
 
     <para>Will be used as key to put the response code message in the return
     payload map from invocation handler. For example:</para>
 
-    <programlisting>   public Object invoke(InvocationRequest invocation) throws Throwable
-   {
-      Map responseHeaders = invocation.getReturnPayload();
-      responseHeaders.put(HTTPMetadataConstants.RESPONSE_CODE_MESSAGE, "Custom response code and message from remoting server");
-    </programlisting>
+    <programlisting>public Object invoke(InvocationRequest invocation) throws Throwable
+{
+   Map responseHeaders = invocation.getReturnPayload();
+   responseHeaders.put(
+           HTTPMetadataConstants.RESPONSE_CODE_MESSAGE,
+           "Custom response code and message from remoting server");</programlisting>
 
     <para><emphasis role="bold">RESPONSE_HEADERS</emphasis> (actual value is
     'ResponseHeaders') - key for returning the value of
@@ -6446,12 +6341,10 @@
     words, a map containing all of the response headers is stored in the
     metadata map. For example,</para>
     
-    <programlisting>
-        Object payload = ... ;
-        HashMap metadata = new HashMap();
-        client.invoke(payload, metadata);
-        Map responseHeaders = (Map) metadata.get(HTTPMetadataConstants.RESPONSE_HEADERS);
-    </programlisting>
+    <programlisting>Object payload = ... ;
+HashMap metadata = new HashMap();
+client.invoke(payload, metadata);
+Map responseHeaders = (Map) metadata.get(HTTPMetadataConstants.RESPONSE_HEADERS);</programlisting>
    
     <para><emphasis role="bold">NO_THROW_ON_ERROR</emphasis> (actual value is
     'NoThrowOnError') - key indicating if http client invoker (for transports
@@ -6574,4 +6467,4 @@
     </section>
     
   </section>
-</chapter>
\ No newline at end of file
+</chapter>




More information about the jboss-remoting-commits mailing list