8.3.4 Controlling the number of concurrent executions of a Web application

In the case of a Web front-end system, the control of concurrently executed threads of a Web Application controls the number of threads in which the Web server will concurrently process the requests received from clients like the Web browser.

The number of concurrent executions is controlled in each URL group, Web application or Web container. The number of concurrently executed threads can be controlled when you integrate with a Web server, or when you use an in-process HTTP server.

Organization of this subsection
(1) Difference in the control of number of concurrently executed threads
(2) Guidelines for selection

(1) Difference in the control of number of concurrently executed threads

The difference in the control of the number of concurrently executed threads in the case of each Web container, Web application and URL group is explained below:

Web container
You can set the number of threads for simultaneous processing of requests in the entire Web container.
Web application
You can set the number of threads for simultaneous processing of requests for each Web application running in the Web container.
URL group
You can set the number of threads for simultaneous processing of requests for each process of distribution destination URL, when a request is distributed to a URL corresponding to the specific business process (business logic) in the Web application.

The figure below illustrates the relationship between concurrently executed threads of each Web container, Web application, and URL group.

Figure 8-4 Relationship between concurrently executed threads of each Web container, Web application, and URL group

[Figure]

The execution of requests for a Web application is controlled by the number of concurrently executed threads set in each Web container, Web application, and URL group. A request that exceeds the number of concurrently executed threads that are set in each Web container, Web application, and URL group enters the respective pending queue.

(2) Guidelines for selection

The guidelines for selecting the unit of control for concurrently executed threads are explained below:

For details about the functionality for controlling the number of concurrently executed threads, see 2.15 Overview of control over the number of concurrently executed threads in the uCosminexus Application Server Web Container Functionality Guide.

Guidelines for selecting a Web application

The J2EE server can manage not only the TCP connection requests but also the pending queue of the Web applications by controlling the number of concurrently executed threads of the Web application. Therefore, Hitachi recommends setting a number of concurrently executed threads of a Web application even when a single Web application is running on the J2EE server.

Setting the number of concurrently executed threads in the Web application has the following advantages as compared to the setting of the number concurrently executed threads in each Web container:

The number of concurrently executed threads of each Web application can be dynamically changed in the running J2EE server. For details about the procedure for dynamically changing the number of concurrently executed threads of Web applications executed on running J2EE servers, see 2.19.2 Flow of dynamically changing the number of concurrently executed threads in the uCosminexus Application Server Web Container Functionality Guide.

Guidelines for selecting a URL group

If concurrently executed threads are controlled in a Web application, control the concurrently executed threads in a URL group if you want to further control the concurrently executed threads in business logic.

Determine the settings of a URL group to include the following business logic in the Web application:

Setting the concurrently executed threads in a URL group has the following advantages as compared to setting only in a Web application.