|
|
TutorialsJini ExampleJxta Example Web Services RelatedJxtaJini Web Services For More InfoFrom P2P to Web Services and Grids: Peers in a Client/Server WorldIan J. Taylor, 2004 Publisher: Springer ISBN: 1-85233-869-5 |
Deploying a Web Service Using AxisTo deploy a service, you need to configure an Axis Web Service Deployment Descriptor (WSDD) file to describe the service you wish to deploy:
and can be downloaded here . The WSDD format contains a deployment XML element. This defines the Java namespace along with a service element, which actually defines the service. The service element may have any or all of the following:
In our case, the provider is java:RPC ,'' i.e., remote procedure caller (RPCProvider). The parameter tag specifies which class (i.e., SilverSevice) the provider should load and which methods in that class to call. Here, we specify that any public method on our class may be called. Alternatively, the accessible methods could be restricted by using a space or comma separated list of available method names. WSDD files are fairly reusable and typically only require minor modifications for use by other services, e.g., service name and class name. The WSDD description is then passed to the Axis AdminClient, which compiles a Web service based on these parameters and deploys the Web service in the appropriate place, as follows:
java -cp $AXISCLASSPATH org.apache.axis.client.AdminClient
-lhttp://localhost:8080/axis/services/AdminService deploy.wsdd
To ensure that the Web service has been installed correctly, you
can check the Web services deployed within the Axis environment
using a Web browser and navigating to the View the list of
deployed Web services option on the Axis configuration page (see
upper part of figure below). This should display
something similar to the bottom screen shot, if the service has been
deployed correctly.
|