aspose file tools
The moose likes Web Services and the fly likes should we create wsdl files ? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Web Services
Reply Bookmark "should we create wsdl files ?" Watch "should we create wsdl files ?" New topic
Author

should we create wsdl files ?

majid nakit
Ranch Hand

Joined: Jun 26, 2001
Posts: 160
Hi, I am new to WebServices, I just downloaded axis2 from Apache.org , in the user guide it says :
There are two methods to create services :
1)Writing Web Services Using Axis2's Primary APIs.

2)Writing Web Services by Code Generating Skeleton.

Which one is the best and the easy one ?

in the second method (Writing Web Services by Code Generating Skeleton) they are using the file Axis2SampleDocLit.wsdl , this file look little bit complicated, should we create a wsdl file like this one anytime we want to create a service.

Thank you, your help is appreciated.
Peer Reynders
Bartender

Joined: Aug 19, 2005
Posts: 2906
IMO:
  • Java-to-WSDL is the easiest to use but not recommended if you want interoperability unless your interface (and the types used in it) is extremely simple (everything has a straight forward JAX-WS Java-to-XML mapping as defined by the JAX-WS spec). Also Java-to-WSDL tends to lead to an unstable interface as the service evolves (i.e. simple interface changes may lead to a non-backward compatible client interface)
  • WSDL-to-Java is the best as you are directly designing the interface as your clients will see it. In terms of interface evolution you should be able to add optional elements later without necessarily breaking old clients.
  • Implementing against the Primary API would be the hardest and should be avoided unless you are implementing a non-standard, proprietary web service. If you can't do it with WSDL-to-Java, your clients probably won't be able to access your web service by simply "looking" at the WSDL either. However you may need access to the primary API if you want access to the Axis2 REST functionality (i.e. you are not building a SOAP Web Service).


  • 3.4.1 Designing the Interface
    [ September 06, 2006: Message edited by: Peer Reynders ]

    "Don't succumb to the false authority of a tool or model. There is no substitute for thinking."
    Andy Hunt, Pragmatic Thinking & Learning: Refactor Your Wetware p.41
    majid nakit
    Ranch Hand

    Joined: Jun 26, 2001
    Posts: 160
    Thank you for the explaination, but I found out that this wsdl files are difficult to write too .
    thanks
    Karthik Rajendiran
    Ranch Hand

    Joined: Aug 13, 2004
    Posts: 209
    Creating WSDL by typing out might be tedious. We have tools for those
    You can try capeclear SOA Editor
    or altova xmlspy suite.

    But you should know the tags in the WSDL and meaningof that..Give a try to WSDL tutorial or visit javapassion.com webservices page.


    SCJP 1.4 SCWCD 1.4 SCDJWS 1.4
     
    I agree. Here's the link: http://aspose.com/file-tools
     
    subject: should we create wsdl files ?
     
    Similar Threads
    WebServices with JBoss
    Creating webservice using Axis2
    Help Needed in java web services using axis2
    WSDL2JAVA generating all the Client code in one solid Java file
    WSDL Location in Axis2