Servlet Lifecycle in Java

Su Suriya Ravichandran Updated 18 Nov 2026
12 min read ·Lesson 269 of 306

The servlet lifecycle in Java is the fixed sequence of steps a web container follows for every servlet: it creates one instance, calls init() once, calls service() for each request, and finally calls destroy() once. Knowing this sequence tells you where to open resources, where to handle requests, where to clean up, and why servlet fields must be thread-safe.

This lesson traces each stage with log output from Tomcat 11, shows how to load a servlet at startup and pass it settings, and ends with a servlet that loads a cache at startup, refreshes it in the background and shuts down cleanly. It builds on Java Servlet Basics.


The Five Stages of the Servlet Lifecycle

StageMethodCalledTypical work
1. Load and instantiateConstructorOnceNothing heavy; the container controls timing
2. Initializeinit()Once, before any requestRead settings, open pools, load caches
3. Handle requestsservice() → doGet, doPost, ...Once per request, on many threadsRead the request, write the response
4. Take out of servicedestroy()Once, at undeploy or shutdownClose resources, stop background threads
5. Garbage collection—When the JVM decidesNothing to do
       deploy or first request
                │
                ▼
   ┌────────────────────────┐
   │ new MyServlet()        │   once
   └───────────┬────────────┘
               ▼
   ┌────────────────────────┐
   │ init(ServletConfig)    │   once
   └───────────┬────────────┘
               ▼
   ┌────────────────────────┐ ◄── request 1 (thread A)
   │ service(req, resp)     │ ◄── request 2 (thread B)
   │   → doGet / doPost ... │ ◄── request 3 (thread A)
   └───────────┬────────────┘
               ▼  undeploy / shutdown
   ┌────────────────────────┐
   │ destroy()              │   once
   └────────────────────────┘

How it works:

  • The container creates one instance per servlet declaration, not one per request. All requests share it.
  • service() is never called before init() finishes, and never called again after destroy() starts.

Watch the Servlet Lifecycle in Action

This servlet prints a line at every stage, so you can see when the container calls each method.

package com.gocourse.portal;

import jakarta.servlet.ServletException;
import jakarta.servlet.annotation.WebServlet;
import jakarta.servlet.http.HttpServlet;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.concurrent.atomic.AtomicInteger;

@WebServlet("/lifecycle")
public class LifecycleServlet extends HttpServlet {

    private final AtomicInteger requestCount = new AtomicInteger();

    public LifecycleServlet() {
        System.out.println("1. constructor  thread=" + Thread.currentThread().getName());
    }

    @Override
    public void init() throws ServletException {
        System.out.println("2. init()       thread=" + Thread.currentThread().getName());
    }

    @Override
    protected void doGet(HttpServletRequest request, HttpServletResponse response)
            throws IOException {
        int number = requestCount.incrementAndGet();
        System.out.println("3. doGet() #" + number + "  thread=" + Thread.currentThread().getName());
        response.setContentType("text/plain;charset=UTF-8");
        response.getWriter().println("Request number " + number);
    }

    @Override
    public void destroy() {
        System.out.println("4. destroy()    after " + requestCount.get() + " requests");
    }
}

Run Tomcat in the foreground, deploy the WAR, send three requests, then delete the WAR:

$CATALINA_HOME/bin/catalina.sh run          # terminal 1
cp target/student-portal.war $CATALINA_HOME/webapps/       # terminal 2
for i in 1 2 3; do curl -s http://localhost:8080/student-portal/lifecycle; done
rm $CATALINA_HOME/webapps/student-portal.war

Output in terminal 1 (Tomcat log lines removed):

1. constructor  thread=http-nio-8080-exec-1
2. init()       thread=http-nio-8080-exec-1
3. doGet() #1  thread=http-nio-8080-exec-1
3. doGet() #2  thread=http-nio-8080-exec-2
3. doGet() #3  thread=http-nio-8080-exec-3
4. destroy()    after 3 requests

Output in terminal 2:

Request number 1
Request number 2
Request number 3

How it works:

  • Nothing is printed at deployment. By default the container creates the servlet lazily, on the first request that maps to it.
  • The constructor and init() run on the thread of that first request, which therefore takes a little longer.
  • Each request may run on a different worker thread (exec-1, exec-2, ...), but it is always the same object, so requestCount keeps growing.
  • Removing the WAR undeploys the app, and the container calls destroy() once.

Load a Servlet at Startup With loadOnStartup

Slow work in init(), such as loading a large file, makes the first user wait. loadOnStartup tells the container to create and initialize the servlet while the app deploys.

@WebServlet(urlPatterns = "/report", loadOnStartup = 1)
public class ReportServlet extends HttpServlet {

    @Override
    public void init() {
        long start = System.nanoTime();
        // Simulate loading report templates
        try { Thread.sleep(800); } catch (InterruptedException e) { Thread.currentThread().interrupt(); }
        System.out.printf("ReportServlet ready in %d ms on %s%n",
                (System.nanoTime() - start) / 1_000_000, Thread.currentThread().getName());
    }

    @Override
    protected void doGet(HttpServletRequest request, HttpServletResponse response)
            throws IOException {
        response.getWriter().println("Report service is running");
    }
}

Output in the Tomcat terminal during deployment, before any request:

ReportServlet ready in 801 ms on Catalina-utility-1
loadOnStartup valueBehaviour
Not set or negativeLoad lazily on the first request
0 or positiveLoad during deployment
Lower numberLoaded earlier than servlets with higher numbers

How it works:

  • The init now runs on Tomcat's deployment thread (Catalina-utility-1), not on a request thread.
  • In web.xml the same setting is <load-on-startup>1</load-on-startup> inside <servlet>.
  • If init() fails at startup, you see the error in the deployment log right away, instead of when a user first visits.

init() vs init(ServletConfig)

GenericServlet, the parent of HttpServlet, has two init methods. The container calls init(ServletConfig), which saves the config and then calls the no-argument init().

OverrideMust call super?getServletConfig() works?
init()NoYes
init(ServletConfig config)Yes, super.init(config)Only if super.init(config) was called
@WebServlet("/broken")
public class BrokenInitServlet extends HttpServlet {

    @Override
    public void init(jakarta.servlet.ServletConfig config) {
        // Missing super.init(config)!
        System.out.println("Servlet name: " + config.getServletName());
    }

    @Override
    protected void doGet(HttpServletRequest request, HttpServletResponse response)
            throws IOException {
        // getServletConfig() returns null, so getServletName() throws an exception
        response.getWriter().println("Hello from " + getServletName());
    }
}
curl -s -o /dev/null -w "%{http_code}\n" http://localhost:8080/student-portal/broken

Output:

500

How it works:

  • getServletName(), getInitParameter() and getServletContext() all read the saved config. Without super.init(config) it is null, so the first call throws an exception (IllegalStateException or NullPointerException, depending on the API version) and the client gets 500.
  • Overriding the no-argument init() avoids this problem completely, so prefer it.

Pass Settings With Servlet Init Parameters

Init parameters are name–value settings given to one servlet. Read them in init(), so the servlet is configured before the first request.

@WebServlet(
    urlPatterns = "/greeting",
    initParams = {
        @WebInitParam(name = "greeting", value = "Welcome to GOCOURSE"),
        @WebInitParam(name = "maxNameLength", value = "20")
    })
public class GreetingServlet extends HttpServlet {

    private String greeting;
    private int maxNameLength;

    @Override
    public void init() throws ServletException {
        greeting = getInitParameter("greeting");
        try {
            maxNameLength = Integer.parseInt(getInitParameter("maxNameLength"));
        } catch (NumberFormatException e) {
            throw new ServletException("maxNameLength must be a number", e);
        }
    }

    @Override
    protected void doGet(HttpServletRequest request, HttpServletResponse response)
            throws IOException {
        String name = request.getParameter("name");
        if (name == null || name.isBlank()) name = "learner";
        if (name.length() > maxNameLength) name = name.substring(0, maxNameLength);
        response.setContentType("text/plain;charset=UTF-8");
        response.getWriter().println(greeting + ", " + name + "!");
    }
}
curl "http://localhost:8080/student-portal/greeting?name=Asha"
curl "http://localhost:8080/student-portal/greeting?name=AVeryVeryLongStudentName"

Output:

Welcome to GOCOURSE, Asha!
Welcome to GOCOURSE, AVeryVeryLongStudent!

How it works:

  • @WebInitParam sets default values. A <servlet> entry with the same name in web.xml can override them with <init-param> without recompiling.
  • The fields are written once in init() and only read afterwards. Because init() finishes before any request runs, all request threads see the values safely.
  • Throwing ServletException from init() stops the servlet from entering service, so a bad setting is caught early.

Application-Wide Startup With ServletContextListener

init() and destroy() belong to one servlet. For work that the whole application needs, such as a shared connection pool, use a ServletContextListener. It runs before any servlet is initialized and after every servlet is destroyed.

package com.gocourse.portal;

import jakarta.servlet.ServletContextEvent;
import jakarta.servlet.ServletContextListener;
import jakarta.servlet.annotation.WebListener;
import java.time.Instant;

@WebListener
public class AppStartupListener implements ServletContextListener {

    @Override
    public void contextInitialized(ServletContextEvent event) {
        event.getServletContext().setAttribute("startedAt", Instant.now());
        System.out.println("App started: " + event.getServletContext().getContextPath());
    }

    @Override
    public void contextDestroyed(ServletContextEvent event) {
        System.out.println("App stopped: " + event.getServletContext().getContextPath());
    }
}

Output in the Tomcat terminal for a deploy, one request to /lifecycle, and an undeploy:

App started: /student-portal
ReportServlet ready in 801 ms on Catalina-utility-1
1. constructor  thread=http-nio-8080-exec-1
2. init()       thread=http-nio-8080-exec-1
3. doGet() #1  thread=http-nio-8080-exec-1
4. destroy()    after 1 requests
App stopped: /student-portal
ScopeStartup hookShutdown hook
One servletinit()destroy()
Whole web appcontextInitialized()contextDestroyed()

How it works:

  • @WebListener registers the class, just like @WebServlet registers a servlet.
  • Attributes stored on the ServletContext are visible to every servlet: getServletContext().getAttribute("startedAt").
  • The listener starts first and stops last, so resources it opens are available for the entire life of every servlet.

One Instance, Many Threads: Keeping Servlets Thread-Safe

Because one servlet object serves all requests at the same time, any instance field that a request changes is shared data. Unsafe fields lead to the lost updates described in Java Thread Safety.

@WebServlet("/counter")
public class CounterServlet extends HttpServlet {

    private int unsafeCount = 0;                             // shared, not thread-safe
    private final AtomicInteger safeCount = new AtomicInteger();

    @Override
    protected void doGet(HttpServletRequest request, HttpServletResponse response)
            throws IOException {
        unsafeCount++;                                       // read-modify-write race
        safeCount.incrementAndGet();                         // atomic
        response.getWriter().println(unsafeCount + " " + safeCount.get());
    }
}

Send 2,000 requests at the same time with virtual threads:

// LoadTest.java
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.util.concurrent.Executors;

public class LoadTest {
    public static void main(String[] args) throws Exception {
        HttpClient client = HttpClient.newHttpClient();
        HttpRequest request = HttpRequest.newBuilder(
                URI.create("http://localhost:8080/student-portal/counter")).build();

        try (var executor = Executors.newVirtualThreadPerTaskExecutor()) {
            for (int i = 0; i < 2000; i++) {
                executor.submit(() -> client.send(request, HttpResponse.BodyHandlers.discarding()));
            }
        }   // waits for all requests to finish

        System.out.print("unsafe safe = ");
        System.out.print(client.send(request, HttpResponse.BodyHandlers.ofString()).body());
    }
}

Output (the first number changes from run to run):

unsafe safe = 1987 2001

How it works:

  • unsafeCount++ reads, adds and writes in three steps. When two threads do this at once, one update is lost, so the unsafe count ends below 2,001.
  • AtomicInteger.incrementAndGet() does the same in one indivisible step, so it always reaches 2,001 (2,000 test requests plus the final one).
  • Local variables inside doGet are safe, because each thread gets its own copy. Keep per-request data in local variables and treat fields as shared.

Note: Do not add synchronized to doGet to fix this. It forces every request to wait in line and removes the benefit of the container's thread pool.


Handle a Failed init With UnavailableException

If a servlet cannot start, for example because a required file is missing, init() should throw an exception. UnavailableException lets you say whether the problem is permanent or temporary.

@WebServlet(urlPatterns = "/rates", loadOnStartup = 2)
public class RatesServlet extends HttpServlet {

