Hitachi

uCosminexus Application Server Compatibility Guide


6.5.2 Execution environment settings (J2EE server settings)

To control the number of concurrent connections from the Web client, you must set a J2EE server.

The setting method and example of controlling the number of concurrent connections from the Web client are described here.

Organization of this subsection

(1) How to set

Specify the definition for controlling the number of concurrent connections from the Web client in the following parameter in the <configuration> tag of the logical J2EE server (j2ee-server), in the Easy Setup definition file:

webserver.connector.inprocess_http.rejection_threads

Specifies the number of requests for which connection is rejected.

For details on the Easy Setup definition file and parameters to specify, see Part 3 Reference (V9 Compatibility Mode).

Important note

When displaying a page with a frame or a page with an image inserted, multiple requests might be received from the Web client. In this case, the pages displayed by the controlling of the number of concurrent connections from the Web client might result in partial errors.

(2) Example settings

The example of settings for controlling the number of concurrent connections from the Web client is described here.

The following is an example of settings wherein the upper limit of number of request processing threads is 40 and the number of request processing threads for which the connection is rejected is 1:

...
<param>
  <param-name>webserver.connector.inprocess_http.max_connections</param-name>
  <param-value>40</param-value>
</param>
<param>
  <param-name>webserver.connector.inprocess_http.rejection_threads</param-name>
  <param-value>1</param-value>
</param>
...

In this example, the number of Web clients that can process requests concurrently after connection is 39. If the number of threads that are processing requests reaches 39, the remaining 1 thread keeps returning error to the Web client.

By controlling the number of concurrent connections from the Web client, an error of the status code 503 (Service Unavailable) is returned to the Web client for the requests for which connection is rejected. At this time if you customize the error page returned to the client, you can customize the response message or redirect to another server. The following are the setting examples for each of these cases. For details on customizing the error page, see 6.15 Error page customization (In-process HTTP server).