Added: synapse/site/3_0_2/userguide/samples/sample254.html URL: http://svn.apache.org/viewvc/synapse/site/3_0_2/userguide/samples/sample254.html?rev=1909775&view=auto ============================================================================== --- synapse/site/3_0_2/userguide/samples/sample254.html (added) +++ synapse/site/3_0_2/userguide/samples/sample254.html Fri May 12 16:09:34 2023 @@ -0,0 +1,227 @@ +<!DOCTYPE html> +<!-- + | Generated by Apache Maven Doxia Site Renderer 1.7.4 at 2023-05-04 + | Rendered using Apache Maven Fluido Skin 1.6 +--> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta name="Date-Revision-yyyymmdd" content="20230504" /> + <meta http-equiv="Content-Language" content="en" /> + <title>Apache Synapse – Apache Synapse - Sample 254</title> + <link rel="stylesheet" href="../../css/apache-maven-fluido-1.6.min.css" /> + <link rel="stylesheet" href="../../css/site.css" /> + <link rel="stylesheet" href="../../css/print.css" media="print" /> + <script type="text/javascript" src="../../js/apache-maven-fluido-1.6.min.js"></script> + </head> + <body class="topBarDisabled"> + <div class="container-fluid"> + <div id="banner"> + <div class="pull-left"><div id="bannerLeft"><h2>Apache Synapse</h2> +</div> +</div> + <div class="pull-right"></div> + <div class="clear"><hr/></div> + </div> + + <div id="breadcrumbs"> + <ul class="breadcrumb"> + <li id="publishDate">Last Published: 2023-05-04<span class="divider">|</span> +</li> + <li id="projectVersion">Version: 3.0.2</li> + </ul> + </div> + <div class="row-fluid"> + <div id="leftColumn" class="span2"> + <div class="well sidebar-nav"> +<ul class="nav nav-list"> + <li class="nav-header">Main Menu</li> + <li><a href="../../index.html" title="Home"><span class="none"></span>Home</a> </li> + <li><a href="../../download.html" title="Download"><span class="none"></span>Download</a> </li> + <li><a href="../../history.html" title="History"><span class="none"></span>History</a> </li> + <li><a href="http://www.apache.org/licenses/LICENSE-2.0" class="externalLink" title="License"><span class="none"></span>License</a> </li> + <li><a href="http://www.apache.org/foundation/thanks.html" class="externalLink" title="Thanks"><span class="none"></span>Thanks</a> </li> + <li><a href="http://www.apache.org/foundation/sponsorship.html" class="externalLink" title="Sponsorship"><span class="none"></span>Sponsorship</a> </li> + <li><a href="http://www.apache.org/security/" class="externalLink" title="Security"><span class="none"></span>Security</a> </li> + <li class="nav-header">Documentation</li> + <li><a href="../../userguide/installation.html" title="Installation Guide"><span class="none"></span>Installation Guide</a> </li> + <li><a href="../../userguide/quick_start.html" title="Quick Start Guide"><span class="none"></span>Quick Start Guide</a> </li> + <li><a href="../../userguide/samples/setup/index.html" title="Samples Setup Guide"><span class="none"></span>Samples Setup Guide</a> </li> + <li><a href="../../userguide/samples.html" title="Samples Catalog"><span class="none"></span>Samples Catalog</a> </li> + <li><a href="../../userguide/config.html" title="Configuration Language"><span class="none"></span>Configuration Language</a> </li> + <li><a href="../../userguide/mediators.html" title="Mediators Catalog"><span class="none"></span>Mediators Catalog</a> </li> + <li><a href="../../userguide/transports.html" title="Transports Catalog"><span class="none"></span>Transports Catalog</a> </li> + <li><a href="../../userguide/properties.html" title="Properties Catalog"><span class="none"></span>Properties Catalog</a> </li> + <li><a href="../../userguide/xpath.html" title="XPath functions and Variables"><span class="none"></span>XPath functions and Variables</a> </li> + <li><a href="../../userguide/extending.html" title="Extending Synapse"><span class="none"></span>Extending Synapse</a> </li> + <li><a href="../../userguide/template_library.html" title="Synapse Template Libraries"><span class="none"></span>Synapse Template Libraries</a> </li> + <li><a href="../../userguide/upgrading.html" title="Upgrading"><span class="none"></span>Upgrading</a> </li> + <li><a href="../../userguide/deployment.html" title="Deployment"><span class="none"></span>Deployment</a> </li> + <li><a href="../../apidocs/" title="Javadocs"><span class="none"></span>Javadocs</a> </li> + <li><a href="../../userguide/faq.html" title="FAQ"><span class="none"></span>FAQ</a> </li> + <li class="nav-header">Developer Resources</li> + <li><a href="../../dev/developer-guide.html" title="Developer Guide"><span class="none"></span>Developer Guide</a> </li> + <li><a href="../../dev/best-practices.html" title="Development Best Practices"><span class="none"></span>Development Best Practices</a> </li> + <li><a href="../../dev/release-process.html" title="Release Process"><span class="none"></span>Release Process</a> </li> + <li class="nav-header">Project Details</li> + <li><a href="../../project-info.html" title="Overview"><span class="none"></span>Overview</a> </li> + <li><a href="../../mail-lists.html" title="Mailing Lists"><span class="none"></span>Mailing Lists</a> </li> + <li><a href="../../source-repository.html" title="Source Repository"><span class="none"></span>Source Repository</a> </li> + <li><a href="../../issue-tracking.html" title="Issue Tracking"><span class="none"></span>Issue Tracking</a> </li> + <li><a href="../../dependency-management.html" title="Dependencies"><span class="none"></span>Dependencies</a> </li> + <li><a href="../../team-list.html" title="Project Team"><span class="none"></span>Project Team</a> </li> + </ul> + <hr /> + <div id="poweredBy"> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy"><img class="builtBy" alt="Built by Maven" src="../../images/logos/maven-feather.png" /></a> + </div> + </div> + </div> + <div id="bodyColumn" class="span10" > + + + <div class="section"> +<h2><a name="Sample_254:_Using_File_System_as_the_Transport_Medium_ReadingWriting_Files"></a>Sample 254: Using File System as the Transport Medium (Reading/Writing Files)</h2> + +<div class="xmlConf"><definitions xmlns="http://ws.apache.org/ns/synapse"> + + <proxy name="StockQuoteProxy" transports="vfs"> + <parameter name="transport.vfs.FileURI">file:///home/user/test/in</parameter> <!--CHANGE--> + <parameter name="transport.vfs.ContentType">text/xml</parameter> + <parameter name="transport.vfs.FileNamePattern">.*\.xml</parameter> + <parameter name="transport.PollInterval">15</parameter> + <parameter name="transport.vfs.MoveAfterProcess">file:///home/user/test/original</parameter> <!--CHANGE--> + <parameter name="transport.vfs.MoveAfterFailure">file:///home/user/test/original</parameter> <!--CHANGE--> + <parameter name="transport.vfs.ActionAfterProcess">MOVE</parameter> + <parameter name="transport.vfs.ActionAfterFailure">MOVE</parameter> + + <target> + <endpoint> + <address format="soap12" + uri="http://localhost:9000/services/SimpleStockQuoteService"/> + </endpoint> + <outSequence> + <property name="transport.vfs.ReplyFileName" + expression="fn:concat(fn:substring-after(get-property('MessageID'), 'urn:uuid:'), '.xml')" + scope="transport"/> + <property action="set" name="OUT_ONLY" value="true"/> + <send> + <endpoint> + <address uri="vfs:file:///home/user/test/out"/> <!--CHANGE--> + </endpoint> + </send> + </outSequence> + </target> + <publishWSDL uri="file:repository/conf/sample/resources/proxy/sample_proxy_1.wsdl"/> + </proxy> + +</definitions></div> + +<div class="section"> +<h3><a name="Objective"></a>Objective</h3> + +<p> + Synapse can access the local file system using its VFS (Virtual File System) + transport receiver and sender. This way Synapse can read files in the local file + system as well as write to the local file system. This sample show cases the + Synapse VFS transport in action. + </p> + </div> + +<div class="section"> +<h3><a name="Pre-requisites"></a>Pre-requisites</h3> + +<p> + </p> +<ul> + +<li> + Deploy the SimpleStockQuoteService in the sample Axis2 server and start Axis2 + </li> + +<li> + Create 3 new directories (folders) named 'in', 'out' and 'original' in a + suitable location in the local file system (eg: /home/user/test). + </li> + +<li> + Open the repository/conf/sample/synapse_sample_254.xml file in a text + editor and. Then change the transport.vfs.FileURI, transport.vfs.MoveAfterProcess, + transport.vfs.MoveAfterFailure parameter values to the above in, original + and original directories respectively. Note that both 2nd and 3rd parameters + are pointed to the 'original' directory. + </li> + +<li> + Change the endpoint in the out-sequence to point to the 'out' directory. + The prefix 'vfs' in the endpoint URL must not be removed or changed. + </li> + +<li> + Enable the VFS transport receiver and sender for Synapse (refer VFS + setup guide for more information) + </li> + +<li> + Start Synapse using the configuration numbered 254 (repository/conf/sample/synapse_sample_254.xml) + +<div class="command"> + Unix/Linux: sh synapse.sh -sample 254<br /> + Windows: synapse.bat -sample 254 + </div> + </li> + </ul> + + </div> + +<div class="section"> +<h3><a name="Executing_the_Client"></a>Executing the Client</h3> + +<p> + Copy the test.xml file in the repository/conf/sample/resources/vfs directory to + the directory given in transport.vfs.FileURI above (i.e the 'in' directory). This + file contains a simple stock quote request in XML/SOAP format. + </p> + +<div class="consoleOutput"><?xml version='1.0' encoding='UTF-8'?> + <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsa="http://www.w3.org/2005/08/addressing"> + <soapenv:Body> + <m0:getQuote xmlns:m0="http://services.samples"> + <m0:request> + <m0:symbol>IBM</m0:symbol> + </m0:request> + </m0:getQuote> + </soapenv:Body> +</soapenv:Envelope></div> + +<p> + VFS transport listener will pick the file from 'in' directory and send it to the + Axis2 service over HTTP. The request XML file will be backed up in the 'original' + directory. The response from the Axis2 server will be saved to the 'out' directory. + </p> + </div> + </div> + +<p><a href="../samples.html">Back to Catalog</a></p> + + + </div> + </div> + </div> + <hr/> + <footer> + <div class="container-fluid"> + <div class="row-fluid"> + <p>Copyright ©2005–2023 +<a href="http://www.apache.org/">Apache Software Foundation</a>. +All rights reserved.</p> + </div> + </div> + </footer> + </body> +</html>
Added: synapse/site/3_0_2/userguide/samples/sample255.html URL: http://svn.apache.org/viewvc/synapse/site/3_0_2/userguide/samples/sample255.html?rev=1909775&view=auto ============================================================================== --- synapse/site/3_0_2/userguide/samples/sample255.html (added) +++ synapse/site/3_0_2/userguide/samples/sample255.html Fri May 12 16:09:34 2023 @@ -0,0 +1,234 @@ +<!DOCTYPE html> +<!-- + | Generated by Apache Maven Doxia Site Renderer 1.7.4 at 2023-05-04 + | Rendered using Apache Maven Fluido Skin 1.6 +--> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta name="Date-Revision-yyyymmdd" content="20230504" /> + <meta http-equiv="Content-Language" content="en" /> + <title>Apache Synapse – Apache Synapse - Sample 255</title> + <link rel="stylesheet" href="../../css/apache-maven-fluido-1.6.min.css" /> + <link rel="stylesheet" href="../../css/site.css" /> + <link rel="stylesheet" href="../../css/print.css" media="print" /> + <script type="text/javascript" src="../../js/apache-maven-fluido-1.6.min.js"></script> + </head> + <body class="topBarDisabled"> + <div class="container-fluid"> + <div id="banner"> + <div class="pull-left"><div id="bannerLeft"><h2>Apache Synapse</h2> +</div> +</div> + <div class="pull-right"></div> + <div class="clear"><hr/></div> + </div> + + <div id="breadcrumbs"> + <ul class="breadcrumb"> + <li id="publishDate">Last Published: 2023-05-04<span class="divider">|</span> +</li> + <li id="projectVersion">Version: 3.0.2</li> + </ul> + </div> + <div class="row-fluid"> + <div id="leftColumn" class="span2"> + <div class="well sidebar-nav"> +<ul class="nav nav-list"> + <li class="nav-header">Main Menu</li> + <li><a href="../../index.html" title="Home"><span class="none"></span>Home</a> </li> + <li><a href="../../download.html" title="Download"><span class="none"></span>Download</a> </li> + <li><a href="../../history.html" title="History"><span class="none"></span>History</a> </li> + <li><a href="http://www.apache.org/licenses/LICENSE-2.0" class="externalLink" title="License"><span class="none"></span>License</a> </li> + <li><a href="http://www.apache.org/foundation/thanks.html" class="externalLink" title="Thanks"><span class="none"></span>Thanks</a> </li> + <li><a href="http://www.apache.org/foundation/sponsorship.html" class="externalLink" title="Sponsorship"><span class="none"></span>Sponsorship</a> </li> + <li><a href="http://www.apache.org/security/" class="externalLink" title="Security"><span class="none"></span>Security</a> </li> + <li class="nav-header">Documentation</li> + <li><a href="../../userguide/installation.html" title="Installation Guide"><span class="none"></span>Installation Guide</a> </li> + <li><a href="../../userguide/quick_start.html" title="Quick Start Guide"><span class="none"></span>Quick Start Guide</a> </li> + <li><a href="../../userguide/samples/setup/index.html" title="Samples Setup Guide"><span class="none"></span>Samples Setup Guide</a> </li> + <li><a href="../../userguide/samples.html" title="Samples Catalog"><span class="none"></span>Samples Catalog</a> </li> + <li><a href="../../userguide/config.html" title="Configuration Language"><span class="none"></span>Configuration Language</a> </li> + <li><a href="../../userguide/mediators.html" title="Mediators Catalog"><span class="none"></span>Mediators Catalog</a> </li> + <li><a href="../../userguide/transports.html" title="Transports Catalog"><span class="none"></span>Transports Catalog</a> </li> + <li><a href="../../userguide/properties.html" title="Properties Catalog"><span class="none"></span>Properties Catalog</a> </li> + <li><a href="../../userguide/xpath.html" title="XPath functions and Variables"><span class="none"></span>XPath functions and Variables</a> </li> + <li><a href="../../userguide/extending.html" title="Extending Synapse"><span class="none"></span>Extending Synapse</a> </li> + <li><a href="../../userguide/template_library.html" title="Synapse Template Libraries"><span class="none"></span>Synapse Template Libraries</a> </li> + <li><a href="../../userguide/upgrading.html" title="Upgrading"><span class="none"></span>Upgrading</a> </li> + <li><a href="../../userguide/deployment.html" title="Deployment"><span class="none"></span>Deployment</a> </li> + <li><a href="../../apidocs/" title="Javadocs"><span class="none"></span>Javadocs</a> </li> + <li><a href="../../userguide/faq.html" title="FAQ"><span class="none"></span>FAQ</a> </li> + <li class="nav-header">Developer Resources</li> + <li><a href="../../dev/developer-guide.html" title="Developer Guide"><span class="none"></span>Developer Guide</a> </li> + <li><a href="../../dev/best-practices.html" title="Development Best Practices"><span class="none"></span>Development Best Practices</a> </li> + <li><a href="../../dev/release-process.html" title="Release Process"><span class="none"></span>Release Process</a> </li> + <li class="nav-header">Project Details</li> + <li><a href="../../project-info.html" title="Overview"><span class="none"></span>Overview</a> </li> + <li><a href="../../mail-lists.html" title="Mailing Lists"><span class="none"></span>Mailing Lists</a> </li> + <li><a href="../../source-repository.html" title="Source Repository"><span class="none"></span>Source Repository</a> </li> + <li><a href="../../issue-tracking.html" title="Issue Tracking"><span class="none"></span>Issue Tracking</a> </li> + <li><a href="../../dependency-management.html" title="Dependencies"><span class="none"></span>Dependencies</a> </li> + <li><a href="../../team-list.html" title="Project Team"><span class="none"></span>Project Team</a> </li> + </ul> + <hr /> + <div id="poweredBy"> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy"><img class="builtBy" alt="Built by Maven" src="../../images/logos/maven-feather.png" /></a> + </div> + </div> + </div> + <div id="bodyColumn" class="span10" > + + + <div class="section"> +<h2><a name="Sample_255:_Switching_from_File_Transport_FTP_to_the_Mail_Transport"></a>Sample 255: Switching from File Transport (FTP) to the Mail Transport</h2> + +<div class="xmlConf"><definitions xmlns="http://ws.apache.org/ns/synapse"> + + <proxy name="StockQuoteProxy" transports="vfs"> + + <target> + <inSequence> + <header name="Action" value="urn:getQuote"/> + </inSequence> + <endpoint> + <address uri="http://localhost:9000/services/SimpleStockQuoteService"/> + </endpoint> + <outSequence> + <property action="set" name="OUT_ONLY" value="true"/> + <send> + <endpoint> + <address uri="mailto:user@host"/> <!--CHANGE--> + </endpoint> + </send> + </outSequence> + </target> + <publishWSDL uri="file:repository/conf/sample/resources/proxy/sample_proxy_1.wsdl"/> + + <parameter name="transport.vfs.FileURI">vfs:ftp://guest:guest@localhost/test?vfs.passive=true</parameter> <!--CHANGE--> + <parameter name="transport.vfs.ContentType">text/xml</parameter> + <parameter name="transport.vfs.FileNamePattern">.*\.xml</parameter> + <parameter name="transport.PollInterval">15</parameter> + </proxy> + +</definitions></div> + +<div class="section"> +<h3><a name="Objective"></a>Objective</h3> + +<p> + In <a href="sample254.html">sample 254</a> we looked at how the VFS transport + can be used to read files from the local file system. VFS transport can also be + used to read files from FTP, SFTP and CIFS sites. This sample illustrates how to + read from a remote FTP site and send the content to a remote client as an e-mail. + </p> + </div> + +<div class="section"> +<h3><a name="Pre-requisites"></a>Pre-requisites</h3> + +<p> + </p> +<ul> + +<div class="command">ant stockquote -Daddurl=http://localhost:9000/services/SimpleStockQuoteService -Dtrpurl=http://localhost:8280/</div> + + +<div class="consoleOutput">Sat Nov 18 21:01:23 IST 2006 SimpleStockQuoteService :: Generating quote for : IBM</div> + + +<div class="consoleOutput">Standard :: Stock price = $95.26454380258552</div> +<li> + This sample requires access to a FTP site and an e-mail account. + </li> + +<li> + Deploy the SimpleStockQuoteService in the sample Axis2 server and start Axis2 + </li> + +<li> + Enable the VFS transport listener for Synapse (refer VFS setup guide for + more details). + </li> + +<li> + Enable the mail transport sender for Synapse + (refer <a href="setup/mail.html#mailTransportSender"> Mail transport setup</a> + guide for more details). + </li> + +<li> + Create a new test directory in the FTP site. + </li> + +<li> + Open the repository/conf/sample/synapse_sample_255.xml and edit the + transport.vfs.FileURI parameter to point to the test directory in the FTP + server. Also change the endpoint in the out sequence to point to your + e-mail account. + </li> + +<li> + Start Synapse using the configuration numbered 255 (repository/conf/sample/synapse_sample_255.xml) + +<div class="command"> + Unix/Linux: sh synapse.sh -sample 255<br /> + Windows: synapse.bat -sample 255 + </div> + </li> + </ul> + + </div> + +<div class="section"> +<h3><a name="Executing_the_Client"></a>Executing the Client</h3> + +<p> + Copy the test.xml file in the repository/conf/sample/resources/vfs directory to + the directory given in transport.vfs.FileURI above (i.e the test directory in + FTP server). This file contains a simple stock quote request in XML/SOAP format. + </p> + +<div class="consoleOutput"><?xml version='1.0' encoding='UTF-8'?> +<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsa="http://www.w3.org/2005/08/addressing"> + <soapenv:Body> + <m0:getQuote xmlns:m0="http://services.samples"> + <m0:request> + <m0:symbol>IBM</m0:symbol> + </m0:request> + </m0:getQuote> + </soapenv:Body> +</soapenv:Envelope></div> + +<p> + VFS transport will pick up the file from the FTP site and send the content to + the stock quote service in Axis2 over HTTP. Response from Axis2 will be sent to + the mail endpoint as an e-mail. It should show up in the configured e-mail account + after a few seconds. + </p> + </div> + </div> + +<p><a href="../samples.html">Back to Catalog</a></p> + + + </div> + </div> + </div> + <hr/> + <footer> + <div class="container-fluid"> + <div class="row-fluid"> + <p>Copyright ©2005–2023 +<a href="http://www.apache.org/">Apache Software Foundation</a>. +All rights reserved.</p> + </div> + </div> + </footer> + </body> +</html> Added: synapse/site/3_0_2/userguide/samples/sample256.html URL: http://svn.apache.org/viewvc/synapse/site/3_0_2/userguide/samples/sample256.html?rev=1909775&view=auto ============================================================================== --- synapse/site/3_0_2/userguide/samples/sample256.html (added) +++ synapse/site/3_0_2/userguide/samples/sample256.html Fri May 12 16:09:34 2023 @@ -0,0 +1,231 @@ +<!DOCTYPE html> +<!-- + | Generated by Apache Maven Doxia Site Renderer 1.7.4 at 2023-05-04 + | Rendered using Apache Maven Fluido Skin 1.6 +--> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta name="Date-Revision-yyyymmdd" content="20230504" /> + <meta http-equiv="Content-Language" content="en" /> + <title>Apache Synapse – Apache Synapse - Sample 256</title> + <link rel="stylesheet" href="../../css/apache-maven-fluido-1.6.min.css" /> + <link rel="stylesheet" href="../../css/site.css" /> + <link rel="stylesheet" href="../../css/print.css" media="print" /> + <script type="text/javascript" src="../../js/apache-maven-fluido-1.6.min.js"></script> + </head> + <body class="topBarDisabled"> + <div class="container-fluid"> + <div id="banner"> + <div class="pull-left"><div id="bannerLeft"><h2>Apache Synapse</h2> +</div> +</div> + <div class="pull-right"></div> + <div class="clear"><hr/></div> + </div> + + <div id="breadcrumbs"> + <ul class="breadcrumb"> + <li id="publishDate">Last Published: 2023-05-04<span class="divider">|</span> +</li> + <li id="projectVersion">Version: 3.0.2</li> + </ul> + </div> + <div class="row-fluid"> + <div id="leftColumn" class="span2"> + <div class="well sidebar-nav"> +<ul class="nav nav-list"> + <li class="nav-header">Main Menu</li> + <li><a href="../../index.html" title="Home"><span class="none"></span>Home</a> </li> + <li><a href="../../download.html" title="Download"><span class="none"></span>Download</a> </li> + <li><a href="../../history.html" title="History"><span class="none"></span>History</a> </li> + <li><a href="http://www.apache.org/licenses/LICENSE-2.0" class="externalLink" title="License"><span class="none"></span>License</a> </li> + <li><a href="http://www.apache.org/foundation/thanks.html" class="externalLink" title="Thanks"><span class="none"></span>Thanks</a> </li> + <li><a href="http://www.apache.org/foundation/sponsorship.html" class="externalLink" title="Sponsorship"><span class="none"></span>Sponsorship</a> </li> + <li><a href="http://www.apache.org/security/" class="externalLink" title="Security"><span class="none"></span>Security</a> </li> + <li class="nav-header">Documentation</li> + <li><a href="../../userguide/installation.html" title="Installation Guide"><span class="none"></span>Installation Guide</a> </li> + <li><a href="../../userguide/quick_start.html" title="Quick Start Guide"><span class="none"></span>Quick Start Guide</a> </li> + <li><a href="../../userguide/samples/setup/index.html" title="Samples Setup Guide"><span class="none"></span>Samples Setup Guide</a> </li> + <li><a href="../../userguide/samples.html" title="Samples Catalog"><span class="none"></span>Samples Catalog</a> </li> + <li><a href="../../userguide/config.html" title="Configuration Language"><span class="none"></span>Configuration Language</a> </li> + <li><a href="../../userguide/mediators.html" title="Mediators Catalog"><span class="none"></span>Mediators Catalog</a> </li> + <li><a href="../../userguide/transports.html" title="Transports Catalog"><span class="none"></span>Transports Catalog</a> </li> + <li><a href="../../userguide/properties.html" title="Properties Catalog"><span class="none"></span>Properties Catalog</a> </li> + <li><a href="../../userguide/xpath.html" title="XPath functions and Variables"><span class="none"></span>XPath functions and Variables</a> </li> + <li><a href="../../userguide/extending.html" title="Extending Synapse"><span class="none"></span>Extending Synapse</a> </li> + <li><a href="../../userguide/template_library.html" title="Synapse Template Libraries"><span class="none"></span>Synapse Template Libraries</a> </li> + <li><a href="../../userguide/upgrading.html" title="Upgrading"><span class="none"></span>Upgrading</a> </li> + <li><a href="../../userguide/deployment.html" title="Deployment"><span class="none"></span>Deployment</a> </li> + <li><a href="../../apidocs/" title="Javadocs"><span class="none"></span>Javadocs</a> </li> + <li><a href="../../userguide/faq.html" title="FAQ"><span class="none"></span>FAQ</a> </li> + <li class="nav-header">Developer Resources</li> + <li><a href="../../dev/developer-guide.html" title="Developer Guide"><span class="none"></span>Developer Guide</a> </li> + <li><a href="../../dev/best-practices.html" title="Development Best Practices"><span class="none"></span>Development Best Practices</a> </li> + <li><a href="../../dev/release-process.html" title="Release Process"><span class="none"></span>Release Process</a> </li> + <li class="nav-header">Project Details</li> + <li><a href="../../project-info.html" title="Overview"><span class="none"></span>Overview</a> </li> + <li><a href="../../mail-lists.html" title="Mailing Lists"><span class="none"></span>Mailing Lists</a> </li> + <li><a href="../../source-repository.html" title="Source Repository"><span class="none"></span>Source Repository</a> </li> + <li><a href="../../issue-tracking.html" title="Issue Tracking"><span class="none"></span>Issue Tracking</a> </li> + <li><a href="../../dependency-management.html" title="Dependencies"><span class="none"></span>Dependencies</a> </li> + <li><a href="../../team-list.html" title="Project Team"><span class="none"></span>Project Team</a> </li> + </ul> + <hr /> + <div id="poweredBy"> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy"><img class="builtBy" alt="Built by Maven" src="../../images/logos/maven-feather.png" /></a> + </div> + </div> + </div> + <div id="bodyColumn" class="span10" > + + + <div class="section"> +<h2><a name="Sample_256:_Proxy_Services_with_the_Mail_Transport"></a>Sample 256: Proxy Services with the Mail Transport</h2> + +<div class="xmlConf"><definitions xmlns="http://ws.apache.org/ns/synapse"> + + <proxy name="StockQuoteProxy" transports="mailto"> + + <target> + <inSequence> + <property name="senderAddress" expression="get-property('transport', 'From')"/> + <log level="full"> + <property name="Sender Address" expression="get-property('senderAddress')"/> + </log> + <send> + <endpoint> + <address uri="http://localhost:9000/services/SimpleStockQuoteService"/> + </endpoint> + </send> + </inSequence> + <outSequence> + <property name="Subject" value="Custom Subject for Response" scope="transport"/> + <header name="To" expression="fn:concat('mailto:', get-property('senderAddress'))"/> + <log level="full"> + <property name="message" value="Response message"/> + <property name="Sender Address" expression="get-property('senderAddress')"/> + </log> + <send/> + </outSequence> + </target> + <publishWSDL uri="file:repository/conf/sample/resources/proxy/sample_proxy_1.wsdl"/> + + <parameter name="transport.mail.Address">synapse.demo.ma...@gmail.com</parameter> + <parameter name="transport.mail.Protocol">pop3</parameter> + <parameter name="transport.PollInterval">5</parameter> + <parameter name="mail.pop3.host">pop.gmail.com</parameter> + <parameter name="mail.pop3.port">995</parameter> + <parameter name="mail.pop3.user">synapse.demo.mail1</parameter> + <parameter name="mail.pop3.password">mailpassword</parameter> + <parameter name="mail.pop3.socketFactory.class">javax.net.ssl.SSLSocketFactory</parameter> + <parameter name="mail.pop3.socketFactory.fallback">false</parameter> + <parameter name="mail.pop3.socketFactory.port">995</parameter> + <parameter name="transport.mail.ContentType">application/xml</parameter> + + </proxy> + +</definitions></div> + +<div class="section"> +<h3><a name="Objective"></a>Objective</h3> + +<p> + This sample show cases the mail transport of Synapse. The mail transport allows + Synapse to receive and send e-mails using common protocols like POP, IMAP and + SMTP. + </p> + </div> + +<div class="section"> +<h3><a name="Pre-requisites"></a>Pre-requisites</h3> + +<p> + </p> +<ul> + +<li> + You need access to an e-mail account to try out this sample + </li> + +<li> + Deploy the SimpleStockQuoteService in the sample Axis2 server and start Axis2 + </li> + +<li> + Enable the mail transport listener and mail transport sender for Synapse + (refer <a href="setup/mail.html#mailTransportSender">Mail transport setup</a> + guide for more details) + </li> + +<li> + Start Synapse using the configuration numbered 256 (repository/conf/sample/synapse_sample_256.xml) + +<div class="command"> + Unix/Linux: sh synapse.sh -sample 256<br /> + Windows: synapse.bat -sample 256 + </div> + </li> + </ul> + + </div> + +<div class="section"> +<h3><a name="Executing_the_Client"></a>Executing the Client</h3> + +<p> + Send an e-mail to <a class="externalLink" href="mailto:synapse.demo.ma...@gmail.com">synapse.demo.ma...@gmail.com</a> + with the following payload. + </p> + +<div class="xmlConf"><getQuote xmlns="http://services.samples"> + <request> + <symbol>IBM</symbol> + </request> +</getQuote></div> + +<p> + Synapse will be polling on the above e-mail account for any incoming requests. When + your mail arrives at this account, Synapse will pick it up and send the payload to + Axis2 over HTTP. The response will be mailed back to your e-mail account. Synapse + retrieves the sender information from the original request to determine the recipient + of the response mail. + </p> + +<p> + Note that in this sample we used the transport.mail.ContentType property to make + sure that the transport parses the request message as POX. If you remove this + property, you may still be able to send requests using a standard mail client if + instead of writing the XML in the body of the message, you add it as an attachment. + In that case, you should use .xml as a suffix for the attachment and format the + request as a SOAP 1.1 message. Indeed, for a file with suffix .xml the mail client + will most likely use text/xml as the content type, exactly as required for SOAP 1.1. + Sending a POX message using this approach will be a lot trickier, because most + standard mail clients don't allow the user to explicitly set the content type. + </p> + </div> + </div> + +<p><a href="../samples.html">Back to Catalog</a></p> + + + </div> + </div> + </div> + <hr/> + <footer> + <div class="container-fluid"> + <div class="row-fluid"> + <p>Copyright ©2005–2023 +<a href="http://www.apache.org/">Apache Software Foundation</a>. +All rights reserved.</p> + </div> + </div> + </footer> + </body> +</html> Added: synapse/site/3_0_2/userguide/samples/sample257.html URL: http://svn.apache.org/viewvc/synapse/site/3_0_2/userguide/samples/sample257.html?rev=1909775&view=auto ============================================================================== --- synapse/site/3_0_2/userguide/samples/sample257.html (added) +++ synapse/site/3_0_2/userguide/samples/sample257.html Fri May 12 16:09:34 2023 @@ -0,0 +1,214 @@ +<!DOCTYPE html> +<!-- + | Generated by Apache Maven Doxia Site Renderer 1.7.4 at 2023-05-04 + | Rendered using Apache Maven Fluido Skin 1.6 +--> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta name="Date-Revision-yyyymmdd" content="20230504" /> + <meta http-equiv="Content-Language" content="en" /> + <title>Apache Synapse – Apache Synapse - Sample 257</title> + <link rel="stylesheet" href="../../css/apache-maven-fluido-1.6.min.css" /> + <link rel="stylesheet" href="../../css/site.css" /> + <link rel="stylesheet" href="../../css/print.css" media="print" /> + <script type="text/javascript" src="../../js/apache-maven-fluido-1.6.min.js"></script> + </head> + <body class="topBarDisabled"> + <div class="container-fluid"> + <div id="banner"> + <div class="pull-left"><div id="bannerLeft"><h2>Apache Synapse</h2> +</div> +</div> + <div class="pull-right"></div> + <div class="clear"><hr/></div> + </div> + + <div id="breadcrumbs"> + <ul class="breadcrumb"> + <li id="publishDate">Last Published: 2023-05-04<span class="divider">|</span> +</li> + <li id="projectVersion">Version: 3.0.2</li> + </ul> + </div> + <div class="row-fluid"> + <div id="leftColumn" class="span2"> + <div class="well sidebar-nav"> +<ul class="nav nav-list"> + <li class="nav-header">Main Menu</li> + <li><a href="../../index.html" title="Home"><span class="none"></span>Home</a> </li> + <li><a href="../../download.html" title="Download"><span class="none"></span>Download</a> </li> + <li><a href="../../history.html" title="History"><span class="none"></span>History</a> </li> + <li><a href="http://www.apache.org/licenses/LICENSE-2.0" class="externalLink" title="License"><span class="none"></span>License</a> </li> + <li><a href="http://www.apache.org/foundation/thanks.html" class="externalLink" title="Thanks"><span class="none"></span>Thanks</a> </li> + <li><a href="http://www.apache.org/foundation/sponsorship.html" class="externalLink" title="Sponsorship"><span class="none"></span>Sponsorship</a> </li> + <li><a href="http://www.apache.org/security/" class="externalLink" title="Security"><span class="none"></span>Security</a> </li> + <li class="nav-header">Documentation</li> + <li><a href="../../userguide/installation.html" title="Installation Guide"><span class="none"></span>Installation Guide</a> </li> + <li><a href="../../userguide/quick_start.html" title="Quick Start Guide"><span class="none"></span>Quick Start Guide</a> </li> + <li><a href="../../userguide/samples/setup/index.html" title="Samples Setup Guide"><span class="none"></span>Samples Setup Guide</a> </li> + <li><a href="../../userguide/samples.html" title="Samples Catalog"><span class="none"></span>Samples Catalog</a> </li> + <li><a href="../../userguide/config.html" title="Configuration Language"><span class="none"></span>Configuration Language</a> </li> + <li><a href="../../userguide/mediators.html" title="Mediators Catalog"><span class="none"></span>Mediators Catalog</a> </li> + <li><a href="../../userguide/transports.html" title="Transports Catalog"><span class="none"></span>Transports Catalog</a> </li> + <li><a href="../../userguide/properties.html" title="Properties Catalog"><span class="none"></span>Properties Catalog</a> </li> + <li><a href="../../userguide/xpath.html" title="XPath functions and Variables"><span class="none"></span>XPath functions and Variables</a> </li> + <li><a href="../../userguide/extending.html" title="Extending Synapse"><span class="none"></span>Extending Synapse</a> </li> + <li><a href="../../userguide/template_library.html" title="Synapse Template Libraries"><span class="none"></span>Synapse Template Libraries</a> </li> + <li><a href="../../userguide/upgrading.html" title="Upgrading"><span class="none"></span>Upgrading</a> </li> + <li><a href="../../userguide/deployment.html" title="Deployment"><span class="none"></span>Deployment</a> </li> + <li><a href="../../apidocs/" title="Javadocs"><span class="none"></span>Javadocs</a> </li> + <li><a href="../../userguide/faq.html" title="FAQ"><span class="none"></span>FAQ</a> </li> + <li class="nav-header">Developer Resources</li> + <li><a href="../../dev/developer-guide.html" title="Developer Guide"><span class="none"></span>Developer Guide</a> </li> + <li><a href="../../dev/best-practices.html" title="Development Best Practices"><span class="none"></span>Development Best Practices</a> </li> + <li><a href="../../dev/release-process.html" title="Release Process"><span class="none"></span>Release Process</a> </li> + <li class="nav-header">Project Details</li> + <li><a href="../../project-info.html" title="Overview"><span class="none"></span>Overview</a> </li> + <li><a href="../../mail-lists.html" title="Mailing Lists"><span class="none"></span>Mailing Lists</a> </li> + <li><a href="../../source-repository.html" title="Source Repository"><span class="none"></span>Source Repository</a> </li> + <li><a href="../../issue-tracking.html" title="Issue Tracking"><span class="none"></span>Issue Tracking</a> </li> + <li><a href="../../dependency-management.html" title="Dependencies"><span class="none"></span>Dependencies</a> </li> + <li><a href="../../team-list.html" title="Project Team"><span class="none"></span>Project Team</a> </li> + </ul> + <hr /> + <div id="poweredBy"> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy"><img class="builtBy" alt="Built by Maven" src="../../images/logos/maven-feather.png" /></a> + </div> + </div> + </div> + <div id="bodyColumn" class="span10" > + + + <div class="section"> +<h2><a name="Sample_257:_Proxy_Services_with_the_FIX_Transport"></a>Sample 257: Proxy Services with the FIX Transport</h2> + +<div class="xmlConf"><definitions xmlns="http://ws.apache.org/ns/synapse"> + + <proxy name="OrderProcesserProxy40" transports="fix"> + <target> + <endpoint> + <address + uri="fix://localhost:19876?BeginString=FIX.4.0&SenderCompID=SYNAPSE&TargetCompID=EXEC"/> + </endpoint> + <inSequence> + <log level="full"/> + </inSequence> + <outSequence> + <log level="full"/> + <send/> + </outSequence> + </target> + + <parameter name="transport.fix.AcceptorConfigURL"> + file:repository/conf/sample/resources/fix/fix-synapse.cfg + </parameter> + <parameter name="transport.fix.AcceptorMessageStore">file</parameter> + <parameter name="transport.fix.InitiatorConfigURL"> + file:repository/conf/sample/resources/fix/synapse-sender.cfg + </parameter> + <parameter name="transport.fix.InitiatorMessageStore">file</parameter> + </proxy> + +</definitions></div> + +<div class="section"> +<h3><a name="Objective"></a>Objective</h3> + +<p> + This sample demonstrates the FIX (Financial Information eXchange) transport of + Synapse. FIX transport allows Synapse to connect to remote FIX acceptors and + initiators and exchange finance data. + </p> + </div> + +<div class="section"> +<h3><a name="Pre-requisites"></a>Pre-requisites</h3> + +<p> + </p> +<ul> + +<li> + You need a <a class="externalLink" href="http://www.quickfixj.org">Quickfix/J</a> installation + to try out FIX samples. Please download and extract a Quickfix/J distribution + into your local machine. + </li> + +<li> + Configure the Executor sample FIX application (shipped with Quickfix/J) + to receive messages from Synapse and start it (refer + <a href="setup/fix.html#exec">FIX setup guide</a> for more details). + </li> + +<li> + Enable the FIX transport listener and sender for Synapse (refer + <a href="setup/fix.html#synapse">FIX setup guide</a> for details). + </li> + +<li> + Start Synapse using the configuration numbered 257 (repository/conf/sample/synapse_sample_257.xml) + +<div class="command"> + Unix/Linux: sh synapse.sh -sample 257<br /> + Windows: synapse.bat -sample 257 + </div> + If Executor is properly configured, Synapse should establish a FIX session + with the Executor upon startup. You should see some log entries confirming + the session logon event on Synapse console as well as Executor console. + </li> + +<li> + Configure Banzai sample FIX application (shipped with Quickfix/J) to send + messages to Synapse and start it (refer <a href="setup/fix.html#banzai">FIX setup guide</a> + for more details). If Banzai was properly configured, it should establish + a FIX session with Synapse upon startup. You should see some session + logon messages on Synapse console and Banzai console. + </li> + </ul> + + </div> + +<div class="section"> +<h3><a name="Executing_the_Client"></a>Executing the Client</h3> + +<p> + Send some FIX messages from Banzai to Synapse. Synapse will forward all requests + to Executor and get them processes. Responses from Executor will be routed back + to Banzai. + </p> + +<p> + Synapse converts all received FIX messages into SOAP format. You can view these + SOAP messages from the Synapse log. When SOAP messages are sent to FIX endpoints, + Synapse converts them back into valid FIX messages. While FIX messages are flowing + through the service bus, you can perform various transformations and content based + routing on the FIX messages using the existing mediators like XSLT, XQuery, Filter + and Switch. + </p> + </div> + </div> + +<p><a href="../samples.html">Back to Catalog</a></p> + + + </div> + </div> + </div> + <hr/> + <footer> + <div class="container-fluid"> + <div class="row-fluid"> + <p>Copyright ©2005–2023 +<a href="http://www.apache.org/">Apache Software Foundation</a>. +All rights reserved.</p> + </div> + </div> + </footer> + </body> +</html> Added: synapse/site/3_0_2/userguide/samples/sample258.html URL: http://svn.apache.org/viewvc/synapse/site/3_0_2/userguide/samples/sample258.html?rev=1909775&view=auto ============================================================================== --- synapse/site/3_0_2/userguide/samples/sample258.html (added) +++ synapse/site/3_0_2/userguide/samples/sample258.html Fri May 12 16:09:34 2023 @@ -0,0 +1,204 @@ +<!DOCTYPE html> +<!-- + | Generated by Apache Maven Doxia Site Renderer 1.7.4 at 2023-05-04 + | Rendered using Apache Maven Fluido Skin 1.6 +--> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta name="Date-Revision-yyyymmdd" content="20230504" /> + <meta http-equiv="Content-Language" content="en" /> + <title>Apache Synapse – Apache Synapse - Sample 258</title> + <link rel="stylesheet" href="../../css/apache-maven-fluido-1.6.min.css" /> + <link rel="stylesheet" href="../../css/site.css" /> + <link rel="stylesheet" href="../../css/print.css" media="print" /> + <script type="text/javascript" src="../../js/apache-maven-fluido-1.6.min.js"></script> + </head> + <body class="topBarDisabled"> + <div class="container-fluid"> + <div id="banner"> + <div class="pull-left"><div id="bannerLeft"><h2>Apache Synapse</h2> +</div> +</div> + <div class="pull-right"></div> + <div class="clear"><hr/></div> + </div> + + <div id="breadcrumbs"> + <ul class="breadcrumb"> + <li id="publishDate">Last Published: 2023-05-04<span class="divider">|</span> +</li> + <li id="projectVersion">Version: 3.0.2</li> + </ul> + </div> + <div class="row-fluid"> + <div id="leftColumn" class="span2"> + <div class="well sidebar-nav"> +<ul class="nav nav-list"> + <li class="nav-header">Main Menu</li> + <li><a href="../../index.html" title="Home"><span class="none"></span>Home</a> </li> + <li><a href="../../download.html" title="Download"><span class="none"></span>Download</a> </li> + <li><a href="../../history.html" title="History"><span class="none"></span>History</a> </li> + <li><a href="http://www.apache.org/licenses/LICENSE-2.0" class="externalLink" title="License"><span class="none"></span>License</a> </li> + <li><a href="http://www.apache.org/foundation/thanks.html" class="externalLink" title="Thanks"><span class="none"></span>Thanks</a> </li> + <li><a href="http://www.apache.org/foundation/sponsorship.html" class="externalLink" title="Sponsorship"><span class="none"></span>Sponsorship</a> </li> + <li><a href="http://www.apache.org/security/" class="externalLink" title="Security"><span class="none"></span>Security</a> </li> + <li class="nav-header">Documentation</li> + <li><a href="../../userguide/installation.html" title="Installation Guide"><span class="none"></span>Installation Guide</a> </li> + <li><a href="../../userguide/quick_start.html" title="Quick Start Guide"><span class="none"></span>Quick Start Guide</a> </li> + <li><a href="../../userguide/samples/setup/index.html" title="Samples Setup Guide"><span class="none"></span>Samples Setup Guide</a> </li> + <li><a href="../../userguide/samples.html" title="Samples Catalog"><span class="none"></span>Samples Catalog</a> </li> + <li><a href="../../userguide/config.html" title="Configuration Language"><span class="none"></span>Configuration Language</a> </li> + <li><a href="../../userguide/mediators.html" title="Mediators Catalog"><span class="none"></span>Mediators Catalog</a> </li> + <li><a href="../../userguide/transports.html" title="Transports Catalog"><span class="none"></span>Transports Catalog</a> </li> + <li><a href="../../userguide/properties.html" title="Properties Catalog"><span class="none"></span>Properties Catalog</a> </li> + <li><a href="../../userguide/xpath.html" title="XPath functions and Variables"><span class="none"></span>XPath functions and Variables</a> </li> + <li><a href="../../userguide/extending.html" title="Extending Synapse"><span class="none"></span>Extending Synapse</a> </li> + <li><a href="../../userguide/template_library.html" title="Synapse Template Libraries"><span class="none"></span>Synapse Template Libraries</a> </li> + <li><a href="../../userguide/upgrading.html" title="Upgrading"><span class="none"></span>Upgrading</a> </li> + <li><a href="../../userguide/deployment.html" title="Deployment"><span class="none"></span>Deployment</a> </li> + <li><a href="../../apidocs/" title="Javadocs"><span class="none"></span>Javadocs</a> </li> + <li><a href="../../userguide/faq.html" title="FAQ"><span class="none"></span>FAQ</a> </li> + <li class="nav-header">Developer Resources</li> + <li><a href="../../dev/developer-guide.html" title="Developer Guide"><span class="none"></span>Developer Guide</a> </li> + <li><a href="../../dev/best-practices.html" title="Development Best Practices"><span class="none"></span>Development Best Practices</a> </li> + <li><a href="../../dev/release-process.html" title="Release Process"><span class="none"></span>Release Process</a> </li> + <li class="nav-header">Project Details</li> + <li><a href="../../project-info.html" title="Overview"><span class="none"></span>Overview</a> </li> + <li><a href="../../mail-lists.html" title="Mailing Lists"><span class="none"></span>Mailing Lists</a> </li> + <li><a href="../../source-repository.html" title="Source Repository"><span class="none"></span>Source Repository</a> </li> + <li><a href="../../issue-tracking.html" title="Issue Tracking"><span class="none"></span>Issue Tracking</a> </li> + <li><a href="../../dependency-management.html" title="Dependencies"><span class="none"></span>Dependencies</a> </li> + <li><a href="../../team-list.html" title="Project Team"><span class="none"></span>Project Team</a> </li> + </ul> + <hr /> + <div id="poweredBy"> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy"><img class="builtBy" alt="Built by Maven" src="../../images/logos/maven-feather.png" /></a> + </div> + </div> + </div> + <div id="bodyColumn" class="span10" > + + + <div class="section"> +<h2><a name="Sample_258:_Switching_from_HTTP_to_FIX"></a>Sample 258: Switching from HTTP to FIX</h2> + +<div class="xmlConf"><definitions xmlns="http://ws.apache.org/ns/synapse"> + + <proxy name="FIXProxy" transports="http"> + <target> + <endpoint> + <address + uri="fix://localhost:19876?BeginString=FIX.4.0&SenderCompID=SYNAPSE&TargetCompID=EXEC"/> + </endpoint> + + <inSequence> + <property name="transport.fix.ServiceName" value="FIXProxy" scope="axis2-client"/> + <log level="full"/> + </inSequence> + + <outSequence> + <log level="full"/> + <send/> + </outSequence> + </target> + + <parameter name="transport.fix.InitiatorConfigURL"> + file:repository/conf/sample/resources/fix/synapse-sender.cfg + </parameter> + <parameter name="transport.fix.InitiatorMessageStore">file</parameter> + <parameter name="transport.fix.SendAllToInSequence">false</parameter> + <parameter name="transport.fix.DropExtraResponses">true</parameter> + </proxy> + +</definitions></div> + +<div class="section"> +<h3><a name="Objective"></a>Objective</h3> + +<p> + Demonstrates how to use the FIX transport in a transport switching scenario with + HTTP. + </p> + </div> + +<div class="section"> +<h3><a name="Pre-requisites"></a>Pre-requisites</h3> + +<p> + </p> +<ul> + +<li> + You need a <a class="externalLink" href="http://www.quickfixj.org">Quickfix/J</a> installation + to try out FIX samples. Please download and extract a Quickfix/J distribution + into your local machine. + </li> + +<li> + Configure the Executor sample FIX application (shipped with Quickfix/J) + to receive messages from Synapse and start it (refer + <a href="setup/fix.html#exec">FIX setup guide</a> for more details). + </li> + +<li> + Enable the FIX transport sender for Synapse (refer + <a href="setup/fix.html#synapse">FIX setup guide</a> for details). + </li> + +<li> + Start Synapse using the configuration numbered 258 (repository/conf/sample/synapse_sample_258.xml) + +<div class="command"> + Unix/Linux: sh synapse.sh -sample 258<br /> + Windows: synapse.bat -sample 258 + </div> + </li> + </ul> + + </div> + +<div class="section"> +<h3><a name="Executing_the_Client"></a>Executing the Client</h3> + +<p> + Go to the samples/axis2Client directory and invoke the sample FIX/HTTP client as + follows. + </p> + +<div class="command">ant fixclient -Dsymbol=IBM -Dqty=5 -Dmode=buy -Daddurl=http://localhost:8280/services/FIXProxy</div> + +<p> + This command sends a HTTP request to the FIXProxy on Synapse. The message is + converted into a FIX message and sent to the Executor sample application. Executor + will send two responses for this request (receive ack and the execution report) and + Synapse will send the first response back to the HTTP client. (Synapse can't send + both responses back, since HTTP does not allow sending two responses to the same + request) + </p> + </div> + </div> + +<p><a href="../samples.html">Back to Catalog</a></p> + + + </div> + </div> + </div> + <hr/> + <footer> + <div class="container-fluid"> + <div class="row-fluid"> + <p>Copyright ©2005–2023 +<a href="http://www.apache.org/">Apache Software Foundation</a>. +All rights reserved.</p> + </div> + </div> + </footer> + </body> +</html> Added: synapse/site/3_0_2/userguide/samples/sample259.html URL: http://svn.apache.org/viewvc/synapse/site/3_0_2/userguide/samples/sample259.html?rev=1909775&view=auto ============================================================================== --- synapse/site/3_0_2/userguide/samples/sample259.html (added) +++ synapse/site/3_0_2/userguide/samples/sample259.html Fri May 12 16:09:34 2023 @@ -0,0 +1,210 @@ +<!DOCTYPE html> +<!-- + | Generated by Apache Maven Doxia Site Renderer 1.7.4 at 2023-05-04 + | Rendered using Apache Maven Fluido Skin 1.6 +--> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta name="Date-Revision-yyyymmdd" content="20230504" /> + <meta http-equiv="Content-Language" content="en" /> + <title>Apache Synapse – Apache Synapse - Sample 259</title> + <link rel="stylesheet" href="../../css/apache-maven-fluido-1.6.min.css" /> + <link rel="stylesheet" href="../../css/site.css" /> + <link rel="stylesheet" href="../../css/print.css" media="print" /> + <script type="text/javascript" src="../../js/apache-maven-fluido-1.6.min.js"></script> + </head> + <body class="topBarDisabled"> + <div class="container-fluid"> + <div id="banner"> + <div class="pull-left"><div id="bannerLeft"><h2>Apache Synapse</h2> +</div> +</div> + <div class="pull-right"></div> + <div class="clear"><hr/></div> + </div> + + <div id="breadcrumbs"> + <ul class="breadcrumb"> + <li id="publishDate">Last Published: 2023-05-04<span class="divider">|</span> +</li> + <li id="projectVersion">Version: 3.0.2</li> + </ul> + </div> + <div class="row-fluid"> + <div id="leftColumn" class="span2"> + <div class="well sidebar-nav"> +<ul class="nav nav-list"> + <li class="nav-header">Main Menu</li> + <li><a href="../../index.html" title="Home"><span class="none"></span>Home</a> </li> + <li><a href="../../download.html" title="Download"><span class="none"></span>Download</a> </li> + <li><a href="../../history.html" title="History"><span class="none"></span>History</a> </li> + <li><a href="http://www.apache.org/licenses/LICENSE-2.0" class="externalLink" title="License"><span class="none"></span>License</a> </li> + <li><a href="http://www.apache.org/foundation/thanks.html" class="externalLink" title="Thanks"><span class="none"></span>Thanks</a> </li> + <li><a href="http://www.apache.org/foundation/sponsorship.html" class="externalLink" title="Sponsorship"><span class="none"></span>Sponsorship</a> </li> + <li><a href="http://www.apache.org/security/" class="externalLink" title="Security"><span class="none"></span>Security</a> </li> + <li class="nav-header">Documentation</li> + <li><a href="../../userguide/installation.html" title="Installation Guide"><span class="none"></span>Installation Guide</a> </li> + <li><a href="../../userguide/quick_start.html" title="Quick Start Guide"><span class="none"></span>Quick Start Guide</a> </li> + <li><a href="../../userguide/samples/setup/index.html" title="Samples Setup Guide"><span class="none"></span>Samples Setup Guide</a> </li> + <li><a href="../../userguide/samples.html" title="Samples Catalog"><span class="none"></span>Samples Catalog</a> </li> + <li><a href="../../userguide/config.html" title="Configuration Language"><span class="none"></span>Configuration Language</a> </li> + <li><a href="../../userguide/mediators.html" title="Mediators Catalog"><span class="none"></span>Mediators Catalog</a> </li> + <li><a href="../../userguide/transports.html" title="Transports Catalog"><span class="none"></span>Transports Catalog</a> </li> + <li><a href="../../userguide/properties.html" title="Properties Catalog"><span class="none"></span>Properties Catalog</a> </li> + <li><a href="../../userguide/xpath.html" title="XPath functions and Variables"><span class="none"></span>XPath functions and Variables</a> </li> + <li><a href="../../userguide/extending.html" title="Extending Synapse"><span class="none"></span>Extending Synapse</a> </li> + <li><a href="../../userguide/template_library.html" title="Synapse Template Libraries"><span class="none"></span>Synapse Template Libraries</a> </li> + <li><a href="../../userguide/upgrading.html" title="Upgrading"><span class="none"></span>Upgrading</a> </li> + <li><a href="../../userguide/deployment.html" title="Deployment"><span class="none"></span>Deployment</a> </li> + <li><a href="../../apidocs/" title="Javadocs"><span class="none"></span>Javadocs</a> </li> + <li><a href="../../userguide/faq.html" title="FAQ"><span class="none"></span>FAQ</a> </li> + <li class="nav-header">Developer Resources</li> + <li><a href="../../dev/developer-guide.html" title="Developer Guide"><span class="none"></span>Developer Guide</a> </li> + <li><a href="../../dev/best-practices.html" title="Development Best Practices"><span class="none"></span>Development Best Practices</a> </li> + <li><a href="../../dev/release-process.html" title="Release Process"><span class="none"></span>Release Process</a> </li> + <li class="nav-header">Project Details</li> + <li><a href="../../project-info.html" title="Overview"><span class="none"></span>Overview</a> </li> + <li><a href="../../mail-lists.html" title="Mailing Lists"><span class="none"></span>Mailing Lists</a> </li> + <li><a href="../../source-repository.html" title="Source Repository"><span class="none"></span>Source Repository</a> </li> + <li><a href="../../issue-tracking.html" title="Issue Tracking"><span class="none"></span>Issue Tracking</a> </li> + <li><a href="../../dependency-management.html" title="Dependencies"><span class="none"></span>Dependencies</a> </li> + <li><a href="../../team-list.html" title="Project Team"><span class="none"></span>Project Team</a> </li> + </ul> + <hr /> + <div id="poweredBy"> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy"><img class="builtBy" alt="Built by Maven" src="../../images/logos/maven-feather.png" /></a> + </div> + </div> + </div> + <div id="bodyColumn" class="span10" > + + + <div class="section"> +<h2><a name="Sample_259:_Switch_from_FIX_to_HTTP"></a>Sample 259: Switch from FIX to HTTP</h2> + +<div class="xmlConf"><definitions xmlns="http://ws.apache.org/ns/synapse"> + + <localEntry key="xslt-key-req" + src="file:repository/conf/sample/resources/transform/transform_fix_to_http.xslt"/> + + <proxy name="FIXProxy" transports="fix"> + <target> + <endpoint> + <address uri="http://localhost:9000/services/SimpleStockQuoteService"/> + </endpoint> + <inSequence> + <log level="full"/> + <xslt key="xslt-key-req"/> + <log level="full"/> + </inSequence> + <outSequence> + <log level="full"/> + </outSequence> + </target> + <parameter name="transport.fix.AcceptorConfigURL"> + file:repository/conf/sample/resources/fix/fix-synapse.cfg + </parameter> + <parameter name="transport.fix.AcceptorMessageStore">file</parameter> + </proxy> + +</definitions></div> + +<div class="section"> +<h3><a name="Objective"></a>Objective</h3> + +<p> + In <a href="sample258.html">sample 258</a> we looked at how to forward HTTP + requests over a FIX session. This sample demonstrates how to send a FIX message + to an HTTP endpoint. + </p> + </div> + +<div class="section"> +<h3><a name="Pre-requisites"></a>Pre-requisites</h3> + +<p> + </p> +<ul> + +<li> + You need a <a class="externalLink" href="http://www.quickfixj.org">Quickfix/J</a> installation + to try out FIX samples. Please download and extract a Quickfix/J distribution + into your local machine. + </li> + +<li> + Deploy the SimpleStockQuoteService in the sample Axis2 server and start Axis2 + </li> + +<li> + Enable the FIX transport receiver for Synapse (refer + <a href="setup/fix.html#synapse">FIX setup guide</a> for details) + </li> + +<li> + Start Synapse using the configuration numbered 259 (repository/conf/sample/synapse_sample_259.xml) + +<div class="command"> + Unix/Linux: sh synapse.sh -sample 259<br /> + Windows: synapse.bat -sample 259 + </div> + </li> + +<li> + Configure Banzai sample FIX application (shipped with Quickfix/J) to send + messages to Synapse and start it (refer <a href="setup/fix.html#banzai">FIX setup guide</a> + for more details). If Banzai was properly configured, it should establish + a FIX session with Synapse upon startup. You should see some session logon + messages on Synapse console and Banzai console. + </li> + </ul> + + </div> + +<div class="section"> +<h3><a name="Executing_the_Client"></a>Executing the Client</h3> + +<p> + This sample expects a Limit order from Banzai to be received by Synapse and + transformed into a place order request in SOAP format. To try it out send a + 'Limit' order request from Banzai to Synapse. Synapse will convert it into a + place order request and send to the Axis2 server over HTTP. The stock quote + service in Axis2 will print the following log when it receives the in-only + place order request. + </p> + +<div class="consoleOutput">Accepted order for : 18406 stocks of MSFT at $ 83.58806051152119</div> + +<p> + Note that the request sent from Banzai must be of type 'Limit'. Otherwise the + XSLT transformation will not work as expected and Axis2 will receive an invalid + request. Also since the place order requests are one-way messages, Banzai is not + supposed to receive any response in this case. + </p> + </div> + </div> + +<p><a href="../samples.html">Back to Catalog</a></p> + + + </div> + </div> + </div> + <hr/> + <footer> + <div class="container-fluid"> + <div class="row-fluid"> + <p>Copyright ©2005–2023 +<a href="http://www.apache.org/">Apache Software Foundation</a>. +All rights reserved.</p> + </div> + </div> + </footer> + </body> +</html> Added: synapse/site/3_0_2/userguide/samples/sample260.html URL: http://svn.apache.org/viewvc/synapse/site/3_0_2/userguide/samples/sample260.html?rev=1909775&view=auto ============================================================================== --- synapse/site/3_0_2/userguide/samples/sample260.html (added) +++ synapse/site/3_0_2/userguide/samples/sample260.html Fri May 12 16:09:34 2023 @@ -0,0 +1,191 @@ +<!DOCTYPE html> +<!-- + | Generated by Apache Maven Doxia Site Renderer 1.7.4 at 2023-05-04 + | Rendered using Apache Maven Fluido Skin 1.6 +--> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta name="Date-Revision-yyyymmdd" content="20230504" /> + <meta http-equiv="Content-Language" content="en" /> + <title>Apache Synapse – Apache Synapse - Sample 260</title> + <link rel="stylesheet" href="../../css/apache-maven-fluido-1.6.min.css" /> + <link rel="stylesheet" href="../../css/site.css" /> + <link rel="stylesheet" href="../../css/print.css" media="print" /> + <script type="text/javascript" src="../../js/apache-maven-fluido-1.6.min.js"></script> + </head> + <body class="topBarDisabled"> + <div class="container-fluid"> + <div id="banner"> + <div class="pull-left"><div id="bannerLeft"><h2>Apache Synapse</h2> +</div> +</div> + <div class="pull-right"></div> + <div class="clear"><hr/></div> + </div> + + <div id="breadcrumbs"> + <ul class="breadcrumb"> + <li id="publishDate">Last Published: 2023-05-04<span class="divider">|</span> +</li> + <li id="projectVersion">Version: 3.0.2</li> + </ul> + </div> + <div class="row-fluid"> + <div id="leftColumn" class="span2"> + <div class="well sidebar-nav"> +<ul class="nav nav-list"> + <li class="nav-header">Main Menu</li> + <li><a href="../../index.html" title="Home"><span class="none"></span>Home</a> </li> + <li><a href="../../download.html" title="Download"><span class="none"></span>Download</a> </li> + <li><a href="../../history.html" title="History"><span class="none"></span>History</a> </li> + <li><a href="http://www.apache.org/licenses/LICENSE-2.0" class="externalLink" title="License"><span class="none"></span>License</a> </li> + <li><a href="http://www.apache.org/foundation/thanks.html" class="externalLink" title="Thanks"><span class="none"></span>Thanks</a> </li> + <li><a href="http://www.apache.org/foundation/sponsorship.html" class="externalLink" title="Sponsorship"><span class="none"></span>Sponsorship</a> </li> + <li><a href="http://www.apache.org/security/" class="externalLink" title="Security"><span class="none"></span>Security</a> </li> + <li class="nav-header">Documentation</li> + <li><a href="../../userguide/installation.html" title="Installation Guide"><span class="none"></span>Installation Guide</a> </li> + <li><a href="../../userguide/quick_start.html" title="Quick Start Guide"><span class="none"></span>Quick Start Guide</a> </li> + <li><a href="../../userguide/samples/setup/index.html" title="Samples Setup Guide"><span class="none"></span>Samples Setup Guide</a> </li> + <li><a href="../../userguide/samples.html" title="Samples Catalog"><span class="none"></span>Samples Catalog</a> </li> + <li><a href="../../userguide/config.html" title="Configuration Language"><span class="none"></span>Configuration Language</a> </li> + <li><a href="../../userguide/mediators.html" title="Mediators Catalog"><span class="none"></span>Mediators Catalog</a> </li> + <li><a href="../../userguide/transports.html" title="Transports Catalog"><span class="none"></span>Transports Catalog</a> </li> + <li><a href="../../userguide/properties.html" title="Properties Catalog"><span class="none"></span>Properties Catalog</a> </li> + <li><a href="../../userguide/xpath.html" title="XPath functions and Variables"><span class="none"></span>XPath functions and Variables</a> </li> + <li><a href="../../userguide/extending.html" title="Extending Synapse"><span class="none"></span>Extending Synapse</a> </li> + <li><a href="../../userguide/template_library.html" title="Synapse Template Libraries"><span class="none"></span>Synapse Template Libraries</a> </li> + <li><a href="../../userguide/upgrading.html" title="Upgrading"><span class="none"></span>Upgrading</a> </li> + <li><a href="../../userguide/deployment.html" title="Deployment"><span class="none"></span>Deployment</a> </li> + <li><a href="../../apidocs/" title="Javadocs"><span class="none"></span>Javadocs</a> </li> + <li><a href="../../userguide/faq.html" title="FAQ"><span class="none"></span>FAQ</a> </li> + <li class="nav-header">Developer Resources</li> + <li><a href="../../dev/developer-guide.html" title="Developer Guide"><span class="none"></span>Developer Guide</a> </li> + <li><a href="../../dev/best-practices.html" title="Development Best Practices"><span class="none"></span>Development Best Practices</a> </li> + <li><a href="../../dev/release-process.html" title="Release Process"><span class="none"></span>Release Process</a> </li> + <li class="nav-header">Project Details</li> + <li><a href="../../project-info.html" title="Overview"><span class="none"></span>Overview</a> </li> + <li><a href="../../mail-lists.html" title="Mailing Lists"><span class="none"></span>Mailing Lists</a> </li> + <li><a href="../../source-repository.html" title="Source Repository"><span class="none"></span>Source Repository</a> </li> + <li><a href="../../issue-tracking.html" title="Issue Tracking"><span class="none"></span>Issue Tracking</a> </li> + <li><a href="../../dependency-management.html" title="Dependencies"><span class="none"></span>Dependencies</a> </li> + <li><a href="../../team-list.html" title="Project Team"><span class="none"></span>Project Team</a> </li> + </ul> + <hr /> + <div id="poweredBy"> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy"><img class="builtBy" alt="Built by Maven" src="../../images/logos/maven-feather.png" /></a> + </div> + </div> + </div> + <div id="bodyColumn" class="span10" > + + + <div class="section"> +<h2><a name="Sample_260:Switch_from_FIX_to_AMQP"></a>Sample 260:Switch from FIX to AMQP</h2> + +<div class="xmlConf"><definitions xmlns="http://ws.apache.org/ns/synapse"> + <proxy name="FIXProxy" transports="fix"> + <target> + <endpoint> + <address + uri="jms:/QpidStockQuoteService?transport.jms.ConnectionFactoryJNDIName=qpidConnectionfactory&java.naming.factory.initial=org.apache.qpid.jndi.PropertiesFileInitialContextFactory&java.naming.provider.url=repository/conf/sample/resources/fix/conn.properties&transport.jms.ReplyDestination=replyQueue"/> + </endpoint> + <inSequence> + <log level="full"/> + </inSequence> + <outSequence> + <property name="transport.fix.ServiceName" value="FIXProxy" scope="axis2-client"/> + <log level="full"/> + <send/> + </outSequence> + </target> + <parameter name="transport.fix.AcceptorConfigURL"> + file:repository/conf/sample/resources/fix/fix-synapse.cfg + </parameter> + <parameter name="transport.fix.AcceptorMessageStore"> + file + </parameter> + </proxy> +</definitions></div> + +<div class="section"> +<h3><a name="Objective"></a>Objective</h3> + +<p> + Demonstrate the capability of switching between FIX and AMQP protocols + </p> + </div> + +<div class="section"> +<h3><a name="Pre-requisites"></a>Pre-requisites</h3> + +<p> + </p> +<ul> + +<li> + You will need the sample FIX blotter that comes with Quickfix/J (Banzai). Configure the blotter to establish sessions with Synapse. (refer + <a href="setup/fix.html#synapse">FIX setup guide</a> for details) + </li> + +<li> + Configure the AMQP transport for Synapse. See Configure Synapse for <a href="setup/jms.html#amqp"> AMQP Transport setup</a> for detail + </li> + +<li> + To get an idea about the various transport parameters being used in this sample see FIX Transport Parameters . + </li> + </ul> + + </div> + +<div class="section"> +<h3><a name="Executing_the_Client"></a>Executing the Client</h3> + +<p> + Start the AMQP consumer, by switching to samples/axis2Client directory and running the consumer using the following command. Consumer will listen to the queue 'QpidStockQuoteService', accept the orders and reply to the queue 'replyQueue'. + </p> + +<div class="command">ant amqpconsumer -Dpropfile=$SYNAPSE_HOME/repository/conf/sample/resources/fix/direct.properties</div> + +<p> + Open up the SYNAPSE_HOME/repository/conf/sample/synapse_sample_260.xml file + and make sure that the transport.fix.AcceptorConfigURL property points + to the fix-synapse.cfg file you created. Once done you can start the + Synapse configuration numbered 260: i.e. synapse -sample 260. Note that + Synapse creates a new FIX session with Banzai at this point. + </p> + +<p> + Send an order request from Banzai to Synapse. e.g. Buy DELL 1000 @ MKT. + </p> + +<p> + Synapse will forward the order request by binding it to a JMS message payload and sending it to the AMQP consumer. AMQP consumer will send a execution back to Banzai. + </p> + </div> + </div> + +<p><a href="../samples.html">Back to Catalog</a></p> + + + </div> + </div> + </div> + <hr/> + <footer> + <div class="container-fluid"> + <div class="row-fluid"> + <p>Copyright ©2005–2023 +<a href="http://www.apache.org/">Apache Software Foundation</a>. +All rights reserved.</p> + </div> + </div> + </footer> + </body> +</html>