Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Spring WS + wsdl + contract First

 
Prachi Pandey
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am expected to work rather consume a web service develop by 3rd party. I need to develop web service client code and I am suppose to use Spring WS. What I have now is a wsdl from them and I have to set up everything here with scratch. Can any one help me in detailing each step or process to get that done in layman language?


Thanks
Prachi
 
Jesus Angeles
Ranch Hand
Posts: 2068
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Layman's language. Try this:
1. download eclipse ide
2. create java web project, and copy the wsdl inside, e.g. webcontent folder (refresh project if needed)
3. right-click the wsdl and choose what you need like 'generate client', etc.

After a few seconds, you got a nice client ready to go.
 
Prachi Pandey
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well.. I want my ant to create those bean classes .

Thanks
Prachi
 
Jesus Angeles
Ranch Hand
Posts: 2068
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Look at wsdl to java implementations.

You can also look at Spring's JaxWsPortProxyFactoryBean.
 
Prachi Pandey
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am referring this tutorial now but it seems that Maven is pre dominantly used here. May be I need to get maven too. I am feeling that Spring WS is much more complex than Apache Axis2 or JAX-ws ...but being client requirement I have to take up Spring only

Thanks
Prachi
 
Prachi Pandey
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

How to create Java bean classes from wsdl in spring ws ? Can anyone help me ?




Thanks
Prachi
 
William P O'Sullivan
Ranch Hand
Posts: 859
Chrome IBM DB2 Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try SOAPUI.

WP
 
Prachi Pandey
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I guess I asked in complete question. I want to frame my question again..

How to create Java bean classes from wsdl using Ant in spring ws ?

Thanks
Prachi
 
William P O'Sullivan
Ranch Hand
Posts: 859
Chrome IBM DB2 Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ant is just a tool.

You need to download/install the wsdl2java application.
Then your build.xml can simply invoke it and generate your Java client components.

WP
 
Prachi Pandey
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

When you say WSDL2JAVA you are talking about Apache Axis I believe and my client's requirement is to make use of Spring WS only. Any thoughts ?

Thanks
Prachi
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic