• 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

Diff Between WebContainer and WebServer

 
Ranch Hand
Posts: 134
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
According to K&B, Apache is the WebServer and Tomcat is the container which takes care everything when a request a comes in.
But in case of SunOne Webserver which one will be container???
And if I am not wrong tomcat can be used independently as a web server.
In the above two cases will both web server and container be same???
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The term "web container" is not widely used. "Web server" and "servlet container" are more familiar.

Tomcat and SunOne can be both, while Apache is just a web server.
 
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think web server is subset of container. Please correct me If I'm wrong..Thanks
 
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Both are different things, they complement each other, but a Web Server and a Servlet container are different things, at least with the Apache HTTP Server + Tom Cat or IBM HTTP Server and Websphere Application Server, you won't want a tomcat server to serve your static content in a production enviroment. So you want to install a Web (HTTP) server for your static content and delegate the dinamic (servlet and jsp's)content to your servlet container.
 
Ulf Dittmer
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

you won't want a tomcat server to serve your static content in a production enviroment



While that once was sound advice (since Tomcat was slow serving content), that's not really the case any more, as it has become much faster. While there are other good reasons to use an Apache/Tomcat combination, this is no longer one of them. If that's the only reason you'd be using httpd in front of Tomcat, I'd reconsider that, because it does introduce architectural complexities.
 
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello


WebServer is either a software or physical box, which is mainly responsible for serving to the client. When client sends the request for something (this something is may be file, image etc.) then WebServer is responsible to find out that something and serve it back to client. In good-old days WebServer alone was able to handle/ serve client requests. As most of those requests were coming from some existing thing on the server like file or image.

With dynamic output or dyna-web scenario, client wanted to see dynamic web pages. This pages are not just static resources but also involves some computation, calculation. This computation is done by servlet container like Tomcat.

I hope this will make things little clear.

Thanks
 
satya mahapatra
Ranch Hand
Posts: 134
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Ulf, Oscar and Dhananjay for your responses. Now its quite clear what is the difference between servlet container and web server.

Thanks,
Satya
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic