Redwood Documentation

Product Documentation

 

›Configuration

RunMyJobsSAP Connector

Introduction

  • The SAP Connector
  • HANA Platforms

Configuration

  • Configuring the Central and Satellite Systems
  • Installing SAP JCo
  • Configuring an SAP System for Process Automation
  • SAP RFC User Privileges
  • Assigning SAP Authorizations to the RFC User
  • Connecting to SAP Systems
  • Connecting to SAP Systems with the Wizard
  • Connection Details for the ABAP Stack
  • Intercepting SAP Jobs
  • SAP Job Interception Configuration
  • Interacting with SAP Events
  • Configuration Details on Interacting with SAP Events
  • Parsing Log Files to set Status of SAP Jobs
  • Understanding the Different XBP Interface Releases

Importing SAP Objects

  • Importing Objects from SAP Systems
  • Importing ABAP Programs
  • Importing ABAP Program Parameter Definitions
  • Importing Archive Objects
  • Importing Batch Events
  • Importing SAP BusinessObjects Processes
  • Importing SAP Calendars
  • Importing SAP CCMS Jobs
  • Importing Communication Channels via PI/XI
  • Importing External Commands
  • Importing and Running Mass Activities
  • Importing Output Devices
  • Importing Process Chains
  • Importing Process Chain Definitions
  • Importing Recipients
  • Importing Variants
  • Importing Variant Definitions

SAP ABAP

  • Handling ABAP Programs
  • Controlling Batch Input Sessions
  • Handling Variants
  • Creating and Modifying Variants in Redwood Server
  • Maintaining Variants Manually
  • Maintaining Variants Automatically
  • Maintaining Variants Automatically (Advanced)
  • Using Temporary Variants
  • Default SAP Process Definitions

Business Objects

  • Main
  • Interface Configuration
  • Crystal Reports
  • Web Intelligence
  • Data Services
  • Triggering Events
  • Crystal Reports REST
  • Web Intelligence REST

Process Chains

  • Handling Process Chains
  • Running Process Chains
  • Monitoring Process Chains
  • Restarting Process Chains

SAP PI/XI

  • SAP Communication Channels with PI/XI
  • Controlling Communication Channels with Redwood Server via PI/XI

Adaptive Computing

  • SAP Adaptive Computing
  • Controlling SAP Adaptive Computing

SAP Monitoring

  • Integrating SAP Monitors
  • Configuration Details for Integrating SAP Monitors
  • Sending Monitoring Data to SAP Systems
  • Configuration Details for Sending Monitoring Data to SAP Systems
  • Monitoring Redwood Server Availability in CEN
  • Active XMB Monitoring
  • Active IDoc Monitoring

Advanced Configuration

  • Connect to an ABAP System via SAProuter
  • SNC connection to an SAP System
  • The SAP Cryptographic Library
  • Tuning Redwood Server

Legacy Systems Support

  • Enable XBP 2.0 or 3.0 Functionality
  • Enhanced SAP Interfaces with Redwood Transports
← Configuration Details on Interacting with SAP EventsUnderstanding the Different XBP Interface Releases →

Parsing Log Files to set Status of SAP Jobs

SAP jobs reach status Completed when no error was returned and Error when an error occurred. You can force an SAP job into Error or Completed based on a specific message in the log file. This is done by mapping specific messages to return codes; the return code 0 maps to Completed, other return codes map to Error. The return code can be configured per SAP instance, on the Return Code Mapping tab of SAP Systems in Redwood Server.

Note that you can also set system-wide return code mapping for SAP jobs that would appear as killed in Redwood Server with the KilledMessages registry entry.

Matching a Log Entry

The following information is required to match a log entry:

  • Message Class - The type of message; it can be found in the log, usually the third column.
  • Message Number - The number of the message; it can be found in the log, usually the fourth column.
  • Message Type - The type of the message, see list below. The message class and number usually uniquely identify the message, so this can be set to asterisk (*) in most cases.
  • Message Text (optional) - The text of the message, it can be found in the log.

The message type can be any of the following:

  • A - Termination
  • E - Error Message
  • I - Information
  • S - Status Message
  • W - Warning
  • X - Exit

The message type can only be retrieved if one of the following is true:

  • transports are used
  • if the SAP Note 603919 - Reading job log by XBP: Message type is missing is implemented
  • 6.40 or newer SAP releases

Based on the criteria, Redwood Server parses the log file and when it finds a matching entry, it will set the return code of the process to the one configured for the rule. Optionally, you may have Redwood Server create a note, which will inform operators, that return code mapping was used on this process. All criteria must be fulfilled for the match to be successful.

The following is the contents of a log file:

180006 20100613 00 516 Job started  0
180007 20100613 00 550 Step 001 started (program BTCTEST, variant , user ID REDWOOD)  0 001 BTCTEST  REDWOOD
180007 20100613 00 544 TEST: SY-BATCH indicates background processing  0
180007 20100613 00 517 Job finished  0


In the above message, we see the following message 180007 20100613 00 544 TEST: SY-BATCH indicates background processing 0 that indicates that no background processing jobs were created, so we would like to force the process into error.

The following rules would catch this log entry:

  • Message Class - 00
  • Message Number - 544
  • Message Type - S
  • Message Text - TEST: SY-BATCH*

It is easier with SAP error messages, see the following error:

BAPI exception: RFC function module = BAPI_XBP_NEW_FUNC_CHECK, message type=E, id=XM,
number=233, text=I:XM:233 BAPI_XBP_NEW_FUNC_CHECK,
msgv1=BAPI_XBP_NEW_FUNC_CHECK, msgv2=, msgv3=, msgv4=


The following rule would match this log entry:

  • Message Class - XM
  • Message Number - 233
  • Message Type - E
  • Message Text - I:XM:233 BAPI_XBP_NEW_FUNC_CHECK*

Specifying the Jobs Logs to be Parsed

The following criteria is available to specify which job logs are to be parsed:

  • Client Number Mask - a client number mask can be a specific client or a range of clients defined with wildcards. For example, 2* would match clients 200 and 250, but not 300.
  • Jobname Mask - a job name mask can be a specific job name, or range of job names specified with wildcards. For example, BI * would match BI PostProcessing but not Backup Production System 12/03.
  • Username Mask - a username mask should be left as * unless you are sure the job will always be started by the same user.

This allows you to limit the rule to a more or less specific range of jobs. For performance reasons, Redwood recommends to avoid parsing logs of all jobs. All criteria must be fulfilled for the match to be successful.

When you configure more than one rule, you should ensure that the most restrictive rules need to have a lower processing order than more generic rules.

Procedure

  1. Navigate to "Environment > SAP".
  2. Choose Edit from the context-menu of an SAP System.
  3. Choose the Return code mapping tab.
  4. Choose Add and fill in the details of the rule, check the Values section below for a description of the available fields.
  5. Choose Save & Close when you are done.

Values

FieldDescription
Processing OrderThe order in which rules are processed, the lower the value, the earlier the rule is processed.
DescriptionAn optional description of the rule.
Client Number MaskThe client number(s) this rule applies to.
Jobname MaskThe job names this rule applies to.
Username MaskThe users this rule applies to.
Message ClassThe type of message; it can be found in the log, usually the third column.
Message NumberThe number of the message; it can be found in the log, usually the fourth column.
Message TypeThe type of the message, S for strings and E for errors, for example.
Message TextThe text of the message, it can be found in the log.
Return CodeThe return code to use when the rule matches.
Create NoteShould a note be created when this rule is applied?

See Also

SAP Systems

← Configuration Details on Interacting with SAP EventsUnderstanding the Different XBP Interface Releases →
  • Matching a Log Entry
  • Specifying the Jobs Logs to be Parsed
  • Procedure
  • Values
  • See Also
Docs
Getting StartedInstallationFinance InstallationConcepts
TroubleshootingArchiving
Learn and Connect
Support Portal
BlogEventsResources
ISO/ IEC 27001 Information Security Management
Automate to be human

2023 All Rights Reserved |

Terms of Service | Policies | Cookies | Glossary | Third-party Software | Contact | Copyright | Impressum |