Developing Web Services Server and Client Code using Apache Axis

org.apache.axis API

Developing Server Code and Deploying the Services

  1. cd ~/8711
  2. mkdir axis
  3. cd axis
  4. mkdir calc
  5. cd calc
  6. Write the Java Web Service; A sample Java class Calculator with two public methods add and subtract can be copied as: cp ~raj/axis/calc/Calculator.java .
  7. Compile the program: cd ..; javac calc/Calculator.java
  8. Write deployment file; Sample deployment file can be copied as: cp ~raj/axis/calc/deploy.wsdd calc/
  9. Run simple Axis server in a separate window:
    cd ~/8711/axis/
    java org.apache.axis.transport.http.SimpleAxisServer -p 15001
    Note: Please use the port assigned to you.
  10. Deploy the service:
    java org.apache.axis.client.AdminClient -p 15001 calc/deploy.wsdd
  11. Check if service is deployed:
    http://tinman.cs.gsu.edu:15001/axis/services/
    You should be able to see the service and the methods of the service and a link to the WSDL file of the service.

Developing Client Code

  1. cd ~/8711/axis
  2. Write client code; Sample client code can be copied as: cp ~raj/axis/calc/calcClient.java calc/
  3. Compile: javac calc/calcClient.java
  4. Run the client: java calc.calcClient -p 15001 add 4 5
    You should see result of 9.

Port Assignments
Badgujar15001
Brannock15002
Damani15003
Desai15004
Deshmukh15005
Frederick15006
Galgali15007
Gupta15008
Hafner15009
Helton15010
Hiremath15011
Jullapelli15012
Karmakar15013
Mathialagan15014
Mohan15015
Mohanbabu15016
Naduvilvadukootu15017
Phoungphol15018
ReyazAhmed15019
Ribadeneira15020
Sethi15021
Shaik15022
Shen15023
Singh15024
Song15025
Srivrunyoo15026
Sun15027
Tran15028
Please do not keep server running when you are done; You may kill the server with CTRL-C.