Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions

Application server instead of webserver

Posted on 2014-03-26
Last Modified: 2014-04-17

I was readign as below

Web Server

Web server contains only web or servlet container. It can be used for servlet, jsp, struts, jsf etc. It can't be used for EJB.

Example of Web Servers are: Apache Tomcat and Resin.
Application Server

Application server contains Web and EJB containers. It can be used for servlet, jsp, struts, jsf, ejb etc.

Example of Application Servers are:

    JBoss Open-source server from JBoss community.
    Glassfish provided by Sun Microsystem. Now acquired by Oracle.
    Weblogic provided by Oracle. It more secured.
    Websphere provided by IBM.

My question is if we use Application server itself that supports EJBs and Servlets etc right. Then what is the need of web server when application server is bundled to do everything.

Please advise
Any links resources ideas highly appreciated. Thanks in advance
Question by:gudii9
LVL 36

Assisted Solution

by:Loganathan Natarajan
Loganathan Natarajan earned 100 total points
ID: 39956582
Application server is for large / enterprise level application development. Web server is for small / medium level development and use.
LVL 35

Expert Comment

by:Gary Patterson
ID: 39956705
If you have an AS, then you don't need a WS.  WS is for when you don't need a full AS.
LVL 13

Assisted Solution

by:Alexander Eßer [Alex140181]
Alexander Eßer [Alex140181] earned 50 total points
ID: 39958491
Application server is for large / enterprise level application development. Web server is for small / medium level development and use.
If you have an AS, then you don't need a WS.  WS is for when you don't need a full AS.

These 2 statements are not (fully) true! Guys, where do you get this "weird" information from?!


...The primary function of a web server is to deliver web pages to clients...
MIM Survival Guide for Service Desk Managers

Major incidents can send mastered service desk processes into disorder. Systems and tools produce the data needed to resolve these incidents, but your challenge is getting that information to the right people fast. Check out the Survival Guide and begin bringing order to chaos.

LVL 12

Assisted Solution

by:Sharon Seth
Sharon Seth earned 50 total points
ID: 39958968
An AS can as well act as a WS ,but if all you need is a servlet serving webpages over the internet, then you SHOULD just use a web server . AS is bundled with more functinality than a WS , so there will be a huge difference in terms of startup time , processing time , space complexity , and not to mention licensing cost
LVL 35

Accepted Solution

Gary Patterson earned 300 total points
ID: 39959540

In the conversation above, the poster is using the term "Web Server" to refer to Tomcat and Resin - clearly meaning "less than full AS" and not "HTTP server" by the term.

The terminology is confusing - especially to someone like you who either didn't bother to read the original question, or didn't understand it very well.

So let's clarify:

A "Web Server" is a generic term, and can apply to any server that responds to requests over the web - and that usually means HTTP and HTTPS, but can also include supporting protocols like FTP, streaming audio/video, messaging, etc.  As a result, it includes a huge array of different types of server software, including HTTP servers, Servlet Containers (SC), Web Profile J2EE AS, full J2EE AS, and more.

To make things confusing, sometimes the term "Web Server" to mean "HTTP Server".  Usually if someone is distinguishing between two servers calling one the "Web Server" and the other the "Application Server", "Web Server" means "HTTP Server".

Anyway, you have to determine what "Web Server" means by context.  

It is a bad term to use in this conversation, I think, because it is not specific enough.

So, let's define our terms a little better.

HTTP Server

For this discussion, let's use the the term "HTTP Server" for "pure" web servers like Apache that focus on the HTTP/HTTPS protocols.  Main job is to serve up static content, and may also redirect requests for non-static content to a SC or AS of some sort.

Servlet Container

Next step up the web server ladder is a Servlet Container (Apache Tomcat, Jetty) - which is an HTTP server in it's own right (though not as sophisticated as a dedicated HTTP server like Apache HTTP server), plus a couple of key capabilities out of the J2EE stack:  JSP and Java servlet container.  A SC is generally used as an extension to an HTTP Server to add JSP and servlet capabilities, though it can be used on its own without a dedicated HTTP Server.

Java EE Web Profile Application Server

Next in order of increasing capabilities, are Java EE Web Profile Application Servers like Resin.  A Web Profile AS provides more J2EE functions than a Servlet Container, but less than the full J2EE stack.  Lots of Application Servers have a Web Profile mode:


Java EE Full Profile Application Server

Then we get up to full-blown "J2EE Full Profile Application Servers", like Glassfish,  WebSphere, etc.  These web servers provide HTTP serving, servlets, JSP, and the rest of the full J2EE stack.

So basically, this is a matter of "increasing, inclusive functionality".  

The full J2EE stack requires quite a bit of resources to support, so if you don't need the full stack, you can select a lesser stack that has the parts you need:  Web Profile or Servlet Container.  

If you don't need Java at all, then you can just step down to an HTTP server.

Understand, too that HTTP servers like Apache HTTP Server offer some sophisticated functions that may be harder to implement in a SC or an AS, so it is very common to see an HTTP server working in conjunction with Tomcat or an AS.  HTTP servers can also be used to offload routine tasks like serving static content to reduce demand on the larger and more expensive hardware required for an AS.  

- Gary Patterson
LVL 13

Expert Comment

by:Alexander Eßer [Alex140181]
ID: 39960041
The terminology is confusing - especially to someone like you who either didn't bother to read the original question, or didn't understand it very well.
No need to be so rude! And yes, I read the question!

Nice explanation btw, good work!

Kind regards,
LVL 35

Expert Comment

by:Gary Patterson
ID: 39960234
@Alex:  It seemed apparent from your response - you, know, the one where where you  contradicted my perfectly correct (in context) response - that you either didn't read the original question, or didn't understand the context the OP was using for the term "web server".  

"These 2 statements are not (fully) true! Guys, where do you get this "weird" information from?!"

If you want to correct a material error in something I post, please, I encourage you to do so.  And if you want to provide additional information, an alternate explanation, agree, disagree, fantastic.  I do that all the time.  

But instead of offering useful first-hand information, or perhaps an article that explains the differences between HTTP server, Servlet Container, Web Profile AS, and full profile AS, you instead chose to contradict me, and then just posted a link to a JavaWorld article that gives only one of the possible definitions for the term "web server", and then posted a wikipedia article that gives a different, broader definition!

How in the world is that useful to someone who is struggling to understand a rather complex topic?

And if you don't want a sharp reply, you might want to do it without characterizations like "weird".  I for one, don't appreciate it, and that's why you got a little jab in my response to your comment.
LVL 13

Expert Comment

by:Alexander Eßer [Alex140181]
ID: 39960281
No further questions, Your Honor.

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
custom annotations 9 42
javap bin 2 41
Opening PDF on button click and fill new document 2 47
how to see all occupied ports on windows 10 laptop 15 77
Introduction Java can be integrated with native programs using an interface called JNI(Java Native Interface). Native programs are programs which can directly run on the processor. JNI is simply a naming and calling convention so that the JVM (Java…
Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
Video by: Michael
Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question