Author: ruwan
Date: Thu Jun  5 03:49:54 2008
New Revision: 17993
URL: http://wso2.org/svn/browse/wso2?view=rev&revision=17993

Log:
Fixing the Configuration language guide


Modified:
   branches/esb/java/1.7/esb/java/src/site/xdoc/ESB_Configuration_Language.xml

Modified: 
branches/esb/java/1.7/esb/java/src/site/xdoc/ESB_Configuration_Language.xml
URL: 
http://wso2.org/svn/browse/wso2/branches/esb/java/1.7/esb/java/src/site/xdoc/ESB_Configuration_Language.xml?rev=17993&r1=17992&r2=17993&view=diff
==============================================================================
--- branches/esb/java/1.7/esb/java/src/site/xdoc/ESB_Configuration_Language.xml 
(original)
+++ branches/esb/java/1.7/esb/java/src/site/xdoc/ESB_Configuration_Language.xml 
Thu Jun  5 03:49:54 2008
@@ -145,22 +145,16 @@
     }</style>
   </head>
   <body>
-    <table border="0" style="width: 100%">
-      <caption/>
-      <tbody>
-        <tr>
-          <td>
-            <h1>
-              Apache Synapse ESB - Configuration
-            </h1>
-          </td>
-          <td>
-            <img alt="Synapse logo" src="images/synapse-logo-web2.png"
-            width="197" height="82"/>
-          </td>
-        </tr>
-      </tbody>
-    </table>
+    <div style="margin-top:-40px; float:right; _margin-top:0px;">
+      <img alt="Synapse logo"
+           src="images/synapse-logo-web2.png" width="197"
+           height="82"/>
+    </div>
+    <div>
+      <h1>
+        Apache Synapse ESB - Configuration
+      </h1>
+    </div>
     <h3>
       Overview
     </h3>
@@ -282,7 +276,7 @@
       A Synapse configuration holds two special sequences named as "main" and
       "fault". These may be defined within the synapse.xml, or externally via
       the Registry. If either is not found, a suitable default is generated at
-      runtime by the ESB. The default "main" sequence will simple send a 
message
+      runtime by the ESB. The default "main" sequence will simply send a 
message
       without mediation, while the default "fault" sequence would log the
       message including the payload and any error/exception encountered and 
stop
       further processing. The 'fault' sequence executes whenever Synapse itself
@@ -506,8 +500,8 @@
       An endpoint may be specified as an address endpoint, WSDL based endpoint,
       a load balancing endpoint or a fail-over endpoint as follows:
     </p>
-<pre xml:space="preserve">&lt;endpoint [name="string"] [key="string"] 
[trace="enable"]&gt;
-  <a href="#address-endpoint">address-endpoint</a> | <a 
href="#wsdl-endpoint">wsdl-endpoint</a> | <a 
href="#load-balanced-endpoint">load-balanced-endpoint</a> | <a 
href="#fail-over-endpoint">fail-over-endpoint</a>
+<pre xml:space="preserve">&lt;endpoint [name="string"] [key="string"]&gt;
+  <a href="#address-endpoint">address-endpoint</a> | <a 
href="#default-endpoint">default-endpoint</a> | <a 
href="#wsdl-endpoint">wsdl-endpoint</a> | <a 
href="#load-balanced-endpoint">load-balanced-endpoint</a> | <a 
href="#fail-over-endpoint">fail-over-endpoint</a>
 &lt;/endpoint&gt; </pre>
     <p>
       All above endpoint types can have a name attribute, and such named
@@ -527,7 +521,7 @@
     </h4>
     <p>
       Address endpoint is an endpoint defined by specifying the EPR and other
-      attributes of the endpoint directly in the configuration.The 'uri'
+      attributes of the endpoint directly in the configuration. The 'uri'
       attribute of the address element contains the EPR of the target endpoint.
       Message format for the endpoint and the method to optimize attachments 
can
       be specified in the format and optimize attributes respectively. Reliable
@@ -562,28 +556,68 @@
       enableAddressing elements. Optionally, the WS-RM and WS-Security policies
       could be specified using the 'policy' attributes.
     </p>
-<pre xml:space="preserve">&lt;address uri="endpoint-address" 
[format="soap11|soap12|pox|get"] [optimize="mtom|swa"]&gt;
-  &lt;enableRM [policy="key"]/&gt;?
-  &lt;enableSec [policy="key"]/&gt;?
-  &lt;enableAddressing/&gt;?
-  
&lt;suspendDurationOnFailure&gt;suspend-duration&lt;/suspendDurationOnFailure&gt;?
+<pre xml:space="preserve">&lt;address uri="<em>endpoint address</em>" 
[format="soap11|soap12|pox|get"] [optimize="mtom|swa"]
+         [encoding="<em>charset encoding</em>"]
+         [statistics="enable|disable"] [trace="enable|disable"]&gt;
+  &lt;enableRM [policy="<em>key</em>"]/&gt;?
+  &lt;enableSec [policy="<em>key</em>"]/&gt;?
+  &lt;enableAddressing [version="final|submission"] 
[separateListener="true|false"]/&gt;?
+
   &lt;timeout&gt;
-    &lt;duration&gt;timeout-duration&lt;/duration&gt;
+    &lt;duration&gt;<em>timeout duration in seconds</em>&lt;/duration&gt;
     &lt;action&gt;discard|fault&lt;/action&gt;
   &lt;/timeout&gt;?
+
+  &lt;suspendDurationOnFailure&gt;
+    <em>suspend duration in seconds</em>
+  &lt;/suspendDurationOnFailure&gt;?
 &lt;/address&gt;</pre>
     <p>
       Following are some sample address URI definitions.
     </p>
-<pre xml:space="preserve">e.g.
-HTTP   http://localhost:9000/soap/SimpleStockQuoteService
-JMS     
jms:/SimpleStockQuoteService?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory&amp;
-              
java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&amp;
-              
java.naming.provider.url=tcp://localhost:61616&amp;transport.jms.DestinationType=topic
-Mail    mailto:[EMAIL PROTECTED]
-File     vfs:file:///home/user/directory
-           vfs:file:///home/user/file
-           vfs:ftp://guest:[EMAIL PROTECTED]/directory?vfs.passive=true</pre>
+<table border="1" cellpadding="0" cellspacing="0" style="width: 100%; 
font-size:small" class="data-table">
+      <tbody>
+        <tr><th>Transport</th><th>Sample address</th></tr>
+        
<tr><td>HTTP</td><td><tt>http://localhost:9000/soap/SimpleStockQuoteService</tt></td></tr>
+        <tr><td>JMS</td><td><tt>jms:/SimpleStockQuoteService?<br/>
+              
&#160;&#160;&#160;transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory&amp;<br/>
+              
&#160;&#160;&#160;java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&amp;<br/>
+              
&#160;&#160;&#160;java.naming.provider.url=tcp://localhost:61616&amp;<br/>
+              
&#160;&#160;&#160;transport.jms.DestinationType=topic</tt></td></tr>
+        <tr><td>Mail</td><td><tt>mailto:[EMAIL PROTECTED]</tt></td></tr>
+        <tr><td>VFS</td><td><tt>vfs:file:///home/user/directory</tt></td></tr>
+        <tr><td/><td><tt>vfs:file:///home/user/file</tt></td></tr>
+        <tr><td/><td><tt>vfs:ftp://guest:[EMAIL 
PROTECTED]/directory?vfs.passive=true</tt></td></tr>
+      </tbody>
+    </table>
+    <h4>
+      <a name="default-endpoint" id="default-endpoint">Default Endpoint</a>
+    </h4>
+    <p>
+      Default endpoint is an endpoint defined for adding QoS and other 
configurations
+      to the endpoint which is resolved from the 'To' address of the message 
context.
+      All the configurations such as message format for the endpoint, the 
method
+      to optimize attachments, reliable messaging, security policies for the 
endpoint
+      can be specified as in the Address Endpoint. This endpoint differs from 
the address
+      endpoint only in the uri attribute which will not be present in this 
endpoint.
+      Following section describes the configuration of a default endpoint
+    </p>
+    <pre xml:space="preserve">&lt;default [format="soap11|soap12|pox|get"] 
[optimize="mtom|swa"]
+         [encoding="<em>charset encoding</em>"]
+         [statistics="enable|disable"] [trace="enable|disable"]&gt;
+  &lt;enableRM [policy="<em>key</em>"]/&gt;?
+  &lt;enableSec [policy="<em>key</em>"]/&gt;?
+  &lt;enableAddressing [version="final|submission"] 
[separateListener="true|false"]/&gt;?
+
+  &lt;timeout&gt;
+    &lt;duration&gt;<em>timeout duration in seconds</em>&lt;/duration&gt;
+    &lt;action&gt;discard|fault&lt;/action&gt;
+  &lt;/timeout&gt;?
+
+  &lt;suspendDurationOnFailure&gt;
+    <em>suspend duration in seconds</em>
+  &lt;/suspendDurationOnFailure&gt;?
+&lt;/default&gt;</pre>
     <h4>
       <a id="wsdl-endpoint">WSDL Endpoint</a>
     </h4>
@@ -629,14 +663,16 @@
       The optional 'session' element makes the endpoint a session affinity 
based
       load balancing endpoint. If it is specified, sessions are bound to
       endpoints in the first message and all successive messages for those
-      sessions are directed to their associated endpoints. Only http sessions
-      are currently supported, and identifies sessions based on http cookies.
-      The 'failover' attribute mentioned above is not applicable for session
-      affinity based endpoints and it is always considered as set to false. If
-      it is required to have failover behavior in session affinity based load
-      balance endpoints, list failover endpoints as the target endpoints.
+      sessions are directed to their associated endpoints. Currently there are 
two types
+      of sessions supported in SAL endpoints. Namely HTTP transport based 
session
+      which identifies the sessions based on http cookies and the client 
session which
+      identifies the session by looking at a SOAP header sent by the client 
with the QName
+      '{http://ws.apache.org/ns/synapse}ClientID'. The 'failover' attribute 
mentioned above
+      is not applicable for session affinity based endpoints and it is always
+      considered as set to false. If it is required to have failover behavior 
in session
+      affinity based load balance endpoints, list failover endpoints as the 
target endpoints.
     </p>
-<pre xml:space="preserve">&lt;session type="http"/&gt;?
+<pre xml:space="preserve">&lt;session type="http|simpleClientSession"/&gt;?
 &lt;loadBalance [policy="roundRobin"] [failover="true|false"]&gt;
   &lt;endpoint .../&gt;+
 &lt;/loadBalance&gt;</pre>
@@ -671,11 +707,12 @@
       &lt;endpoint&gt;...&lt;/endpoint&gt;?
    &lt;/target&gt;?
    &lt;publishWSDL key="string" uri="string"&gt;
-      &lt;description&gt;...&lt;/description&gt; | 
&lt;definitions&gt;...&lt;/definitions&gt;
+      ( &lt;wsdl:definition&gt;...&lt;/wsdl:definition&gt; | 
&lt;wsdl20:description&gt;...&lt;/wsdl20:description&gt; )?
+      &lt;resource location="..." key="..."/&gt;*
    &lt;/publishWSDL&gt;?
    &lt;enableSec/&gt;?
    &lt;enableRM/&gt;?
-   &lt;policy key="string"&gt;...&lt;/policy&gt;?       // optional service 
level policies such as (e.g. WS-Security and/or WS-RM policies)
+   &lt;policy key="string" [type="(in | out)"]/&gt;?       // optional service 
or message level policies such as (e.g. WS-Security and/or WS-RM policies)
    &lt;parameter name="string"&gt;                 // optional service 
parameters such as (e.g. transport.jms.ConnectionFactory)
       string | xml
    &lt;/parameter&gt;
@@ -690,12 +727,12 @@
       these as specified with the optional 'transports' attribute.
     </p>
     <p>
-      You can give a list of synapse server names where this proxy service
+      You can give a list of Synapse server names where this proxy service
       should be deployed using 'pinnedServers' attribute. It takes the server
       names separated by comma or space character. If there is no pinned server
       list then proxy service will be started in all server instances. If a
       pinned server names list is given it will only start in the given named
-      Synapse server instances. The Synapse server name picked up from the
+      Synapse server instances. The Synapse server name is picked up from the
       system property 'SynapseServerName', failing which the hostname of the
       machine would be used or default to 'localhost'. You can give a name to a
       Synapse server instance as ./synapse.sh 
-DSynapseServerName=&lt;ServerName&gt;
@@ -721,11 +758,29 @@
       proxy service definition itself can not be specified to be dynamic; i.e
       &lt;proxy key="string"/&gt; is wrong)
     </p>
-    <p/>
+    <p>
+      A WSDL for the proxy service can be published using the 
&lt;publishWSDL&gt;
+      element. The WSDL document can be loaded from the registry by
+      specifying the 'key' attribute or from any other location by specifying 
the
+      'uri' attribute. Alternatively the WSDL can be provided inline as a child
+      element of &lt;publishWSDL&gt;. Artifacts (schemas or other WSDL 
documents)
+      imported by the WSDL can be resolved from the registry by specifying
+      appropriate &lt;resource&gt; elements:
+    </p>
+<pre> &lt;publishWSDL key="my.wsdl"&gt;
+   &lt;resource location="http://www.standards.org/standard.wsdl"; 
key="standard.wsdl"/&gt;
+ &lt;/publishWSDL&gt;
+</pre>
+    <p>
+      In this example the WSDL is retrieved from the registry using the key 
'my.wsdl'. It
+      imports another WSDL from location 
'http://www.standards.org/standard.wsdl'. Instead
+      of loading it from this location, Synapse will retrieve the imported 
WSDL from the
+      registry entry 'standard.wsdl'.
+    </p>
     <p>
       You can give the following as service parameters:
     </p>
-    <table border="0" cellpadding="0" cellspacing="0" style="width: 100%" 
class="data-table">
+    <table border="1" cellpadding="0" cellspacing="0" style="width: 100%" 
class="data-table">
       <caption/>
       <tbody>
         <tr>
@@ -777,7 +832,7 @@
     <p>
       Transport specific parameters that may be set as service parameters:
     </p>
-    <table border="0" cellpadding="0" cellspacing="0" style="width: 100%" 
class="data-table">
+    <table border="1" cellpadding="0" cellspacing="0" style="width: 100%" 
class="data-table">
       <caption/>
       <tbody>
         <tr>
@@ -847,9 +902,15 @@
         </tr>
         <tr>
           <td/>
-          <td/>
-          <td/>
-          <td/>
+          <td>
+            Optional
+          </td>
+          <td>
+            transport.jms.Wrapper
+          </td>
+          <td>
+            The wrapper element for the JMS message
+          </td>
         </tr>
         <tr>
           <td>
@@ -875,7 +936,16 @@
             transport.vfs.ContentType
           </td>
           <td>
-            The content type for messages for this service
+            The expected content type for files retrieved for this service. The
+            VFS transport uses this information to select the appropriate
+            message builder.
+            <br/>
+            Examples:
+            <ul>
+              <li><tt>text/xml</tt> for plain XML or SOAP</li>
+              <li><tt>text/plain; charset=ISO-8859-1</tt> for text files</li>
+              <li><tt>application/octet-stream</tt> for binary data</li>
+            </ul>
           </td>
         </tr>
         <tr>
@@ -979,12 +1049,6 @@
         </tr>
         <tr>
           <td/>
-          <td/>
-          <td/>
-          <td/>
-        </tr>
-        <tr>
-          <td/>
           <td>
             Optional
           </td>
@@ -1009,9 +1073,15 @@
         </tr>
         <tr>
           <td/>
-          <td/>
-          <td/>
-          <td/>
+          <td>
+            Optional
+          </td>
+          <td>
+            transport.vfs.MoveTimestampFormat
+          </td>
+          <td>
+            Timestamp prefix format for processed file name. 
java.text.SimpleDateFormat compatible string. e.g. yyMMddHHmmss&apos;-&apos;
+          </td>
         </tr>
       </tbody>
     </table>
@@ -1075,7 +1145,7 @@
     <p>
     </p>
     <p>
-      You can give a list of synapse server names where this task should be
+      You can give a list of Synapse server names where this task should be
       started using pinnedServers attribute. Refer to the explanation of this
       attribute under proxy services for more information.
     </p>
@@ -1091,7 +1161,7 @@
     </p>
     <p>
     </p>
-<pre xml:space="preserve"><a href="#send">send</a> | <a href="#drop">drop</a> 
| <a href="#log">log</a> | <a href="#property">property</a> | <a 
href="#sequence_ref">sequence</a> | <a href="#validate">validate</a> | <a 
href="#makefault">makefault</a> | <a href="#xslt">xslt</a> | <a 
href="#header">header</a> | <a href="#filter">filter</a> | <a 
href="#switch">switch</a> | <a href="#in">in</a> | <a href="#out">out</a> | <a 
href="#router">router</a>
+<pre xml:space="preserve"><a href="#send">send</a> | <a href="#drop">drop</a> 
| <a href="#log">log</a> | <a href="#property">property</a> | <a 
href="#sequence_ref">sequence</a> | <a href="#validate">validate</a> | <a 
href="#makefault">makefault</a> | <a href="#callout">callout</a> | <a 
href="#xslt">xslt</a> | <a href="#header">header</a> | <a 
href="#filter">filter</a> | <a href="#switch">switch</a> | <a href="#in">in</a> 
| <a href="#out">out</a> | <a href="#router">router</a>
     | <a href="#dblookup">dblookup</a> | <a href="#dbreport">dbreport</a> | <a 
href="#RMSequence">RMSequence</a> | <a href="#throttle">throttle</a> | <a 
href="#xquery">xquery</a> | <a href="#cache">cache</a> | <a 
href="#clone">clone</a> | <a href="#iterate">iterate</a> | <a 
href="#aggregate">aggregate</a> | <a href="#class">class</a> | <a 
href="#pojoCommand">pojoCommand</a> | <a href="#script">script</a> | <a 
href="#spring">spring</a> </pre>
     <p>
     </p>
@@ -1230,29 +1300,19 @@
     </p>
     <ul>
       <li>
-      </li>
-      <li>
         simple = To, From, WSAction, SOAPAction, ReplyTo, MessageID and any
         properties
       </li>
       <li>
-      </li>
-      <li>
         headers = All SOAP header blocks and any properties
       </li>
       <li>
-      </li>
-      <li>
         full = all attributes included in log level 'simple' and the SOAP
         envelope and any properties
       </li>
       <li>
-      </li>
-      <li>
         custom = Only properties specified to the Log mediator
       </li>
-      <li>
-      </li>
     </ul>
     <p>
     </p>
@@ -1295,32 +1355,22 @@
     </p>
     <ul>
       <li>
-      </li>
-      <li>
         RESPONSE - 'true' means the message is to be marked as a response
         message
       </li>
       <li>
-      </li>
-      <li>
         OUT_ONLY - 'true' means the message is to be marked as an out-only
         message that does not expect a response
       </li>
       <li>
-      </li>
-      <li>
         ERROR_CODE - this is set to any error message code encountered during a
         fault
       </li>
       <li>
-      </li>
-      <li>
         ERROR_MESSAGE - this is set to any error message text encountered 
during
         a fault
       </li>
       <li>
-      </li>
-      <li>
         ERROR_DETAIL - this is set to any error message detail text encountered
         during a fault
       </li>
@@ -1330,8 +1380,6 @@
         ERROR_EXCEPTION - this is set to any Java Exception encountered during 
a
         fault
       </li>
-      <li>
-      </li>
     </ul>
     <p>
     </p>
@@ -1343,24 +1391,13 @@
     </p>
     <ul>
       <li>
-      </li>
-      <li>
-        Sandesha2RMSpecVersion - can be '1.0' or '1.1'
-      </li>
-      <li>
-      </li>
-      <li>
-        Sandesha2SequenceKey - can be an identifier specifying an Sandesha
+        MercurySequenceKey - can be an identifier specifying an Mercury
         internal sequence key, and
       </li>
       <li>
-      </li>
-      <li>
-        Sandesha2LastMessage - 'true' will make this the last message and
+        MercuryLastMessage - 'true' will make this the last message and
         terminate the sequence
       </li>
-      <li>
-      </li>
     </ul>
     <p>
     </p>
@@ -1372,13 +1409,9 @@
     </p>
     <ul>
       <li>
-      </li>
-      <li>
         FORCE_HTTP_1.0 - forces outgoing http/s messages to use HTTP 1.0
         (instead of the default 1.1)
       </li>
-      <li>
-      </li>
     </ul>
     <p>
     </p>
@@ -1413,14 +1446,10 @@
     </p>
     <ul>
       <li>
-      </li>
-      <li>
         SYSTEM_DATE - Returns the current date as a String. Optionally a date
         format as per standard date format may be supplied. e.g.
-        synapse:get-property(SYSTEM_DATE, "yyyy.MM.dd G 'at' HH:mm:ss z") or
-        get-property(SYSTEM_DATE)
-      </li>
-      <li>
+        synapse:get-property("SYSTEM_DATE", "yyyy.MM.dd G 'at' HH:mm:ss z") or
+        get-property('SYSTEM_DATE')
       </li>
       <li>
         SYSTEM_TIME - Returns the current time in milliseconds. (i.e. the
@@ -1428,24 +1457,16 @@
         midnight, January 1, 1970 UTC)
       </li>
       <li>
-      </li>
-      <li>
         To, From, Action, FaultTo, ReplyTo, MessageID the message To and Action
         and WS-Addressing properties
       </li>
       <li>
-      </li>
-      <li>
         MESSAGE_FORMAT - returns the message format - i.e. returns pox, get,
         soap11 or soap12
       </li>
       <li>
-      </li>
-      <li>
         OperationName - returns the operation name for the message
       </li>
