TestingDocs.com
Software Testing website
  • Automation
    • Selenium
    • JBehave Framework
  • Tutorials
    • MySQL Tutorials
    • Testlink
    • Maven
    • Git
  • IDEs
    • IntelliJ IDEA
    • Eclipse
  • Flowcharts
    • Flowgorithm
    • Raptor
  • About

Java Servlets

Java Servlet API

Overview

Servlet Technology contains both Java Servlet API and the Java Servlet Specification. Servlet technology is the technology used to develop web components capable of running on web servers/containers. Sun Microsystems developed Servlet technology to overcome the drawbacks of CGI technology( Common Gateway Interface ). Servlet technology is an integral part of J2EE component technology.

Java Servlet technology = Java Servlet API + Java Servlet Specification

The Java Servlet API contains both the classes and interfaces related to the Servlet. Servlet specification provides the rules, guidelines, and regulations to develop Servlets. The vendors will follow the Servlet Specification for providing implementations of the Servlet API.

Servlet API = Java Classes + Interfaces

J2EE Technologies

The J2EE component technologies are as follows:

  • Servlet
  • JSP(Java Server Pages)

Servlet API

A Servlet is a platform-independent Java class that runs on the server. The server-side java class provides service to the clients across the computer network. Servlets are multithreaded. The Servlet container runs multiple threads to process multiple client requests to the servlet.

 

Java Servlet API Packages

 

Servlet API consists of the following packages.

  • javax.servlet
  • javax.servlet.http

The javax.servlet package contains the interfaces and the classes that
define the contracts between the servlet class and the runtime provided by the servlet container.

The javax.servlet.http sub-package contains the interfaces and the classes that define the contracts between the servlet class that runs on HTTP protocol and the runtime provided by the servlet container.

The important interface is the Servlet interface. Any servlet class directly or indirectly implements the Servlet interface provided by the Servlet API. The Servlet interface defines the servlet lifecycle methods for creating and destroying them in the servlet container.

https://www.testingdocs.com/java-servlet-lifecycle/

—

Java Tutorials

Java Tutorial on this website:

https://www.testingdocs.com/java-tutorial/

For more information on Java, visit the official website :

https://www.oracle.com/java/

Related Posts

Java Servlets /

JSP Architecture

Java Servlets /

Java ServletRequest Interface

Model View Controller

Java Servlets /

Model View Controller( MVC )

Java Servlets /

Deployment Descriptor File (web.xml)

Java Servlets /

GenericServlet Class

‹ Java Server Pages› Java Servlet Lifecycle

Recent Posts

  • MS Access Data Types
  • Install RAPTOR Avalonia on CentOS
  • Download RAPTOR Avalonia Edition on Windows
  • npm doctor command
  • Build & Run CLion Project
  • Create New CLion C Project on Windows
  • Configure CLion Toolchains on Windows
  • Launch CLion IDE on Windows
  • Activate CLion IDE
  • CLion IDE for C/C++ Development

Back to Top

Links

  • Contact
  • Privacy Policy
  • Cookie Policy

www.TestingDocs.com

Go to mobile version