Back in July of 2022 we published an article highlighting some of the support and guidance tools that can be used during an implementation project to identify inconsistencies and errors before full deployment, or to troubleshoot an issue when identified in a productive system. One such tool that we briefly touched upon was the ABAP Test Cockpit (ATC).
There are times when customer implementations require not just standard SAP coding, but also custom ABAP coding tailored to specific customer requirements. The ATC is a central quality assurance toolset through which users can create static functional, performance and security code checks as well as ABAP Unit tests for ABAP programs. To make sure migrations go smoothly and provide comparable check results throughout the company, the ATC is compatible with SAP’s Code Inspector, SAP’s tool for the static analysis of ABAP programs and other SAP repository objects. This means that custom Code Inspector checks and variants can be reused in the ABAP Test Cockpit.
Prior to the SAP S/4HANA 2022 release, there were no SAP EWM specific checks available in the toolset. However, with the new release, SAP has delivered 6 EWM checks. Currently the ATC checks are available only on embedded and decentral On Premise SAP S/4HANA 2022 systems, but SAP plans to offer downports in upcoming months.
Demo of Delivery Query ATC results
The currently available ATC checks for SAP EWM are:
Check Delivery Query(/SCWM/CL_ATC_DELIVERY_QUERY)
If performance slowdowns happen because of an inefficient call of delivery cue method when a custom code is executed, then users can try out the check class /SCWM/CL_ATC_DELIVERY_QUERY. This check class can be used to improve performance when the custom code calls delivery query method /SCWM/CL_DLV_MANAGEMENT_PRD=>QUERY with specific parameters.
Check Function Call with Update Module Flag (/SCWM/CL_ATC_FUNCTION_CALL)
SAP recommends not to use the custom code to call Function Module which is configured as “Update Module”. A new check class is provided to check when the custom code calls a function module that is an update module.
Check Application Context in PPF Action Schedule Condition (/SCWM/CL_ATC_PPF_SCHEDCOND)
The Post Processing Framework (PPF) action is running independently from the application context. In some cases, this may lead to a double assignment when a PPF action is called from another context, which in turn leads to performance issues. SAP provides a new check class to examine the application context in the schedule condition method of the PPF action to avoid this performance issue.
Check /SCWM/TO_POST or /SCWM/TO_CONFIRM Call in a Loop (/SCWM/CL_ATC_TO_CO_PO)
There may be instances when in a custom code, the Function Modules /SCWM/TO_CONFIRM and /SCWM/TO_POST are called within a loop. This in turn results in performance issues. This new check class that SAP provides will verify whether the function module /SCWM/TO_CONFIRM or /SCWM/TO_POST is being called inside a loop statement.
Check for Wait Satement (/SCWM/CL_ATC_WAIT)
In case that performance suffers when executing a custom code, which is caused by the Wait Sleep Statement being called, SAP provides a new check class /SCWM/CL_ATC_WAIT to avoid calling wait statements and subsequent performance issues.
Check for Method INIT_BY_WORKSTATION (/SCWM/CL_ATC_WM_PACKING)
The method /SCWM/CL_WM_PACKING=>INIT_BY_WORKSTATION is recommended to use in custom code with parameter IV_NO_HU_BY_WC set to “X”. Otherwise, all handling units (HUs) from the work centre are read, leading to a long runtime, especially in the RF transactions. SAP provides a new check Class /SCWM/CL_ATC_WM_PACKING to check custom code to avoid this performance issue.