-      <li>
-      </li>
     </ul>
     <p>
     </p>
@@ -1454,6 +1475,58 @@
       retrieve Axis2 message context properties or transport headers. e.g.
       synapse:get-property('transport', 'USER_AGENT')
     </p>
+    <h5>
+      SynapseXpath variables
+    </h5>
+    <p>
+      There are a set of predefined XPath variables when writing XPaths in
+      the Synapse Configuration. Those are as follows;
+    </p>
+    <ul>
+        <li>
+            body - The SOAP 1.1 or 1.2 body element
+        </li>
+        <p>
+            For example; expression="$body/getQuote" refers to the first
+            getQuote element in the SOAP body regardless of whether the message
+            is SOAP-11 or SOAP-12
+        </p>
+        <li>
+            header - The SOAP 1.1 or 1.2 header element
+        </li>
+        <p>
+            For example; expression="$header/wsa:To" refers to the addressing
+            To header regardless of whether this message is SOAP-11 or SOAP-12
+        </p>
+    </ul>
+    <p>
+      Further there are some variable prefixes defined in Synapse XPaths
+      which can be usefull in writing the configurations;
+    </p>
+    <ul>
+        <li>
+            ctx - Prefix for Synapse MessageContext properties
+        </li>
+        <p>
+            For example; expression="$ctx:RESPONSE" gives the value of the
+            Synapse message context property with name 'RESPONSE'
+        </p>
+        <li>
+            axis2 - Prefix for Axis2 MessageContext properties
+        </li>
+        <p>
+            For example; expression="$axis2:messageType" gives the value of the
+            axis2 message context property with name 'messageType'
+        </p>
+        <li>
+            trp - Prefix for the transport headers
+        </li>
+        <p>
+            For example; expression="$trp:Content-Type" gives the value of the
+            'Content-Type' transport header, which is going to be the
+            Content-Type of the current message
+        </p>
+    </ul>
     <p>
     </p>
     <h4>
@@ -1511,7 +1584,7 @@
     </h4>
     <p>
     </p>
-<pre xml:space="preserve"> &lt;makefault [version="soap11|soap12"]&gt;
+<pre xml:space="preserve"> &lt;makefault [version="soap11|soap12|pox"]&gt;
    &lt;code (value="literal" | expression="xpath")/&gt;
    &lt;reason (value="literal" | expression="xpath")&gt;
    &lt;node&gt;?
@@ -1523,11 +1596,11 @@
     <p>
       The &lt;makefault&gt; mediator transforms the current message into a 
fault
       message, but does NOT send it. The &lt;send&gt; mediator needs to be
-      invoked to send a fault message created this way. The fault message "to"
-      header is set to the "faultTo" of the original message if such a header
-      existed on the original message. If a 'version' attribute is specified,
-      the created fault message will be created as a selected SOAP 1.1 or SOAP
-      1.2 fault.
+      invoked to send a fault message created this way. The fault message "To"
+      header is set to the "Fault-To" of the original message if such a header
+      exists on the original message. If a 'version' attribute is specified,
+      the created fault message will be created as a selected SOAP 1.1, SOAP
+      1.2 or POX fault.
     </p>
     <p>
     </p>
@@ -1535,6 +1608,28 @@
     <p>
     </p>
     <h4>
+      <a id="callout">Callout</a>
+    </h4>
+<pre xml:space="preserve"> &lt;callout serviceURL="string" 
[action="string"]&gt;
+   &lt;configuration [axis2xml="string"] [repository="string"]/&gt;?
+   &lt;source xpath="expression" | key="string"&gt;
+   &lt;target xpath="expression" | key="string"/&gt;
+ &lt;/callout&gt;
+</pre>
+    <p>
+      The &lt;callout&gt; mediator performs a blocking external service 
invocation during
+      mediation. The serviceURL and the optional action specifies the 
parameters for this external
+      call. The source element specifies the payload for the request message 
using an XPath expression;
+      or a registry key that will be used. The target element specifies a 
node, at which the resulting
+      payload will be attached into the current message, or the name of a 
key/property using which
+      the response would be attached to the current message context as a 
property.
+    </p>
+    <p>As the callout mediator performs a blocking call, it cannot use the 
default non-blocking http/s
+      transports based on Java NIO, and thus defaults to using the 
samples/axis2Client/client_repo/conf/axis2.xml
+      as the Axis2 configuration, and samples/axis2Client/client_repo as the 
client repository unless
+      these are specified separately
+    </p>
+    <h4>
       <a id="xslt">XSLT</a>
     </h4>
     <p>
