Help coderanch get a
new server
by contributing to the fundraiser
  • 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

Question about publishing JAX-WS

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello everyone ! I have a question that I couldn't manage to fully answer myself. I am wondering what is the difference between using Endpoint.publish("some address", new SomeWebServiceClass()) and publishing it on tomcat using WAR file. I suppose the first is publishing it on Java Virtual Machine? But are there any differences in threads. How many threads can a web service that is published on tomcat using War file have ?
 
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Mike,

EndPoint.publish will bind your web service available on the mentioned port and url.
Also as like servlet for web services underlying container will have configuration set to specify max number of concurrent threads.
Ex : server.xml in tomcat.
Please try using frameworks like cxf which has implemented jax-ws and will take care of thread safety almost.

Thanks,
Kesava
 
Mike Endrow
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, I am using CXF, but I can't really distinguish both of them... Will the servlet create an instance every time a web service method is called or it will just use the same instance every time? What exactly happens when it is published. I just cant find anywhere to read about these details.
 
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Check this link http://docs.oracle.com/cd/B14099_19/web.1012/b14027/orawebservices.htm#sthref66.

Refer the section 2.4 and 2.4.3.

 
Those cherries would go best on cherry cheesecake. Don't put those cherries on this tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/t/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic