Packages, Transports, gCTS and abapGit
|
This content was generated with the assistance of AI and should be verified against the official documentation before being relied on in production. |
An ABAP system does not let you simply copy a program from the system where you wrote it to the system where people use it. Every development object is filed in a package, every change is written into a transport request, and a transport request is then moved from the development system to a test system and on to the production system. A newcomer meets this the first time the editor asks for a transport request before it saves a class. This page explains what a package is, what a transport request and its tasks are, how the three-system landscape of development (DEV), quality assurance (QAS) and production (PRD) is wired, and how two Git-based tools, the Git-enabled Change and Transport System (gCTS) and abapGit, relate to that classic process. It is written against Standard ABAP release 8.16 (SAP S/4HANA 2025) and ABAP for Cloud Development release 9.20 (2608). Packages and transport requests apply in all of them. The classic transport tools (Transport Organizer transactions and the Transport Management System) belong to classic Standard ABAP systems such as SAP S/4HANA on premise and Private Edition. gCTS belongs to the same family of systems, and abapGit exists as a community tool and as an SAP-delivered version in SAP BTP and SAP S/4HANA Cloud. In SAP S/4HANA Cloud Public Edition and the SAP BTP ABAP environment, SAP names other tools, described in the section on products below.
Before you read
-
Getting Started: what an ABAP system and a development object are.
-
Classic Tools: SE80, SE38, SE11, SE37 and SE16: the Object Navigator, where packages are browsed.
-
ABAP Development Tools (ADT): the Eclipse editor that asks for a package and a transport request when you create an object.
-
Language Versions and Released APIs: why a package carries an ABAP language version.
Key terms
-
Package: a container that groups development objects that belong together and is the unit that connects an object to the transport system.
-
Package interface: the list of objects a package offers to other packages under the package concept.
-
Software component: the delivery unit that a package belongs to and that carries the language version rules between packages.
-
Transport request: a container that records changed objects so they can be moved to the next system.
-
Task: the part of a transport request that one developer owns and writes changes into.
-
Transport layer: the group of development projects that share the same transport routes.
-
Change and Transport System (CTS): all the tools of an ABAP system that manage and transport development objects between systems.
-
gCTS: the Git-enabled Change and Transport System, which keeps transported objects as files in a Git repository.
-
abapGit: a Git client written in ABAP that exports and imports development objects as plain text files.
Packages: where every object lives
A package groups development objects that belong together: for the expense claim running example, the table
ZEXP_CLAIM, the item table zexp_item, the interface view ZI_ExpClaim and the classes around them can all sit in one
package. The keyword documentation defines a package as something that encapsulates repository objects in self-contained
units, and it ties the package to the transport system: a repository object is connected to the Change and Transport
System through its package. The Transport Organizer documentation adds that each development object is assigned a
package and a responsible developer, and that the package is also used as a structuring and access aid in the ABAP
development environment.
Packages form a hierarchy. When you create a package in ADT, the wizard asks for a name, a description, the software
component, the package type (structure, main or development) and the transport layer. Names for customer objects start
with Y or Z or use your own namespace. In the ABAP Cloud development model, developers create only development
packages, as subpackages of the single structure package. A package is either local or transportable. The abapGit
documentation lists the cases: a local $ package, for example $TMP, produces no transport; a Z package without
a transport layer produces local requests that cannot leave the system; a package with a transport layer produces a
transportable Workbench request.
Source: Creating ABAP Packages
Software components and language versions
Every package belongs to a software component, and the software component decides the ABAP language version of its objects when the version is not set explicitly. The keyword documentation names two main language versions: ABAP for Cloud Development, which is restricted, and Standard ABAP, which is unrestricted apart from the package concept. Objects with the language version ABAP for Cloud Development can use released APIs and objects in the same software component, and objects of a local software component can also use other local and custom software components that are also ABAP for Cloud Development. This is why a clean-core project keeps its cloud-ready code in a separate software component and package tree instead of mixing it with classic code.
Package interfaces
The package concept describes who may use what. The keyword documentation defines the package concept as a rule set, based on packages, that specifies the mutual usability of repository objects. An older SAP Help page for the classic ABAP Workbench explains the method behind it: a package that offers services, the server package, exposes selected repository objects (function modules, BAPIs, classes, programs and types) in one or more package interfaces; a package that wants to use them, the client package, declares a use access; and a package check reports a use that is not allowed. That page is older than the current release, and the details of package checks are configured per system, so check them in your own system before relying on them. The mechanism stays useful as an idea: a package interface is the small, stable surface a team promises to keep, and everything else in the package is free to change.
Transport requests and tasks
A transport request is the container that carries changes from one system to the next. The Transport Organizer, which is built into the ABAP development and Customizing tools, registers every change to a development object or a Customizing setting in a request. The rules it applies are worth knowing as a newcomer.
-
An object has to be in a change request before a user can create or change it. The editor asks for the request when you save.
-
A request holds one or more tasks. Developments, corrections and repairs are recorded in tasks and transported using change requests. Several developers can work on one project by each owning a task of the same request.
-
Once an object is in a request, it can be edited in that request only, and other developers can only display it until the request is released. That lock is how the system prevents uncoordinated parallel changes.
-
Development objects and Customizing settings are kept in separate requests: a Workbench request for objects such as classes and tables, and a Customizing request for configuration such as settings for company codes.
-
Releasing a task and then the request exports its content so it can be imported into the next system. A transport log is created automatically for each request and shows which objects were transported, who requested the transport and why.
The request editor, which shows the properties, the objects and the documentation of a request or task on tab pages, is
available in the Transport Organizer (transaction SE09) and in the Object Navigator (SE80). The extended view of the
Transport Organizer is transaction SE01; it adds request types without automatic transport routes, such as piece
lists, client transports and delivery transports.
For the expense claim example, a developer creates the table ZEXP_CLAIM in the package ZEXP_CLAIMS. The system asks for
a Workbench request, and the developer creates one with the description "Expense claims: first version". The request now
contains one task, owned by the developer, and the table is locked in that request. Releasing the task and then the
request makes the table available for import in the next system.
Source: Transport Organizer - Concept
The three-system landscape
SAP recommends a group of three systems: a development system DEV, a quality assurance system QAS and a production system PRD. All changes to repository objects and Customizing data are made in DEV. When the matching requests are released, they are imported into QAS, where the team tests whether the transports are complete. If the test succeeds, the same requests are imported into PRD. A two-system group, where the quality assurance client lives inside DEV, is possible for small implementations but can hide missing transports because cross-client data is shared. A single system that holds all roles is not recommended.
The Transport Management System (TMS, started with transaction STMS) models this landscape and runs the imports. The
route between the systems is defined by transport layers and transport routes. A consolidation route leads from the
development system to the quality assurance system for one transport layer; a delivery route leads on from there to the
production system, and every request flagged for import into the first target is flagged for the next one in the order
in which it was exported, so a newer version is never overwritten by an older one. TMS also has quality assurance
functions that let a reviewer approve or reject requests in the QA system before they continue.
The solid arrows are the classic transport routes of TMS. The dotted arrows show gCTS, where the Git repository takes the place of the transport directory and each follow-on system pulls the commit instead of receiving an import from the queue. A landscape can use either way, or both for different packages.
Creating and releasing transports from ABAP code
Most people work with transports in the Transport Organizer or ADT, but ABAP code can do the same. The XCO library has a CTS module that creates and releases Workbench and Customizing transport requests and finds the objects on a transport. The next listing follows the documentation sample: it reads the transport layer and transport target of a structure package, creates a Workbench request, and releases its tasks and then the request. It needs a transport target, which the sample derives from the package.
DATA(ls_package) = xco_cp_abap_repository=>package->for( 'ZMY_STRUCTURE_PACKAGE'
)->read( ).
DATA(lv_transport_layer) = ls_package-property-transport_layer->value.
DATA(lv_transport_target) = ls_package-property-transport_layer->get_transport_target( )->value.
DATA(lo_transport_request) = xco_cp_cts=>transports->workbench( lv_transport_target
)->create_request( 'My generated Workbench transport request' ).
DATA(lt_transport_tasks) = lo_transport_request->get_tasks( ).
LOOP AT lt_transport_tasks INTO DATA(lo_transport_task).
CHECK lo_transport_task->get_status( ) EQ xco_cp_transport=>status->modifiable.
lo_transport_task->release( ).
ENDLOOP.
lo_transport_request->release( ).
This listing requires an SAP system; not run here. The documentation says the new request is created with one unclassified
task in the name of the active user, and that releasing a request with the release option IGNORE_OBJECTS_CHECK has
the same effect as confirming the release in an interactive tool such as the ADT Transport Organizer when non-critical
issues, for example ATC findings, were detected.
gCTS: transports through Git
The Git-enabled Change and Transport System keeps the objects of a package in a Git repository on a Git server, in addition to the ABAP database. SAP describes it as a way to manage ABAP change and transport processes using Git as an external version management system, and it is available for Workbench and Customizing objects from SAP S/4HANA 2020. Using it is optional, so a team can start with a single test project.
Three points explain how it fits next to the classic tools.
-
gCTS is part of CTS, not a replacement. You can use it only together with the existing CTS, and you still develop in the classic ABAP development environment, for example ADT. Objects are still recorded in change requests and tasks; in addition, gCTS converts them to files and stores them in Git.
-
A package is managed either by classic CTS or by gCTS, and the choice is made through its transport layer. In gCTS the transport layer is a
Zfollowed by the virtual system ID (vSID) of the repository, and a package used with gCTS needs a transport layer different from the one used by the consolidation route to the next system. -
The import changes. Imports in target systems are performed by pulling commits and are no longer started in
STMS. A BAdI can push the changed objects of a released task to a Git repository. If only gCTS is used, no classic landscape with a transport domain controller, transport routes and a shared transport directory has to be configured, although the initial activation of TMS must still run in every system.
There is one limit. Requests created for SAP Note implementations, and modification adjustment transports after a Support Package import, cannot be pushed to Git and are not supported by gCTS, so a classic transport landscape stays necessary for them. SAP also says gCTS works with all Git servers in general and fully supports repositories on GitHub; for known restrictions with other servers and for the SAP Notes required for your SAP S/4HANA version, the documentation points to the central gCTS SAP Note 2821718. gCTS offers project "Piper" steps that connect it to continuous integration pipelines.
abapGit: a community Git client for ABAP
abapGit is "a git client for ABAP developed in ABAP" and is a tool to import and export code between ABAP systems. It is not part of CTS and it does not move changes along transport routes. It serializes each development object into text files that can be reviewed in a normal Git workflow, which is unlike traditional transport files. The community version is documented at docs.abapgit.org and requires ABAP 702 SP 8 or higher; the version that is part of SAP BTP and SAP S/4HANA Cloud is documented on help.sap.com and has different capabilities and supported object types.
It comes in two forms. The standalone version is one large program, installed by copying its source into a new report
(ZABAPGIT_STANDALONE) and run from SE38; it is meant for users. The developer version is meant for contributors,
runs as transaction ZABAPGIT, and is installed as a repository itself. Online projects talk to a Git server; offline projects
exchange ZIP files, which suits systems without internet access.
The way abapGit handles packages and transports is the part to remember.
-
An abapGit repository does not store any SAP package names. When you create the repository in a system you choose the top package, and abapGit can create it, with its sub packages, automatically.
-
Depending on the package type, abapGit decides what kind of transport the change needs. When it pulls or uninstalls a repository it asks for a matching transport request, so a pull into a transportable package creates changes that travel to the next system by the usual transport route.
-
A project is committed with "Stage", "Add All and Commit" and "Commit"; a commit needs a comment, a committer name and an email address. The repository then holds a
.abapgit.xmlfile and a/src/folder with the objects.
The local playground used for the runnable examples of this site keeps its objects in that same file layout. This listing
is the real output of ls src in a copy of the lab: each object is one or more files whose names carry the
object name and type.
zcl_greeter.clas.abap
zcl_greeter.clas.testclasses.abap
zcl_greeter.clas.xml
zexp_claim.tabl.xml
zhello.prog.abap
zhello.prog.xml
The .abap file holds the source code and the .xml file holds the attributes that the system keeps next to it. For the
program ZHELLO the XML file starts with an abapGit element that names the serializer and then holds the program
attributes (the program name ZHELLO, the program type and the original language). In an SAP system the same files would be
created and read by abapGit; here the playground only reads them.
Which tool for which system
The tools overlap, so it helps to see what each one is for.
| Tool | What it moves | Where it belongs |
|---|---|---|
Transport Organizer and TMS (classic CTS) |
Workbench and Customizing requests along consolidation and delivery routes. |
Standard ABAP systems such as SAP S/4HANA on premise and Private Edition, and SAP NetWeaver AS ABAP. |
gCTS |
The same requests, with the objects stored as files in a Git repository and imported by pulling commits. |
SAP S/4HANA from 2020, on top of CTS. |
abapGit |
Development objects as text files between ABAP systems and Git, outside the transport route. |
Open-source projects and developer workflows; an SAP version exists in SAP BTP and SAP S/4HANA Cloud. |
For the products themselves, the ABAP Cloud background documentation lists the lifecycle management solution each one relies on: Transport Management for SAP S/4HANA Cloud, ABAP Lifecycle Management for the SAP BTP ABAP environment, and the Change and Transport System for SAP S/4HANA Cloud Private Edition and SAP S/4HANA. It also says ABAP Cloud supports CI/CD and Git integration and a dedicated transport environment for key users on the SAP Fiori launchpad. Separately, SAP Cloud ALM can orchestrate deployment across a landscape. It supports three transport technologies, CTS for ABAP-based systems, the Cloud Transport Management service for cloud content, and the Adaptation Transport Organizer for SAP S/4HANA Cloud, and it does not handle transports itself but through the deployment tool.
HANA Transport for ABAP (legacy)
Some ABAP systems on SAP HANA also hold native HANA content, such as views kept in the HANA repository, next to ABAP objects. HANA Transport for ABAP (HTA) lets you synchronize such objects and packages from the HANA repository into an HTA repository in the ABAP system and add them to a transport request, so the HANA content travels with the ABAP objects. SAP describes it for cases where ABAP and HANA content are closely linked, recommends enhanced CTS (CTS+) for transporting SAP HANA objects in general, and names HTA for HDI as the successor for HDI objects. For new work, keep native HANA content out of the ABAP transport where you can, and prefer the ABAP-managed code pushdown described in ABAP for SAP HANA and Code Pushdown.
The book ABAP Development for SAP HANA shows this area as it was in its time. It describes the HANA transport container, a transport object that stands for exactly one delivery unit, created in ABAP Development Tools, and it assumes SAP HANA Studio and the HANA repository. That container has been superseded by HTA, and the whole tooling around the HANA repository has been replaced for new development. The book also appeared years before gCTS (2019 and later), so it says nothing about Git-based transports.
Source: SAP Support: SAP HANA and HALM
Summary
-
A package groups development objects and is what connects an object to the Change and Transport System; its software component decides the language version and which other packages its objects may use.
-
A package interface lists what a package offers to other packages; the older Workbench documentation explains use access and package checks.
-
A transport request carries changes, a task is one developer’s part of it, and an object in a request is locked for other developers until release. Workbench and Customizing changes go in separate requests.
-
The recommended landscape is DEV, QAS and PRD, linked by a consolidation route and a delivery route that TMS runs.
-
gCTS adds a Git repository to CTS: follow-on systems pull commits instead of importing from a queue, and SAP Note and modification adjustment transports still need classic CTS.
-
abapGit exchanges objects as text files with Git and asks for a transport request when it pulls into a transportable package; HANA Transport for ABAP is legacy for native HANA content.