    @Override
    public void init() throws ServletException {
        try {
            if (getServletContext().getResource("/WEB-INF/rates.csv") == null) {
                // Temporary: tell clients to retry in 60 seconds
                throw new UnavailableException("rates.csv not uploaded yet", 60);
            }
        } catch (MalformedURLException e) {
            throw new ServletException("Bad resource path", e);
        }
    }

    @Override
    protected void doGet(HttpServletRequest request, HttpServletResponse response)
            throws IOException {
        response.getWriter().println("Rates loaded");
    }
}
curl -s -o /dev/null -w "%{http_code}\n" http://localhost:8080/student-portal/rates

Output:

503

How it works:

  • An exception from init() means the servlet never enters service, and destroy() is not called for it, because it was never initialized.
  • For a temporary UnavailableException, the Servlet specification requires the container to answer 503 Service Unavailable. The container tries init() again later.
  • new UnavailableException("message") without seconds marks the servlet permanently unavailable.

Real-World Example: Servlet Lifecycle in Java for a Cached Course Catalog

This servlet loads a course catalog from WEB-INF/courses.csv during init(), reloads it in the background every few minutes, serves requests from memory, and stops its background thread in destroy().

# src/main/webapp/WEB-INF/courses.csv
java,Java Tutorial,306
python,Python Tutorial,120
go,Go Language,90
package com.gocourse.portal;

import jakarta.servlet.ServletException;
import jakarta.servlet.annotation.WebInitParam;
import jakarta.servlet.annotation.WebServlet;
import jakarta.servlet.http.HttpServlet;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.nio.charset.StandardCharsets;
import java.util.Collections;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicLong;

@WebServlet(
    urlPatterns = "/catalog/*",
    loadOnStartup = 1,
    initParams = {
        @WebInitParam(name = "catalogFile", value = "/WEB-INF/courses.csv"),
        @WebInitParam(name = "refreshMinutes", value = "5")
    })
public class CatalogServlet extends HttpServlet {

    record Course(String code, String title, int lessons) {}

    // volatile: request threads always see the latest map that the refresher published
    private volatile Map<String, Course> catalog = Map.of();
    private final AtomicLong requestsServed = new AtomicLong();
    private ScheduledExecutorService refresher;
    private String catalogFile;

    @Override
    public void init() throws ServletException {
        catalogFile = getInitParameter("catalogFile");
        long refreshMinutes = Long.parseLong(getInitParameter("refreshMinutes"));

        reloadCatalog();                       // fail deployment if the first load fails
        log("Loaded " + catalog.size() + " courses from " + catalogFile);

        refresher = Executors.newSingleThreadScheduledExecutor(task -> {
            Thread thread = new Thread(task, "catalog-refresher");
            thread.setDaemon(true);
            return thread;
        });
        refresher.scheduleAtFixedRate(() -> {
            try {
                reloadCatalog();
            } catch (ServletException e) {
                log("Refresh failed, keeping previous catalog", e);
            }
        }, refreshMinutes, refreshMinutes, TimeUnit.MINUTES);
    }

    @Override
    protected void doGet(HttpServletRequest request, HttpServletResponse response)
            throws IOException {
        requestsServed.incrementAndGet();
        Map<String, Course> snapshot = catalog;          // read the field once per request
        response.setContentType("text/plain;charset=UTF-8");

        String pathInfo = request.getPathInfo();          // null or "/java"
        if (pathInfo == null || pathInfo.equals("/")) {
            snapshot.values().forEach(course ->
                    response.getWriter().println(course.code() + " - " + course.title()));
            return;
        }
        Course course = snapshot.get(pathInfo.substring(1));
        if (course == null) {
            response.sendError(HttpServletResponse.SC_NOT_FOUND, "Unknown course");
            return;
        }
        response.getWriter().println(course.title() + " has " + course.lessons() + " lessons");
    }

    @Override
    public void destroy() {
        if (refresher != null) {
            refresher.shutdownNow();                       // stop the background thread
        }
        log("Catalog servlet stopped after serving " + requestsServed.get() + " requests");
    }

    private void reloadCatalog() throws ServletException {
        try (InputStream input = getServletContext().getResourceAsStream(catalogFile)) {
            if (input == null) {
                throw new ServletException("Catalog file not found: " + catalogFile);
            }
            Map<String, Course> fresh = new LinkedHashMap<>();
            BufferedReader reader = new BufferedReader(new InputStreamReader(input, StandardCharsets.UTF_8));
            String line;
            while ((line = reader.readLine()) != null) {
                if (line.isBlank() || line.startsWith("#")) continue;
                String[] parts = line.split(",");
                fresh.put(parts[0], new Course(parts[0], parts[1], Integer.parseInt(parts[2].trim())));
            }
            catalog = Collections.unmodifiableMap(fresh);  // publish a read-only snapshot
        } catch (IOException | RuntimeException e) {
            throw new ServletException("Cannot load " + catalogFile, e);
        }
    }
}

Deploy, call it, then undeploy:

cp target/student-portal.war $CATALINA_HOME/webapps/
curl -s http://localhost:8080/student-portal/catalog
curl -s http://localhost:8080/student-portal/catalog/java
curl -s -o /dev/null -w "%{http_code}\n" http://localhost:8080/student-portal/catalog/rust
rm $CATALINA_HOME/webapps/student-portal.war
grep CatalogServlet $CATALINA_HOME/logs/localhost.*.log

Output:

java - Java Tutorial
python - Python Tutorial
go - Go Language
Java Tutorial has 306 lessons
404
... INFO [Catalina-utility-1] ... CatalogServlet: Loaded 3 courses from /WEB-INF/courses.csv
... INFO [Catalina-utility-2] ... CatalogServlet: Catalog servlet stopped after serving 3 requests

How it works:

  1. Startup work in init(). loadOnStartup = 1 loads the catalog while the app deploys. If the file is missing, init() throws and the error appears in the deployment log, before users arrive.
  2. Settings from init parameters. The file path and refresh interval come from @WebInitParam, so operations staff can change them in web.xml without touching code.
  3. Safe sharing between threads. The background thread builds a new map and publishes it with one write to a volatile field. Request threads read that field once and work with an immutable snapshot, so they never see a half-loaded catalog and need no locks. The map is never changed after it is published, so the read-only wrapper is safe to share.
  4. Cleanup in destroy(). shutdownNow() stops the refresher thread. Without it, the thread would keep the old class loader alive after undeploy, causing a memory leak that Tomcat reports as "appears to have started a thread ... but has failed to stop it".
  5. Container logging. log(...) writes to the container's log (localhost.<date>.log in Tomcat) with the servlet's name, which is easier to search than System.out. The snapshot wraps a LinkedHashMap, so courses print in file order. Reading request data such as getPathInfo() in more detail is the topic of HttpServletRequest in Java.

0 Comments

Reviewed before they appear

No comments yet.

Java
Java Introduction Java Features Java Syntax Java Comments Java Statements Java Output Java Variables Java Data Types Java Type Casting Java Operators Java Strings Java Numbers Java Math Java Booleans Java User Input Java Conditions Java If Else Java Switch Java While Loop Java For Loop Java Break Java Continue Java Arrays Java Methods Java Parameters Java Return Values Java Scope Java Recursion Install Java Install JDK Java IDEs Java JDK Java JRE Java JVM Java Compiler Java File Compile Java Run Java JShell Basics Java Packages Java OOP Java Classes Java Objects Class Methods Constructors Constructor Overload this Keyword static Keyword final Keyword Encapsulation Inheritance Polymorphism Abstraction Access Modifiers super Keyword Method Overload Method Override Instanceof Operator Nested Classes Inner Classes Anonymous Classes Enums Records Array Basics Array Length Loop Arrays Multidimensional Arrays Array Copy Array Sorting Array Search ArrayList LinkedList HashSet TreeSet HashMap TreeMap Queue Interface Deque Interface Stack Class Iterator List Interface Set Interface Map Interface Collections Class Comparable Comparator Generics Basics Generic Classes Generic Methods Wildcards String Basics String Length String Methods String Concatenation String Compare String Search String Replace String Split String Format StringBuilder StringBuffer Text Blocks Regular Expressions Number Types Integer Class Float Class Double Class BigInteger BigDecimal Math Class Random Numbers Number Format Date Basics LocalDate LocalTime LocalDateTime ZonedDateTime Date Formatting Date Parsing Period Class Duration Class Java Instant Class Java Exception Basics Java try...catch Java Multiple Catch Blocks Java finally Block Java throw Keyword Java throws Keyword Java Checked Exceptions Java Unchecked Exceptions Java Custom Exceptions Java try-with-resources Java Exception Chaining Java File Basics Java Create Files Java Read Files Java Write Files Java Delete Files Java File Paths Java File Class Java BufferedReader Java BufferedWriter Java FileInputStream Java FileOutputStream Java Object Streams Java Directory Handling Java NIO Basics Java Files API Java Input Java Scanner Class Java Console Input Java PrintStream Java InputStream Java OutputStream Java Reader Class Java Writer Class Java Buffered Streams Java Data Streams Java Generics Introduction Java Generic Types Java Generic Methods Java Bounded Types Java Wildcards Java Type Erasure Java Generic Interfaces Java Generic Collections Java Lambda Basics Java Lambda Syntax Java Functional Interfaces Java Method References Java Stream API Java Stream Creation Java Stream Filter Java Stream Map Java Stream Reduce Java Stream Sort Java Stream Collect Java Collectors Class Java Optional Class Java Parallel Streams Java Threads: Thread Basics Create a Thread in Java Java Thread Class Java Runnable Interface Java Thread States Java Thread Sleep Java Thread Join Java Thread Priority Java Synchronization Java Thread Safety Java Race Conditions Java Deadlocks Java Executor Service Java Thread Pools Java Callable Interface Java Future Interface Java CompletableFuture Java Concurrent Collections Java Atomic Classes Java Virtual Threads Java Networking Basics Java URL Class Java URI Class Java HttpClient Java HTTP Requests Java HTTP Responses Java Socket Basics Java ServerSocket Java DatagramSocket Java WebSocket Basics Java JDBC Basics Java JDBC Setup Java Database Connection Java JDBC Connection Interface Java JDBC Statement Java PreparedStatement Java ResultSet Java JDBC CRUD Operations Java JDBC Transactions Java JDBC Batch Update Java Connection Pooling with HikariCP Java JPA Basics: Entities, EntityManager and JPQL Java Hibernate Basics: SessionFactory, Session and HQL Package in Java: Basics Explained with Examples Create Package in Java: Step-by-Step Guide with Examples Import Package in Java: The import Statement Explained Access Control in Java: Packages, Classes and Members JAR File in Java: Create, Run and Inspect JAR Files Java Modules: Introduction to the Java Module System module-info in Java: Every Module Directive Explained Java Module Path: How --module-path Finds Your Modules Java Classpath: How -cp and CLASSPATH Find Your Classes Java Annotations: Basics of @ Metadata in Java Java Built-in Annotations: @Override, @Deprecated and More Java Custom Annotations: Create Your Own @interface Java Annotation Targets: @Target and ElementType Explained Java Reflection API: Inspect and Use Classes at Runtime Java Class Metadata: Names, Modifiers, Hierarchy and Generic Java Dynamic Objects: Create Objects Dynamically With Reflec Java Dynamic Proxy: Intercept Method Calls With Proxy and In Java Security Java Secure Coding Java Password Hashing Java Input Validation Java Cryptography Basics Java KeyStore Basics Java TLS Basics Java SecureRandom Java JUnit Basics Java JUnit Test Methods JUnit Assertions JUnit Test Fixtures JUnit Parameterized Tests Mockito in Java Java Mock Objects Java Integration Testing Java Code Coverage Maven in Java Create a Maven Project in Java Maven Dependencies Maven Plugins Gradle in Java Gradle Build Gradle Dependencies Build Executable JAR in Java Build WAR File in Java HTTP Basics in Java Java Servlet Basics Servlet Lifecycle in Java HttpServletRequest in Java HttpServletResponse in Java JSP in Java JSTL in JSP REST API in Java JSON in Java Java Web Application Spring Framework Basics Spring Boot Tutorial Spring MVC Spring Data JPA Spring Security Spring Boot REST API Jakarta EE Basics Java Deployment JAR Deployment Java WAR Deployment Run Java as a Service Docker Java: Dockerize a Java Application Java Environment Variables and Configuration Java Logging Basics Java Production Setup Java JVM Options Java JVM Monitoring Java Hello World App Java Calculator App Java Number Guess Game Java Student Manager Java Library System Java Bank App Java Todo App Java File Manager Java Quiz App Java REST API Project Java Chat Server Java Employee Manager Java E-commerce API
Ask about this post
AI Ask about this post

Ask questions about Servlet Lifecycle in Java and get answers drawn from it.

Signed-in readers only.