abap-log
A logging library for ABAP with one logger interface in front of several targets, from the Application Log and the job log to database tables, files and the Eclipse console.
One interface, zif_alog_logger, sits in front of every logger, so a class can take its logger as a dependency and logging actions stay decoupled from application logic. The loggers behind it write to an internal table, the Application Log (BC-SRV-BAL), the job log through MESSAGE statements, the SAP GUI progress indicator, custom database tables, text files on the application server and the Eclipse console, and each accepts an inline string or a message-class message. It installs through abapGitabapGitA Git client written in ABAP that runs inside the system, so objects are cloned, pulled and pushed without leaving it; with no package manager in ABAP, a cloned repository is how code is distributed.community org, abap into a recommended package ZALOG, and the application server must support at least ABAP 740, for the newer syntax the library uses throughout.
Facts
Where it sits
Who is behind it
In the atlas: maintains 1, contributes to 7@fabianlupamaintainerLars HvamContributes to this
In the atlas: maintains 13, contributes to 92, wrote 1@larshpPCFContributes to this
In the atlas: contributes to 4@pcf02 contributors
Before choosing this
Signals
ActivityQuietNo published releases; repository quiet for 36 months
It publishes no releases, and its repository has been quiet for at least 24 full months. This may be normal for stable software; check whether its current state still fits your use.
What it declares
Every artifact
- Type
- Package
- Origin
- Independently maintained
As a package
- Where it runs
- Inside its host
- Distributed through
- abapGit
Connections
Seeing what a running service did, in a readable form
Git client written in ABAP that runs inside the system
Download
README
quoted from fabianlupa/abap-log under MIT, readabap-log

Logging library for ABAP
Overview
abap-log is a library to provide various ways of logging messages in ABAP. The goal is to have a common interface for logger objects so that dependency injection can be used and logging-actions can be decoupled from application logic. Inline string log messages as well as message-class-based messages are supported.
Supported targets
- Internal table
- Application log (BC-SRV-BAL)
MESSAGE-statements for batch processing (job log)- SAP GUI progress indicator
- Custom database tables
- Log text files on the application server
- Eclipse console (using IF_OO_ADT_CLASSRUN)
Examples
Example programs for each logger can be found in the package ZALOG_EXAMPLE.
Console logging in ABAP 7.51

Internal table logging
REPORT zalog_example.
DATA(go_logger) = NEW zcl_alog_itab_logger( ).
go_logger->info( `Hello world.` ) ##NO_TEXT.
go_logger->warning( `Hello darkness my old friend.` ) ##NO_TEXT.
go_logger->error( `Ive come to talk with you again.` ) ##NO_TEXT.
go_logger->debug( `BEEP BOOP` ) ##NO_TEXT.
go_logger->exception( NEW zcx_alog_argument_null( ) ).
MESSAGE s000(zalog) WITH 'Hello from message class' INTO DATA(gv_dummy) ##NEEDED ##NO_TEXT.
go_logger->info_msg( ).
go_logger->warning_msg(
iv_msgid = 'ZALOG'
iv_msgno = '001'
iv_msgv1 = 'Hello from message class'
iv_msgv2 = 'without where used list support...'
) ##NO_TEXT.
TRY.
go_logger->display_as_alv( ).
CATCH cx_salv_msg INTO DATA(gx_ex).
MESSAGE gx_ex TYPE 'E'.
ENDTRY.
Java style logging
CLASS lcl_class_with_logging DEFINITION.
PUBLIC SECTION.
CLASS-METHODS:
class_constructor.
METHODS:
run.
PRIVATE SECTION.
CLASS-DATA:
gi_logger TYPE REF TO zif_alog_logger.
ENDCLASS.
CLASS lcl_class_with_logging IMPLEMENTATION.
METHOD class_constructor.
DATA: lo_dummy TYPE REF TO lcl_class_with_logging ##NEEDED.
gi_logger = zcl_alog_static_logger=>get_logger_for_any( lo_dummy ).
ENDMETHOD.
METHOD run.
gi_logger->info( `Info message` ) ##NO_TEXT.
gi_logger->warning( `WARNING` ) ##NO_TEXT.
ENDMETHOD.
ENDCLASS.
API and documentation
Library documentation is done using ABAP Doc and can be found here as deployed HTML. It can also be viewed in eclipse in the ABAP Element Info view (F2).
Class diagram

