Skip to content

manjinsi/cloud-sdk-training-sandbox

Repository files navigation

SAP Cloud SDK Training Sandbox

Description

This repository is created to conduct an SAP Cloud SDK training with the goal to implement a sample Business Partner Address Manager Application based on Spring Boot and the SAP Cloud SDK from SAP.

It contains the structure and definition of one SAP Cloud SDK project with an skeleton application. This application will be enchanced by the participants during the training.

The developed application has the following business scope:

  • Display buisness partners in a search list (fetching data from S/4HANA)
  • Display single partner detail page (fetching data from S/4HANA)
  • Add address information to business partner (add data to S/4HANA)
  • Update address information (update data to S/4HANA)
  • Delete address information from business partner (delete data to S/4HANA)

Preparation

Please setup the local development and infrastructure environment beforehand:

Tools

  1. Download and Install Java SDK 8.
  2. Download and Install the latest Eclipse version.
  3. Download and Install the latest node.js version.
    • Please add the installation folder to the Windows PATH environment variable

Clone Repository

Please clone latest master branch from this repository and import it into the Eclipse IDE environment

Project Structure

The sample SAP Cloud SDK project has the following structure

  • application The actual source code of the Java Spring Boot application.
  • cx-server The SAP Cloud SDK provides a fully configured CI/CD pipeline with predefined Jenkin configuration.
  • integration-tests Contains fully integrated end-end JUnit tests starting from simulating REST calls.
  • mock-server During the training we will have no real access to an S/4HANA system. Therefore, to test the backend connectivity we will use an OData mock server based on a a simple Node.js application. The server makes it possible to test the SAP S/4HANA integration capabilities of the SAP Cloud SDK without access to an SAP S/4HANA system. The server hosts an OData v2 mock service that mimics the business partner API of SAP S/4HANA Cloud to a limited extent.
  • unit-tests Contains all application related to JUnit tests.

Running the Application locally

  1. Before the starting the Spring Boot application please install and run the OData mock server locally
  2. Run the Spring Boot Application with the following option
    • Go to Run Configuration -> Java Application -> Right Click -> New
    • Select the application project and the main class is com.capgemini.sandbox.Application
    • Go to Environment -> New
      • Name: destinations
      • Value: [{"name"="ErpQueryEndpoint", "url"="http://localhost:3000"}]
  3. The UI Frontend can be reached under this link