You are viewing a plain text version of this content. The canonical link for it is here.
Posted to yoko-commits@incubator.apache.org by br...@apache.org on 2006/06/22 17:56:11 UTC

svn commit: r416434 - in /incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world: README.txt src/yoko/client/Client.java

Author: bravi
Date: Thu Jun 22 10:56:11 2006
New Revision: 416434

URL: http://svn.apache.org/viewvc?rev=416434&view=rev
Log:
Updated the hello_world readme and the client code.
JIRA: http://issues.apache.org/jira/browse/YOKO-54

Modified:
    incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world/README.txt
    incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world/src/yoko/client/Client.java

Modified: incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world/README.txt
URL: http://svn.apache.org/viewvc/incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world/README.txt?rev=416434&r1=416433&r2=416434&view=diff
==============================================================================
--- incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world/README.txt (original)
+++ incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world/README.txt Thu Jun 22 10:56:11 2006
@@ -9,11 +9,36 @@
 it is not necessary to run the environment script described in
 the samples directory README.  If your environment is not
 properly configured, or if you are planning on using wsdl2idl/idl2wsdl,
-javac, and java to build and run the demos, you must set the
-environment by running the script.
+javac, and java to build and run the demos, you must include the yoko.jar
+in the CLASSPATH. Also set YOKO_HOME to the installation directory.
 
-Building and running the demo using ant
----------------------------------------
+This demo allows the user to run 3 use cases.
+
+- Yoko client & Yoko server.
+
+   In this usecase, it is assumed that we have an existing wsdl interface
+and we want to migrate our corba servers & clients to use the web services
+interface. We start by adding a corba binding to the wsdl interface using the wsdltoidl tool.
+Then we add a corba service to this wsdl and use the celtix wsdl2java tool to generate
+java server & client code from this wsdl.
+
+- Yoko client & corba server.
+
+  In this usecase, we want to access an existing corba server via a web services
+client. So first we use the idl interface of the corba server & use the idltowsdl tool
+to convert the idl to a wsdl with a corba binding & a corba service. Then we can use the
+celtix wsdl2java tool to generate the client code.
+
+- Corba Client & Yoko Server.
+
+  In this usecase, we want existing corba clients to access the web service enabled
+corba server. If we have an idl, we can use the idltowsdl to generate the wsdl for our
+server implementation or if we have a wsdl, use the wsdltoidl tool to generate the idl 
+for our client.
+
+
+Building and running the demo using ant (First use case).
+----------------------------------------------------------
 
 From the samples/ws/hello_world directory, the ant build script
 can be used to build and run the demo.
@@ -54,13 +79,15 @@
 From the samples/ws/hello_world directory run the commands, entered on a
 single command line:
 
+We have to set the Xbootclasspath because the ORB classes in yoko conflicts with the jdk classes.
+
 For UNIX (must use forward slashes):
-    java -Djava.endorsed.dirs=<yoko-install-dir>/lib 
-        -Dceltix.config.file=file:/<yoko-install-dir>/samples/ws/hello_world/etc/corba_bus_config.xml
+    java -Xbootclasspath/p:$YOKO_HOME/lib/yoko-core-1.0-incubating-M1-SNAPSHOT.jar 
+        -Dceltix.config.file=file:/$YOKO_HOME/samples/ws/hello_world/etc/corba_bus_config.xml
         -classpath $CLASSPATH:build/classes yoko.server.Server &
 
-    java -Djava.endorsed.dirs=<yoko-install-dir>/lib 
-        -Dceltix.config.file=file:/<yoko-install-dir>/samples/ws/hello_world/etc/corba_bus_config.xml 
+    java -Xbootclasspath/p:$YOKO_HOME%/lib/yoko-core-1.0-incubating-M1-SNAPSHOT.jar 
+        -Dceltix.config.file=file:/$YOKO_HOME/samples/ws/hello_world/etc/corba_bus_config.xml 
         -classpath $CLASSPATH:build/classes yoko.client.Client <Name>
 
 The server process starts in the background.  After running the client,
@@ -68,12 +95,12 @@
 
 For Windows (may use either forward or back slashes):
   start 
-    java -Djava.endorsed.dirs=<yoko-install-dir>\lib 
-        -Dceltix.config.file=file:/<yoko-install-dir>\samples\ws\hello_world\etc\corba_bus_config.xml
+    java -Xbootclasspath/p:%YOKO_HOME%\lib\yoko-core-1.0-incubating-M1-SNAPSHOT.jar 
+        -Dceltix.config.file=file:/%YOKO_HOME%\samples\ws\hello_world\etc\corba_bus_config.xml
         -classpath %CLASSPATH%;build\classes yoko.server.Server
 
-    java -Djava.endorsed.dirs=<yoko-install-dir>\lib
-        -Dceltix.config.file=file:/<yoko-install-dir>\samples\ws\hello_world\etc\corba_bus_config.xml
+    java -Xbootclasspath/p:%YOKO_HOME%\lib\yoko-core-1.0-incubating-M1-SNAPSHOT.jar
+        -Dceltix.config.file=file:/%YOKO_HOME%\samples\ws\hello_world\etc\corba_bus_config.xml
         -classpath %CLASSPATH%;build\classes yoko.client.Client <Name>
 
 A new command windows opens for the server process.  After running the

Modified: incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world/src/yoko/client/Client.java
URL: http://svn.apache.org/viewvc/incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world/src/yoko/client/Client.java?rev=416434&r1=416433&r2=416434&view=diff
==============================================================================
--- incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world/src/yoko/client/Client.java (original)
+++ incubator/yoko/trunk/distribution/src/main/samples/ws/hello_world/src/yoko/client/Client.java Thu Jun 22 10:56:11 2006
@@ -32,7 +32,7 @@
     }
 
     public static void main(String args[]) throws Exception {
-        if (args.length == 1) {
+        if (args.length != 1) {
             System.err.println("Please pass the greetMe argument.");
             System.exit(1);
         }