ICM and SAP Web Dispatcher Timeout Parameter-sap web service接口超时时间设置

SAP分三种超时:连接超时,处理超时,keepalive超时

You want to configure the timeout settings of the Internet Communication Manager (ICM) or the SAP Web Dispatcher. The SAP Web Application Server may issue HTTP timeout error messages. The error message displayed is "500 Connection timed out" if you have not defined your own dynamic ICM error pages. If the error occurs, you can use the note to help you with troubleshooting.



Other terms
keepalive, 402, 500, ICM_HTTP_TIMEOUT, ICM_HTTP_CONNECTION_FAILED


Reason and Prerequisites
You are using ICM Release 6.40 or higher for HTTP connections of the SAP Web AS. In other words, your kernel release is 6.40 or higher.
Up to and including Release 7.00, ICM is only used in systems which also have an ABAP stack, and not in J2EE-only systems.

You may also be using the SAP Web Dispatcher.

Solution
The note describes the following:

Client and server roles of the ICM
List of the various ICM timeout parameters
Short description of the icm/conn_timeout parameter
Description of "Processing timeout" and "Keepalive timeout"
Configuration of the ICM parameters for the processing timeout and the keepalive timeout
Timeout parameters in the SAP Web Dispatcher
ICM kernel patches that affect timeouts

There is detailed ICM documentation in the SAP Knowledge Warehouse.



Client and server roles of the ICM

The ICM can forward incoming HTTP connections for further processing to the SAP Web Application Server; the ICM then serves as the HTTP server. The ICM can also forward outgoing HTTP connections from the SAP Web Application Server to other HTTP servers; the ICM then serves as the HTTP client.


Available parameters that control ICM timeouts
icm/conn_timeout
icm/keep_alive_timeout
icm/server_port_< n >

Parameter icm/conn_timeout

icm/conn_timeout is used to set the timeout when setting up the connection. If the timeout is exceeded, an error page is generally displayed with the information "404 Resource not found" "Partner not reached".
Therefore, exceeding the icm/conn_timeout does not lead to a "500 Connection timed out" error message.


Processing timeout and keepalive timeout

The icm/keep_alive_timeout and icm/server_port_< n > parameters define the keepalive timeout and the processing timeout.
ICM distinguishes between these two types of timeout.

The processing timeout is the timeout between the HTTP request being issued and the HTTP response being received.
If the ICM is used as a server for the relevant HTTP request (in other words, when it forwards an incoming request to the SAP Web Application Server), the processing timeout is the time that the ICM will wait until a response is received from the SAP Web Application Server (ABAP or J2EE). This interval may be exceeded with long-running applications in ABAP or the J2EE engine.
If the ICM serves as a client for the relevant HTTP request (that is, when it forwards outgoing requests from the SAP Web Application Server), the processing timeout is the time that the ICM waits until a response is received from the network. This interval may also be exceeded in the case of long-running applications in the network.
The keepalive timeout specifies how long the network should remain open after a request has been processed successfully so that the TCP/IP connection does not have to be reestablished if additional requests are received.
When you set the keepalive timeout, this does not normally lead to timeout errors. You should set the keepalive timeout high enough that the connection does not have to be reestablished for requests that are sent within a short time of each other, but low enough that the number of unused open TCP/IP connections is not unnecessarily high.

Configuration of the ICM parameters for the processing timeout and the keepalive timeout
For the ICM, the parameters mentioned here are in the instance profile.

The processing timeout is set for individual services with the following parameter:
icm/server_port_ < n > = ...,PROCTIMEOUT=< s >.

The keepalive timeout can be set globally for all services of the ICM with the parameter icm/keepalive_timeout.
You can also set it for individual services by using the following parameter:
icm/server_port_ < n > = ...,TIMEOUT=< s >.
If you set this parameter, it overwrites parameter icm/keepalive_timeout for the specified service.

Even if the ICM serves as client for a request, the TIMEOUT and PROCTIMEOUT parameters of icm/server_port_ < n > control the timeouts for the relevant protocol, provided that you have set TIMEOUT or PROCTIMEOUT.

If you have not set the PROCTIMEOUT parameter, TIMEOUT (or icm/keepalive_timeout) defines both the processing timeout and the keepalive timeout. Also, as of release 6.40, the keepalive timeout is limited to a maximum of 30 seconds.

In a system where the default timeout settings of 30 seconds for the keepalive timeout and the processing timeout are not sufficient because of long-running applications, we recommend that you set the TIMEOUT and PROCTIMEOUT parameters for the relevant services so that you can configure them independently of each other. In addition, we recommend that you do not set the TIMEOUT value higher than necessary, for example, to the usual default value of 30 seconds.
We recommend, for example, the following settings:
icm/server_port_0 = PROT=HTTP,PORT=1080,TIMEOUT=30,PROCTIMEOUT=600
to allow a maximum processing time of 10 minutes.


Timeout parameters in the SAP Web Dispatcher

The same timeout parameters are available for the SAP Web Dispatcher as for the ICM. You can change the parameters of the SAP Web Dispatcher in the profile file of the SAP Web Dispatcher (for example, sapwebdisp.pfl). We recommend that you set the same parameters in the SAP Web Dispatcher and ICM.


Known errors in ICM and Web Dispatcher timeout handling
Since 6.40 patch level 64, there have not been any known errors in ICM and Web Dispatcher timeout handling.
In Release 7.00, there are no known errors in ICM and Web Dispatcher Timeout Handling.

Known Internet Explorer errors in the keepalive timeout handling
Known errors in the keepalive handling from Internet Explorer are described in Note 900804. However, these errors are not usually displayed as timeout errors.
请使用浏览器的分享功能分享到微信等