• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need explainations please

 
clojure forum advocate
Posts: 3479
Mac Objective C Clojure
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all.
I know who to create and use a web service in Java.
writting the server end point interface and its implementation, then using wscompile tool to generate WSDL file and the static stubs.
consider the following situation :
we have a .NET web service in the server, and the client will be a Java client using JAX-RPC API, static stubs.
some code :

well, I just need some explainations...
1. how my Java client will get its static stub of .NET service ?
2. how my Java client will get all the available methods of the service ?
I know it is the mission of WSDL file, but I am not sure how..
more easily :
How to access a .NET web serivce in Java client ? would you mind telling me the required steps ??
thanks for help.
[ January 14, 2005: Message edited by: John Todd ]
 
author and deputy
Posts: 3150
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
from the apache axis point of view.
WDSL2Java tool will take care of all the steps and requirements...
Basically it will generate all the neccessary stubs code to access any methods listed under a wsdl file.
All u have to do is make use of that stub classes.
Guess i answered ur question... if not plz comment back.
 
Hussein Baghdadi
clojure forum advocate
Posts: 3479
Mac Objective C Clojure
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks.
please correct me if I'm wrong.
we have a web service developed using .net, the URL of this service is :
http://.netservice/ws/catalog.asmx (or what ever).
so to access this service in a Java client, we perform :
1. get the WSDL file of this .net service.
2. using wscompile tool (in case we are using SJSAS) to generate the static stubs.
3. done.
now we can use these static stubs to access the web service, right ??
 
Ranch Hand
Posts: 190
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thats right.

Remember the language the WS is written in 'shouldn't' be of concern (assuming the WS developer has adhered to some common standards.

Everything you need to know is in the WSDL - generating the stubs either by wsdl2java (axis) or wscompile (sun) is the best way but don't have to do that. You could build the call by hand.
 
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,

The biggest challenge in getting your client to go cross-platform is getting your hands on the WSDL. I just came from the other direction, trying to connect my .NET client to a Java Web Service. My biggest difficulty was trying to figure out the URL to supply for the service, which meant understanding the App Server's organizational/jar structure and puzzling out the DD's. It's much worse puzzling out .NET client/Java Web Service than Java client/.NET service.

Neither one's particularly difficult, though, once you have your hands on the URL to the service.

Once I found the URL on which to append my "?WSDL" the rest was dead easy proxy boilerplating. It should be for you too.

When you're a Java client trying to find the WSDL for the .NET service, you need to have the URL and the service ".asmx" file. With .NET, the URL is always a physical path straight to the physical ".asmx" file. There's no DD-based indirection like there is in Java.

Example:
http://localhost/myservices/myservice.asmx?WSDL

The service URL is everything up to the "?"

Doug Hoople
MCSD.NET, MCDBA, MCSE, MCT, SCJP1.4
 
Hussein Baghdadi
clojure forum advocate
Posts: 3479
Mac Objective C Clojure
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
So, to access a .net web service and get its WSDL file, we wrote :
http://localhost/myservices/myservice.asmx
??
in this way we got the WSDL file ?? I'm just curious ...
 
Doug Hoople
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi John,

http://localhost/myservices/myservice.asmx

will invoke the "blue banner" Service Description html page. You can use this as a human being to explore the structure of the Web Service.

http://localhost/myservices/myservice.asmx?WSDL

will invoke the actual WSDL file, which you can then supply to your proxy generation utility.

Doug Hoople
MCSD.NET, MCDBA, MCSE, MCT, SCJP1.4
 
I child proofed my house but they still get in. Distract them with this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic