What is the difference between an application server and a web server?,Java, C ,C++, ASP, ASP.net C# ,Struts ,Questions & Answer, Struts2, Ajax, Hibernate, Swing ,JSP , Servlet, J2EE ,Core Java ,Stping, VC++, HTML, DHTML, JAVASCRIPT, VB ,CSS, interview ,questions, and answers, for,experienced, and fresher
What is the difference between an application server and a web server?

A Web server handles the HTTP protocol. When the Web server receives an HTTP request, it responds with an HTTP response, such as sending back an HTML page. it doesnt do any operations. that means franckly seaking it can serve only html files, if u ask for ASP/Servlets/Jsp page then the request will be redirected to the particular engine(incase of ASP-ASPEngine, Servlet-ServletEngine, no idea abt JSP but it should be like this only) then the engine will process the file then it gives a htm output that will be returned to the client thats what abt the webserver.

An application server exposes business logic to client applications through various protocols. While a Web server mainly deals with sending HTML for display in a Web browser, an application server provides access to business logic for use by client application programs. The application server exposes the business logic through a component API, such as the EJB (Enterprise JavaBean) component model found on J2EE (Java 2 Platform, Enterprise Edition) application servers. Application Server usually refers to a server that is able to handle the entire J2EE specification (JSP, Servlets, EJBs, etc). Most Application Servers also contain web servers.

A Web server handles the HTTP protocol. When the Web server receives an HTTP request, it responds with an HTTP response, such as sending back an HTML page. it doesnt do any operations. that means franckly seaking it can serve only html files, if u ask for ASP/Servlets/Jsp page then the request will be redirected to the particular engine(incase of ASP-ASPEngine, Servlet-ServletEngine, no idea abt JSP but it should be like this only) then the engine will process the file then it gives a htm output that will be returned to the client thats what abt the webserver.

An application server exposes business logic to client applications through various protocols. While a Web server mainly deals with sending HTML for display in a Web browser, an application server provides access to business logic for use by client application programs. The application server exposes the business logic through a component API, such as the EJB (Enterprise JavaBean) component model found on J2EE (Java 2 Platform, Enterprise Edition) application servers. Application Server usually refers to a server that is able to handle the entire J2EE specification (JSP, Servlets, EJBs, etc). Most Application Servers also contain web servers.

More interview questions and answers
What is the difference between <%@ include ...> (directive include) and ?
Can I just abort processing a JSP?
What are the parameters for service method ?
How do I prevent the output of my JSP or Servlet pages from being cached by the browser?
How to refer the \"this\" variable within a JSP page?
Can we implement an interface in JSP ?
How do I use a scriptlet to initialize a newly instantiated bean?
What are JSP Actions?
What is the difference between ServletContext and ServletConfig?
What is a Hidden Comment?
How to pass information from JSP to included JSP?
How do you pass data (including JavaBeans) to a JSP from a servlet?
How can I set a cookie?
How will you delete a cookie?
What JSP lifecycle methods we can override?
How will you include a static file in a JSP page?
How you can perform browser redirection?
Can we use ServletOutputStream object from a JSP page?
How can I invoke a JSP error page from a servlet?
How can I enable session tracking for JSP pages if the browser has disabled cookies?
How can you declare methods in your JSP page?
How can we set the inactivity period on a per-session basis?
How do you pass an init parameter to a JSP?
How can my application get to know when a HttpSession is removed?
How many cookies can one set in the response object of the servlet? Also, are there any restrictions on the size of cookies?
When a session object gets added or removed to the session, which event will get notified ?
What is URL Encoding and URL Decoding ?
What is the difference between an applet and a servlet?
What are the different web servers available name few of them?
What are the different types of ServletEngines?
What is a Session Id?
What is the use of setComment and getComment methods in Cookies ?
Why we are used setMaxAge() and getMaxAge() in Cookies ?
What is the use of setSecure() and getSecure() in Cookies ?
Is HTML page a web component?
What is the container?
What is deployment descriptor?
How can I print the stack trace of an exception from a JSP page?
Do objects stored in a HTTP Session need to be serializable? Or can it store any object?
What is the differecnce between JspWriter and PrintWriter?
How can you implement singleton pattern in servlets ?
What is the difference between an application server and a web server?
Can we implement Runnable interface from within our servlet?
Can a main() method of class be invoked in another class?
What is the difference between java command line arguments and C command line arguments?
What is the difference between == & .equals()?
What is the difference between abstract class & Interface?
What is use of static, final variable?
Examples of final class.
What is a java bean?
What is use of synchronized keyword?
What is reflect package used for & the methods of it?
What is use of serialization?
Can methods be overloaded based on the return types ?
Why do we need a finalize() method when Garbage Collection is there ?
Difference between AWT and Swing components ?
Is there any heavy weight component in Swings ?
What are the methods in Applet ?
When is init(), start() called ?
What is Exception ?
What are the ways you can handle exception ?
What is finally method in Exceptions ?
What are the types of access modifiers ?
What are the other modifiers in java ?
Is synchronized modifier ?
What is meant by polymorphism ?
What is inheritance ?
What is method Overloading ?
What is method Overriding ?
Does java support multi dimensional arrays ?
Is multiple inheritance used in Java ?
Is there any tool in java that can create reports ?
What is meant by Java ?
What is meant by a class ?
What is meant by a method ?
What are the OOPS concepts in Java ?
What is meant by encapsulation ? Explain with an example.
What is meant by inheritance ? Explain with an example.
What is mean by JVM ?
What is meant by identifiers ?
What are the different types of modifiers ?
What are the primitive data types in Java ?
What is mean by a wrapper class ?
What is Garbage collection ?
What is mean by final class, methods and variables ?
What is mean by interface ?
What is the difference between an array and a vector ?
What is singleton class ?
What is constructor ?
What is casting ?
What is the difference between final, finally and finalize ?
What is mean by packages in java?
Name 5 calsses you have used ?
Name 2 classes that can store arbitrary number of objects ?
What is the difference between java.applet.* and java.applet.Applet ?
What is a default package ?
What is anonymous class ?
What is the use of an interface ?
What is a serializable interface ?
How to prevent field from serialization ?