Show TOC

Procedure documentationSpecifying the Maximum Server Threads Acquired by Different Web Resources Locate this document in the navigation structure

 

In a system where many different applications run, you can limit the possibility of one application affecting the availability of another. The Web Container provides functionality that restricts and monitors the access to those Web resources or Web applications that are currently recognized as blocked. You can choose whether or not to block the locked Web resource/application. Every time such a Web resource or an application is blocked due to current unavailability, an error is thrown.

Recommendation Recommendation

We recommend that you keep the restriction of the Web resources/applications switched on. Otherwise, all available threads may hang occupied by a certain Web resource and the system will not respond.

End of the recommendation.

The first entry point for client requests in the instance is ICM. If the request is related to a Java application then ICM forwards this request to some of the running Java server processes. This communication is done via the SAP optimized protocol Fast Channel Architecture (FCA). There are several threads on the Java server node that process such requests passed by ICM.

The number of server threads is configurable via the FCAServerThreadCount property. However, increasing this number is recommended only when the system has many clients and there is a possibility that the Java server processes can handle more simultaneous requests.

Note Note

Increasing the number of server threads affects the number of available server threads that may be required by other services/components.

End of the note.

AS Java provides the functionality of managing all threads processing HTTP requests. If a thread processes an HTTP request for more than 15 seconds, the system assumes it has hung and automatically starts a new one which can process new incoming requests. This ensures that the number of parallel threads processing new HTTP requests remains the same.

There are several cases that are related to the type of application or Web resource where the HTTP requests are processed:

  • If HTTP requests to a particular URL occupy as many threads as the configured maximum number of server threads and does not finish processing within the 15 seconds timeout, any consequent request to this URL will receive the 503 HTTP error response. If HTTP requests to a different URL appear, these requests will be processed.

  • If HTTP requests that are dispatched (using either include() or forward() methods of the RequestDispatcher) to a single application or a Web resource occupy the configured maximum number of server threads, any consequent request to this application or Web resource will receive the 503 HTTP error response. If HTTP requests are dispatched to a different Web resource or application, these requests will be processed.

    More information: Dispatching Requests to Web Application Resources

Procedure

Defining the maximum number of threads allowed for each Web resource or an application

You can use the Config Tool to configure the FCA server threads.

If you want to specify the maximum server threads for ICM requests, proceed as follows:

  1. Start the Config Tool by double-clicking the configtool script file in <SAP_install_dir>/<system_name>/<instance_name>/j2ee/configtool directory.

  2. Choose   cluster-data   template   instance - <n>   services   http  .

  3. From the list of properties, select FCAServerThreadCount.

  4. Set the required maximum server threads.

  5. Choose Set Custom Value to apply the new value.

  6. Choose Apply changes to save the changes.

  7. For the changes to take effect, restart the cluster.

Defining the maximum number of threads allowed for each Web resource or an application for request dispatching

The maximum number of requests is calculated using the formula: FCAServerThreadCount*RDThreadCountFactor. To modify the FCAServerThreadCount property, use the procedure above. To configure the RDThreadCountFactor, perform the following tasks:

  1. Open the SAP NetWeaver Administrator.

  2. Choose   Configuration Management   Infrastructure   Java System Properties  . Specify a template in the Templates section.

  3. Choose the Services tab in the Details section.

  4. Choose the Web Container service.

  5. Select the RDThreadCountFactor property in the Extended Details section. Choose Modify.

  6. Enter the new value of the property. Choose Set and then Save.

Configuring restrictions for request dispatching

You can enable restrictions by specifying the EnableQoSRestrictionsForRD property of the Web Container service.

  1. Open the SAP NetWeaver Administrator.

  2. Choose   Configuration Management   Infrastructure   Java System Properties  . Specify a template in the Templates section.

  3. Choose theServices tab in the Details section.

  4. Choose the Web Container service.

  5. Select the EnableQoSRestrictionsForRD property in the Extended Details section. Choose Modify.

  6. Enter the new value of the property. Choose Set and then Save.

Applying restrictions to Web resources or Web applications

You can configure whether to apply the restrictions to a Web resource (servlet, JSP. JSF) or to a Web application by specifying the ConsumerTypeIsAlias property of the HTTP Provider service.

  1. Open the SAP NetWeaver Administrator.

  2. Choose   Configuration Management   Infrastructure   Java System Properties  . Specify a template in the Templates section.

  3. Choose theServices tab in the Details section.

  4. Choose theHTTP Provider service.

  5. Select the ConsumerTypeIsAlias property in the Extended Details section. Choose Modify.

  6. Enter the new value of the property. Choose Set and then Save.