You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by ni...@apache.org on 2007/07/01 06:58:18 UTC
svn commit: r552244 - in
/incubator/cxf/trunk/distribution/src/main/release/samples:
js_client/README.txt js_client/build.xml js_client/logging.properties
js_client/run_client.bat js_client/run_client.sh js_provider/README.txt
Author: ningjiang
Date: Sat Jun 30 21:58:17 2007
New Revision: 552244
URL: http://svn.apache.org/viewvc?view=rev&rev=552244
Log:
CXF-757 applied the patch of Glen, and removed the prerequisite of downloading the js and xmlbean jars, because we ship them in CXF distribution.
Added:
incubator/cxf/trunk/distribution/src/main/release/samples/js_client/build.xml (with props)
Removed:
incubator/cxf/trunk/distribution/src/main/release/samples/js_client/logging.properties
incubator/cxf/trunk/distribution/src/main/release/samples/js_client/run_client.bat
incubator/cxf/trunk/distribution/src/main/release/samples/js_client/run_client.sh
Modified:
incubator/cxf/trunk/distribution/src/main/release/samples/js_client/README.txt
incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt
Modified: incubator/cxf/trunk/distribution/src/main/release/samples/js_client/README.txt
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/js_client/README.txt?view=diff&rev=552244&r1=552243&r2=552244
==============================================================================
--- incubator/cxf/trunk/distribution/src/main/release/samples/js_client/README.txt (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/js_client/README.txt Sat Jun 30 21:58:17 2007
@@ -1,24 +1,11 @@
Hello World Client Demo using JavaScript
=========================================================
+The client demo demonstrates the use of (non-browser)
+JavaScript to call a CXF server.
-The client demo demonstrates the use of the JavaScript to call CXF server
+The client side makes call by JAXWS. It uses the Mozilla Rhino library
+to read the JavaScript file and run it.
-The client side makes call by JAXWS. It use mozilla Rhino library to read
-java script file and run it.
-
-Prerequisite
-------------
-
-You should set the CXF_HOME environment to the CXF install path in
-run_client and run_client.bat files.
-
-If your environment already includes cxf-manifest-incubator.jar on the
-CLASSPATH, and the JDK and ant bin directories on the PATH.
-
-You also need to download js-1.6R5.jar from
-(http://repo1.maven.org/maven2/rhino/js/1.6R5/) and xbean-2.2.0.jar
-from (http://repo1.maven.org/maven2/xmlbeans/xbean/2.2.0/) and place
-these two jars under CXF_HOME/lib directory.
Building and running the demo server using ant
@@ -37,25 +24,22 @@
ant clean
-Running the demo using javascript
----------------------------
+Running the JavaScript client
+-----------------------------
+In another command line window, run the ant "client" target from
+the build.xml file located in the same directory as this README.
-From the samples/js_client directory run the commands, entered on a
-single command line:
-
-For UNIX (must use forward slashes):
- ./run_client.sh
-
-For Windows (may use either forward or back slashes):
- run_client.bat
+Using either UNIX or Windows:
+ ant client
-When running the client, it can terminate the server process by issuing Ctrl-C in its command window.
+When running the client, you can terminate the server process by issuing
+Ctrl-C in its command window.
-It will show the output:
+The client will show this output:
invoke sayHi(). return Bonjour
invoke greetMe(String). return Hello Jeff
-The same time, server give the output:
+The same time, the server will give this output:
[java] Executing operation sayHi
[java] Executing operation greetMe
Added: incubator/cxf/trunk/distribution/src/main/release/samples/js_client/build.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/js_client/build.xml?view=auto&rev=552244
==============================================================================
--- incubator/cxf/trunk/distribution/src/main/release/samples/js_client/build.xml (added)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/js_client/build.xml Sat Jun 30 21:58:17 2007
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-->
+<project name="js_client" default="all" basedir=".">
+ <property name="thirdparty.classpath"
+ value="../hello_world/build/classes;lib/js-1.6R5.jar;lib/xbean-2.2.0.jar"/>
+
+ <import file="../common_build.xml"/>
+
+ <target name="client" description="run demo client">
+ <cxfrun classname="org.mozilla.javascript.tools.shell.Main"
+ param1="src/helloworld.js"/>
+ </target>
+</project>
Propchange: incubator/cxf/trunk/distribution/src/main/release/samples/js_client/build.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/cxf/trunk/distribution/src/main/release/samples/js_client/build.xml
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: incubator/cxf/trunk/distribution/src/main/release/samples/js_client/build.xml
------------------------------------------------------------------------------
svn:mime-type = text/xml
Modified: incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt?view=diff&rev=552244&r1=552243&r2=552244
==============================================================================
--- incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt Sat Jun 30 21:58:17 2007
@@ -27,10 +27,6 @@
javac, and java to build and run the demos, you must set the
environment.
-You also need to download js-1.6R5.jar from
-(http://repo1.maven.org/maven2/rhino/js/1.6R5/) and xbean-2.2.0.jar
-from (http://repo1.maven.org/maven2/xmlbeans/xbean/2.2.0/) and place
-these two jars under CXF_HOME/lib directory.
Building and running the demo using ant
Re: svn commit: r552244 - in/incubator/cxf/trunk/distribution/src/main/release/samples:js_client/README.txt js_client/build.xml js_client/logging.propertiesjs_client/run_client.bat js_client/run_client.sh js_provider/README.txt
Posted by Daniel Kulp <dk...@apache.org>.
On Tuesday 03 July 2007 22:58, Glen Mazza wrote:
> Am Montag, den 02.07.2007, 10:04 -0400 schrieb Glen Mazza:
> > Yes, I see them in the lib directory after I run those commands, but
> > (pardon the simple Maven question) how does Maven know that those
> > two jars need to be downloaded? I can't see their repositories
> > listed in the pom.xml file--either the pom.xml at the trunk or the
> > one in the distribution directory.
>
> Found them--they are located in the pom.xml in the trunk/parent
> directory.
Well, not really. The stuff in parent/pom.xml is in a
dependencyManagement section. In that section, we define versions that
we want to use IF it is used elsewhere. The dependencyManagement
section doesn't actually define dependencies.
In the case of the js and xbean jars, those are actually pulled in by
rt/frontend/js/pom.xml. In the dependencies section there, it defines
a direct dependency on js and xbean. Note that that pom doesn't set
the version. The version in inherited from the dependencyManangement
section of parent/pom.xml.
If you look at distribution/pom.xml, it has a dependency on
cxf-rt-frontend-js. Since cxf-rt-frontend-js has a dependency on the
xbean and js jars, those two jars will get sucked in along with the
cxf-rt-frontend-js jar.
Hope that helps a little.
Dan
> Glen
>
> > Thanks,
> > Glen
> >
> > Am Montag, den 02.07.2007, 08:40 -0400 schrieb Jiang, Ning (Willem):
> > > Hi Glen,
> > >
> > > Yes, I am sure about it.
> > > You can build a kit with the fellowing instruction:
> > >
> > > cd trunk
> > > mvn install
> > > cd trunk/distribution
> > > mvn install
> > >
> > > You can find the two jars in the lib, when you extract the zip
> > > file in the trage directory.
> > >
> > > Willem.
--
J. Daniel Kulp
Principal Engineer
IONA
P: 781-902-8727 C: 508-380-7194
daniel.kulp@iona.com
http://www.dankulp.com/blog
RE: svn commit: r552244 -
in/incubator/cxf/trunk/distribution/src/main/release/samples:js_client/README.txt
js_client/build.xml js_client/logging.propertiesjs_client/run_client.bat
js_client/run_client.sh js_provider/README.txt
Posted by Glen Mazza <gl...@verizon.net>.
Am Montag, den 02.07.2007, 10:04 -0400 schrieb Glen Mazza:
> Yes, I see them in the lib directory after I run those commands, but
> (pardon the simple Maven question) how does Maven know that those two
> jars need to be downloaded? I can't see their repositories listed in
> the pom.xml file--either the pom.xml at the trunk or the one in the
> distribution directory.
>
Found them--they are located in the pom.xml in the trunk/parent
directory.
Glen
> Thanks,
> Glen
>
> Am Montag, den 02.07.2007, 08:40 -0400 schrieb Jiang, Ning (Willem):
> > Hi Glen,
> >
> > Yes, I am sure about it.
> > You can build a kit with the fellowing instruction:
> >
> > cd trunk
> > mvn install
> > cd trunk/distribution
> > mvn install
> >
> > You can find the two jars in the lib, when you extract the zip file in the trage directory.
> >
> > Willem.
> >
RE: svn commit: r552244 -
in/incubator/cxf/trunk/distribution/src/main/release/samples:js_client/README.txt
js_client/build.xml js_client/logging.propertiesjs_client/run_client.bat
js_client/run_client.sh js_provider/README.txt
Posted by Glen Mazza <gl...@verizon.net>.
Yes, I see them in the lib directory after I run those commands, but
(pardon the simple Maven question) how does Maven know that those two
jars need to be downloaded? I can't see their repositories listed in
the pom.xml file--either the pom.xml at the trunk or the one in the
distribution directory.
Thanks,
Glen
Am Montag, den 02.07.2007, 08:40 -0400 schrieb Jiang, Ning (Willem):
> Hi Glen,
>
> Yes, I am sure about it.
> You can build a kit with the fellowing instruction:
>
> cd trunk
> mvn install
> cd trunk/distribution
> mvn install
>
> You can find the two jars in the lib, when you extract the zip file in the trage directory.
>
> Willem.
>
>
> -----Original Message-----
> From: Glen Mazza [mailto:glen.mazza@verizon.net]
> Sent: Sun 7/1/2007 13:21
> To: cxf-dev@incubator.apache.org
> Subject: Re: svn commit: r552244 - in/incubator/cxf/trunk/distribution/src/main/release/samples:js_client/README.txt js_client/build.xml js_client/logging.propertiesjs_client/run_client.bat js_client/run_client.sh js_provider/README.txt
>
> Am Sonntag, den 01.07.2007, 04:58 +0000 schrieb ningjiang@apache.org:
> > Author: ningjiang
> > Date: Sat Jun 30 21:58:17 2007
> > New Revision: 552244
> >
> > URL: http://svn.apache.org/viewvc?view=rev&rev=552244
> > Log:
> > CXF-757 applied the patch of Glen, and removed the prerequisite of downloading the js and xmlbean jars, because we ship them in CXF distribution.
> >
>
> BTW, are you sure you include those two jars in the distribution? I
> don't see them listed here, and I *did* need to download them manually:
>
> http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/lib/WHICH_JARS?revision=531341&view=markup
>
> Glen
>
>
> > ==============================================================================
> > --- incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt (original)
> > +++ incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt Sat Jun 30 21:58:17 2007
> > @@ -27,10 +27,6 @@
> > javac, and java to build and run the demos, you must set the
> > environment.
> >
> > -You also need to download js-1.6R5.jar from
> > -(http://repo1.maven.org/maven2/rhino/js/1.6R5/) and xbean-2.2.0.jar
> > -from (http://repo1.maven.org/maven2/xmlbeans/xbean/2.2.0/) and place
> > -these two jars under CXF_HOME/lib directory.
> >
> >
> > Building and running the demo using ant
> >
> >
>
RE: svn commit: r552244 - in/incubator/cxf/trunk/distribution/src/main/release/samples:js_client/README.txt js_client/build.xml js_client/logging.propertiesjs_client/run_client.bat js_client/run_client.sh js_provider/README.txt
Posted by "Jiang, Ning (Willem)" <Ni...@iona.com>.
Hi Glen,
Yes, I am sure about it.
You can build a kit with the fellowing instruction:
cd trunk
mvn install
cd trunk/distribution
mvn install
You can find the two jars in the lib, when you extract the zip file in the trage directory.
Willem.
-----Original Message-----
From: Glen Mazza [mailto:glen.mazza@verizon.net]
Sent: Sun 7/1/2007 13:21
To: cxf-dev@incubator.apache.org
Subject: Re: svn commit: r552244 - in/incubator/cxf/trunk/distribution/src/main/release/samples:js_client/README.txt js_client/build.xml js_client/logging.propertiesjs_client/run_client.bat js_client/run_client.sh js_provider/README.txt
Am Sonntag, den 01.07.2007, 04:58 +0000 schrieb ningjiang@apache.org:
> Author: ningjiang
> Date: Sat Jun 30 21:58:17 2007
> New Revision: 552244
>
> URL: http://svn.apache.org/viewvc?view=rev&rev=552244
> Log:
> CXF-757 applied the patch of Glen, and removed the prerequisite of downloading the js and xmlbean jars, because we ship them in CXF distribution.
>
BTW, are you sure you include those two jars in the distribution? I
don't see them listed here, and I *did* need to download them manually:
http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/lib/WHICH_JARS?revision=531341&view=markup
Glen
> ==============================================================================
> --- incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt (original)
> +++ incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt Sat Jun 30 21:58:17 2007
> @@ -27,10 +27,6 @@
> javac, and java to build and run the demos, you must set the
> environment.
>
> -You also need to download js-1.6R5.jar from
> -(http://repo1.maven.org/maven2/rhino/js/1.6R5/) and xbean-2.2.0.jar
> -from (http://repo1.maven.org/maven2/xmlbeans/xbean/2.2.0/) and place
> -these two jars under CXF_HOME/lib directory.
>
>
> Building and running the demo using ant
>
>
Re: svn commit: r552244 - in
/incubator/cxf/trunk/distribution/src/main/release/samples:
js_client/README.txt js_client/build.xml js_client/logging.properties
js_client/run_client.bat js_client/run_client.sh js_provider/README.txt
Posted by Glen Mazza <gl...@verizon.net>.
Am Sonntag, den 01.07.2007, 04:58 +0000 schrieb ningjiang@apache.org:
> Author: ningjiang
> Date: Sat Jun 30 21:58:17 2007
> New Revision: 552244
>
> URL: http://svn.apache.org/viewvc?view=rev&rev=552244
> Log:
> CXF-757 applied the patch of Glen, and removed the prerequisite of downloading the js and xmlbean jars, because we ship them in CXF distribution.
>
BTW, are you sure you include those two jars in the distribution? I
don't see them listed here, and I *did* need to download them manually:
http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/lib/WHICH_JARS?revision=531341&view=markup
Glen
> ==============================================================================
> --- incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt (original)
> +++ incubator/cxf/trunk/distribution/src/main/release/samples/js_provider/README.txt Sat Jun 30 21:58:17 2007
> @@ -27,10 +27,6 @@
> javac, and java to build and run the demos, you must set the
> environment.
>
> -You also need to download js-1.6R5.jar from
> -(http://repo1.maven.org/maven2/rhino/js/1.6R5/) and xbean-2.2.0.jar
> -from (http://repo1.maven.org/maven2/xmlbeans/xbean/2.2.0/) and place
> -these two jars under CXF_HOME/lib directory.
>
>
> Building and running the demo using ant
>
>
Re: svn commit: r552244 - in
/incubator/cxf/trunk/distribution/src/main/release/samples:
js_client/README.txt js_client/build.xml js_client/logging.properties
js_client/run_client.bat js_client/run_client.sh js_provider/README.txt
Posted by Glen Mazza <gl...@verizon.net>.
Am Sonntag, den 01.07.2007, 04:58 +0000 schrieb ningjiang@apache.org:
> Author: ningjiang
> Date: Sat Jun 30 21:58:17 2007
> New Revision: 552244
>
> URL: http://svn.apache.org/viewvc?view=rev&rev=552244
> Log:
> CXF-757 applied the patch of Glen, and removed the prerequisite of downloading the js and xmlbean jars, because we ship them in CXF distribution.
>
Unfortunately, though, that creates a slight "Catch-22" problem
(although I'm still very happy that those two jars are shipped in the
distribution, as that makes it simpler for the user.)
Problem is: In the build file below, in order to take advantage of the
<cxfrun> macro, I must predefine "thirdparty.classpath" before I import
common_build.xml, which I indeed did below.
But, in my property definition of thirdparty.classpath below, I cannot
use the ${cxf.home} parameter defined in common_build.xml (which I would
need to use so I can include those two preshipped jars), because the
property definition below precedes the <import> statement.
I think what we need to do is modify line 88 of [1] below to bring in
*all* jars in the lib directory (${cxf.home}/lib/*.jar will work fine I
believe). That will naturally include the js and xmlbean jars, and
whatever other jars the other samples need. These are just samples, so
I don't think the performance hit involved with bringing in all jars
would be that important.
I'll send a patch Monday (Tuesday your time) if you can't get to this
(or think of a better solution) before then.
Regards,
Glen
[1]
http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/common_build.xml?view=annotate
> +-->
> +<project name="js_client" default="all" basedir=".">
> + <property name="thirdparty.classpath"
> + value="../hello_world/build/classes;lib/js-1.6R5.jar;lib/xbean-2.2.0.jar"/>
> +
> + <import file="../common_build.xml"/>
> +
> + <target name="client" description="run demo client">
> + <cxfrun classname="org.mozilla.javascript.tools.shell.Main"
> + param1="src/helloworld.js"/>
> + </target>
> +</project>
>