@@ -1550,8 +1645,8 @@
       selected element of the current message payload. If the source element is
       not specified, it defaults to the first child of the soap body. 
Optionally
       parameters (XSLT) could be passed into the transformations through the
-      'property' elements.The 'feature' elements defines any features which
-      should be set to the TransformerFactory by explicitly. The feature
+      'property' elements. The 'feature' element defines any features which
+      should be explicitly set to the TransformerFactory. The feature
       'http://ws.apache.org/ns/synapse/transform/feature/dom' turns on DOM 
based
       transformations instead of serializing elements into Byte streams and/or
       temporary files. Though this would be better in performance than using
@@ -1563,6 +1658,72 @@
     <p>
     </p>
     <h4>
+      <a name="xquery" id="xquery">XQuery</a>
+    </h4>
+<pre xml:space="preserve">&lt;xquery key="string" [target="xpath"]&gt;
+    &lt;variable name="string" type="string" [key="string"] 
[expression="xpath"] [value="string"]/&gt;?
+&lt;/xquery&gt; </pre>
+    <p/>
+    <p>
+      The XQuery mediator can be used to perform an XQuery transformation. The
+      'key' attribute specifies the XQuery transformation, and the optional
+      'target' attribute specifies the node of the message that should be
+      transformed. This defaults to the first child of the SOAP body of the
+      payload. The 'variable' elements define a variable that could be bound to
+      the dynamic context of the XQuery engine in order to access those
+      variables through the XQuery script .
+    </p>
+    <p>
+      It is possible to specify just a literal 'value', or an XPath expression
+      over the payload, or even specify a registry key or a registry key
+      combined with an XPath expression that selects the variable. The name of
+      the variable corresponds to the name of variable declaration in the 
XQuery
+      script. The 'type' of the variable must be a valid type defined by the
+      JSR-000225 (XQJ API).
+    </p>
+    <p>
+      The supported types are:
+    </p>
+    <ul>
+      <li>
+        XQItemType.XQBASETYPE_INT -&gt; INT
+      </li>
+      <li>
+        XQItemType.XQBASETYPE_INTEGER -&gt; INTEGER
+      </li>
+      <li>
+        XQItemType.XQBASETYPE_BOOLEAN -&gt; BOOLEAN
+      </li>
+      <li>
+        XQItemType.XQBASETYPE_BYTE - &gt; BYTE
+      </li>
+      <li>
+        XQItemType.XQBASETYPE_DOUBLE -&gt; DOUBLE
+      </li>
+      <li>
+        XQItemType.XQBASETYPE_SHORT -&gt; SHORT
+      </li>
+      <li>
+        XQItemType.XQBASETYPE_LONG -&gt; LONG
+      </li>
+      <li>
+        XQItemType.XQBASETYPE_FLOAT -&gt; FLOAT
+      </li>
+      <li>
+        XQItemType.XQBASETYPE_STRING -&gt; STRING
+      </li>
+      <li>
+        XQItemType.XQITEMKIND_DOCUMENT -&gt; DOCUMENT
+      </li>
+      <li>
+        XQItemType.XQITEMKIND_DOCUMENT_ELEMENT -&gt; DOCUMENT_ELEMENT
+      </li>
+      <li>
+        XQItemType.XQITEMKIND_ELEMENT -&gt; ELEMENT
+      </li>
+    </ul>
+    <p/>
+    <h4>
       <a id="header">Header</a>
     </h4>
     <p>
@@ -1606,6 +1767,22 @@
       succeeds, the filter mediator will execute the enclosed mediators in
       sequence.
     </p>
+    <p>One could also use this mediator to handle the failure case as well, in 
which case the
+       configuration would be as follows
+    </p>
+<pre xml:space="preserve"> &lt;filter (source="xpath" regex="string") | 
xpath="xpath"&gt;
+   &lt;then [sequence="string"]&gt;
+     mediator+
+   &lt;/then&gt;
+   &lt;else [sequence="string"]&gt;
+     mediator+
+   &lt;/else&gt;
+ &lt;/filter&gt;</pre>
+    <p>In this case the filter condition remains as earlier and the succeeded 
messages will be
+       mediated using the the set of mediators enclosed in the 'then' element 
in sequence, while
+       failed messages will be mediated using the set of mediators enclosed in 
the else element
+       in sequence
+    </p>
     <p>
     </p>
     <p/>
