Sub topic 8
Extensibility: in-app, developer, and classic options
This chapter assumes you know the three editions (Cloud Public Edition, Cloud Private Edition, on-premise) and the split of operating responsibility between SAP and the customer. It also assumes you have read ABAP before. You do not need to have written ABAP Cloud code.
Extensibility is the set of ways you add to or change standard S/4HANA behavior without replacing the product. Each edition allows a different set of ways. The set you may use determines how much custom code you can write and how hard future upgrades will be.
The four extensibility styles
S/4HANA offers four styles. The first three change the S/4HANA system itself or run inside it. The fourth runs next to it.
- In-app extensibility (also called key user extensibility). Business experts add fields, logic, and views through apps in the SAP Fiori launchpad. No development environment is needed.
- Developer extensibility. Developers write ABAP in ABAP Development Tools (ADT), the Eclipse-based IDE. In ABAP Cloud, they may only use released APIs.
- Classic extensibility. Developers use the older ABAP toolset: user exits, classic enhancement spots, modifications, and direct access to unreleased tables and function modules.
- Side-by-side extensibility. Extensions run outside the S/4HANA system on SAP Business Technology Platform (BTP) and talk to S/4HANA through released APIs and events.
In-app extensibility
In-app tools cover the common needs:
- Custom fields that appear on standard UIs, in reports, and in forms.
- Custom logic, such as a BAdI implementation written in a restricted ABAP editor.
- Custom CDS views and analytical queries.
- Custom business objects with their own persistence.
- UI adaptation, such as hiding fields or reordering sections.
- Form and email template changes.
Every edition supports in-app extensibility. In Public Edition it is the first option you should consider, because the system is multi-tenant and SAP upgrades it for everyone on a fixed schedule. In-app extensions are stored as metadata and are checked by SAP's lifecycle tooling, so they usually survive upgrades.
Developer extensibility
Developer extensibility is the style for logic that does not fit the in-app tools. You write classes, CDS view entities, behavior definitions, and RAP (RESTful Application Programming Model) business objects in ADT.
The language version is ABAP for Cloud Development. The compiler enforces two rules:
- Your code may only use objects that SAP has marked as released for cloud development (release contract C1 or similar).
- Your code may only use the restricted language subset.
Developer extensibility with ABAP Cloud is available in all three editions. In Public Edition it is the only form of ABAP development in the system.
A custom CDS view entity that reads a released view looks like this:
@AccessControl.authorizationCheck: #NOT_REQUIRED
@EndUserText.label: 'Product basics'
define view entity ZI_ProductBasic
as select from I_Product
{
key Product,
ProductType,
BaseUnit
}I_Product is a released interface view. A view that selected from an unreleased table such as MARA would produce an error in an ABAP Cloud project. The compiler stops you at development time. You do not find out at upgrade time.
Classic extensibility
Classic extensibility is what most ECC developers know. It includes:
- Customer exits and user exits.
- Classic BAdIs and enhancement spots in unreleased code.
- Implicit enhancements.
- Modifications of SAP-delivered objects.
- Custom reports and function modules that read SAP tables directly.
The following statement is valid classic ABAP:
SELECT SINGLE matnr
FROM mara
INTO @DATA(lv_matnr).It works in Private Edition and on-premise. In Public Edition an ABAP Cloud project rejects it because MARA is not released. Classic extensibility is not allowed in Public Edition at all.
Private Edition and on-premise still allow it, but it is the style that causes the most upgrade effort. A modification of an SAP object has to be re-adjusted at every upgrade. A direct read of an SAP table breaks when SAP changes the table, which has happened in the move from ECC to S/4HANA (for example, the redesign of the finance tables).
Side-by-side extensibility
Side-by-side extensions are separate applications on SAP BTP. They can use the ABAP environment (ABAP Cloud on BTP), the Cloud Application Programming Model (CAP) with Node.js or Java, or other runtimes. They call S/4HANA through OData or SOAP APIs and subscribe to business events.
Choose this style when:
- The extension has its own lifecycle, release schedule, or user group.
- It needs services S/4HANA does not provide, such as AI services or external partner integration.
- It must serve users outside the ERP, such as customers or suppliers.
- The load of the extension should not compete with core ERP processing.
Side-by-side extensibility works with all three editions. The next chapters on the clean core and SAP BTP integration treat it further.
What each edition allows
| Style | Public Edition | Private Edition | On-premise |
|---|---|---|---|
| In-app (key user) | Yes | Yes | Yes |
| Developer (ABAP Cloud, released APIs only) | Yes, the only ABAP option | Yes, recommended | Yes, recommended |
| Classic (unreleased objects, modifications) | No | Allowed, discouraged | Allowed, discouraged |
| Side-by-side on SAP BTP | Yes | Yes | Yes |
Private Edition and on-premise are not limited to ABAP Cloud. They let you mix both worlds, which is useful during a conversion from ECC where old custom code already exists. SAP's guidance is to write all new code in ABAP Cloud and to move old code over time.
Choosing a style
The order below goes from the lowest upgrade risk to the highest. Go down the list only when the earlier option cannot meet the requirement.
Common errors
- Assuming Private Edition means "do what you like". SAP hosts the system and applies the upgrades on a cadence you agreed to. Heavy classic modification makes those upgrades slower and riskier, even though the system allows them.
- Treating in-app extensions as risk-free. A custom field is safe. A custom logic BAdI that calls unreleased code, or that runs a slow loop in a posting transaction, can still break a process. Test it as you would any code.
- Copying ECC code into an ABAP Cloud project. It fails the syntax check on unreleased objects. The usual fix is to find the released successor API, not to ask for an exception.
- Choosing side-by-side for everything. Extra latency, a second operations model, and extra licensing apply. Use it where its benefits are real.
- Mixing up "developer extensibility" and "classic". Both involve ABAP developers. The difference is the release contract, not the IDE or the people.
Exercises
Exercise
A sales team needs a new "Delivery Priority" field on the sales order screen, shown in a report and in the printed form. The company runs Cloud Public Edition. Which style should you use first, and why?
Show answer
In-app extensibility. A custom field can be added through the key user tools, appears on the UI, in reports, and in forms, and needs no code. It is also stored in a way that survives SAP upgrades. Developer extensibility or side-by-side are only needed if the field requires logic the in-app tools cannot provide.
Exercise
A company on on-premise S/4HANA has an old report that runs SELECT ... FROM mara. They plan to move to Public Edition later. What will happen to that report in an ABAP Cloud project, and what should they do now?
Show answer
The ABAP Cloud syntax check rejects the report because MARA is not a released object, and classic extensibility is not allowed in Public Edition. Now, they should replace the direct table access with a released API or CDS view such as I_Product, and write new code in ABAP Cloud, so the code is ready for the move.
Exercise
Name two situations where side-by-side extensibility on SAP BTP is a better choice than developer extensibility inside S/4HANA.
Show answer
Any two of these: the extension has its own release schedule, it serves users outside the ERP such as customers or suppliers, it needs services S/4HANA does not provide, or its load should be kept away from core ERP processing.