summaryrefslogtreecommitdiffstats
path: root/java/sca/samples/calculator-rmi-service
diff options
context:
space:
mode:
authorslaws <slaws@13f79535-47bb-0310-9956-ffa450edef68>2009-02-04 18:57:37 +0000
committerslaws <slaws@13f79535-47bb-0310-9956-ffa450edef68>2009-02-04 18:57:37 +0000
commit9d50b86d029573d79dbd6dcb4bc40ccbe8601765 (patch)
treebdc76140af4953d2015c2592257d959925a2fb12 /java/sca/samples/calculator-rmi-service
parent9bc87487f853cc8ae512ed840556325f3a08115e (diff)
Add the rmi samples to itest/samples. Commented out at the moment in the build.xml file as the service node is not shutting down cleanly when called from ant with a timeout. I also need to find a away to turing the timeout on only for itest/sample and allow the use to use it in a mode where the node blocks until a key is pressed.
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@740823 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/sca/samples/calculator-rmi-service')
-rw-r--r--java/sca/samples/calculator-rmi-service/build.xml58
1 files changed, 49 insertions, 9 deletions
diff --git a/java/sca/samples/calculator-rmi-service/build.xml b/java/sca/samples/calculator-rmi-service/build.xml
index 4abba9f5a6..870ac9f68f 100644
--- a/java/sca/samples/calculator-rmi-service/build.xml
+++ b/java/sca/samples/calculator-rmi-service/build.xml
@@ -17,15 +17,30 @@
* under the License.
-->
-<project name="calculator" default="compile">
+<project name="binding-rmi-calculator-service" default="run">
<property name="jar.name" value="sample-calculator-rmi-service.jar" />
<property name="main.class" value="calculator.CalculatorClient" />
+ <target name="init">
+ <delete quiet="true" includeemptydirs="true">
+ <fileset dir="target"/>
+ </delete>
+ <mkdir dir="target/classes"/>
+ </target>
+
<target name="compile" depends="init">
- <javac srcdir="src/main/java" destdir="target/classes" debug="on" source="1.5" target="1.5">
+ <javac srcdir="src/main/java"
+ destdir="target/classes"
+ debug="on"
+ source="1.5"
+ target="1.5"
+ failonerror="true">
<classpath>
<pathelement location="../../modules/tuscany-sca-api-2.0-SNAPSHOT.jar"/>
+ <pathelement location="../../modules/tuscany-node-api-2.0-SNAPSHOT.jar"/>
+ <pathelement location="../../modules/sca-api/target/tuscany-sca-api-2.0-SNAPSHOT.jar"/>
+ <pathelement location="../../modules/node-api/target/tuscany-node-api-2.0-SNAPSHOT.jar"/>
</classpath>
</javac>
<copy todir="target/classes">
@@ -37,13 +52,38 @@
</manifest>
</jar>
</target>
-
- <target name="init">
- <delete quiet="true" includeemptydirs="true">
- <fileset dir="target"/>
- </delete>
- <mkdir dir="target/classes"/>
- </target>
+
+ <!--target name="run" depends="compile">
+ <java classname="org.apache.tuscany.sca.launcher.LauncherMain"
+ fork="true"
+ inputstring="\n"
+ failonerror="true">
+ <jvmarg value="-Djava.util.logging.config.file=${sample.root}/../../logging.properties"/>
+ <classpath>
+ <pathelement location="../../distribution/all/target/apache-tuscany-sca-all-2.0-SNAPSHOT/tuscany-sca-2.0-SNAPSHOT/bin/launcher.jar"/>
+ <pathelement location="../../bin/launcher.jar"/>
+ </classpath>
+ <arg value="target/${jar.name}"/>
+ </java>
+ </target-->
+
+ <target name="run" depends="compile">
+ <java classname="org.apache.tuscany.sca.node.launcher.NodeLauncher"
+ fork="true"
+ timeout="6000"
+ failonerror="true">
+ <jvmarg value="-Djava.util.logging.config.file=${sample.root}/../../logging.properties"/>
+ <classpath>
+ <pathelement location="../../modules/tuscany-node-launcher-2.0-SNAPSHOT.jar"/>
+ <pathelement location="../../modules/commons-cli-1.1/commons-cli-1.1.jar"/>
+ <pathelement location="../../distribution/all/target/apache-tuscany-sca-all-2.0-SNAPSHOT/tuscany-sca-2.0-SNAPSHOT/modules/tuscany-node-launcher-2.0-SNAPSHOT.jar"/>
+ <pathelement location="../../distribution/all/target/apache-tuscany-sca-all-2.0-SNAPSHOT/tuscany-sca-2.0-SNAPSHOT/modules/commons-cli-1.1/commons-cli-1.1.jar"/>
+ </classpath>
+ <arg value="target/${jar.name}"/>
+ <arg value="-t"/>
+ <arg value="5000"/>
+ </java>
+ </target>
</project>