Technology Blogs by SAP
Learn how to extend and personalize SAP applications. Follow the SAP technology blog for insights into SAP BTP, ABAP, SAP Analytics Cloud, SAP HANA, and more.
cancel
Showing results for 
Search instead for 
Did you mean: 
Martin_Lauer
Product and Topic Expert
Product and Topic Expert
Job Interception: Controlling end-user scheduled jobs

Controlling background jobs that are scheduled by end-users is one of the top challenges for customers. End-user scheduled jobs that bypass a central scheduling are undermining all efforts of controlling the batch workload on a backend-system. So especially during times like Period End Closing, end-user scheduled jobs have led to overload situations of customer systems. Besides the problem of undermining a meaningful workload distribution, jobs that are run outside a central scheduling tool are usually not covered by any Service Level Agreement and are hence not properly monitored by the corresponding scheduling team. End-user jobs are also nowhere documented and no error handling procedures exist. So even if these are covered by monitoring nobody knows how to react in case of an exception.

 

To make things more complicated, company policies often do not allow restricting the scheduling authorization of end-users. Now actually a technical solution to this problem exists since many years, but is unfortunately still widely unknown to most SAP customers: Job Interception. SAP introduced the job interception functionality for the first time already with the eXternal Batch Processing (XBP) interface version 2.0 in Q1/2003. Back then you could maintain entries in table TBCICPT1 in order to define which jobs should be intercepted. Every external scheduling tool certified for XBP 2.0 could get a list of intercepted jobs and (re-)schedule them according to defined rule-sets. Meanwhile the XBP version 3.0 was introduced which allows a more flexible maintenance of interception criteria via program CRITERIA_MANAGER.

 

This blog describes more details on how to configure job interception in combination with SAP Process Scheduling by Redwood.

 

Configuration on backend system:

For activating job interception on a specific backend-system you have to execute program INITXBP2 first. There you select either XBP 2.0 or XBP 3.0 depending on whether the interception rules should be maintained via table TBCICPT1 or via program CRITERIA_MANAGER. The later is only available for SAP_BASIS 7.0 or higher but is recommended when available. Instead of switching-on job interception manually an external scheduler like SAP Central Process Scheduling by Redwood can use function module BAPI_XBP_NEW_FUNC_CHECK to switch-on or switch-off the functionality.

 

Case 1: Maintenance via table TBCICPT1

  • n Go to transaction SE16
  • n Enter table name TBCICPT1
  • n Create a new entry which jobs and/or jobs of which user should be intercepted

 

 

 

An external scheduler like SAP Central Process Scheduling by Redwood would use function module BAPI_XBP_MODIFY_CRITERIA_TABLE in order to read or change table TBCICPT1, so no manual maintenance via transaction SE16 s necessary.

 

Case 2: Maintenance via program CRITERIA_MANAGER (recommended for SAP_BASIS 7.0 or higher)

  • n Add a new Criterion of Type "Interception"
  • n For this type: Add a new criterion specifying which jobs and/or jobs of which user and/or of which job calls should be included/excluded from job interception
  • n Activate the newly created profile

 

While the criteria maintenance via table TBCICPT1 only allows a positive list, i.e. intercept all jobs that meet the criteria, the maintenance via CRITERIA_MANAGER also allows a negative list, i.e. intercept everything except the entries meeting the criteria. While the later maintenance provides more flexibility, in both cases the result is basically the same. The respective end-user can still schedule background jobs via transaction SM36 or by sending reports in the background but the respective job is no longer executed - it is intercepted!

 

 

Configuration in SAP Central Process Scheduling by Redwood:

Now these intercepted jobs shall be picked up by SAP Central Process Scheduling by Redwood in order to (re-)schedule it in a controlled way. This is done via function module BAPI_XBP_GET_INTERCEPTED_JOBS.

 

In the Environment view from SAP CPS you go and edit the corresponding SAP system entry. Within the SAP System view you have to set the Job Handling to Intercepted.

 

Within view XBP Job Control Rules you can then create different Control Rules where you define which intercepted jobs should be handled in what way, e.g. all end-user jobs could be scheduled via a certain Queue which has just a limited number of background work processes assigned.

 

In that way SAP CPS picks up the intercepted backend jobs and schedules them anew.

 

As a result you can now also see the changed status on the backend system. Instead of being intercepted, they are now scheduled and will run once the scheduling criteria are met.

 

 

 

Summary: For many years SAP provides the possibility to technically intercept selected background jobs as part of SAP_BASIS with the XBP interface version 2.0 or 3.0. In combination with an external scheduling tool like SAP Central Process Scheduling by Redwood you can pick-up the intercepted jobs and schedule them in a controlled manner based on freely definable rule-sets.

The interception functionality was shipped in Q1/2003 with XBP 2.0

 

SAP_BASIS Release

Support Package

4.6C  

SP 41

4.6D  

SP 34

610

SP 27

620

SP 17

>= 640

from the beginning

 

Outlook: As already outlined in the SDN blog about SAP is first vendor to provide a comprehensive Job Management Suite, SAP will soon go even one step further. Besides intercepting jobs that have been already scheduled, SAP will re-direct end-users into a standardized job request form who are trying to access transaction SM36 or execute programs in background via transaction SA38. Then background jobs with a re-occurring scheduling will only get into the backend system in a very controlled and documented way. You will soon learn more about it in a separate SDN blog.

 

 

 

Corresponding abstract of SAP TechEd 2009 session in Phoenix and Vienna:

 

Job Management with SAP Central Process Scheduling and SAP Solution Manager

This session showcases the capabilities offered by SAP's Central Process Scheduler by Redwood, to automate the background job processing in your landscape . Also showcased is the integration with SAP's Solution Manager which provides end to end Lifecycle Management of your background jobs. The session will introduce submitting job requests through SAP Solution Manager and SAP CPS will be used by the administrator to intercept and schedule the jobs. Based on the job documentation created by SAP Solution Manager, the administrator can create Job Chains. SAP CPS allows administrators, to create and schedule Job Chains spanning across multiple systems using user defined jobs or jobs imported from the backend systems. Jobs can be monitored and the enhanced notification mechanism of SAP CPS allows administrators to be notified about failed jobs or job chains, in real time.

 

 

List of selected related SDN blogs:

11 Comments