Sun GlassFish Enterprise Server 2.1 Administration Reference

Properties

The following table describes properties for the http-listener element. Any of these properties can be defined as an http-service property, so that it applies to all http-listener elements.

Table 1–72 http-listener Properties

Property 

Default 

Description 

recycle-objects

true

If true, recycles internal objects instead of using the VM garbage collector.

reader-threads

0

Specifies the number of reader threads, which read bytes from the non-blocking socket. 

acceptor-queue-length

4096

Specifies the length of the acceptor thread queue. Once full, connections are rejected. 

reader-queue-length

4096

Specifies the length of the reader thread queue. Once full, connections are rejected. 

use-nio-direct-bytebuffer

true

If true, specifies that the NIO direct ByteBuffer is used. In a limited resource environment, it might be faster to use non-direct Java's ByteBuffer by setting a value of false.

authPassthroughEnabled

false

If true, indicates that this http-listener element receives traffic from an SSL-terminating proxy server. Overrides the authPassthroughEnabled property of the parent http-service element.

proxyHandler

com.sun.enterprise.web.ProxyHandlerImpl

Specifies the fully qualified class name of a custom implementation of the com.sun.appserv.ProxyHandler abstract class that this http-listener uses.

Only used if the authPassthroughEnabled property of this http-listener and the parent http-service element are both set to true. Overrides the proxyHandler property of the parent http-service element.

proxiedProtocol

none 

Specifies a comma-separated list of protocols that can use the same port. Allowed values are ws/tcp (SOAP over TCP), http, https and tls.

For example, if you set this property to http,https and set the port to 4567, you can access the port with either http://host:4567/ or https://host:4567/.

Specifying this property at the http-service level overrides settings at the http-listener level. If this property is not set at either level, this feature is disabled.

bufferSize

4096

Specifies the size, in bytes, of the buffer to be provided for input streams created by HTTP listeners. 

connectionTimeout

30

Specifies the number of seconds HTTP listeners wait, after accepting a connection, for the request URI line to be presented. 

maxKeepAliveRequests

250

Specifies the maximum number of HTTP requests that can be pipelined until the connection is closed by the server. Set this property to 1 to disable HTTP/1.0 keep-alive, as well as HTTP/1.1 keep-alive and pipelining.

traceEnabled

true

If true, enables the TRACE operation. Set this property to false to make the Enterprise Server less susceptible to cross-site scripting attacks.

cometSupport

false

If true, enables Comet support for this listener.

If your servlet or JSP page uses Comet technology, make sure it is initialized when the Enterprise Server starts up by adding the load-on-startup element to your web.xml file. For example:

<servlet>
   <servlet-name>CheckIn</servlet-name>
   <servlet-class>CheckInServlet</servlet-class>
   <load-on-startup>0</load-on-startup>
</servlet>

compression

off

Specifies use of HTTP/1.1 GZIP compression to save server bandwidth. Allowed values are: 

  • off – Disables compression.

  • on – Compresses data.

  • force – Forces data compression in all cases.

  • positive integer – Specifies the minimum amount of data required before the output is compressed.

If the content-length is not known, the output is compressed only if compression is set to on or force.

compressableMimeType

text/html,text/xml,text/plain

Specifies a comma-separated list of MIME types for which HTTP compression is used. 

noCompressionUserAgents

empty String (regexp matching disabled)

Specifies a comma-separated list of regular expressions matching user-agents of HTTP clients for which compression should not be used. 

minCompressionSize

none 

Specifies the minimum size of a file when compression is applied. 

crlFile

none 

Specifies the location of the Certificate Revocation List (CRL) file to consult during SSL client authentication. This can be an absolute or relative file path. If relative, it is resolved against domain-dir. If unspecified, CRL checking is disabled.

trustAlgorithm

none  

Specifies the name of the trust management algorithm (for example, PKIX) to use for certification path validation.

trustMaxCertLength

5

Specifies the maximum number of non-self-issued intermediate certificates that can exist in a certification path. This property is considered only if trustAlgorithm is set to PKIX. A value of zero implies that the path can only contain a single certificate. A value of -1 implies that the path length is unconstrained (there is no maximum). Setting a value less than -1 causes an exception to be thrown.

disableUploadTimeout

true

if false, the connection for a servlet that reads bytes slowly is closed after the connectionUploadTimeout is reached.

connectionUploadTimeout

5

Specifies the timeout for uploads. Applicable only if disableUploadTimeout is set to false.

uriEncoding

UTF-8

Specifies the character set used to decode the request URIs received on this HTTP listener. Must be a valid IANA character set name. Overrides the uriEncoding property of the parent http-service element.

maxPostSize

4096

Specifies the maximum size in bytes of the body of a POST request. POST requests greater than this size are rejected. A value of zero means the maximum post size is unlimited.