HTTP Headers
A servlet can set HTTP headers to provide extra information about its response. As we said in Chapter 4, a full discussion of all the possible HTTP 1.0 and HTTP 1.1 headers is beyond the scope of this book. Table 5.2 lists the HTTP headers that are most often set by servlets as a part of a response.
Table 5-2. HTTP Response Headers
Header |
Usage |
---|---|
|
Specifies any special treatment a caching
system should give to this document. The most common values are
|
|
The HTTP 1.0 equivalent of |
|
Used to indicate whether the server is willing to maintain an open
(persistent) connection to the client. If so, its value is set to
|
|
Specifies a time when the server can again handle requests, used with
the |
Get Java Servlet Programming now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.