You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ws.apache.org by ch...@apache.org on 2006/01/05 10:25:50 UTC

svn commit: r366133 [5/10] - in /webservices/site/trunk/targets/axis2: ./ 0_93/ 0_94/ 0_94/adb/ 0_94/adb/images/ 0_94/images/ 0_94/images/archi-guide/ 0_94/images/faq/ 0_94/images/logos/ 0_94/images/tools/ 0_94/images/tools/service/ 0_94/images/tools/w...

Added: webservices/site/trunk/targets/axis2/0_94/images/viewphases.jpg
URL: http://svn.apache.org/viewcvs/webservices/site/trunk/targets/axis2/0_94/images/viewphases.jpg?rev=366133&view=auto
==============================================================================
Binary file - no diff available.

Propchange: webservices/site/trunk/targets/axis2/0_94/images/viewphases.jpg
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: webservices/site/trunk/targets/axis2/0_94/images/wom.png
URL: http://svn.apache.org/viewcvs/webservices/site/trunk/targets/axis2/0_94/images/wom.png?rev=366133&view=auto
==============================================================================
Binary file - no diff available.

Propchange: webservices/site/trunk/targets/axis2/0_94/images/wom.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: webservices/site/trunk/targets/axis2/0_94/index.html
URL: http://svn.apache.org/viewcvs/webservices/site/trunk/targets/axis2/0_94/index.html?rev=366133&view=auto
==============================================================================
--- webservices/site/trunk/targets/axis2/0_94/index.html (added)
+++ webservices/site/trunk/targets/axis2/0_94/index.html Thu Jan  5 01:17:47 2006
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html><head><title>Axis 2.0 - Axis2 0.94 Documentation</title><style type="text/css" media="all">
+          @import url("../style/maven-base.css");
+          
+			    @import url("../style/maven-theme.css");</style><link rel="stylesheet" href="../style/print.css" type="text/css" media="print"></link><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"></meta></head><body class="composite"><div id="banner"><a href="http://www.apache.org/" id="organizationLogo"><img alt="Apache Software Foundation" src="http://www.apache.org/images/asf-logo.gif"></img></a><a href="http://ws.apache.org/axis2/" id="projectLogo"><img alt="Apache Axis 2.0" src="http://ws.apache.org/axis2/images/axis.jpg"></img></a><div class="clear"><hr></hr></div></div><div id="breadcrumbs"><div class="xleft">
+                	Last published: 05 January 2006
+                  | Doc for 0.94</div><div class="xright"></div><div class="clear"><hr></hr></div></div><div id="leftColumn"><div id="navcolumn"><div id="menuAxis_2_0"><h5>Axis 2.0</h5><ul><li class="none"><a href="../index.html">Home</a></li><li class="expanded"><a href="../">Download Axis2</a><ul><li class="none"><a href="../download.cgi">Releases</a></li><li class="none"><a href="http://svn.apache.org/viewcvs.cgi/webservices/axis2/trunk/?root=Apache-SVN" class="externalLink" title="External Link">Source Code</a></li></ul></li><li class="expanded"><a href="../">Documentation</a><ul><li class="none"><a href="../0_93/index.html">Version 0.93</a></li><li class="none"><strong><a href="../0_94/index.html">Version 0.94</a></strong></li></ul></li><li class="expanded"><a href="../overview.html">Get Involved</a><ul><li class="none"><a href="../svn.html">Checkout the Source</a></li><li class="none"><a href="../siteHowTo.html">Build the Site</a></li><li class="none"><a href="../guide
 lines.html">Developer Guidelines</a></li><li class="none"><a href="../refLib.html">Reference Library</a></li><li class="none"><a href="../mail-lists.html">Mailing Lists</a></li><li class="none"><a href="../faq.html">FAQ</a></li></ul></li><li class="none"><a href="../thanks.html">Ackknowledgements</a></li><li class="expanded"><a href="../">Project Information</a><ul><li class="none"><a href="../team-list.html">Project Team</a></li><li class="none"><a href="../issue-tracking.html">Issue Tracking</a></li></ul></li></ul></div><a href="http://maven.apache.org/" title="Built by Maven" id="poweredBy"><img alt="Built by Maven" src="../images/logos/maven-button-1.png"></img></a></div></div><div id="bodyColumn"><div class="contentBox"><div class="section"><a name="Getting_Started_Guides_for_Axis2"></a><h2>Getting Started Guides for Axis2</h2><ul>
+  <li><a href="installationguide.html">Installation Guide</a></li>
+  <li><a href="userguide.html">User's Guide</a></li>
+  <li><a href="webadminguide.html">Web Administration Guide </a></li>
+</ul></div><div class="section"><a name="Additional_References"></a><h2>Additional References</h2><ul>
+  <li><a href="http://wiki.apache.org/ws/FrontPage/Axis2" class="externalLink" title="External Link">Axis2 Wiki</a></li>
+  <li><a href="Axis2ArchitectureGuide.html">Architecture Guide</a></li>
+  <li><a href="OMTutorial.html">AXIOM Tutorial</a></li>
+  <li><a href="CodegenToolReference.html">Code Generation Tutorial</a></li>
+  <li><a href="rest-ws.html">REST Support</a></li>
+  <li>    <a href="mtom-guide.html">Handling Binary Data with Axis2</a></li>
+  <li>    <a href="axis2config.html">Axis2 Configuration Guide</a></li>
+  <li>    <a href="migration.html">Migrating from Axis 1.x</a></li>
+  <li>    <a href="api/api.html">Online Java Docs</a></li>
+  <li>    <a href="adb/adb-howto.html">ADB How-to</a></li>
+  <li>    <a href="security-module.html">WS-Security How-to</a></li>
+</ul></div><div class="section"><a name="Other_Tutorials"></a><h2>Other Tutorials</h2><div class="subsection"><a name="Axis2"></a><h3>Axis2</h3><ul>
+  <li><a href="http://www.jaxmagazine.com/itr/online_artikel/psecom,id,747,nodeid,147.html" class="externalLink" title="External Link">Axis2
+    - The Future of Web Services</a>
+  </li>
+  <li>
+    <a href="http://www.developer.com/services/article.php/3525481" class="externalLink" title="External Link">Introducing
+        Axis2</a>
+  </li>
+  <li><a href="http://www.onjava.com/pub/a/onjava/2005/07/27/axis2.html" class="externalLink" title="External Link">Web
+    Services Messaging with Apache Axis2: Concepts and Techniques</a></li>
+  <li><a href="http://developer.com/java/web/article.php/3529321" class="externalLink" title="External Link">Axis2
+    Execution Framework</a>
+  </li>
+  <li><a href="http://jaxmag.com/itr/online_artikel/psecom,id,757,nodeid,147.html" class="externalLink" title="External Link">Axis2
+    Deployment Model</a>
+  </li>
+  <li><a href="http://www.developer.com/open/article.php/3557741" class="externalLink" title="External Link">Undertanding Axis2 Deployment Architecture</a>
+  </li>
+
+</ul></div><div class="subsection"><a name="AXIOM"></a><h3>AXIOM</h3><ul>
+  <li><a href="http://www.jaxmag.com/itr/online_artikel/psecom,id,726,nodeid,147.html" class="externalLink" title="External Link">Fast
+    and Lightweight Object Model for XML </a> - An Introduction to AXIOM, the
+    Open Source API for Working with XML
+  </li>
+  <li><a href="http://www-128.ibm.com/developerworks/library/x-axiom/" class="externalLink" title="External Link">Get
+    the most out of XML processing with AXIOM</a> - Explaining the
+    flexibilities of AXIOM in developerworks.
+  </li>
+</ul></div></div></div></div><div class="clear"><hr></hr></div><div id="footer"><div class="xright">© 2004-2006, Apache Software Foundation</div><div class="clear"><hr></hr></div></div></body></html>
\ No newline at end of file

Added: webservices/site/trunk/targets/axis2/0_94/installationguide.html
URL: http://svn.apache.org/viewcvs/webservices/site/trunk/targets/axis2/0_94/installationguide.html?rev=366133&view=auto
==============================================================================
--- webservices/site/trunk/targets/axis2/0_94/installationguide.html (added)
+++ webservices/site/trunk/targets/axis2/0_94/installationguide.html Thu Jan  5 01:17:47 2006
@@ -0,0 +1,139 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html><head><title>Axis 2.0 - Axis2 Installation Guide</title><style type="text/css" media="all">
+          @import url("./style/maven-base.css");
+          
+			    @import url("./style/maven-theme.css");</style><link rel="stylesheet" href="./style/print.css" type="text/css" media="print"></link><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"></meta></head><body class="composite"><div id="banner"><a href="http://www.apache.org/" id="organizationLogo"><img alt="Apache Software Foundation" src="http://www.apache.org/images/asf-logo.gif"></img></a><a href="http://ws.apache.org/axis2/" id="projectLogo"><img alt="Apache Axis 2.0" src="http://ws.apache.org/axis2/images/axis.jpg"></img></a><div class="clear"><hr></hr></div></div><div id="breadcrumbs"><div class="xleft">
+                	Last published: 05 January 2006
+                  | Doc for 0.94</div><div class="xright"></div><div class="clear"><hr></hr></div></div><div id="leftColumn"><div id="navcolumn"><div id="menuAxis_2_0"><h5>Axis 2.0</h5><ul><li class="none"><a href="index.html">Home</a></li><li class="expanded"><a href="">Download Axis2</a><ul><li class="none"><a href="download.cgi">Releases</a></li><li class="none"><a href="http://svn.apache.org/viewcvs.cgi/webservices/axis2/trunk/?root=Apache-SVN" class="externalLink" title="External Link">Source Code</a></li></ul></li><li class="expanded"><a href="">Documentation</a><ul><li class="none"><a href="0_93/index.html">Version 0.93</a></li><li class="none"><a href="0_94/index.html">Version 0.94</a></li></ul></li><li class="expanded"><a href="overview.html">Get Involved</a><ul><li class="none"><a href="svn.html">Checkout the Source</a></li><li class="none"><a href="siteHowTo.html">Build the Site</a></li><li class="none"><a href="guidelines.html">Developer Guidelines</a></li><li cl
 ass="none"><a href="refLib.html">Reference Library</a></li><li class="none"><a href="mail-lists.html">Mailing Lists</a></li><li class="none"><a href="faq.html">FAQ</a></li></ul></li><li class="none"><a href="thanks.html">Ackknowledgements</a></li><li class="expanded"><a href="">Project Information</a><ul><li class="none"><a href="team-list.html">Project Team</a></li><li class="none"><a href="issue-tracking.html">Issue Tracking</a></li></ul></li></ul></div><a href="http://maven.apache.org/" title="Built by Maven" id="poweredBy"><img alt="Built by Maven" src="./images/logos/maven-button-1.png"></img></a></div></div><div id="bodyColumn"><div class="contentBox"><div class="section"><a name="Axis2_Installation_Guide"></a><h2>Axis2 Installation Guide</h2><p><i>Version 0.94</i></p><i>Feedback: <a href="mailto:axis-dev@ws.apache.org">axis-dev@ws.apache.org</a></i><div class="subsection"><a name="Contents"></a><h3>Contents</h3><ul>
