Saturday, 30 June 2012

Servlet Vs JSP


Servlet is a Java programming language class used to extend the capabilities of servers that host applications accessed via a request-response programming model.

JSP is a Java technology that helps software developers serve dynamically generated web pages based on HTML, XML or other document types.
Key CriteriaServletJSP
DefinitionServlet is a Java programming language class used to extend the capabilities of servers that host applications accessed via a request-response programming model.JavaServer Pages is a Java technology that helps software developers serve dynamically generated web pages based on HTML, XML or other document types.
Developed BySun Microsystems.Sun Microsystems.
Released OnJune 1997.JSP released on 1999.
EmbeddingServlet doesnt allow to embed java code in the HTML.JSP allows to embed java code in the HTML.
ContentServlets are Java programs that are already compiled which also creates dynamic web content.JSP is a webpage scripting language that can generate dynamic content.
PurposeServlet act as a controller. Servlet is used for bussiness logic.JSP act as a view. JSP is basically used for presentation.
SpeedServlets are faster than jsp.JSP is slower than Servlet.
ValidationClientside validation is possible in servlets.Clientside validation is not possible in JSP.

No comments:

Post a Comment