summaryrefslogtreecommitdiffstats
path: root/site/branches/site-20070701-mvnbased/site-author/java_das_overview.xml
diff options
context:
space:
mode:
Diffstat (limited to 'site/branches/site-20070701-mvnbased/site-author/java_das_overview.xml')
-rw-r--r--site/branches/site-20070701-mvnbased/site-author/java_das_overview.xml317
1 files changed, 317 insertions, 0 deletions
diff --git a/site/branches/site-20070701-mvnbased/site-author/java_das_overview.xml b/site/branches/site-20070701-mvnbased/site-author/java_das_overview.xml
new file mode 100644
index 0000000000..b3be6b4f3e
--- /dev/null
+++ b/site/branches/site-20070701-mvnbased/site-author/java_das_overview.xml
@@ -0,0 +1,317 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<document>
+ <properties>
+ <title>Tuscany</title>
+ <bannertitle>Welcome to Tuscany</bannertitle>
+ <tab>das</tab>
+ </properties>
+ <body>
+
+ <section name="Tuscany DAS - Java">
+ <p>This document proves a high-level overview of the Java DAS (Data Access Services) subproject of the Apache Tuscany incubator project.</p>
+ </section>
+
+
+ <section name="DAS Java Getting Started">
+ <p>To get started with Java DAS, follow the <a href="downloads.html">downloads</a> link and pick up either a binary or source distribution.
+ If you are working from a source distribution, you can follow the <a href="java-projects.html">general instructions</a> for building the whole of the Tuscany java projects,
+ or you can follow the intructions within the <A href="java_das_overview.html"> DAS Java overview </A> to build and explore just DAS java.
+ </p>
+
+ <h3>General DAS Documentation</h3>
+ <table class="bodyTable">
+ <tr class="b">
+ <td>
+ <span style="font-weight: bold;">Title</span>
+ </td>
+ <td>
+ <span style="font-weight: bold;">Description</span>
+ </td>
+ </tr>
+
+ <tr class="b">
+ <td>
+ <a href='RDB_DAS_white_paper_v-0.2.pdf' target='_blank'>DAS White Paper: The Data Access Service</a>
+ </td>
+ <td>
+ How to access relational data in terms of Service Data Objects
+ </td>
+ </tr>
+
+ <tr class="b">
+ <td>
+ <a class="external" rel="nofollow" href='http://java.sys-con.com/read/260053.htm'>JDJ DAS Article</a>
+ </td>
+ <td>
+ How to access relational data in terms of Service Data Objects
+ </td>
+ </tr>
+ </table>
+ </section>
+
+
+ <section name="DAS Java Overview">
+
+ <p>Currently, the project's code base includes an implementation of a DAS RDB (relational database) with following key features :</p>
+
+ <h3>DAS Java Project Structure</h3>
+
+ <p>The DAS RDB project is divided into three parts:</p>
+ <ol type="1">
+ <li><p><strong>das.rdb</strong> contains the DAS interfaces and the RDB (Relational Database) runtime implementation.</p></li>
+ <li><p><strong>samples.das</strong> provides sample applications based on DAS.</p></li>
+ <li><p><strong>distribution.das</strong> provides DAS binaries distribution with required dependencies.</p></li>
+ <li><p><strong>distribution.das-samples</strong> provides DAS samples distribution as a ready-to-deploy war file.</p></li>
+ </ol>
+
+
+ <h3>DAS high level class diagram</h3>
+
+ <img src ="images/das_class_diagram.jpg" alt="DAS High level class diagram" align="middle" border="0" height="561" width="710"/>
+
+ </section>
+
+ <section name="Build Environment Setup">
+
+ <h3>Tuscany Build Environment Setup</h3>
+
+ <p>DAS is a subproject of the Tuscany project. If you check out and
+ build the whole Tuscany Java project, you will have also built the DAS
+ subproject. If you want to work with the DAS project, without the rest
+ of Tuscany, skip to the next section.</p>
+
+ <p>To build the whole Tuscany project follow <a class="external" rel="nofollow" href="java-projects.html">these instructions</a>.</p>
+
+
+
+ <h3>DAS Java Build Environment Setup</h3>
+
+ <p>If you want to work with the DAS project alone, without the rest of Tuscany, proceed with the following steps.</p>
+ <ol type="1">
+ <li><p>Set up your environment using the <a class="external" rel="nofollow" href="java-projects.html"> instructions for building the whole of Tuscany</a>,
+ <strong>but</strong> only download and install Java 5, Maven and Svn</p></li>
+
+ <li><p>Make sure 'mvn' and 'svn' commands are in your PATH environment variable.</p></li>
+
+ <li><p>Check out the DAS open source projects from Apache.</p></li>
+
+ <ul>
+ <li style="list-style-type: none;">
+ <p>Commands:</p>
+ <p>md &lt;local tuscany dir&gt; <br/>
+ cd &lt;local tuscany dir&gt; <br/>
+ svn co <a rel="nofollow" href="https://svn.apache.org/repos/asf/incubator/tuscany/java">https://svn.apache.org/repos/asf/incubator/tuscany/java</a> <br/>
+ </p>
+ </li>
+ </ul>
+ </ol>
+
+ <ol start="4" type="1">
+ <li><p>Run "mvn" under &lt;local tuscany dir&gt;/java directory to install
+ POM files from the root project to the local repository</p></li>
+ </ol>
+ <ul>
+ <li style="list-style-type: none;">
+ <p>Commands:</p>
+ <ul>
+ <li style="list-style-type: none;">
+ <p>cd &lt;local tuscany dir&gt;/java/das <br/>
+ mvn<br/>
+ </p>
+ </li>
+ </ul>
+ </li>
+ </ul>
+
+ <ul>
+ <li style="list-style-type: none;">
+ <p><strong>Notes:</strong></p>
+ <ol type="1">
+ <li><p>If the mvn command completed successfully, you will see BUILD
+ SUCCESSFUL in the output and tuscany-das-rdb-1.0-SNAPSHOP.jar is created under
+ &lt;local tuscany dir&gt;/java/das/rdb/target directory.</p></li>
+
+ <li><p>External resources are at times unavailable. It may be necessary to
+ run "mvn" again at a later time.</p></li>
+
+ <li><p>If you are taking time to reply to firewall prompts, this can cause
+ some requests to time out. Set up the firewall to permit the action without prompting.</p></li>
+ </ol>
+ </li>
+ </ul>
+
+ <H3>Building Javadoc for DAS</H3>
+
+ <p> In order to build DAS Javadocs, you will need to build the a specific maven profile called "javadoc" </p>
+
+ <ul>
+ <li style="list-style-type: none;">
+ <p>Commands:</p>
+ <ul>
+ <li style="list-style-type: none;">
+ <p>cd &lt;local tuscany dir&gt;/java/das <br/>
+ mvn -P javadoc<br/>
+ </p>
+ </li>
+ </ul>
+ <p>Note: Javadoc will be available at &lt;local tuscany dir&gt;/java/das/rdb/target/apidocs/index.html.</p>
+ </li>
+ </ul>
+
+
+ <H3 >Dependency Jars</H3>
+
+ <p> The DAS.RDB project has a dependency on SDO and requires the following SDO runtime jars to build</p>
+
+ <ul>
+ <li><p>sdo-api-r2.0.1-1.0-SNAPSHOT.jar - SDO 2.0 Interfaces</p></li>
+ <li><p>tuscany-sdo-impl-1.0-SNAPSHOT.jar - SDO 2.0 implementation</p></li>
+ </ul>
+
+
+ <p>The SDO.IMPL project have dependencies on the following EMF (Eclipse Modeling
+ Framework - www.eclipse.org/emf) runtime jars to build:</p>
+ <ul>
+ <li><p>common-2.2.1.jar - some common framework utility and base classes</p></li>
+ <li><p>ecore-2.2.1.jar - the EMF core runtime implementation classes (the Ecore metamodel)</p></li>
+ <li><p>ecore-change-2.2.1.jar - the EMF change recorder and framework</p></li>
+ <li><p>ecore-xmi-2.2.1.jar - EMF's default XML (and XMI) serializer and loader</p></li>
+ <li><p>xsd-2.2.1.jar - the XML Schema model</p></li>
+ <li><p>log4j-1.2.12.jar - log4j logging framework</p></li>
+ </ul>
+
+ </section>
+
+
+ <section name="Running DAS Samples">
+
+ <p>DAS provide sample a CompanyWeb scenario where it exposes some of the DAS Features integrated in a J2EE webapp.</p>
+ <p>Follow the steps below to be able to run the samples in a J2EE webserver (in our case Apache Tomcat)</p>
+
+ <p><strong>From the source repository</strong></p>
+
+ <ul>
+ <li><p>checkout DAS Sample from SVN repository:</p></li>
+ <ul>
+ <li><p>md 'local tuscany dir'</p></li>
+ <li><p>cd 'local tuscany dir'</p></li>
+ <li><p>svn co https://svn.apache.org/repos/asf/incubator/tuscany/java/das das</p></li>
+ </ul>
+ <li><p>use maven to build the CompanyWeb war file:</p></li>
+ <ul>
+ <li><p>cd das\samples</p></li>
+ <li><p>mvn</p></li>
+ </ul>
+ <li><p>use maven to deploy the CompanyWeb war file to Tomcat</p></li>
+ <ul>
+ <li><p>mvn tomcat:deploy</p></li>
+ </ul>
+ </ul>
+
+ <p>There are also some sample applications that use a mix of SCA, SDO and DAS. See "Running the Samples" on the <a href="java-projects.html#Running the Samples">Java project page</a> for details.</p>
+
+ <p><strong>From a DAS Sample distribution (starting with M2)</strong>:</p>
+
+ <ul>
+ <li><p>Download a das-sample distribution from http://incubator.apache.org/tuscany/downloads.html</p></li>
+ <li><p>Extract the companyweb war file</p></li>
+ <li><p>Follow regular deployment procedures to deploy the war file</p></li>
+ </ul>
+ </section>
+
+ <section name="Running Tuscany DAS Unit Tests">
+ <p>DAS is currently providing two sets of unit tests</p>
+ <ul>
+ <li><p>JUnit tests for the core DAS code</p></li>
+ <li><p>HTMLUnit tests integrated with Tomcat for DAS CompanyWeb sample application</p></li>
+ </ul>
+ <p>Below we are going to describe how you can exercise these two sets of tests, and we recommend you running them after contributing code/patches for DAS
+ to validate that your new changes are not introducing any regressions.</p>
+
+ <p><strong>Running DAS tests as part of the build</strong></p>
+ <ul>
+ <li><p>cd 'local tuscany dir'/java/das</p></li>
+ <li><p>mvn test</p></li>
+
+ <p>
+ -------------------------------------------------------<br/>
+ T E S T S<br/>
+ -------------------------------------------------------<br/>
+ Running org.apache.tuscany.das.rdb.test.suites.AllTestsDerby<br/>
+ Setting up for Derby run<br/>
+ Ending Derby run<br/>
+ Tests run: 137, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 33.468 sec<br/>
+ <br/>
+ Results :<br/>
+ <br/>
+ Tests run: 137, Failures: 0, Errors: 0, Skipped: 0<br/>
+ <br/>
+ [INFO] ------------------------------------------------------------------------<br/>
+ [INFO] BUILD SUCCESSFUL<br/>
+ [INFO] ------------------------------------------------------------------------<br/>
+ [INFO] Total time: 57 seconds<br/>
+ [INFO] Finished at: Tue Oct 03 12:06:13 PDT 2006<br/>
+ [INFO] Final Memory: 5M/10M<br/>
+ [INFO] ------------------------------------------------------------------------<br/>
+ <br/>
+ </p>
+ </ul>
+
+ <p><strong>Running DAS CompanyWeb tests in tomcat</strong></p>
+ <ul>
+ <li><p>Download tomcat distribution into your local filesystem : http://tomcat.apache.org/</p></li>
+ <li><p>Create a build.properties in your root directory (e.g. C:\Documents and Settings\lresende in Win2K systems) with the following contents</p></li>
+ <ul>
+ <li><p>tuscany.acceptance.tomcat.zipped='directory where tomcat was downloaded'\\apache-tomcat-5.5.17-tuscany.zip</p></li>
+ </ul>
+ <li><p>checkout DAS Sample from SVN repository:</p></li>
+ <ul>
+ <li><p>md 'local tuscany dir'</p></li>
+ <li><p>cd 'local tuscany dir'</p></li>
+ <li><p>svn co https://svn.apache.org/repos/asf/incubator/tuscany/java/das das</p></li>
+ </ul>
+ <li><p>use maven run the DAS CompanyWeb tests in Tomcat:</p></li>
+ <ul>
+ <li><p>cd das/samples/testing/tomcat</p></li>
+ <li><p>mvn</p></li>
+ <p>
+ -------------------------------------------------------<br/>
+ T E S T S<br/>
+ -------------------------------------------------------<br/>
+ Running org.apache.tuscany.test.das.DasTestCase<br/>
+ Running:HomePage SUCCESS!!!<br/>
+ Running:AllCompanies SUCCESS!!!<br/>
+ Running:AllCompaniesDepartments SUCCESS!!!<br/>
+ Running:AddDepartmentToFirstCompany SUCCESS!!!<br/>
+ Running:ChangeCompanyDepartmentNames SUCCESS!!!<br/>
+ Running:DeleteCompanyOneDepartments SUCCESS!!!<br/>
+ Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 14.911 sec<br/>
+ <br/>
+ Results :<br/>
+ <br/>
+ Tests run: 6, Failures: 0, Errors: 0, Skipped: 0<br/>
+ <br/>
+ [INFO]<br/>
+ [INFO]<br/>
+ [INFO] ------------------------------------------------------------------------<br/>
+ [INFO] Reactor Summary:<br/>
+ [INFO] ------------------------------------------------------------------------<br/>
+ [INFO] Tuscany Testing in Tomcat ............................. SUCCESS [0.251s]<br/>
+ [INFO] Tuscany Testing DAS Sample - Companyweb ............... SUCCESS [1:17.791s]<br/>
+ [INFO] ------------------------------------------------------------------------<br/>
+ [INFO] ------------------------------------------------------------------------<br/>
+ [INFO] BUILD SUCCESSFUL<br/>
+ [INFO] ------------------------------------------------------------------------<br/>
+ [INFO] Total time: 1 minute 18 seconds<br/>
+ [INFO] Finished at: Tue Oct 03 12:25:48 PDT 2006<br/>
+ [INFO] Final Memory: 7M/15M<br/>
+ [INFO] ------------------------------------------------------------------------<br/>
+ </p>
+ <li><p><strong>Note: Due to a current limitation, you must run mvn clean before you can run the tests a second time</strong></p></li>
+ </ul>
+ </ul>
+ </section>
+
+
+ </body>
+</document>