Upload
josleviathan
View
271
Download
0
Embed Size (px)
Citation preview
7/24/2019 568271 Lifetime of an RFC Connection
http://slidepdf.com/reader/full/568271-lifetime-of-an-rfc-connection 1/2
SAP Note
Header Data
Symptom
You discover RFC type or CPIC type users logged on in Transaction SM04 (User List).
Other Terms
RFC, connection duration, SM04,
Reason and Prerequisites
The lifetime of an RFC connection depends on its context (caller context).
l In the R/3 environment, a context is represented as an internal mode, whereby an ABAP reportprogram or a transaction is generally processed within an internal mode. In other words, aninternal mode is generated to carry out an ABAP report or an ABAP transaction and this is wherethe global data and RFC connections are administered. The RFC connections are reused within thiskind of context. That is, as soon as a connection to an RFC destination was set up in a context,this would reused each time the same destination was accessed in the future. This does not applyto RFC communication types where the RFC connection is terminated after the call. This includestransactional or queued RFC as well as asynchronous RFC without response or asynchronous RFCwith response without the "KEEPING TASK" addition. See the ABAP online documentation on thesubject of RFC for more information. After you successfully set up an RFC connection, theconnection and the respective RFC session remain active on the target server until the callercontext is terminated. You can do this either by terminating the report (the transaction) or byusing the "LEAVE" or "LEAVE TO" ABAP language element or by entering a "/n<tcode>" transactioncode in the OK code field of the SAP GUI menu bar. Depending on their application logic, theapplications can also actively terminate RFC connections by calling the "RFC_CONNECTION_CLOSE"function module. The application cannot terminate RFC connections and their sessions thatdetached themselves from the caller context (such as asynchronous RFC without response).
l The lifetime of RFC connections initiated from external programs depends on the lifetime of theRFC caller process or, in the case of multithreading programs, on the lifetime of the RFC callerthread. An external caller program can actively terminate its RFC connections using the RfcCloseRFC API function.
l When an RFC function module terminates as a result of application or communication errors (forexample, due to E-, A- or X messages or due to ABAP runtime errors) all respective RFCconnections and their contexts are terminated.
Solution
You can use one of the following strategies to localize the caller context:
l Evaluate the respective statistic records on the server
¡ By using Transaction ST03 (Workload monitor) to select the relevant log entries for thecurrent server and the RFC user, you can use the RFC statistics records to determine theorigin of the caller.
l Evaluate the communication entries
¡ You can use the Conversation ID of the RFC context in Transaction SMGW (Gateway Monitor) tofind out additional information about the caller.
Comment: Every application is responsible for the administration of its RFC calls and the respectiveRFC contexts.Note 780817 describes the analysis procedure for this.
Validity
568271 - Lifetime of an RFC connection
Version 3 Validity: 08.10.2004 - active Language English
Released On 08.10.2004 12:30:40
Release Status Released for Customer
Component BC-MID-RFC RFC
Priority Recommendations / Additional InfoCategory Help for error analysis
7/24/2019 568271 Lifetime of an RFC Connection
http://slidepdf.com/reader/full/568271-lifetime-of-an-rfc-connection 2/2
This document is not restricted to a software component or software component version
References
This document refers to:
SAP Notes
This document is referenced by:
SAP Notes (3)
1013467 Too many sessions for each user/terminal in the SRM Server
780817 Analyzing the RFC user in SM04
542521 CST Patch Collection 31 2002
1013467 Too many sessions for each user/terminal in the SRM Server
780817 Analyzing the RFC user in SM04
542521 CST Patch Collection 31 2002