Installation
To use this library at least ABAP 740 must be supported by the application server. The reason for this is mostly the new syntax which is heavily used.
- Clone the repository via abapGit
- Recommended target package: ZALOG
Development
Feel free to contribute using pull requests or issues for feature requests and bug reports. This project has been entirely developed in the ABAP Development Tools for eclipse, including ABAP Doc documentation (which is automatically deployed to GitHub pages) and class based exceptions (these cannot be fully edited in SE24 (!)). Using eclipse is therefore highly recommended.
License
History
Others providing
Compare all 20 on the Logging page →- ABAP-LoggerABAP-LoggerA logging library for ABAP that records messages into the standard Application Log (BC-SRV-BAL) and displays them from there, installed through abapGit on ABAP 702 or higher.independent, abapLogging library for ABAP over the Application Logfrom ABAP
- abap-log-exporterabap-log-exporterExports SAP NetWeaver logs from the Business Application Log to an external log system such as Graylog or Loki, converting entries to GELF or Loki format through a separately configured reader, converter and connector.independent, abapExports Business Application Log entries to Graylog or Lokifrom ABAP
- ABAP-PRCABAP-PRCA framework for custom multi-step ABAP processes: a process class declares the states, and the framework runs each document through them and monitors the run.independent, abapFramework for multi-step ABAP processes with monitoringfrom ABAP
- SAP Application Logging service for SAP BTPSAP Application Logging service for SAP BTPCollects an application's log lines from Cloud Foundry or Kyma into a searchable Kibana, for the retention the plan sets.sap official, btpCollects Cloud Foundry or Kyma logs into a searchable Kibanafrom BTP/BAIP
- SAP Cloud LoggingSAP Cloud LoggingAn instance-based observability service built on OpenSearch that stores and analyses logs, metrics and traces from Cloud Foundry, Kyma, Kubernetes and other runtime environments.sap official, btpOpenSearch-based store for logs, metrics and tracesfrom BTP/BAIP
- com.sap.cds:cds-services-bomcom.sap.cds:cds-services-bomThe Maven bill of materials for CAP Java, pinning every com.sap.cds module in a release, from the API and core runtime to the Spring Boot starters and the CQN engine, to the same version.sap official, capMaven bill of materials pinning CAP Java module versionsfrom CAP
- @cap-js/audit-logging@cap-js/audit-loggingIntegration with the SAP Audit Log service, so operations on personal data are recorded in the form an auditor expects without the application writing the entries.sap official, capCAP integration with the SAP Audit Log servicefrom CAP
- ABAP_LOGGINGABAP_LOGGINGAn object-oriented wrapper around SAP's Business Application Log (BAL) for ABAP NetWeaver, chaining texts, messages and exceptions onto a log header that persists in its own or the same connection.independent, abapObject-oriented wrapper around the Business Application Logfrom ABAP
- abap-cloud-loggerabap-cloud-loggerA logging library for ABAP Cloud that wraps the released class CL_BALI_LOG in a chainable logger, collecting exceptions, messages and tables, with a stopwatch and a sticky context tag.independent, abapChainable logger for ABAP Cloud around CL_BALI_LOGfrom ABAP
- abap-fm-loggerabap-fm-loggerA logger for ABAP function modules (RFC) that stores each call's parameters as JSON in one table, with a viewer report to search the log and reprocess a record, akin to WE10 and WE19.independent, abapLogger storing RFC function module call parameters as JSONfrom ABAP
- openui5-error-collectoropenui5-error-collectorA UI5 library that collects a running app's JavaScript errors, unhandled Promise rejections and UI5 log events, and can post them to a backend with navigator.sendBeacon.independent, ui5UI5 library collecting an app's JavaScript errorsfrom UI5
- open-abap-balopen-abap-balApplication logging for ABAP code transpiled to JavaScript and run on Node.js, one of the runtime libraries open-abap.org lists.community org, abapApplication logging for ABAP transpiled to JavaScript on Node.jsfrom ABAP
- @openui5/sap.ui.core@openui5/sap.ui.coreThe OpenUI5 core: the module loader, the MVC runtime, data binding, routing, theming and the test stack, which is everything a UI5 app does before a single community package is added.sap official, ui5Framework core: module loader, MVC runtime, binding, routing, themingfrom UI5
- abap-fluentdabap-fluentdA Fluentd client written in ABAP for sending log lines from an ABAP system to a Fluentd collector, where entries are flushed with an explicit COMMIT WORK.independent, abapFluentd client in ABAP for sending log lines to a collectorfrom ABAP
- @saptools/cf-logs@saptools/cf-logsA command line and typed Node.js library that fetches and streams the logs of one Cloud Foundry app and parses them into structured rows.independent, btpLog fetcher and parser for one Cloud Foundry appfrom BTP/BAIP
- @saptools/cf-tail@saptools/cf-tailA command line that tails every started app in a Cloud Foundry space at once and merges their logs into one timeline by timestamp, with filters by level, tenant, router status and time window.independent, btpMerged log tail of every started app in a Cloud Foundry spacefrom BTP/BAIP
- sap-usi-logging-apisap-usi-logging-apiAn object-oriented encapsulation around SAP's Application Log (transaction SLG1), controlled by customizing, with attachable data containers that SLG1 shows behind a detail button.independent, abapObject-oriented wrapper around SAP's Application Log (SLG1)from ABAP
- srbjsloggersrbjsloggerA browser JavaScript logger whose log, warn and error calls write prominent output to the console, loaded into a UI5 app through index.html or the manifest's resources.independent, ui5A browser JavaScript logger whose log, warn and error calls write prominent output to the console, loaded into a UI5 app through index.html or the manifest's resources.from UI5
- abap-message-loggerabap-message-loggerA message logger for ABAP Cloud that collects T100 messages, BAPIRET2 structures, exceptions and plain text before saving them to the Application Log.independent, abapMessage logger for ABAP Cloud that saves to the Application Logfrom ABAP
Details
Sources
Sources are graph entities: the same page may back several entries, and an unreachable source flags every row that rests on it.
Compatibility and provenance
abaplint
Flavors
“To use this library at least ABAP 740 must be supported by the application server.” — fabianlupa/abap-log — README, Installation
History in the atlas
- First seen.
For your agent
- Ref
artifact:fabianlupa-abap-log- JSON
- /artifacts/fabianlupa-abap-log.json
- MCP
- Connecting an agent