summaryrefslogtreecommitdiffstats
path: root/sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer
diff options
context:
space:
mode:
Diffstat (limited to 'sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer')
-rw-r--r--sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer/README49
-rw-r--r--sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer/build.xml2
2 files changed, 41 insertions, 10 deletions
diff --git a/sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer/README b/sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer/README
index 62ef1d0126..4993c5ce79 100644
--- a/sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer/README
+++ b/sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer/README
@@ -1,5 +1,5 @@
Notification Consumer Binding Sample
-===============================
+====================================
This sample illustrates the use of <binding.notification/> with a
remote consumer.
@@ -29,15 +29,32 @@ via <binding.notification/> to be transported as literal xml over http.
Sample Usage
------------
-This sample is run using the tuscany binary distribution. To run it, navigate to this sample's directory and
+These instructions assume that you will start the notification samples in the
+following order:
+ binding-notification-consumer
+ binding-notification-broker
+ binding-notification-producer
-on Wondows, use following command:
+For a clean shutdown without exceptions, you should end the notification samples
+in the following order:
+ binding-notification-producer
+ binding-notification-broker
+ binding-notification-consumer
-java -Dnotification.httpPort=8082 -cp ..\..\lib\tuscany-sca-manifest.jar;target\sample-binding-notification-consumer.jar notification.consumer.TrafficAdvisoryServer
+This sample is run using the tuscany binary distribution. To see what it does,
+open a command prompt, navigate to this sample's directory and do
-on *nix, use following command:
+ant run
+
+OR if you don't have ant,
+
+on Windows, use the following command:
+
+java -Dnotification.httpPort=8083 -cp ..\..\lib\tuscany-sca-manifest.jar;target\sample-binding-notification-consumer.jar notification.consumer.TrafficAdvisoryServer
+
+on *nix, use the following command:
-java -Dnotification.httpPort=8082 -cp ../../lib/tuscany-sca-manifest.jar:target/sample-binding-notification-consumer.jar notification.consumer.TrafficAdvisoryServer
+java -Dnotification.httpPort=8083 -cp ../../lib/tuscany-sca-manifest.jar:target/sample-binding-notification-consumer.jar notification.consumer.TrafficAdvisoryServer
this should bring up the following prompt:
@@ -49,9 +66,9 @@ Notice that before you try to receive any message, you should bring up the
producer sample or the broker sample. When you have finished using this
sample, hit return to end.
-Also notice that '-Dnotification.httpPort=8082' is used in the java command.
+Also notice that '-Dnotification.httpPort=8083' is used in the java command.
This indicates the port the sample should use. This also says that this server
-is not going to play the role of ntm, given our previous assumption. It is important
+is going to play the role of ntm, given our previous assumption. It is important
that the first one of the producer, consumer or broker sample that is run be the
one that uses '-Dnotification.httpPort=8083', otherwise there is no ntm to talk
to and an exception will be thrown.
@@ -80,7 +97,7 @@ binding-notification-consumer/
TrafficAdvisoryTestCase.java - JUnit test case
resources/
binding-notification-consumer.png - a pictorial representation of the sample .composite file
- build.xml - the Ant build file
+ build.xml - the Ant build file
pom.xml - the Maven build file
Building And Running The Sample Using Ant
@@ -108,3 +125,17 @@ using Maven as follows.
cd binding-notification-consumer
mvn
+You should see the following output from the test phase.
+
+-------------------------------------------------------
+ T E S T S
+-------------------------------------------------------
+Running notification.consumer.TrafficAdvisoryTestCase
+Only instantiating and closing domain ...
+Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.252 sec
+
+Results :
+
+Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
+
+This shows that the Junit test cases have run successfully.
diff --git a/sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer/build.xml b/sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer/build.xml
index f57fe1bb26..b4ddaa3aec 100644
--- a/sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer/build.xml
+++ b/sca-java-1.x/branches/sca-java-1.6.1/samples/binding-notification-consumer/build.xml
@@ -63,7 +63,7 @@
<pathelement path="target/${test.jar}"/>
<pathelement location="../../lib/tuscany-sca-manifest.jar"/>
</classpath>
- <sysproperty key="notification.httpPort" value="8081"/>
+ <sysproperty key="notification.httpPort" value="8083"/>
</java>
</target>