+  <li><a href="#Download">Download Axis2</a></li>
+  <li><p><a href="#requirements">System Requirements</a></p>
+  </li>
+  <li><a href="#_Toc96698083">Setting up the Environment and tools</a>
+    <ul>
+      <li><p><a href="#_Toc96698084">Maven</a></p>
+      </li>
+      <li><a href="#_Toc96698085">The Axis2 source distribution</a></li>
+    </ul>
+  </li>
+  <li><p><a href="#_Toc96698086">Installing Axis2 in a Servlet
+    container</a></p>
+    <ul>
+      <li><a href="#upload">Uploading services</a></li>
+    </ul>
+  </li>
+</ul></div><div class="subsection"><a name="Download_Axis2"></a><h3>Download Axis2</h3><p>Axis2 is distributed in several formats and can be installed either as a
+standalone server or as part of a J2EE compliant servlet container. Axis2 is
+distributed under the Apache License, version 2.0</p><p>You can <a href="http://ws.apache.org/axis2/download.cgi" class="externalLink" title="External Link">download</a>
+Axis2 as a zipped binary, WAR or the <a href="http://svn.apache.org/viewcvs.cgi/webservices/axis2/trunk/?root=Apache-SVN" class="externalLink" title="External Link">source</a>
+depending on your requirements.</p><p>Latest release Axis2 version 0.94</p></div><div class="subsection"><a name="System_Requirements"></a><h3>System Requirements</h3><table class="bodyTable"><caption></caption><tbody>
+    <tr class="b"><td>Java Runtime
+
+        <p>Environment</p>
+      </td><td>1.4 (It has not been fully tested on the latest JRE 1.5)
+
+        <p>For instructions on setting up the JRE in different operating
+        systems, visit <a href="http://java.sun.com/" class="externalLink" title="External Link">http://java.sun.com</a></p>
+      </td></tr>
+    <tr class="a"><td>Maven</td><td>1.0.2 or higher (<a href="http://maven.apache.org/" class="externalLink" title="External Link">download</a>)
+
+        <p>Required only for building Axis2 from source distribution</p>
+      </td></tr>
+    <tr class="b"><td>Memory</td><td>No minimum requirement</td></tr>
+    <tr class="a"><td>Disk</td><td>No minimum requirement.
+
+        <p>Approximately 20 MB will be used for war distribution</p>
+      </td></tr>
+    <tr class="b"><td>Operating system</td><td>Tested on Windows XP, Mac OS X, Fedora core, Ubuntu</td></tr>
+  </tbody></table><p></p><p>All the required jars are shipped with the binary distribution.</p><p>Running the Maven build will automatically download the required jars when
+using source distribution.</p></div><div class="subsection"><a name="Setting_up_the_Environment_and_tools"></a><h3>Setting up the Environment and tools</h3></div><div class="subsection"><a name="Maven"></a><h3>Maven</h3><p>The Axis2 build is based on <a href="http://maven.apache.org/" class="externalLink" title="External Link">Maven </a>.
+Hence the only prerequisite to build Axis2 from source distribution is to
+have Maven installed. Extensive instruction guides are available at the Maven
+site.This guide however contains the easiest path for quick environment
+setting. Advanced users who wish to know more about Maven can visit <a href="http://maven.apache.org/start/index.html" class="externalLink" title="External Link">here </a>.</p><p>- Windows</p><ol>
+  <li>Download and run the Windows installer package</li>
+  <li>Set the 'Environment Variables' ( create system variable MAVEN_HOME and
+    edit path. eg: "C:\Program Files\Apache Software Foundation\maven-2.0.1";
+    path %MAVEN_HOME%\bin)</li>
+  <li>Make sure that system variable JAVA_HOME is set to the location of your
+    JDK, eg. C:\Program Files\Java\jdk1.5.0_02</li>
+  <li>Run maven --version to verify that it is correctly installed.</li>
+</ol><p>.</p><p align="center"><img alt="clip_image002 (15K)" src="images/clip_image002.jpg" height="211" width="477"></img></p><p>  - Unix based OS (Linux etc)</p><p>The tar ball or the zip archive is the best option. Once the archive is
+downloaded expand it to a directory of choice and set the environment
+variable MAVEN_HOME and add MAVEN_HOME/bin to the path as well. More
+instructions for installing Maven in Unix based operating systems can be
+found <a href="http://maven.apache.org/start/install.html" class="externalLink" title="External Link">here </a>.</p><p></p><p>Once maven is properly installed you can start building Axis2.</p></div><div class="subsection"><a name="The_Axis2_source_distribution"></a><h3>The Axis2 source distribution</h3><p>The <a href="releases.html">source distribution </a> is available as a
+zipped archive. All the necessary build scripts are included with the source
+distribution. Once the source archive is expanded into a directory of choice,
+moving to the particular directory and running maven command will build the
+Axis2 jar file.</p><p align="center"><img alt="clip_image004 (43K)" src="images/maven.jpg" height="248" width="668"></img></p><p>Once the command completes, the binaries (jar files in this case) can be
+found at a newly created "target" directory.</p><p><strong>Note: For the first Maven build (if the maven repository is not
+built first) it will take a while since required jars need to be downloaded.
+However this is a once only process and will not affect any successive
+builds.</strong></p><p><strong></strong>The default maven build will however build only the Axis2
+jar file. To obtain a WAR (Web Archive), "maven war" command should be
+issued. This will create a complete WAR with the name axis2.war inside the
+target directory.</p><p>Once this build step is complete, the binaries are ready to be
+deployed.</p></div><div class="subsection"><a name="Installing_Axis2_in_a_Servlet_container"></a><h3>Installing Axis2 in a Servlet container</h3><ol>
+  <li>Download Axis2 war file</li>
+  <li>Drop the war in the webapps folder. Most servlet containers will
+    automatically install war. (some servlet containers may require a restart
+    in order to capture the new web application. Refer your servlet container
+    documentation for more information about this.)</li>
+  <li>Once the WAR is successfully installed, test it by pointing the web
+    browser to the <strong>http:// &lt;host :port&gt;/ axis2. </strong>It
+    should produce the following page.</li>
+
+  <p align="center"><strong><img src="images/clip_image006.jpg" alt=""></img></strong></p>
+
+  <p></p>
+  <li>Use validate link to ensure that everything is fine and smooth. If the
+    validation fails then the war has failed to install properly or some
+    essential jars are missing. At such a situation the documentation of the
+    particular servlet container should be consulted to find the problem. The
+    following page is a successful validation. Note the statement core Axis2
+    libraries are present.
+    <p></p>
+  </li>
+
+  <p align="center"><strong><img src="images/happyaxis.jpg" alt=""></img></strong></p>
+</ol><p></p></div><div class="subsection"><a name="Uploading_services"></a><h3>Uploading services</h3><ol>
+  <p>The Axis2 web application also provides an interface to upload services.
+  Once a service is created according to the service specification as
+  described in userguide that jar file can be uploaded using the upload
+  page.</p>
+
+  <p align="center"><strong><img src="images/clip_image010.jpg" alt=""></img></strong></p>
+
+  <p>The uploaded jar files will be stored in the default service directory.
+  For Axis2 this will be the &lt;webapps&gt;/axis2/WEB-INF/services
+  directory. Once a service is uploaded it will be installed instantly.</p>
+
+  <p>Since Axis2 supports hot deployment one can drop the service jar
+  directly through the file system to the above mentioned services
+  directory.It will also cause the service to be automatically installed
+  without the container being restarted.</p>
+
+  <p>Use the <em>available services link</em>to check the successful
+  installation of a service. The services and the operations of successfully
+  installed services will be displayed in the available services page.</p>
+
+  <p align="center"><strong><img src="images/clip_image012.jpg" alt=""></img></strong></p>
+
+  <p></p>
+
+  <p>If the service has deployment time error it will list out those services
+  as faulty services. If you click on the link it will show your deployment
+  fault.</p>
+
+  <p align="center"><strong><img src="images/faultservice.jpg" alt=""></img></strong></p>
+
+  <p>Deployment time error message</p>
+
+  <p align="center"><strong><img src="images/faultmsg.jpg" alt=""></img></strong></p>
+
+  <p>  </p>
+
+  <p>  </p>
+
+  <p>Axis2 Administration is all about configuring Axis2 at the run time and
+  the configuration will be transient. More descriptions are available in <a href="webadminguide.html">Axis2 Web Administration Guide</a></p>
+</ol></div></div></div></div><div class="clear"><hr></hr></div><div id="footer"><div class="xright">© 2004-2006, Apache Software Foundation</div><div class="clear"><hr></hr></div></div></body></html>
\ No newline at end of file

Added: webservices/site/trunk/targets/axis2/0_94/mail-configuration.html
URL: http://svn.apache.org/viewcvs/webservices/site/trunk/targets/axis2/0_94/mail-configuration.html?rev=366133&view=auto
==============================================================================
--- webservices/site/trunk/targets/axis2/0_94/mail-configuration.html (added)
+++ webservices/site/trunk/targets/axis2/0_94/mail-configuration.html Thu Jan  5 01:17:47 2006
@@ -0,0 +1,71 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html><head><title>Axis 2.0 - Mail transport</title><style type="text/css" media="all">
+          @import url("./style/maven-base.css");
+          
+			    @import url("./style/maven-theme.css");</style><link rel="stylesheet" href="./style/print.css" type="text/css" media="print"></link><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"></meta></head><body class="composite"><div id="banner"><a href="http://www.apache.org/" id="organizationLogo"><img alt="Apache Software Foundation" src="http://www.apache.org/images/asf-logo.gif"></img></a><a href="http://ws.apache.org/axis2/" id="projectLogo"><img alt="Apache Axis 2.0" src="http://ws.apache.org/axis2/images/axis.jpg"></img></a><div class="clear"><hr></hr></div></div><div id="breadcrumbs"><div class="xleft">
+                	Last published: 05 January 2006
+                  | Doc for 0.94</div><div class="xright"></div><div class="clear"><hr></hr></div></div><div id="leftColumn"><div id="navcolumn"><div id="menuAxis_2_0"><h5>Axis 2.0</h5><ul><li class="none"><a href="index.html">Home</a></li><li class="expanded"><a href="">Download Axis2</a><ul><li class="none"><a href="download.cgi">Releases</a></li><li class="none"><a href="http://svn.apache.org/viewcvs.cgi/webservices/axis2/trunk/?root=Apache-SVN" class="externalLink" title="External Link">Source Code</a></li></ul></li><li class="expanded"><a href="">Documentation</a><ul><li class="none"><a href="0_93/index.html">Version 0.93</a></li><li class="none"><a href="0_94/index.html">Version 0.94</a></li></ul></li><li class="expanded"><a href="overview.html">Get Involved</a><ul><li class="none"><a href="svn.html">Checkout the Source</a></li><li class="none"><a href="siteHowTo.html">Build the Site</a></li><li class="none"><a href="guidelines.html">Developer Guidelines</a></li><li cl
 ass="none"><a href="refLib.html">Reference Library</a></li><li class="none"><a href="mail-lists.html">Mailing Lists</a></li><li class="none"><a href="faq.html">FAQ</a></li></ul></li><li class="none"><a href="thanks.html">Ackknowledgements</a></li><li class="expanded"><a href="">Project Information</a><ul><li class="none"><a href="team-list.html">Project Team</a></li><li class="none"><a href="issue-tracking.html">Issue Tracking</a></li></ul></li></ul></div><a href="http://maven.apache.org/" title="Built by Maven" id="poweredBy"><img alt="Built by Maven" src="./images/logos/maven-button-1.png"></img></a></div></div><div id="bodyColumn"><div class="contentBox"><div class="section"><a name="Mail_transport"></a><h2>Mail transport</h2><p>The inner workings of the mail transport has two parts, the transport sender and the transport listener. The transport listener is a basic email client which will be on a loop checking for new messages for a particular email address. When an email
  comes in it will be tunneled into the Axis engine.</p><p>Mail transport can be used against a generic mail server or it can be used like a mailet. The simple mailet provided with Axis2 will direct any message that is coming to a particular address into the Axis engine. The engine will process the message and will use the Transport sender to send the reply.</p><p></p><p>To get started on the mail transport you need the following additional jar dependencies on the classpath.</p><ol>
+  <li>javamail</li>
+  <li>activation</li>
+  </ol><p>We use the Geronimo version of these jars to compile but you will need the sun version to run the code. Specificaly we are using geronimo-spec-javamail-[version].jar and geronimo-spec-activation-[version].jar. These will be downloaded by maven when you run the maven build.</p><div class="subsection"><a name="Transport_Sender"></a><h3>Transport Sender</h3><p>You need to have a mail account to activate the mail functionality. This can either be a generic mail server or you can start up a james mail server. The Mail transport sender can be activated by adding following entry to the axis2.xml file.</p>
+    <div class="source"><pre>
+  <pre>
+   &lt;transportSender name="mail" class="org.apache.axis2.transport.mail.MailTransportSender"&gt;
+        &lt;parameter name="transport.mail.smtp.host" locked="xsd:false"&gt;smtp server host&lt;/parameter&gt;
+        &lt;parameter name="transport.mail.smtp.user" locked="xsd:false"&gt;user name&lt;/parameter&gt;
+        &lt;parameter name="transport.mail.smtp.password" locked="xsd:false"&gt;password&lt;/parameter&gt;
+        &lt;parameter name="transport.mail.smtp.port" locked="xsd:false"&gt;Port on the server for pop&lt;/parameter&gt;
+   &lt;/transportSender&gt;
+  </pre>
+  </pre></div>
+  </div><div class="subsection"><a name="Transport_Receiver"></a><h3>Transport Receiver</h3><p>The mail Listener can be activated by adding the following entry to the axis2.xml file.</p>
+    <div class="source"><pre><pre>
+   &lt;transportReceiver name="mail" class="org.apache.axis2.transport.mail.SimpleMailListener"&gt;
+        &lt;parameter name="transport.mail.pop3.host" locked="xsd:false"&gt;pop server host&lt;/parameter&gt;
+        &lt;parameter name="transport.mail.pop3.user" locked="xsd:false"&gt;user name&lt;/parameter&gt;
+        &lt;parameter name="transport.mail.pop3.password" locked="xsd:false"&gt;password&lt;/parameter&gt;
+        &lt;parameter name="transport.mail.pop3.port" locked="xsd:false"&gt;Port on the server for smtp&lt;/parameter&gt;
+        &lt;parameter name="transport.mail.replyToAddress" locked="xsd:false"&gt;email address&lt;/parameter&gt;
+  &lt;/transportReceiver&gt;
+  </pre></pre></div>
+  <p>At the Client side if the Mail Listener is needed it is automatically started by Axis2.</p></div><div class="subsection"><a name="Using_Mail_transport_in_the_Server_Side"></a><h3>Using Mail transport in the Server Side</h3><p> If the Mail Listener is need to be started as the server it can be done with following command with the all the axis2 jars and the mail dependency jars in the classpath.</p>
+    <div class="source"><pre><pre>java org.apache.axis2.transport.mail.SimpleMailListener repository-directory</pre></pre></div>
+  </div><div class="subsection"><a name="Using_Mail_transport_in_the_Client_Side"></a><h3>Using Mail transport in the Client Side</h3><p>Following code segment shows how to send a oneway SOAP message using the mail transport, this need the Transport Sender configured.</p>
+    <div class="source"><pre>
+<pre>
+OMElement payload = ....
+
+MessageSender sender = new MessageSender(serviceContext);
+sender.setTo(targetEPR);
+sender.setSenderTransport(Constants.TRANSPORT_MAIL);
+
+sender.send(operationName.getLocalPart(), payload);
+</pre>
+</pre></div>
+  </div><div class="subsection"><a name="Configure_James_as_SMTP_and_POP_server"></a><h3>Configure James as SMTP and POP server</h3><p>Download the <a href="http://james.apache.org/" class="externalLink" title="External Link">Apache James</a> and start James, connect to the James via telnet for administrator James with the following code
+</p>
+    <div class="source"><pre>
+<pre>
+$telnet 127.0.0.1 4555
+Trying 127.0.0.1...
+Connected to localhost.localdomain (127.0.0.1).
+Escape character is '^]'.
+JAMES Remote Administration Tool 2.2.0
+Please enter your login and password
+Login id:
+root
+Password:
+root
+Welcome root. HELP for a list of commands
+</pre>
+</pre></div>
+  <p>Add users to James</p>
+    <div class="source"><pre>
+<pre>
+adduser axis2-server axis2
+User axis2-server added
+adduser axis2-client axis2
+User axis2-client added
+Connection closed by foreign host.
+</pre>
+</pre></div>
+  <p>Now James is up and running with the accounts</p></div><div class="subsection"><a name="Using_the_included_mail_server"></a><h3>Using the included mail server</h3><p>The inbuilt mail server can be started from the command line using the following piece of code when all the needed jars are in the class path.</p><p><code>java org.apache.axis2.transport.mail.server.MailServer</code></p><p>The server itself does not need any configuration or tinkering to work. A ConfigurationContext and the ports to operate on are the only details needed. The server will store the mails in memory against the recipient till the recipient pops it from the server. To facilitate the use in *nix environments as a non root user the pop and smtp ports used by default config/test cases are (1024 + 25) and (1024 + 110).</p></div></div><div class="section"><p> </p></div></div></div><div class="clear"><hr></hr></div><div id="footer"><div class="xright">© 2004-2006, Apache Software Foundation</div><d
 iv class="clear"><hr></hr></div></div></body></html>
\ No newline at end of file

Added: webservices/site/trunk/targets/axis2/0_94/mail-transport.html
URL: http://svn.apache.org/viewcvs/webservices/site/trunk/targets/axis2/0_94/mail-transport.html?rev=366133&view=auto
==============================================================================
--- webservices/site/trunk/targets/axis2/0_94/mail-transport.html (added)
+++ webservices/site/trunk/targets/axis2/0_94/mail-transport.html Thu Jan  5 01:17:47 2006
@@ -0,0 +1,228 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html><head><title>Axis 2.0 - Invoking a service using a mail</title><style type="text/css" media="all">
+          @import url("./style/maven-base.css");
+          
+			    @import url("./style/maven-theme.css");</style><link rel="stylesheet" href="./style/print.css" type="text/css" media="print"></link><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"></meta></head><body class="composite"><div id="banner"><a href="http://www.apache.org/" id="organizationLogo"><img alt="Apache Software Foundation" src="http://www.apache.org/images/asf-logo.gif"></img></a><a href="http://ws.apache.org/axis2/" id="projectLogo"><img alt="Apache Axis 2.0" src="http://ws.apache.org/axis2/images/axis.jpg"></img></a><div class="clear"><hr></hr></div></div><div id="breadcrumbs"><div class="xleft">
+                	Last published: 05 January 2006
+                  | Doc for 0.94</div><div class="xright"></div><div class="clear"><hr></hr></div></div><div id="leftColumn"><div id="navcolumn"><div id="menuAxis_2_0"><h5>Axis 2.0</h5><ul><li class="none"><a href="index.html">Home</a></li><li class="expanded"><a href="">Download Axis2</a><ul><li class="none"><a href="download.cgi">Releases</a></li><li class="none"><a href="http://svn.apache.org/viewcvs.cgi/webservices/axis2/trunk/?root=Apache-SVN" class="externalLink" title="External Link">Source Code</a></li></ul></li><li class="expanded"><a href="">Documentation</a><ul><li class="none"><a href="0_93/index.html">Version 0.93</a></li><li class="none"><a href="0_94/index.html">Version 0.94</a></li></ul></li><li class="expanded"><a href="overview.html">Get Involved</a><ul><li class="none"><a href="svn.html">Checkout the Source</a></li><li class="none"><a href="siteHowTo.html">Build the Site</a></li><li class="none"><a href="guidelines.html">Developer Guidelines</a></li><li cl
 ass="none"><a href="refLib.html">Reference Library</a></li><li class="none"><a href="mail-lists.html">Mailing Lists</a></li><li class="none"><a href="faq.html">FAQ</a></li></ul></li><li class="none"><a href="thanks.html">Ackknowledgements</a></li><li class="expanded"><a href="">Project Information</a><ul><li class="none"><a href="team-list.html">Project Team</a></li><li class="none"><a href="issue-tracking.html">Issue Tracking</a></li></ul></li></ul></div><a href="http://maven.apache.org/" title="Built by Maven" id="poweredBy"><img alt="Built by Maven" src="./images/logos/maven-button-1.png"></img></a></div></div><div id="bodyColumn"><div class="contentBox"><div class="section"><a name="Invoking_a_service_using_a_mail"></a><h2>Invoking a service using a mail</h2><div class="subsection"><a name="Prologue"></a><h3>Prologue</h3><p>Most of Web services that we interact with are synchronous and
+request-response in nature. However, we see that the synchronous
+request-response type of interaction is only a part of the messaging
+scenarios we encounter in real life. Asynchronous messaging is very important
+in constructing loosely coupled systems. Take for instance a chain of stores,
+at the end of the day all the stores all over can send a mail to the central
+system telling it what that days business activity was and in the morning
+when the store opens there will be a reply to that mail with new instructions
+and updates. It is a lot like the way the old business worked but with a
+modern touch. Similarly Axis2 mail transport can be used to implement
+SETI@HOME through mail.</p></div><div class="subsection"><a name="Introduction"></a><h3>Introduction</h3><p>To start you will first need to go through the Mail Transport <a href="mail-configuration.html">configuration document</a>. It will give you
+all the information you need on how to configure Axis2 to get mail transport
+working.</p><p>Broadly speaking there are 3 ways of calling a service through mail.</p><blockquote>
+  1. Using the simple mail server included in Axis2.<br></br>
+  2. Using a generic mail server.<br></br>
+  3. Using mailets.<br></br>
+</blockquote><p></p><p>Option number 1 and 2 are fairly simple and easy to implement, whereas
+option 3 is somewhat harder.The mailet scenario however does provide a more
+robust and useful solution in a production environment.</p><p>If you are not a guru in mail related issues you should probably get
+started on the simple mail server that has been provided with Axis2. Once you
+get the hang of the Axis2 related issues then you can move on to tackle the
+mail beast. Please do keep in mind that the mail server we have implemented
+is ONLY FOR DEMONSTRATION/TESTING PURPOSES.</p></div><div class="subsection"><a name="1__Using_the_simple_mail_server_included_in_Axis2"></a><h3>1. Using the simple mail server included in Axis2</h3><p>The SMTP/POP server that we have included has the ability to function as a
+standalone SMTP/POP server and also has the ability to work as a mailet. All
+this is done through a small filter that keeps watch for certain
+pre-configured email addresses. These pre-configured email addresses can be
+changed by doing a simple edit of the filter class
+org.apache.axis2.transport.mail.server.Sorter.</p><p>Now that we have the environment set up, let us start pumping out some
+code to get the mail functionality off the ground. First we'll have a look at
+it from the mail server side. <br></br>
+</p>
+    <div class="source"><pre><pre>        // Start the mail server using the default configurations.
+        ConfigurationContext configContext = UtilsMailServer.start();
+
+        // Start the default mail listener. It will starting poling for mail
+        // using the configuration from the XML file.
+        SimpleMailListener ml = new SimpleMailListener();
+        ml.init(configContext, configContext.getAxisConfiguration()
+                .getTransportIn(new QName(Constants.TRANSPORT_MAIL)));
+        ml.start();
+
+        // Setup a service that will echo what we send to the server.
+        AxisService axisService = Utils.createSimpleService(serviceName,
+                Echo.class.getName(), new QName("echoOMElement"));
+        configContext.getAxisConfiguration().addService(axisService);
+        Utils.resolvePhases(configContext.getAxisConfiguration(), axisService);
+        ServiceContext serviceContext = configContext
+                .createServiceContext(new QName("EchoXMLService"));</pre>
+</pre></div>
+  <p>This code sets up your Axis2 server working through mail, with a single
+service. If you need to have a look under the hood check out the MailServer
+and UtilsMailServer classes.</p><p>Moving onto the client side have a look at the code listing below. It will
+call the axisService that was setup on the previous code listing.</p>
+    <div class="source"><pre><pre>	ConfigurationContext configContext = UtilsMailServer
+                .createClientConfigurationContext();
+        AxisService axisService = new AxisService(serviceName);
+        AxisOperation axisOperation = new AxisOperation(operationName);
+        axisOperation.setMessageReceiver(new MessageReceiver() {
+                public void receive(MessageContext messgeCtx) throws AxisFault {
+                        envelope = messgeCtx.getEnvelope();
+                }
+        });
+        axisService.addOperation(axisOperation);
+        configContext.getAxisConfiguration().addService(axisService);
+        Utils.resolvePhases(configContext.getAxisConfiguration(), axisService);
+        ServiceContext serviceContext = configContext
+                .createServiceContext(serviceName);
+                
+        Options options = new Options();
+        options.setTo(targetEPR);
+        options.setTransportInProtocol(Constants.TRANSPORT_MAIL);
+        options.setUseSeparateListener(true);
+        // Create a callback to set to the axisService invocation.
+        Callback callback = new Callback() {
+                public void onComplete(AsyncResult result) {
+                        try {
+                                result.getResponseEnvelope().serialize(
+                                        XMLOutputFactory.newInstance()
+                                                .createXMLStreamWriter(System.out));
+                        } catch (XMLStreamException e) {
+                                reportError(e);
+                        } finally {
+                                finish = true;
+                        }
+                }
+                public void reportError(Exception e) {
+                        log.info(e.getMessage());
+                        finish = true;
+                }
+         };
+
+        ServiceClient sender = new ServiceClient(configContext, axisService);
+        sender.setOptions(options);
+        options.setTo(targetEPR);
+        // Call the service and start poling for the reply from the server.
+        sender.sendReceiveNonBlocking(operationName.getLocalPart(), createEnvelope(), callback);
+
+        int index = 0;
+        while (!finish) {
+                Thread.sleep(1000);
+                index++;
+                if (index &gt; 10) {
+                        throw new AxisFault(
+                                "Server is being shutdown as the Async response is taking too long.");
+                }
+        }
+</pre>
+</pre></div>
+  <p>This will call the service that was setup on the server and will poll the
+mail server till the response is received.Thats all there is to it. Please do note that
+serviceName and operationName need to be QNames.
+</p><p></p></div><div class="subsection"><a name="2__Using_a_generic_mail_server"></a><h3>2. Using a generic mail server</h3><p>First you need two email accounts that works with POP/SMTP. One will act
+as a server and the other will act as the client. For the time being we will
+use server@somewhere.org and client@somewhere.org as the server and the
+client email addresses. Now that we have the email addresses you will have to
+set up the client and the server with Mail Transport <a href="http://ws.apache.org/axis2/mail-transport.html" class="externalLink" title="External Link">introduction
+document</a>.</p><p>When calling the generic mail server the client side code will remain the
+same and there will be some modification to the server-side code.</p><p></p>
+    <div class="source"><pre><pre>        // Create a configuration context. This will also load the details about the mail
+        // address to listen to from the configuration file.
+        File file = new File(MAIL_TRANSPORT_SERVER_ENABLED_REPO_PATH);
+        ConfigurationContextFactory builder = new ConfigurationContextFactory();
+        ConfigurationContext configContextbuilder
+                .buildConfigurationContext(file.getAbsolutePath());
+
+        // Startup the default mail server and start listening to a 
+        // mail address.
+        SimpleMailListener ml = new SimpleMailListener();
+        ml.init(configContext, configContext.getAxisConfiguration()
+                .getTransportIn(new QName(Constants.TRANSPORT_MAIL)));
+        ml.start();
+
+        // Setup a simple service.
+        AxisService axisService = Utils.createSimpleService(serviceName,
+                Echo.class.getName(), operationName);
+        configContext.getAxisConfiguration().addService(axisService);
+        Utils.resolvePhases(configContext.getAxisConfiguration(), axisService);
+        ServiceContext serviceContext = configContext.createServiceContext(serviceName);</pre>
+</pre></div>
+  <p>Note that a separate ConfigurationContext needs to be created and used.</p></div><div class="subsection"><a name="3__Calling_Axis_through_a_James_mailet"></a><h3>3. Calling Axis through a James mailet</h3><p>This process will be a bit more challenging than the other two methods but
+will provide a really elegant way to use the mail transport. Before we get
+started you will have to go though the James documents <a href="http://james.apache.org/custom_matcher_2_1.html" class="externalLink" title="External Link">Writing a Custom
+Matcher</a> and <a href="http://james.apache.org/custom_mailet_2_1.html" class="externalLink" title="External Link">Writing a Custom
+Mailet</a>.</p><p>Now that we know the James part of it lets dive into to the Axis2 part of
+the code. Once you have set up the James side of business we need to use the
+same functionality that is used in the above code. Have a look at the code
+listing below for more details</p>
+    <div class="source"><pre><pre>    public void processMail(ConfigurationContext confContext, MimeMessage mimeMessage) {
+        // create an Axis server
+        AxisEngine engine = new AxisEngine(confContext);
+        MessageContext msgContext = null;
+        // create and initialize a message context
+        try {
+            // Create a message context with mail as in and out transports.
+            msgContext =
+                    new MessageContext(confContext,
+                            confContext.getAxisConfiguration().getTransportIn(new QName(Constants.TRANSPORT_MAIL)),
+                            confContext.getAxisConfiguration().getTransportOut(new QName(Constants.TRANSPORT_MAIL)));
+            msgContext.setServerSide(true);
+
+            msgContext.setProperty(MailConstants.CONTENT_TYPE, mimeMessage.getContentType());
+            msgContext.setWSAAction(getMailHeader(MailConstants.HEADER_SOAP_ACTION, mimeMessage));
+
+            // The service path is in the subject of the mail.
+            String serviceURL = mimeMessage.getSubject();
+            if (serviceURL == null) {
+                serviceURL = "";
+            }
+
+            String replyTo = ((InternetAddress) mimeMessage.getReplyTo()[0]).getAddress();
+            if (replyTo != null) {
+                msgContext.setReplyTo(new EndpointReference(replyTo));
+            }
+
+            String recipients = ((InternetAddress) mimeMessage.getAllRecipients()[0]).getAddress();
+
+            if (recipients != null) {
+                msgContext.setTo(new EndpointReference(recipients + "/" + serviceURL));
+            }
+
+            // add the SOAPEnvelope
+            String message = mimeMessage.getContent().toString();
+            ByteArrayInputStream bais = new ByteArrayInputStream(message.getBytes());
+            XMLStreamReader reader = XMLInputFactory.newInstance().createXMLStreamReader(bais);
+
+            // This is just in place to work with SOAP 1.1 and 1.2.
+            String soapNamespaceURI = "";
+            if (mimeMessage.getContentType().indexOf(SOAP12Constants.SOAP_12_CONTENT_TYPE) &gt; -1) {
+                soapNamespaceURI = SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI;
+            } else if (mimeMessage.getContentType().indexOf(SOAP11Constants.SOAP_11_CONTENT_TYPE) &gt; -1) {
+                soapNamespaceURI = SOAP11Constants.SOAP_ENVELOPE_NAMESPACE_URI;
+
+            }
+            StAXBuilder builder = new StAXSOAPModelBuilder(reader, soapNamespaceURI);
+
+            SOAPEnvelope envelope = (SOAPEnvelope) builder.getDocumentElement();
+            msgContext.setEnvelope(envelope);
+            if (envelope.getBody().hasFault()) {
+                engine.receiveFault(msgContext);
+            } else {
+                engine.receive(msgContext);
+            }
+        } catch (Exception e) {
+            try {
+                if (msgContext != null) {
+                    MessageContext faultContext = engine.createFaultMessageContext(msgContext, e);
+                    engine.sendFault(faultContext);
+                }
+            } catch (Exception e1) {
+                log.error(e);
+            }
+        }
+    }</pre>
+</pre></div>
+  <p>If you don't happen to have a ConfigurationContext lying around to call
+this method you can use the following bit of code to get one. Once you create
+one you can store that on the mailet and keep using it.</p>
+    <div class="source"><pre><pre>        File file = new File(MAIL_TRANSPORT_SERVER_ENABLED_REPO_PATH);
+        ConfigurationContextFactory builder = new ConfigurationContextFactory();
+        ConfigurationContext configContextbuilder
+                .buildConfigurationContext(file.getAbsolutePath());</pre>
+</pre></div>
+  <p></p></div></div></div></div><div class="clear"><hr></hr></div><div id="footer"><div class="xright">© 2004-2006, Apache Software Foundation</div><div class="clear"><hr></hr></div></div></body></html>
\ No newline at end of file

Added: webservices/site/trunk/targets/axis2/0_94/migration.html
URL: http://svn.apache.org/viewcvs/webservices/site/trunk/targets/axis2/0_94/migration.html?rev=366133&view=auto
==============================================================================
--- webservices/site/trunk/targets/axis2/0_94/migration.html (added)
+++ webservices/site/trunk/targets/axis2/0_94/migration.html Thu Jan  5 01:17:47 2006
@@ -0,0 +1,103 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html><head><title>Axis 2.0 - Migrating from Axis 1.x</title><style type="text/css" media="all">
+          @import url("./style/maven-base.css");
+          
+			    @import url("./style/maven-theme.css");</style><link rel="stylesheet" href="./style/print.css" type="text/css" media="print"></link><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"></meta></head><body class="composite"><div id="banner"><a href="http://www.apache.org/" id="organizationLogo"><img alt="Apache Software Foundation" src="http://www.apache.org/images/asf-logo.gif"></img></a><a href="http://ws.apache.org/axis2/" id="projectLogo"><img alt="Apache Axis 2.0" src="http://ws.apache.org/axis2/images/axis.jpg"></img></a><div class="clear"><hr></hr></div></div><div id="breadcrumbs"><div class="xleft">
+                	Last published: 05 January 2006
+                  | Doc for 0.94</div><div class="xright"></div><div class="clear"><hr></hr></div></div><div id="leftColumn"><div id="navcolumn"><div id="menuAxis_2_0"><h5>Axis 2.0</h5><ul><li class="none"><a href="index.html">Home</a></li><li class="expanded"><a href="">Download Axis2</a><ul><li class="none"><a href="download.cgi">Releases</a></li><li class="none"><a href="http://svn.apache.org/viewcvs.cgi/webservices/axis2/trunk/?root=Apache-SVN" class="externalLink" title="External Link">Source Code</a></li></ul></li><li class="expanded"><a href="">Documentation</a><ul><li class="none"><a href="0_93/index.html">Version 0.93</a></li><li class="none"><a href="0_94/index.html">Version 0.94</a></li></ul></li><li class="expanded"><a href="overview.html">Get Involved</a><ul><li class="none"><a href="svn.html">Checkout the Source</a></li><li class="none"><a href="siteHowTo.html">Build the Site</a></li><li class="none"><a href="guidelines.html">Developer Guidelines</a></li><li cl
 ass="none"><a href="refLib.html">Reference Library</a></li><li class="none"><a href="mail-lists.html">Mailing Lists</a></li><li class="none"><a href="faq.html">FAQ</a></li></ul></li><li class="none"><a href="thanks.html">Ackknowledgements</a></li><li class="expanded"><a href="">Project Information</a><ul><li class="none"><a href="team-list.html">Project Team</a></li><li class="none"><a href="issue-tracking.html">Issue Tracking</a></li></ul></li></ul></div><a href="http://maven.apache.org/" title="Built by Maven" id="poweredBy"><img alt="Built by Maven" src="./images/logos/maven-button-1.png"></img></a></div></div><div id="bodyColumn"><div class="contentBox"><div class="section"><a name="Migrating_from_Axis_1_x_to_Axis_2"></a><h2>Migrating from Axis 1.x to Axis 2</h2><div class="subsection"><a name="Compatibility"></a><h3>Compatibility</h3><p>Axis1.x and Axis2 have been evolved from different architectures.</p><p>Speed - Axis2 is based on StAX API, which gives greater speed t
 han SAX