@@ -1750,13 +1927,9 @@
     </p>
     <ul>
       <li>
-      </li>
-      <li>
         autocommit = true | false
       </li>
       <li>
-      </li>
-      <li>
         isolation = Connection.TRANSACTION_NONE |
         Connection.TRANSACTION_READ_COMMITTED |
         Connection.TRANSACTION_READ_UNCOMMITTED |
@@ -1764,62 +1937,38 @@
         Connection.TRANSACTION_SERIALIZABLE
       </li>
       <li>
-      </li>
-      <li>
         initialsize = int
       </li>
       <li>
-      </li>
-      <li>
         maxactive = int
       </li>
       <li>
-      </li>
-      <li>
         maxidle = int
       </li>
       <li>
-      </li>
-      <li>
         maxopenstatements = int
       </li>
       <li>
-      </li>
-      <li>
         maxwait = long
       </li>
       <li>
-      </li>
-      <li>
         minidle = int
       </li>
       <li>
-      </li>
-      <li>
         poolstatements = true | false
       </li>
       <li>
-      </li>
-      <li>
         testonborrow = true | false
       </li>
       <li>
-      </li>
-      <li>
         testonreturn = true | false
       </li>
       <li>
-      </li>
-      <li>
         testwhileidle = true | false
       </li>
       <li>
-      </li>
-      <li>
         validationquery = String
       </li>
-      <li>
-      </li>
     </ul>
     <p>
     </p>
@@ -1941,116 +2090,11 @@
     <p>
     </p>
     <h4>
-      <a id="xquery">XQuery</a>
-    </h4>
-    <p>
-    </p>
-<pre xml:space="preserve">&lt;xquery key="string" [target="xpath"]&gt;
-    &lt;variable name="string" type="string" [key="string"] 
[expression="xpath"] [value="string"]/&gt;?
-&lt;/xquery&gt; </pre>
-    <p>
-    </p>
-    <p/>
-    <p>
-    </p>
-    <p>
-      The XQuery mediator can be used to perform an XQuery transformation. The
-      'key' attribute specifies the XQuery transformation, and the optional
-      'target' attribute specifies the node of the message that should be
-      transformed. This defaults to the first child of the SOAP body of the
-      payload. The 'variable' elements define a variable that could be bound to
-      the dynamic context of the XQuery engine in order to access those
-      variables through the XQuery script .
-    </p>
-    <p>
-    </p>
-    <p>
-      It is possible to specify just a literal 'value', or an XPath expression
-      over the payload, or even specify a registry key or a registry key
-      combined with an XPath expression that selects the variable. The name of
-      the variable corresponds to the name of variable declaration in the 
XQuery
-      script. The 'type' of the variable must be a valid type defined by the
-      JSR-000225 (XQJ API).
-    </p>
-    <p>
-    </p>
-    <p>
-      The supported types are:
-    </p>
-    <p>
-    </p>
-    <ul>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQBASETYPE_INT -&gt; INT
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQBASETYPE_INTEGER -&gt; INTEGER
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQBASETYPE_BOOLEAN -&gt; BOOLEAN
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQBASETYPE_BYTE - &gt; BYTE
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQBASETYPE_DOUBLE -&gt; DOUBLE
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQBASETYPE_SHORT -&gt; SHORT
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQBASETYPE_LONG -&gt; LONG
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQBASETYPE_FLOAT -&gt; FLOAT
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQBASETYPE_STRING -&gt; STRING
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQITEMKIND_DOCUMENT -&gt; DOCUMENT
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQITEMKIND_DOCUMENT_ELEMENT -&gt; DOCUMENT_ELEMENT
-      </li>
-      <li>
-      </li>
-      <li>
-        XQItemType.XQITEMKIND_ELEMENT -&gt; ELEMENT
-      </li>
-      <li>
-      </li>
-    </ul>
-    <p>
-    </p>
-    <h4>
       <a id="cache">Cache</a>
     </h4>
     <p>
     </p>
-<pre xml:space="preserve"> &lt;cache id="string" [hashGenerator="class"] 
[timeout="seconds"] [scope=(per-host | per-mediator)]
+<pre xml:space="preserve"> &lt;cache [id="string"] [hashGenerator="class"] 
[timeout="seconds"] [scope=(per-host | per-mediator)]
      collector=(true | false) [maxMessageSize="in-bytes"]&gt;
    &lt;onCacheHit [sequence="key"]&gt;
      (mediator)+

_______________________________________________
Esb-java-dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/esb-java-dev

Reply via email to