Header Ads

  • Breaking Now

    Webserivces With Apache Axis Continued...

    In continuation with my previous post,this post explores various ways of deploying a webservice using Apache Axis and how stubs can be generated with tools provided in Apache Axis.

    Deploying A Webservice:
    Web services can be deployed in axis in two ways
    -JWS (Java Web Service) Files - Instant Deployment
    -Custom Deployment - Introducing WSDD

    JWS Deployment:
    -Copy the *.java file into your web directory, and rename it *.jws.
    -You're done!
    You should now be able to access the service at the following URL (assuming your Axis web application is on port 8080):
    http://localhost:8080/axis/Calculator.jws
    Axis automatically locates the file, compiles the class, and converts SOAP calls correctly into Java invocations of your service class

    Custom Deployment - Introducing WSDD:
    Axis uses *.wsdd files to deploy Web services. This is a Axis specific format for deploying custom web services.

    Steps to Deploy a Class File as Webservice:
    -Create the class file.
    -Write a deploy.wsdd file for that class
    -Run AdminClient as follows :
    java org.apache.axis.client.AdminClient -lhttp://localhost:8080/axis deploy.wsdd
    -Done !
    Now you'll be able to view this web service wsdl file at the path
    http://localhost:8080/axis/services/MyService?wsdl

    Generating Stubs For A Web Service:
    -Run following command at the command prompt
    java org.apache.axis.wsdl.WSDL2Java -v -p -o
    Here is an exmaple
    java org.apache.axis.wsdl.WSDL2Java -v -p com.punsoft.ws.client.generated

    http://localhost:9080/WSAxis/services/HelloWorldEJBService?wsdl–o javasource/com/punsoft/ws/client/generated

    5 comments:

    1. Hi there! This blog post couldn't be written much better!
      Looking through this article reminds me of my previous roommate!
      He continually kept preaching about this. I'll send this information to him.
      Pretty sure he'll have a good read. Thanks for sharing!

      ReplyDelete
    2. Greate article. Keep writing such kind of info on your page.
      Im really impressed by it.
      Hello there, You've performed a great job. I'll certainly digg it and in my opinion suggest to my friends.
      I'm confident they will be benefited from this
      web site.

      ReplyDelete
    3. When someone writes an post he/she retains the thought of a user in his/her brain that how a user can understand it.
      Thus that's why this post is amazing. Thanks!

      ReplyDelete
    4. For latest news you have to pay a visit web and on world-wide-web I found this web page
      as a finest web page for newest updates.

      ReplyDelete
    5. If some one wishes to be updated with latest technologies afterward he must be visit this website and be up to date all the time.

      ReplyDelete

    Post Top Ad

    Post Bottom Ad