CI/CD is a hot topic in the world of software development. It stands for Continuous Integration and Continuous Deployment (or Continuous Delivery), and it plays a pivotal role in modern software development processes. CI/CD is a set of practices, tools, and principles aimed at automating and streamlining the software development lifecycle.
Most modern developer tools, such as VS Code, even SAP BAS, etc. now come equipped with native Git integration. However, SAP Cloud Integration differs significantly from other development tools, and as a result, implementing a CI/CD solution for it presents unique challenges.
Getting started with this process can be relatively straightforward, but it does necessitate a certain level of familiarity with Git, pipelines, and some knowledge on any CI/CD tools such as Jenkins, GitHub Actions, Bitbucket, Azure Pipelines or GitLab, among others. Moreover, you’ll need to install additional tools or programs on your local computer to kickstart the CI/CD process.
However, it’s important to note that while constructing a CI/CD pipeline using CI/CD tools can be relatively straightforward, resolving issues or errors in the pipeline and maintaining it demands additional skills, time, and effort. SAP customers may need to train their workforce to effectively use CI/CD tools.
All the above solutions have been crafted by experts and possess their own merits. However, it’s important to note that all the above solutions have not been developed using the native style of SAP Cloud Integration development, which typically involves the use of the building blocks of the integration artifacts available. With this in mind, my goal was to leverage the inherent capabilities of SAP Cloud Integration, alongside the Power of Groovy and APIs, to create a solution that aligns more closely with the platform’s core development style.
Allow me to introduce another possible approach to implement the Continuous Integration (CI) & Continuous Delivery/Deployment (CD) pipelines for SAP Cloud Integration, that enables anyone to setup CI/CD pipelines easily without even relying on native Git, a prerequisite for most CI/CD and DevOps tools. Designed with ease-of-use in mind, making it simple and straightforward to begin without the need for any additional external tools or specialized knowledge. It is designed entirely around the core building blocks and artifacts of SAP Cloud Integration.
Fig.1 – General architecture
The diagram describes the general architecture of the solution, beginning with SAP Cloud Integration where integration artifacts/flows are executed as part of a CI/CD pipeline. GitHub is used as the Source Code Management (SCM) tool since it is the most popular choice in the community.
These integration artifacts use the standard public ODATA APIs of the SAP Integration Suite and the public GitHub REST API under the hood to create CI/CD pipelines.
Since different SAP customers have diverse landscapes and processes, CI/CD pipelines also vary for each SAP customer. Instead of supporting only one approach and potentially missing out on others, the design/architecture aims to provide a common framework. This framework enables anyone to easily select and adapt useful scenarios (as required), such as synchronizing artifacts from a tenant to GitHub, uploading artifacts from GitHub to a tenant, or copying/transporting artifacts from one tenant to other instance/tenant, and deploying artifacts to the runtime if necessary.
These integration artifacts are built in a way that requires you to replace only a few configuration parameters specific to your environment and organization/project, leaving the rest unchanged. Furthermore, you can use these integration artifacts as a starting point for further customization tailored to the needs of your organization or project.
This integration artifacts is published as an open source project.
Firstly, it guarantees that you will always have access to the complete source code, which will be readily available on GitHub and included in every project release. Secondly, the open-source license, specifically the MIT License, provides you with the freedom to make modifications to the code. This is released under the MIT License, which is known for its permissiveness and simplicity among open-source licenses. This means that if you wish to make additions or alterations, you can do so without any restrictions.
You can download the complete integration package from GitHub at this link: Download. The full source code and all other necessary files are included in the download. Everything you need is also available in the GitHub repository ci-cd-sap-cloud-integration. For documentation and installation instructions, please refer to the user documentation. If you encounter any issues, please do let me know by either commenting below or creating an issue on GitHub.
Contributions from the community are welcome. If you would like to contribute code, provide fixes, or suggest improvements, please refer to our contribution guidelines page on GitHub.
This integration package contains 4 integration flows. For more details, please refer to the table below.
Reference to General Architecture | Integration Flow Name | Descriptions |
---|---|---|
1. | Sync Integration Contents to GitHub | Sync all or specific integration contents (only packages, iflows, value mappings) from the SAP Cloud Integration tenant to GitHub Repository to store and see the full history of changes |
2. | Sync Integration Contents to GitHub – Delta | Check the SAP Cloud Integration tenant for a new version of your integration contents (only packages, iflows) and if a new version exists, sync the changed integration contents to GitHub Repository and keep track of the latest changes. |
3. | Transport or Migrate Integration Contents | Export the latest version of all or specific integration artifacts (either packages or iflows or value mappings) from the Source tenant and either import or update the artifact on the Target tenant without using any external tool. |
4. | Upload Integration Contents from GitHub | Download the latest version of either an integration flow artifact or resources of an integration flow artifact from GitHub repository and either update or create the artifacts on the tenant. |
Some Key Points:
Recommendation:
Before going deep into the topic, I think it is very important to understand the underlying ideas, concepts, and design style of the above development by experimenting in your trial or non-production tenant with a smaller set of interfaces. Once you grasp the concept of each exchange property, Groovy, chaining of API requests, and HTTP Receiver configuration, you will easily able to change and adapt as per your project needs.
Each above integration flow provides the capability to filter artifacts by [Packages, Integration Flow, Value Mapping]. For more details, please refer to the table below. Additionally, please note that filtering options for other artifacts types will be added in upcoming releases.
Integration Flow Name | Packages | Integration Flow | Value Mapping |
---|---|---|---|
Sync Integration Contents to GitHub | Yes | Yes | Yes |
Sync Integration Contents to GitHub – Delta | Yes | Yes | No |
Transport Integration Contents | Yes | Yes | Yes |
Upload Integration Contents from GitHub * |
No | Yes | No |
* Additionally you can filter (single or multiple) specific resources of an integration flow artifact.
Additionally, each above integration flow provides optional parameters. For more details, please refer to the table below.
Integration Flow Name | Deploy | Send Notification to MS Teams Channel |
---|---|---|
Sync Integration Contents to GitHub | No | Yes |
Sync Integration Contents to GitHub – Delta | No | Yes |
Transport Integration Contents | Yes | Yes |
Upload Integration Contents from GitHub | No | No |
To use this integration artifacts, you will need the following:
For the Neo Environment, please refer to steps 1 and 2 in the Neo documentation. Assign the roles mentioned above to the user ‘oauth_client_’. Copy the Token Endpoint (found in the branding tab), Client ID, and Client Secret to your clipboard for use in Step 4 when creating the OAuth2 Client Credentials.
integration-content-repo or sap-cloud-integration-artifacts
If the prerequisites are fulfilled, you’ll be ready to configure the external parameters of the integration flow!
Follow the configuration guide for each interface in the table below, which contains links to their respective configuration guides.
Integration Flow Name | Config Guide Link |
---|---|
Sync Integration Contents to GitHub | [Link] |
Sync Integration Contents to GitHub – Delta | [Link] |
Transport Integration Contents | [Link] |
Upload Integration Contents from GitHub | [Link] |
Integration Flow Name | Walk-through/Demo Link |
---|---|
Sync Integration Contents to GitHub | [Link] |
Sync Integration Contents to GitHub – Delta | [Link] |
Transport Integration Contents | [Link] |
Upload Integration Contents from GitHub | [Link] |
In the upcoming release, I have planned to implement the following features:
Based on feedback and responses from the community, I am open to considering other features as well.
This was a humble attempt to create an alternative approach for building CI/CD by leveraging the inherent capabilities of SAP Cloud Integration, harnessing the power of Groovy, chaining APIs, and seeing how far I could go with it. I would also like to invite you all to share your feedback or thoughts in the comments section. I’m certain there are still opportunities for improvement and ideas for new rules or features that can be added to make this solution even better and more robust.