What is the difference between jdbc and servlets




















Table of Contents. Save Article. Improve Article. Like Article. Brief Introduction: A servlet is a Java class which is used to extend the capabilities of servers that host applications accessed by means of a request-response model.

Servlets are mainly used to extend the applications hosted by webs servers, however, they can respond to other types of requests too. A JSP is a text document which contains two types of text: static data and dynamic data. Attention reader!

Designing in a servlet is difficult and slows down the application. For non-java developers, servlet is not suitable as they required to have a broad knowledge of Java servlet. HTML code is mixed up with Java code therefore, changes done in one code can affect another code. Writing HTML code in servlet programming is very difficult. It also makes servlet looks bulky. In servlet programming, if you want to use implicit objects, you need to write some additional code in order to access them.

Developers must take care of exception handling because servlet programming is not thread-safe by default. We can write the servlet code into the JSP. It is only intended for simple inclusions which can use form data and make connections. JSP is built on Java technology hence it is platform-independent and not depending on any operating systems. JSP includes the feature of multithreading of java. We can also make use of exception handling of java into JSP. It enables to separate presentation layer with the business logic layer in the web application.

It is easy for developers to show as well as process the information. It is very hard to debug or trace errors because JSP pages are first translated into servlets before the compilation process. Database connectivity is not easy. Report a Bug.

Previous Prev. Recommended Articles. Article Contributed By :. Easy Normal Medium Hard Expert. Writing code in comment? Please use ide. Load Comments. What's New. Most popular in Java Programs. Most visited in Web Technologies. Installation of Node. We use cookies to ensure you have the best browsing experience on our website.



0コメント

  • 1000 / 1000