• 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
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Tim Cooke
Sheriffs:
  • Rob Spoor
  • Liutauras Vilda
  • paul wheaton
Saloon Keepers:
  • Tim Holloway
  • Tim Moores
  • Mikalai Zaikin
  • Carey Brown
  • Piet Souris
Bartenders:
  • Stephan van Hulst

JAX-WS clarification

 
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Guys,


I have a simple question.

What chganges do one needs to make in web.xml file while using JAX-WS. I mean, recently I one example that tells you to do this(assume this web service adds two given numbers)





Is it necessary to do these changes? Because some tutorials don't tell to specify the above mentioned servlet . As an example, I deployed a sample web service project that comes with Netbeans(Calculator web service) and when I see the web.xml file I don't see the servlet mapping for com.sun.xml.ws.transport.http.servlet.WSServlet.

2. Also I see another configuration file named sun-jaxws.xml in some of the tutorials. What is this file used for? Again some examples don't use this file.

Please bear with me as I jave just started using JAX-WS implementation for web service develpoment.


Thanks and Regards,
Girish.


 
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
First of all, the servlet implementation class and the second deployment descriptor file you talk about are both specific to the GlassFish server and cannot be used with other servers.
When using JAX-WS, it is not necessary to use the web.xml deployment descriptor - rather you should rely on using annotations for configuration.
Yes, you can use the web.xml deployment descriptor but experimenting with it has caused at least me some hassle.
Thus, I recommend staying away from these files until you gain more knowledge.
I have written some about web service deployment in my SCDJWS study notes, if you are interested. They are available here on JavaRanch.
Best wishes!
 
Girish Vasmatkar
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Ivan for making things clear.

Some more questions.

Just after posting my first question in this thread I cam to know that the sun-jaxws.xml file is specific to metro project.

1.So does effectively mean that metro can not be used with other application servers or web servers other than glassfish?

2.Also how different is metro from JAX-WS?

3. I need to know where I can find your study notes as you mentioned at javaranch.

4. I have developed a simple web service using JAX-WS and I need to how can I print the actual SOAP message exchange between the client and the web service.


Thanks again for your reply.

Regards,
Girish



 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Girish Vasmatkar wrote:
1.So does effectively mean that metro can not be used with other application servers or web servers other than glassfish?


No, check this page, which says that Metry web services can, for instance, be deployed into a Tomcat web container: https://metro.dev.java.net/getting-started/basic.html


2.Also how different is metro from JAX-WS?


Another reference: https://jax-ws.dev.java.net/
As the above web page says, Metro is the reference implementation of JAX-WS. Metro does not only implement the JAX-WS specification.


3. I need to know where I can find your study notes as you mentioned at javaranch.


The latest version can be found here: http://www.javaforum.se/jforum/posts/list/549.page


4. I have developed a simple web service using JAX-WS and I need to how can I print the actual SOAP message exchange between the client and the web service.


Check section 9.5 SOAP Logging in my study notes.

Best wishes!



 
Girish Vasmatkar
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Awesome Ivan. Thank you very much again for taking out precious time for answering the questions.

I have downloaded your study notes and already started styding them.

Regards,
Girish
 
Ranch Hand
Posts: 165
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ivan,

Where are the study notes (i.e. step by step certificate installation)?

Thanks.

-Ravi
 
Ranch Hand
Posts: 234
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,

please can you give to me any exemple step by step saying e.g a hello world on JAX-WS?

bye,
AS
 
And then the flying monkeys attacked. My only defense was this tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic