You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by ke...@apache.org on 2007/03/23 14:49:06 UTC
svn commit: r521726 - in /incubator/tuscany/java/sdo: ./ distribution/
impl/src/main/resources/META-INF/
sample/src/main/java/org/apache/tuscany/samples/sdo/
sample/src/main/java/org/apache/tuscany/samples/sdo/specCodeSnippets/
sample/src/main/resource...
Author: kelvingoodson
Date: Fri Mar 23 06:49:04 2007
New Revision: 521726
URL: http://svn.apache.org/viewvc?view=rev&rev=521726
Log:
TUSCANY-1171 fix instruction and documentation errors and 1 sample program failure
Modified:
incubator/tuscany/java/sdo/BUILDING.txt
incubator/tuscany/java/sdo/distribution/RELEASE_NOTES.txt
incubator/tuscany/java/sdo/impl/src/main/resources/META-INF/README.txt
incubator/tuscany/java/sdo/sample/src/main/java/org/apache/tuscany/samples/sdo/overview.html
incubator/tuscany/java/sdo/sample/src/main/java/org/apache/tuscany/samples/sdo/specCodeSnippets/CreateDataObjectFromXmlString.java
incubator/tuscany/java/sdo/sample/src/main/resources/companyDataGraphGenerated.xml
incubator/tuscany/java/sdo/tools/src/main/resources/META-INF/NOTICE
incubator/tuscany/java/sdo/tools/src/main/resources/META-INF/README.txt
Modified: incubator/tuscany/java/sdo/BUILDING.txt
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sdo/BUILDING.txt?view=diff&rev=521726&r1=521725&r2=521726
==============================================================================
--- incubator/tuscany/java/sdo/BUILDING.txt (original)
+++ incubator/tuscany/java/sdo/BUILDING.txt Fri Mar 23 06:49:04 2007
@@ -15,14 +15,16 @@
Building
--------
+In these instructions <archive-root> refers to the common root folder contained in all distribution archives for a particular release, for example "tuscany-sdo-1.0-incubating-M3"
+
1) Download the corresponding SDO specification source distribution from http://cwiki.apache.org/TUSCANY/sdo-java-download.html
2) Execute the instructions in that archive for building the SDO specification component
Note: following this step you will have maven installed, and a Java JDK at level 1.4.2 or above installed.
3) If you have chosen to install a JDK at level 5 then all will be fine, but there is one value add component in the
Tuscany SDO implementation which relies on new JDK 5.0 features. If you do not wish to use JDK 5 for the following
build step, then you will need to delete the file
- sdo/tools/src/main/java/org/apache/tuscany/sdo/generate/Interface2JavaGenerator.java before proceding
-4) Change to the top level directory of the Tuscany SDO Java Implementation project (sdo) of this source distribution.
+ <archive-root>/sdo/tools/src/main/java/org/apache/tuscany/sdo/generate/Interface2JavaGenerator.java before proceding
+4) Change to the top level directory of the Tuscany SDO Java Implementation project (<archive-root>/sdo) of this source distribution.
6) Execute: mvn
This will install the sdo implementation and tools jars in your local maven repository
5) Execute: mvn package javadoc:javadoc assembly:assembly
@@ -33,15 +35,18 @@
times until required dependencies are all located in your local maven repository. After you have completed a
full successful build you can use "mvn -o" which builds without trying to access updated build dependencies (offline mode) and is much faster.
-6) To run the sample programs, change directory to the "sample" directory, and run the command "mvn". Then look in the sample/target/site/apidocs/index.html file for javadoc that describes how to run the samples.
+6) Currently, due to maven configuration issues, the distribution artefacts at this point contain 2 spurious items, junit-3.8.1.jar and asm-2.2.jar. In order for the distribution archives to be consistent with the contained license information, these jar files must be manually removed from the archives. This step will become unnecessary once the issues with maven have been overcome/fixed.
+
+7) To run the sample programs, change directory to the <archive-root>/sdo/sample directory, and run the command "mvn". Then look in the <archive-root>/sdo/sample/target/site/apidocs/index.html file for javadoc that describes how to run the samples.
Building the SDO Samples Source distribution
============================================
To build the SDO Samples source distribution
-1) copy the sdo/sample directory from the SDO implementation source distribution to a temporary folder
-2) Build the SDO binary distribution as instructed above
-3) From the top level directory of your SDO implementation build tree change directory to the sample directory and execute the command mvn javadoc:javadoc to create javadoc for the samples in the target/site directory
-4) copy the site folder to the temporary directory created for step 1
-4) create .zip and .tar.gz archives of the sample source and javadoc
\ No newline at end of file
+1) Build the SDO binary distribution as instructed above
+2) From the top level directory of your SDO implementation build tree change directory to the <archive-root>/sdo/sample directory and execute the command mvn javadoc:javadoc to create javadoc for the samples in the <archive-root>/sdo/sample/target/site directory
+3) copy the <archive-root>/sdo/sample directory from the SDO implementation source distribution to a temporary location retaining the path <archive-root>/sdo/sample below the temporary directory location
+4) copy the site folder created in step 2 to the temporary directory created for step 3, so that it exists at path <archive-root>/sample/site
+4) create .zip and .tar.gz archives containing the sample source and javadoc using the naming convention
+apache-<archive-root>-sample.<archive-extension>, such that the archives each contain a single root folder <archive-root>
\ No newline at end of file
Modified: incubator/tuscany/java/sdo/distribution/RELEASE_NOTES.txt
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sdo/distribution/RELEASE_NOTES.txt?view=diff&rev=521726&r1=521725&r2=521726
==============================================================================
--- incubator/tuscany/java/sdo/distribution/RELEASE_NOTES.txt (original)
+++ incubator/tuscany/java/sdo/distribution/RELEASE_NOTES.txt Fri Mar 23 06:49:04 2007
@@ -12,7 +12,7 @@
Compatibility Concerns
M2 now uses the SDO 2.1 interfaces whereas M2 used the 2.0.1 interfaces.
- A program written to the M2 dynamic SDO API/SPI can both compile against M3 libraries,
+ A program written to the M2 dynamic SDO API/SPI can compile against M3 libraries,
although some API and SPI interfaces have been deprecated between releases.
In most instances these programs will execute as before, but if the programs relied
on the exposure of EMF Property instances through the SDO API then they will fail.
Modified: incubator/tuscany/java/sdo/impl/src/main/resources/META-INF/README.txt
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sdo/impl/src/main/resources/META-INF/README.txt?view=diff&rev=521726&r1=521725&r2=521726
==============================================================================
--- incubator/tuscany/java/sdo/impl/src/main/resources/META-INF/README.txt (original)
+++ incubator/tuscany/java/sdo/impl/src/main/resources/META-INF/README.txt Fri Mar 23 06:49:04 2007
@@ -1,4 +1,4 @@
-Apache Tuscany M1 build (May, 2006)
+Apache Tuscany M3 build (March 2007)
===================================
http://incubator.apache.org/tuscany/
Modified: incubator/tuscany/java/sdo/sample/src/main/java/org/apache/tuscany/samples/sdo/overview.html
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sdo/sample/src/main/java/org/apache/tuscany/samples/sdo/overview.html?view=diff&rev=521726&r1=521725&r2=521726
==============================================================================
--- incubator/tuscany/java/sdo/sample/src/main/java/org/apache/tuscany/samples/sdo/overview.html (original)
+++ incubator/tuscany/java/sdo/sample/src/main/java/org/apache/tuscany/samples/sdo/overview.html Fri Mar 23 06:49:04 2007
@@ -28,7 +28,7 @@
target="_blank"> Apache Tuscany</a> project. The samples were written to help users
understand and experiment with SDO. They are grouped into three packages according to the source of the example material. Some are based upon example code contained
within the <a
- href="http://osoa.org/download/attachments/791/SDO_Specification_Java_V2.01.pdf?version=1"
+ href="http://osoa.org/display/Main/Service+Data+Objects+Specifications"
target="_bank">SDO Specification</a>, and are intended to be read alongside the specification. Others are based upon papers and published material
(see the documentation for each sample for the reference to the publication),
or were simply written specifically for these samples.
@@ -65,7 +65,7 @@
<BR>
If you are running these samples as a result of building Tuscany SDO for Java from a Tuscany source distribution using maven then these dependencies will be resolved by having followed the build instructions.<BR>
<BR>To run these samples against the current Tuscany codebase, follow the instructions at <A
- href="http://incubator.apache.org/tuscany/java_sdo_overview.html">Tuscany SDO Java Overview</A>, which describes how to build Tuscany SDO for Java in an Eclipse SDK environment.</P>
+ href="http://cwiki.apache.org/TUSCANY/sdo-java.html">Tuscany SDO Java Overview</A>, which describes how to build Tuscany SDO for Java in an Eclipse SDK environment.</P>
<H3>Running the Samples</H3>
<P>In order to get an overview of the samples the user may wish to run
{@link org.apache.tuscany.samples.sdo.ExecuteSamples} which will execute
Modified: incubator/tuscany/java/sdo/sample/src/main/java/org/apache/tuscany/samples/sdo/specCodeSnippets/CreateDataObjectFromXmlString.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sdo/sample/src/main/java/org/apache/tuscany/samples/sdo/specCodeSnippets/CreateDataObjectFromXmlString.java?view=diff&rev=521726&r1=521725&r2=521726
==============================================================================
--- incubator/tuscany/java/sdo/sample/src/main/java/org/apache/tuscany/samples/sdo/specCodeSnippets/CreateDataObjectFromXmlString.java (original)
+++ incubator/tuscany/java/sdo/sample/src/main/java/org/apache/tuscany/samples/sdo/specCodeSnippets/CreateDataObjectFromXmlString.java Fri Mar 23 06:49:04 2007
@@ -22,6 +22,7 @@
import java.util.List;
import commonj.sdo.DataObject;
+import commonj.sdo.Sequence;
import commonj.sdo.helper.XMLHelper;
/**
@@ -29,13 +30,13 @@
*
* The following sample is from the <a href="http://incubator.apache.org/tuscany"
* target="_blank"> Apache Tuscany</a> project. It was written to help users
- * understand and experiement with SDO. It is based upon code snippets contained
+ * understand and experiment with SDO. It is based upon code snippets contained
* within, and is meant for use with, and reference to the <a
* href="http://www.osoa.org/download/attachments/791/SDO_Specification_Java_V2.01.pdf?version=1"
* target="_bank">SDO Specification</a>. Specifically this sample is based upon section titled "Creating DataObjects from XML documents" <br>
* <br>
* <b>Usage:</b> <br>
- * This sample can easily be run from within Eclipse as a Java Application if tuscany or
+ * This sample can easily be run from within Eclipse as a Java Application if Tuscany or
* the sample-sdo project is imported into Eclipse as an existing project.
* <br><br>
* If executing as a standalone application please do the following:
@@ -101,7 +102,7 @@
System.out.println("***************************************");
System.out.println("SDO Sample CreateDataObjectFromXmlString");
System.out.println("***************************************");
- System.out.println("Demonstrats creating a DataObject from a String of XML, based upon section titled 'Creating DataObjects from XML documents'");
+ System.out.println("Demonstrates creating a DataObject from a String of XML, based upon section titled 'Creating DataObjects from XML documents'");
System.out.println("***************************************");
// sample
@@ -110,7 +111,7 @@
System.out.println("Use the following XML String: " + XML_STRING);
System.out.println("Creating DataObject");
DataObject po = createDataObjectFromXmlString();
- System.out.println("The following DataObject sucessfully created from XML String");
+ System.out.println("The following DataObject was sucessfully created from the XML String");
System.out.println(XMLHelper.INSTANCE.save(po, "http://example.com/purchaseOrder", "purchaseOrder"));
@@ -119,7 +120,7 @@
* difficult. This is because without a Type definition SDO does not know
* the intended multiplicity of properties. Currently the Tuscany
* implementation assumes that elements and attributes are lists. There
- * is some discussion (SDO-3, also mentioned in SDO-22) about adding
+ * is some discussion (SDO-3, also mentioned in SDO Specification JIRA SDO-22) about adding
* annotations to the XML (sdo:many="false") to control the indended
* multiplicity of DataObjects created without a model.
*
@@ -149,8 +150,8 @@
List nameList = shipTo.getList("name");
DataObject name = (DataObject) nameList.get(0);
// access the contents of the name DataObject
- List textList = name.getList("text");
- String actualName = (String) textList.get(0);
+ Sequence s = name.getSequence();
+ String actualName = (String) s.getValue(0);
System.out.println("Name being shipped to: " + actualName);
} catch (Exception e) {
Modified: incubator/tuscany/java/sdo/sample/src/main/resources/companyDataGraphGenerated.xml
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sdo/sample/src/main/resources/companyDataGraphGenerated.xml?view=diff&rev=521726&r1=521725&r2=521726
==============================================================================
--- incubator/tuscany/java/sdo/sample/src/main/resources/companyDataGraphGenerated.xml (original)
+++ incubator/tuscany/java/sdo/sample/src/main/resources/companyDataGraphGenerated.xml Fri Mar 23 06:49:04 2007
@@ -19,12 +19,12 @@
-->
<sdo:datagraph xmlns:company="company.xsd" xmlns:sdo="commonj.sdo">
- <company:CompanyType employeeOfTheMonth="E0002"
+ <company:company employeeOfTheMonth="E0002"
name="ACME">
<departments location="NY" name="Advanced Technologies" number="123">
<employees name="John Jones" SN="E0001"/>
<employees name="Jane Doe" SN="E0003"/>
<employees manager="true" name="Al Smith" SN="E0004"/>
</departments>
- </company:CompanyType>
+ </company:company>
</sdo:datagraph>
Modified: incubator/tuscany/java/sdo/tools/src/main/resources/META-INF/NOTICE
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sdo/tools/src/main/resources/META-INF/NOTICE?view=diff&rev=521726&r1=521725&r2=521726
==============================================================================
--- incubator/tuscany/java/sdo/tools/src/main/resources/META-INF/NOTICE (original)
+++ incubator/tuscany/java/sdo/tools/src/main/resources/META-INF/NOTICE Fri Mar 23 06:49:04 2007
@@ -1,5 +1,5 @@
Apache Tuscany SDO for Java
-Copyright 2006 The Apache Software Foundation
+Copyright 2006, 2007 The Apache Software Foundation
This product includes software developed at
The Apache Software Foundation (http://www.apache.org/).
Modified: incubator/tuscany/java/sdo/tools/src/main/resources/META-INF/README.txt
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sdo/tools/src/main/resources/META-INF/README.txt?view=diff&rev=521726&r1=521725&r2=521726
==============================================================================
--- incubator/tuscany/java/sdo/tools/src/main/resources/META-INF/README.txt (original)
+++ incubator/tuscany/java/sdo/tools/src/main/resources/META-INF/README.txt Fri Mar 23 06:49:04 2007
@@ -1,4 +1,4 @@
-Apache Tuscany M1 build (May, 2006)
+Apache Tuscany M3 build (March 2007)
===================================
http://incubator.apache.org/tuscany/
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org