How to enable debug logging in TIBCO Data Virtualization for SAP adapter?

How to enable debug logging in TIBCO Data Virtualization for SAP adapter?

book

Article ID: KB0070861

calendar_today

Updated On:

Products Versions
TIBCO Data Virtualization TIBCO Data Virtualization version 8.5.x and above

Description

This article explains steps for enabling debug logging for analyzing SAP adapter issues in TIBCO Data Virtualization (TDV). During troubleshooting, debugging involves modifying the log4j2.properties file to access detailed information on API calls between TDV and the SAP data source. Additionally, tracing captures raw data from the external SAP source, creating HTML and XML file pairs for each call, offering enhanced insights into the issues at hand.

Issue/Introduction

This article provides details on how to enable debug logging to troubleshoot SAP adapter related issues in TIBCO Data Virtualization(TDV).

Environment

All supported Operating Systems.

Resolution

Below are the steps to enable debug logging in TIBCO Data Virtualization for SAP adapter:

Step 1: Modifying logs4j2.properties File

1. Navigate to the logs4j2.properties file in the <TDV_Install_dir>/conf/server directory.
2. Open the logs4j2.properties file using a text editor.
3. Append the following lines to enable debug logging for the SAP adapter:
    logger.cdms_ds_sap.name = com.compositesw.cdms.ds.sap
    logger.cdms_ds_sap.level = DEBUG

Step 2: Modifying product.properties File

1. Navigate to the <TDV_Install_dir>\apps\dlm\app_ds_sap\conf\ directory.
2. Locate the product.properties file and open it using a text editor.
3. Modify the following lines in the product.properties file to enable SAP debugging:
    Set: sap.debug = true
    This property, when set to true, logs all data returned from SAP requests to CSV files in the SAP driver folder.

Step 3: Restarting the TDV Server

1. To apply the changes, restart the TDV server.
2. After restarting, reproduce the issue to generate debug logs.

Step 4: Identifying the generated SAP trace files location from the cs_server.log debug messages"

Review the cs_server.log located at <TDV_Install_Dir>/logs folder to retrieve the 'SAP trace files' location. Search for the string "Data files created at" to identify this folder.

Example string from the cs_server.log file: Data files created at "D:\TIBCO\TDV Server 8.5\tmp\SAPConnector"

Additional Information

Documentation for SAP Global Properties:
https://docs.tibco.com/pub/tdv/8.8.0/doc/html/en-US/AdapterHelp/SAP/SAP_Global_Properties.htm