+event base parsing that has been used in Axis1.x.</p><p>Stability - Axis2 has fixed phases and for extensions an area of user
+defined phases. This allows far more stability and flexibility than
+Axis1.x.</p><p>Transport framework - Simple abstraction designing of transports (i.e.,
+senders and listeners for SOAP over various protocols such as SMTP, etc),
+allow far more flexibility and the core of the engine is completely
+transport-independent.</p><p>WSDL Support - Axis2 supports version 1.1 and 2.0, which allow creating
+stubs and skeletons, to manipulate web service arena.</p><p>Component - Oriented Architecture - This is merely through archives (.mar
+and .aar) . Easily reusable components such as Handlers, Modules allow
+patterns processing for your applications, or to distribute to partners.
+Axis2 more concern on the "Module" concept rather Handler concept. Modules
+contain handlers that have been ordered through phase rules. which being
+ordered to specific service(s).</p></div><div class="subsection"><a name="Getting_Started"></a><h3>Getting Started</h3><p>Lets look at a simple example of echoing at client API</p><p><b>Axis 1.x</b></p>
+    <div class="source"><pre>import ..
+public class TestClient {
+        public static void main(String [] args) {
+                try {
+                        String endpoint = ...
+                        Service axisService = new Service();
+                        Call call = (Call) axisService.createCall();
+                        call.setTargetEndpointAddress( new java.net.URL(endpoint) );
+                        call.setOperationName(new QName("http://soapinterop.org/", echoString"));
+                        String ret = (String) call.invoke( new Object[] { "Hello!" } );
+                        System.out.println("Sent 'Hello!', got '" + ret + "'");
+                } catch (Exception e) {
+                        System.err.println(e.toString());
+                }
+        }
+}
+
+</pre></div>
+  <p><b>Axis 2</b></p>
+    <div class="source"><pre>import ....
+public class EchoBlockingClient {
+        private static EndpointReference targetEPR = new EndpointReference(
+        AddressingConstants.WSA_TO,
+                                "http://127.0.0.1:8080/axis2/services/MyService");
+        public static void main(String[] args) {
+                try {
+                        OMElement payload = ClientUtil.getEchoOMElement();
+                        Options options = new Options();
+                        Call call = new Call();
+                        options.setTo(targetEPR);
+                        options.setSenderTransport(new TransportOutDescription(new QName(Constants.TRANSPORT_HTTP)));
+                        //Blocking invocation
+                        OMElement result = (OMElement) call.invokeBlocking("echo",payload);
+                        ...
+                } catch (AxisFault axisFault) {
+                        axisFault.printStackTrace();
+                } catch (XMLStreamException e) {
+                        e.printStackTrace();
+                }
+        }
+}
+
+</pre></div>
+  <p>It has clearly depicted that the invocation in Axis2 is dealt with SOAP
+body element itself. Here the invocation is synchronous, and Axis2 can handle
+Asynchronous invocation as well. Above "payload" is the SOAP body element
+which should go in the Envelop.</p><p>Once the service is called through Stub in Axis2, "payload" is according
+to the data binding framework that will be using. So the extra work of
+"payload" will be vanished.</p><p>Apart from Synchronous invocation, Axis2 support Asynchronous invocation
+through invokeNonBlocking(). Synchronous/Asynchronous invocations can handle
+both single/double HTTP connection.</p><p>With the advance architecture Axis2 is capable of handling Megabytes of
+Requests and Responses, which is far form Axis1.x.</p></div><div class="subsection"><a name="Custom_Deployment_of_Services__Handlers_and_Modules"></a><h3>Custom Deployment of Services, Handlers and Modules</h3><p>In Axis 1.x deployment of services is via WSDD, which is for my opinion
+highly cumbersome. Service deployment in Axis2 is straight forward and
+dynamic. Dynamic behavior is from the Administrator facility given by
+development in server side. It's just a matter of creating a .aar file, and
+deploying it ,which more detail is given in the Axis2 user guide.</p><p>Axis2 is far way from Handler concept and more into the Module concept,
+which is abstractly speaking, a collection of handlers with Rules of
+governing. Modules created as a .mar file. It has module.xml, which is the
+brain behind manipulating handlers.</p><p>When a service is called through a handler, it is just a matter of giving
+reference to the module that includes the handler in the service.xml. Apart
+from that a handler can be directly called to a particular service, via
+service.xml, no module is needed, and several handlers can be invoked when
+the handlers are registered with the proper phases.</p><p>Services are hot deployable in Axis2 and dynamic, but Modules. This is one
+feature, which is unique to Axis2.</p></div><div class="subsection"><a name="Transports_for_HTTP_Connection"></a><h3>Transports for HTTP Connection</h3><p>Axis2 comes with two  CommonsHTTPTransportSender which is based on
+commons-httpclient. The configuration of the transport is as follows,</p>
+    <div class="source"><pre>Options.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
+
+</pre></div>
+  <p>It should be noted that axis2.xml should be configured to call the commons
+transports, with the statement,</p>
+    <div class="source"><pre>...
+&lt;transportSender name="http" class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"&gt; 
+   &lt;parameter name="PROTOCOL" locked="false"&gt;HTTP/1.1&lt;/parameter&gt; 
+   &lt;parameter name="Transfer-Encoding" locked="false"&gt;chunked&lt;/parameter&gt;
+&lt;/transportSender&gt;
+...
+
+
+</pre></div>
+  </div><div class="subsection"><a name="Data_Binding_Support"></a><h3>Data Binding Support</h3><p>Xml-beans is used to provide data binding support. In Axis2, xml is
+manipulated via AXIOM, which is based on StAX API. XML give full schema
+support. Thus, serialization and de-serialization of Xml is handle in Axis2
+via xml-data binding framework.</p></div><div class="subsection"><a name="Best_Usage"></a><h3>Best Usage</h3><p>Axis1.x and Axis2 have different ways of seen the SOAP stack. So the best
+way to migrate can be done through following the User guide and Architecture
+guide properly in Axis2. Axis2 is straight forward and friendly.</p></div></div></div></div><div class="clear"><hr></hr></div><div id="footer"><div class="xright">© 2004-2006, Apache Software Foundation</div><div class="clear"><hr></hr></div></div></body></html>
\ No newline at end of file

Added: webservices/site/trunk/targets/axis2/0_94/mtom-guide.html
URL: http://svn.apache.org/viewcvs/webservices/site/trunk/targets/axis2/0_94/mtom-guide.html?rev=366133&view=auto
==============================================================================
--- webservices/site/trunk/targets/axis2/0_94/mtom-guide.html (added)
+++ webservices/site/trunk/targets/axis2/0_94/mtom-guide.html Thu Jan  5 01:17:47 2006
@@ -0,0 +1,381 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html><head><title>Axis 2.0 - Sending Binary data with SOAP</title><style type="text/css" media="all">
+          @import url("./style/maven-base.css");
+          
+			    @import url("./style/maven-theme.css");</style><link rel="stylesheet" href="./style/print.css" type="text/css" media="print"></link><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"></meta></head><body class="composite"><div id="banner"><a href="http://www.apache.org/" id="organizationLogo"><img alt="Apache Software Foundation" src="http://www.apache.org/images/asf-logo.gif"></img></a><a href="http://ws.apache.org/axis2/" id="projectLogo"><img alt="Apache Axis 2.0" src="http://ws.apache.org/axis2/images/axis.jpg"></img></a><div class="clear"><hr></hr></div></div><div id="breadcrumbs"><div class="xleft">
+                	Last published: 05 January 2006
+                  | Doc for 0.94</div><div class="xright"></div><div class="clear"><hr></hr></div></div><div id="leftColumn"><div id="navcolumn"><div id="menuAxis_2_0"><h5>Axis 2.0</h5><ul><li class="none"><a href="index.html">Home</a></li><li class="expanded"><a href="">Download Axis2</a><ul><li class="none"><a href="download.cgi">Releases</a></li><li class="none"><a href="http://svn.apache.org/viewcvs.cgi/webservices/axis2/trunk/?root=Apache-SVN" class="externalLink" title="External Link">Source Code</a></li></ul></li><li class="expanded"><a href="">Documentation</a><ul><li class="none"><a href="0_93/index.html">Version 0.93</a></li><li class="none"><a href="0_94/index.html">Version 0.94</a></li></ul></li><li class="expanded"><a href="overview.html">Get Involved</a><ul><li class="none"><a href="svn.html">Checkout the Source</a></li><li class="none"><a href="siteHowTo.html">Build the Site</a></li><li class="none"><a href="guidelines.html">Developer Guidelines</a></li><li cl
 ass="none"><a href="refLib.html">Reference Library</a></li><li class="none"><a href="mail-lists.html">Mailing Lists</a></li><li class="none"><a href="faq.html">FAQ</a></li></ul></li><li class="none"><a href="thanks.html">Ackknowledgements</a></li><li class="expanded"><a href="">Project Information</a><ul><li class="none"><a href="team-list.html">Project Team</a></li><li class="none"><a href="issue-tracking.html">Issue Tracking</a></li></ul></li></ul></div><a href="http://maven.apache.org/" title="Built by Maven" id="poweredBy"><img alt="Built by Maven" src="./images/logos/maven-button-1.png"></img></a></div></div><div id="bodyColumn"><div class="contentBox"><div class="section"><a name="Sending_Binary_Data_with_SOAP"></a><h2>Sending Binary Data with SOAP</h2><ul>
+  <li><a href="#1">Introduction</a></li>
+  <li><a href="#2">MTOM with Axis2 </a>
+    <ul>
+      <li><a href="#21">Programming Model</a></li>
+      <li><a href="#22">Enabling MTOM optimization at client side</a></li>
+      <li><a href="#23">Enabling MTOM optimization at server side</a></li>
+      <li><a href="#24">Accessing received Binary Data (Sample Code) </a>
+        <ul>
+          <li><a href="#241">Service</a></li>
+          <li><a href="#242">Client</a></li>
+        </ul>
+      </li>
+    </ul>
+  </li>
+  <li><a href="#3">SOAP with Attachments with Axis2</a></li>
+  <li><a href="#4">Advanced Topics </a>
+    <ul>
+      <li><a href="#41">File Caching for Attachments</a></li>
+    </ul>
+  </li>
+</ul><p><a name="1"></a></p><div class="subsection"><a name="Introduction"></a><h3>Introduction</h3><p>Despite the flexibility, interoperability and global acceptance of XML,
+there are times when serializing data into XML does not make sense. Web
+services users may need to transmit binary attachments of various sorts like
+images, drawings, xml docs, etc together with SOAP message. Such data are
+often in a particular binary format.<br></br>
+Traditionally, two techniques have been used in dealing with opaque data in
+XML;</p><ol>
+  <li><strong>"By value"</strong></li>
+
+  <blockquote>
+    <p>Sending binary data by value is achieved by embedding opaque data (of
+    course after some form of encoding) as element or attribute content of
+    the XML component of data. The main advantage of this technique is that
+    it gives applications the ability to process and describe data based and
+    looking only on XML component of the data.</p>
+
+    <p>XML supports opaque data as content through the use of either base64
+    or hexadecimal text encoding. Both these techniques bloat the size of the
+    data. For UTF-8 underlying text encoding, base64 encoding increases the
+    size of the binary data by a factor of 1.33x of the original size, while
+    hexadecimal encoding expands data by a factor of 2x. Above factors will
+    be doubled if UTF-16 text encoding is used. Also of concern is the
+    overhead in processing costs (both real and perceived) for these formats,
+    especially when decoding back into raw binary.</p>
+  </blockquote>
+  <li><strong>"By reference"</strong>
+
+    <blockquote>
+      <p>Sending binary data by reference is achieved by attaching pure
+      binary data as external unparsed general entities outside of the XML
+      document and then embedding  reference URI's to those entities as
+      elements or attribute values. This prevents the unnecessary bloating of
+      data and wasting of processing power. The primary obstacle for using
+      these unparsed entities is their heavy reliance on DTDs, which impedes
+      modularity as well as use of XML namespaces.</p>
+      <p>There were several specifications introduced in the Web services
+      world to deal with this binary attachment problem using the "by
+      reference" technique. <a href="http://www.w3.org/TR/SOAP-attachments" class="externalLink" title="External Link">SOAP with Attachments</a>
+      is one such example. Since SOAP prohibits document type declarations
+      (DTD) in messages, this leads to the  problem of not  representing data
+      as part of the message infoset, creating two data models. This scenario
+      is like sending attachments with an e-mail message. Even though those
+      attachments are related to the message content they are not inside the
+      message.  This causes the technologies for processing and description
+      of data based on XML component of the data, to malfunction. One example
+      is  WS-Security.</p>
+    </blockquote>
+  </li>
+</ol><p><a href="http://www.w3.org/TR/2004/PR-soap12-mtom-20041116/" class="externalLink" title="External Link">MTOM (SOAP
+Message Transmission Optimization Mechanism)</a> is another specification
+which focuses on solving the "Attachments" problem. MTOM tries to leverage
+the advantages of above two techniques by trying to merge the two techniques.
+MTOM is actually a "by reference" method. Wire format of a MTOM optimized
+message is same as the Soap with Attachments message, which also makes it
+backward compatible with SwA endpoints. The most notable feature of MTOM is
+the use of XOP:Include element, which is defined in <a href="http://www.w3.org/TR/2004/PR-xop10-20041116/" class="externalLink" title="External Link">XML Binary Optimized
+Packaging (XOP)</a> specification to reference  the binary attachments
+(external unparsed general entities) of the message. With the use of this
+exclusive element the attached binary content logically become inline (by
+value) with the SOAP document even though actually it is attached separately.
+This merges the two realms by making it possible to work only with one data
+model. This allows the applications to process and describe by only looking
+at XML part making reliance on DTDs obsolete. On a lighter note MTOM has
+standardized the referencing mechanism of SwA. Following is an extract from
+the <a href="http://www.w3.org/TR/2004/PR-xop10-20041116/" class="externalLink" title="External Link">XOP</a>
+specification.</p><p><em>At the conceptual level, this binary data can be thought of as being
+base64-encoded in the XML Document. As this conceptual form might be needed
+during some processing of the XML Document (e.g., for signing the XML
+document), it is necessary to have a one to one correspondence between XML
+Infosets and XOP Packages. Therefore, the conceptual representation of such
+binary data is as if it were base64-encoded, using the canonical lexical form
+of XML Schema base64Binary datatype (see <a href="#XMLSchemaP2">[XML Schema
+Part 2: Datatypes Second Edition] </a><a href="http://www.w3.org/TR/2004/REC-xmlschema-2-20041028/#base64Binary" class="externalLink" title="External Link">3.2.16
+base64Binary</a>). In the reverse direction, XOP is capable of optimizing
+only base64-encoded Infoset data that is in the canonical lexical
+form.</em></p><p>Apache Axis2 supports <strong>Base64 encoding</strong>, <strong>SOAP with
+Attachments</strong> &amp; <strong>MTOM (SOAP Message Transmission
+Optimization Mechanism).</strong></p><p><a name="2"></a></p></div></div><div class="section"><a name="MTOM_with_Axis2"></a><h2>MTOM with Axis2</h2><p><a name="21"></a></p><div class="subsection"><a name="Programming_Model"></a><h3>Programming Model</h3><p>AXIOM is (and may be the first) Object Model which has the ability to hold
+binary data. It has been given this ability by allowing OMText to hold raw
+binary content in the form of javax.activation.DataHandler. OMText has been
+chosen for this purpose with two reasons. One is that XOP (MTOM) is capable
+of optimizing only base64-encoded Infoset data that is in the canonical
+lexical form of XML Schema base64Binary datatype. Other one is to preserve
+the infoset in both sender and receiver (To store the binary content in the
+same kind of object regardless of whether it is optimized or not).</p><p>MTOM allows to selectively encode portions of the message, which allows us
+to send base64encoded data as well as externally attached raw binary data
+referenced by "XOP" element (optimized content) to be send in a SOAP message.
+User can specify whether an OMText node which contains raw binary data or
+base64encoded binary data is qualified to be optimized or not at the
+construction time of that node or later. To take the optimum efficiency of
+MTOM a user is advised to send smaller binary attachments using
+base64encoding (None optimized) and larger attachments as optimized
+content.</p>
+    <div class="source"><pre><pre>        OMElement imageElement = fac.createOMElement("image", omNs);
+
+        // Creating the Data Handler for the image.
+        // User has the option to use a FileDataSource or a ImageDataSource 
+        // in this scenario...
+        Image image;
+        image = new ImageIO()
+                .loadImage(new FileInputStream(inputImageFileName));
+        ImageDataSource dataSource = new ImageDataSource("test.jpg",image);
+        DataHandler dataHandler = new DataHandler(dataSource);
+
+        //create an OMText node with the above DataHandler and set optimized to true
+        OMText textData = fac.createText(dataHandler, true);
+        imageElement.addChild(textData);
+
+        //User can set optimized to false by using the following
+        //textData.doOptimize(false);</pre>
+</pre></div>
+  <p>Also a user can create an optimizable binary content node  using a base64
+encoded string, which contains encoded binary content, given with the mime
+type of the actual binary representation.</p>
+    <div class="source"><pre><pre>        String base64String = "some_string";
+        OMText binaryNode =  fac.createText(base64String,"image/jpg",true);</pre>
+</pre></div>
+  <p>Axis2 uses javax.activation.DataHandler to handle the binary data. All
+optimized binary content nodes will be serialized as Base64 Strings if "MTOM
+is not enabled". One can also create binary content nodes which will not be
+optimized at any case. They will be serialized and send as Base64 Strings.</p>
+    <div class="source"><pre><pre>        //create an OMText node with the above DataHandler and set "optimized" to false
+        //This data will be send as Base64 encoded string regardless of MTOM is enabled or not
+        javax.activation.DataHandler dataHandler = new javax.activation.DataHandler(new FileDataHandler("someLocation"));
+        OMText textData = fac.createText(dataHandler, false); 
+        image.addChild(textData);</pre>
+</pre></div>
+  <p></p><p><a name="22"></a></p></div><div class="subsection"><a name="Enabling_MTOM_optimization_at_client_side"></a><h3>Enabling MTOM optimization at client side</h3><p>Set the "enableMTOM" property in the call to true, when sending
+messages.</p>
+    <div class="source"><pre><pre>        Call call = new Call();
+        Options options = new Options();
+        options.setTo(targetEPR);
+        options.setProperty(Constants.Configuration.ENABLE_MTOM, Constants.VALUE_TRUE);
+        call.setClientOptions(options);</pre>
+</pre></div>
+  <p>When this property is set to true any SOAP envelope which contains
+optimizable content (OMText nodes containing binary content with optimizable
+flag "true") will be serialized as a MTOM optimized message. Messages will
+not be packaged as MTOM if they did not contain any optimizable content even
+though MTOM is enabled. But due considering the policy assertions, there may
+be a policy saying, all the request should be optimized eventhough there are
+any optimized contents. To support this phenomenon there is an entry called
+"forced mime" which has to be set as</p>
+    <div class="source"><pre><pre>        Call call = new Call();
+        Options options = new Options();
+        options.setTo(targetEPR);
+        options.setProperty(Constants.Configuration.FORCE_MIME, Constants.VALUE_TRUE);
+        call.setClientOptions(options);</pre>
+</pre></div>
+  <p></p><p>Axis2 serializes all binary content nodes as Base64 encoded strings
+regardless of they are qualified to be optimize or not, if,</p><ul>
+  <li>"enableMTOM" property is set to false.</li>
+  <li>If envelope contains any element information items of name xop:Include
+    (see <a href="#XOP">[XML-binary Optimized Packaging] </a><a href="http://www.w3.org/TR/2005/REC-xop10-20050125/#xop_infosets" class="externalLink" title="External Link">3. XOP
+    Infosets Constructs </a>).</li>
+</ul><p>MTOM is *always enabled* in Axis2 when it comes to receiving messages.
+Axis2 will automatically identify and de-serialize any MTOM message it
+receives.</p><p></p><p><a name="23"></a></p></div><div class="subsection"><a name="Enabling_MTOM_optimization_in_the_Server_side"></a><h3>Enabling MTOM optimization in the Server side</h3><p>Axis 2 server automatically identifies incoming MTOM optimized messages
+based on the content-type and de-serializes accordingly. User can enableMTOM
+in the server side for outgoing messages,</p><ul>
+  <li>Globally for all services
+
+    <blockquote>
+      <p>add and set the "enableMTOM" parameter to true in the Axis2.xml.
+      When it is set, *outgoing* messages *which contains optimizable
+      content* will be serialized and send as MTOM optimized messages. If it
+      is not set all the binary data in binary content nodes will be
+      serialized as Base64 encoded strings.</p>
+    </blockquote>
+  </li>
+</ul><p>
+    <div class="source"><pre></pre></div>
+  </p>
+    <div class="source"><pre>&lt;parameter name="enableMTOM" locked="false"&gt;true&lt;/parameter&gt;
+</pre></div>
+  <ul>
+  <ul>
+    <p>User must restart the server after setting this parameter.</p>
+  </ul>
+</ul><p><a name="24"></a></p></div><div class="subsection"><a name="Accessing_received_Binary_Data"></a><h3>Accessing received Binary Data</h3><ul>
+  <li><strong><a name="241"></a>Service</strong></li>
+</ul>
+    <div class="source"><pre><pre>public class MTOMService {
+    public OMElement mtomSample(OMElement element) throws Exception {
+        OMElement imageEle = element.getFirstElement();
+        OMElement imageName = (OMElement) imageEle.getNextSibling();
+        OMText binaryNode = (OMText) imageEle.getFirstChild();
+        String fileName = imageName.getText();
+
+        //Extracting the data and saving
+        DataHandler actualDH;
+        actualDH = binaryNode.getDataHandler();
+        Image actualObject = new ImageIO().loadImage(actualDH.getDataSource()
+                .getInputStream());
+        FileOutputStream imageOutStream = new FileOutputStream(fileName);
+        new JDK13IO().saveImage("image/jpeg", actualObject, imageOutStream);
+
+        //setting response
+        OMFactory fac = OMAbstractFactory.getOMFactory();
+        OMNamespace ns = fac.createOMNamespace("urn://fakenamespace", "ns");
+        OMElement ele = fac.createOMElement("response", ns);
+        ele.setText("Image Saved");
+        return ele;
+    }
+}</pre>
+</pre></div>
+  <ul>
+  <li><strong><a name="242"></a>Client</strong></li>
+</ul>
+    <div class="source"><pre><pre>        Options options = new Options();
+        options.setTo(targetEPR); 
+        // enabling MTOM
+        options.set(Constants.Configuration.ENABLE_MTOM, Constants.VALUE_TRUE);
+        options.setTransportInfo(Constants.TRANSPORT_HTTP,
+                Constants.TRANSPORT_HTTP, false);
+        options.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
+
+        OMElement result = (OMElement) call.invokeBlocking(operationName.
+                                getLocalPart(),payload);
+        OMElement ele = (OMElement) result.getFirstChild();
+        OMText binaryNode = (OMText) ele.getFirstChild();
+        
+        // Retrieving the DataHandler &amp; then do whatever the processing to the data
+        DataHandler actualDH;
+        actualDH = binaryNode.getDataHandler();
+        Image actualObject = new ImageIO().loadImage(actualDH.getDataSource()
+                .getInputStream());</pre>
+</pre></div>
+  <p><a name="3"></a></p></div></div><div class="section"><a name="SOAP_with_Attachments__SwA__with_Axis2"></a><h2>SOAP with Attachments (SwA) with Axis2</h2><p>Axis2 Handles SwA messages at the inflow only. When Axis2 receives a SwA
+message it extracts the binary attachment parts and puts a reference to those
+parts in the Message Context. Users can access binary attachments using the
+content-id. Care should be taken to rip off the "cid" prefix when content-id
+is taken from the "Href" attributes. When accessing the message context from
+a service users need to use the message context injection mechanism by
+introducing an "init" method to the service class.(see the following service
+example)</p><p>Note: Axis2 supports content-id referencing only. Axis2 does not support
+Content Location referencing of MIME parts.</p><ul>
+  <li><strong>Sample service which accepts a SwA message</strong></li>
+</ul>
+    <div class="source"><pre><pre>public class EchoSwA {
+    private MessageContext msgcts;
+
+    public void init(MessageContext msgcts) {
+        this.msgcts = msgcts;
+    }
+
+    public OMElement echoAttachment(OMElement omEle) {
+        OMElement child  = (OMElement)omEle.getFirstChild();
+        //retreiving the Href attribute which contains the Content Id 
+        OMAttribute attr = (OMAttribute)child.getFirstAttribute(new QName("href"));
+        String contentID = attr.getValue();
+        //content-id processing to remove the "cid" prefix
+        contentID = contentID.trim();
+        if (contentID.substring(0, 3).equalsIgnoreCase("cid")) {
+            contentID = contentID.substring(4);
+        }
+                
+        // Retrieving the MIMEHelper instance (which contains reference to attachments)
+        // from the Message Context
+        MIMEHelper attachments = (MIMEHelper)msgcts.getProperty(MIMEHelper.ATTACHMENTS);
+        // Retrieving the respective DataHandler referenced by the content-id
+        DataHandler dataHandler = attachments.getDataHandler(contentID);
+
+        // Echoing back the attachment. Sends out MTOM message
+        OMText textNode = new OMTextImpl(dataHandler);
+        omEle.build();
+        child.detach();
+        omEle.addChild(textNode);
+        return omEle;
+    }
+}</pre>
+</pre></div>
+  <p>MTOM specification is designed to be backward compatible with the SOAP
+with Attachments specification. Even though the representation is different,
+both technologies have the same wire format. We can safely assume that any
+SOAP with Attachments endpoint can accept a MTOM optimized messages and treat
+them as SOAP with Attachment messages - Any MTOM optimized message is a valid
+SwA message. Because of that Axis2 does not define a separate programming
+model or serialization for SwA. Users can use the MTOM programming model and
+serialization to send messages to SwA endpoints.</p><p>Note : Above is tested with Axis 1.x</p><ul>
+  <li><strong>A sample SwA message from Axis 1.x</strong></li>
+</ul>
+    <div class="source"><pre><pre>Content-Type: multipart/related; type="text/xml"; 
+          start="&lt;9D645C8EBB837CE54ABD027A3659535D&gt;";
+                boundary="----=_Part_0_1977511.1123163571138"
+
+------=_Part_0_1977511.1123163571138
+Content-Type: text/xml; charset=UTF-8
+Content-Transfer-Encoding: binary
+Content-Id: &lt;9D645C8EBB837CE54ABD027A3659535D&gt;
+
+&lt;?xml version="1.0" encoding="UTF-8"?&gt;
+&lt;soapenv:Envelope xmlns:soapenv="...."....&gt;
+    ........
+                &lt;source href="cid:3936AE19FBED55AE4620B81C73BDD76E" xmlns="/&gt;
+    ........
+&lt;/soapenv:Envelope&gt;
+------=_Part_0_1977511.1123163571138
+Content-Type: text/plain
+Content-Transfer-Encoding: binary
+Content-Id: &lt;3936AE19FBED55AE4620B81C73BDD76E&gt;
+
+<em>Binary Data.....</em>
+------=_Part_0_1977511.1123163571138--</pre>
+</pre></div>
+  <ul>
+  <li><strong>Corresponding MTOM message from Axis2</strong></li>
+</ul>
+    <div class="source"><pre><pre>Content-Type: multipart/related; boundary=MIMEBoundary4A7AE55984E7438034;
+                         type="application/xop+xml"; start="&lt;0.09BC7F4BE2E4D3EF1B@apache.org&gt;";
+                         start-info="text/xml; charset=utf-8"
+
+--MIMEBoundary4A7AE55984E7438034
+content-type: application/xop+xml; charset=utf-8; type="application/soap+xml;"
+content-transfer-encoding: binary
+content-id: &lt;0.09BC7F4BE2E4D3EF1B@apache.org&gt;
+
+&lt;?xml version='1.0' encoding='utf-8'?&gt;
+&lt;soapenv:Envelope xmlns:soapenv="...."....&gt;
+  ........
+         &lt;xop:Include href="cid:1.A91D6D2E3D7AC4D580@apache.org" 
+                        xmlns:xop="http://www.w3.org/2004/08/xop/include"&gt;
+         &lt;/xop:Include&gt;
+  ........
+&lt;/soapenv:Envelope&gt;
+--MIMEBoundary4A7AE55984E7438034
+content-type: application/octet-stream
+content-transfer-encoding: binary
+content-id: &lt;1.A91D6D2E3D7AC4D580@apache.org&gt;
+
+<em>Binary Data.....</em>
+--MIMEBoundary4A7AE55984E7438034--</pre>
+</pre></div>
+  <p><a name="4"></a></p></div><div class="section"><a name="Advanced_Topics"></a><h2>Advanced Topics</h2><p><a name="41"></a></p><div class="subsection"><a name="File_Caching_For_Attachments"></a><h3>File Caching For Attachments</h3><p>Axis2 comes handy with a file caching mechanism for incoming attachments,
+which gives Axis2 the ability to handle very large attachments without
+buffering them in memory at any time. Axis2 file caching streams the incoming
+MIME parts directly in to files, after reading the MIME part headers.</p><p>Also a user can specify a size threshold for the File caching. When this
+threshold value is specified, only the attachments whose size is bigger than
+the threshold value will get cached in files. Smaller attachments will remain
+in Memory.</p><p>NOTE : It is a must to specify a directory to temporary store the
+attachments. Also care should be taken to *clean that directory* from time to
+time.</p><p>The following parameters need to be set in Axis2.xml in order to enable
+file caching.</p>
+    <div class="source"><pre><pre><em>&lt;axisconfig name="AxisJava2.0"&gt;
+    &lt;!-- ================================================= --&gt;
+    &lt;!-- Parameters --&gt;
+    &lt;!-- ================================================= --&gt;</em>
+    &lt;parameter name="cacheAttachments" locked="xsd:false"&gt;true&lt;/parameter&gt;
+    &lt;parameter name="attachmentDIR" locked="xsd:false"&gt;<em>temp directory</em>&lt;/parameter&gt;
+    &lt;parameter name="sizeThreshold" locked="xsd:false"&gt;4000&lt;/parameter&gt;
+    .........
+    .........
+&lt;/axisconfig&gt;</pre>
+</pre></div>
+  </div></div></div></div><div class="clear"><hr></hr></div><div id="footer"><div class="xright">© 2004-2006, Apache Software Foundation</div><div class="clear"><hr></hr></div></div></body></html>
\ No newline at end of file