Developing Business Applications with
Application Programming Model of SAP Cloud Platform
Sanjay Patil, Babu Ganesh V.
Strategy & Product Management, SAP Cloud Platform
Oct 2018
PUBLIC
WebIDE/ App Center/
UI5 / Fiori Mobile Co-Pilot
Cockpit Marketplace
APIs & Events
Rates & LOBs &
Master data objects
Commerce Globalization Master Data …
Measures Industries
Analytics Machine Learning Blockchain IoT Data Intelligence Big Data
Data
Integration & Data Privacy & Dev XP & DevOps Management
Business Suite UX & Mobile Collaboration
Orchestration Security
BW
2 2
NEO
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 1) BETA , 2) planned innovations / future direction 2
Cloud Foundry environment in SAP Cloud Platform
Environment
Authorization & Trust Corporate
App SAP Web IDE App Autoscaler
XSA/XSC Management Identity Provider
Developer Full-Stack
Your
Application
Cloud Logging Services
Foundry
CLI
RabbitMQ
… Redis Connectivity Cloud
Connector
SAP
Admin Cloud
SAP HANA PostgreSQL
Platform Job Scheduler Innovation Services
cockpit
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 3
Demo Application Scenario
Business Wishlist of Customer Could we help
Innovation Items Input Franck and Mary
Franck is a Franck maintains Customers like to get cool items
Manager in a a Wishlist of Mary provide in the store?
home furniture attractive items ratings for Franck
franchise with for adding to his to prioritize his
dwindling sales assortment Wishlist
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 4
Furniture Shop Application - Architecture See TechEd Session OPP363
Environment
SAP HANA
Franck SAPUI5 Application Wishlist service
Store Manager with [SAP Business Application] On-Premise
Connectivity Cloud
passion for attractive System
Connector
assortment of item
PostgreSQL
Mary SAPUI5 Application Ratings Service
Customer Willing [Node.js Express App]
Rabbit MQ
to Provide Input
User Interface Microservices Backing Services
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 5
Developing Full-Stack Business Applications
SAP Web IDE SAP Cloud Platform
User Interface Cloud Foundry
Business Services
Data Models
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 6
Demo ..
http://bit.ly/opp363-docs
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 7
Developing Full-Stack Business Applications
SAP Web IDE SAP Cloud Platform
User Interface Cloud Foundry
Business Services
Data Models
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 8
Define Data Models
SAP Web IDE SAP Cloud Platform
User Interface Cloud Foundry
Business Services
Data Models
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 9
The 12-factor app
[http://12factor.net/]
I. Codebase VII. Port binding
- One codebase tracked in revision control, many deploys - Export services via port binding
II. Dependencies VIII. Concurrency
- Explicitly declare and isolate dependencies - Scale out via the process model
III. Config
- Store config in environment IX. Disposability
- Maximize robustness with fast startup and graceful
shutdown
IV. Backing Services
- Treat backing services as attached resources
X. Dev/prod parity
V. Build, release, run - Keep development, staging, and production as
- Strictly separate build and run stages similar as possible
VI. Processes XI. Logs
- Execute the app as one or more stateless processes - Treat logs as event streams
XII. Admin processes
- Run admin/management tasks as one-off
processes
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 10
Business Application
@ SAP Cloud Platform Cloud Foundry Environment
A logical view of a sample business app:
Environment
• Consists of multiple micro-services which
are deployed as separate applications Your Application
any buildpack
Your Service 1
• Each micro-service can be developed in service instance App Autoscaler
different language Your Service 2
service instance PostgreSQL
App User
• Micro-services use multiple backing
Your Service 3
services service instance Redis
Admin
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 11
Backing Services besides SAP HANA
Provision, Operate and Scale
MongoDB
PostgreSQL
Object Store
Redis
RabbitMQ
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 12
Define Business Services
SAP Web IDE SAP Cloud Platform
User Interface Cloud Foundry
Business Services
Data Models
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 13
Application Deployment Process
$ cf push
UPLOAD STAGE START
➢ upload application ➢ build droplet ➢ start app container
Find more info: https://docs.cloudfoundry.org/devguide/deploy-apps/app-lifecycle.html
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 14
How applications are staged and started?
Staging is the process of creating an application package (droplet) that contains all needed components for
the application to run (e.g. runtime, drivers, additional libraries, etc.).
staging
+
buildpack droplet
+ start
droplet rootfs
application
For more information: http://docs.cloudfoundry.org/concepts/how-applications-are-staged.html
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 15
Runtimes & Containers
Overview
With Cloud Foundry environment, SAP Cloud Platform enables the usage of additional programming languages and
frameworks via buildpacks*
….
Java HTML5 Node.js <your choice>
▪ Develop, deploy and ▪ Develop and run ▪ Benefit from multiple ▪ Bring your own
operate Java HTML5 applications Node.js packages language and runtime
applications available of choice
▪ Benefit from multiple
▪ E.g. complex SAPUI5 code ▪ Develop and run ▪ Choose from existing
integration projects templates Node.js applications in community buildpacks
the cloud or develop your own
* Note: There is Enterprise Support only for selected buildpacks.
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 16
Define User Interface
SAP Web IDE SAP Cloud Platform
User Interface Cloud Foundry
Business Services
Data Models
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 17
Multitarget Application (MTA) Concept
Motivation – Heterogeneity of cloud software…
Cloud applications often show a high heterogeneity
▪ Consisting of multiple interdependent software “modules”
▪ Written in different languages (polyglot)
▪ Using multiple programming paradigms and development tools SAP Cloud Platform
▪ Deployed to multiple target runtimes Roles Java
JavaScript
▪ Involving different products
HTML5
…
As modules provide single coherent application
Stored DB
purpose, shared single lifecycle is desired procedure Core Data
Cloud Integration SAP Services model
▪ to deploy all parts together, in the right order, automatically HANA
▪ to manage configuration of complete solution
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 18
Multitarget Application (MTA) Concept
…and our approach to tackle it
To ease handling of such a combined single lifecycle, SAP introduced
multitarget applications (MTAs)
▪ Hand-over artifact between development and operation + delivery construct for partners
▪ Can be delivered, transported, linked to SAP software components, and deployed
▪ Process can be automated in a continuous integration pipeline
▪ For more information about MTAs, see SAP Help Portal
Module 1 Java
module
module
Archive Deploy
HTML5
MTA deployment
descriptor
MTA SAP HANA
archive
(MTAR) …
Develop Operate
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 19
The Application Programming Model for SAP Cloud Platform
The Application Programming Model for SAP Cloud Platform is SAP Web
IDE
an integrated framework of tools, languages and libraries to Eclipse
VSCode CLI CDS
efficiently and rapidly build enterprise services and
applications in a full-stack development approach. Node.js
express
Service
SDKs
It guides developers along a golden path of best practices,
Java EE, REST
Spring OData
allowing them to focus on their domain while relieving them
from tedious technical tasks. HANA Fiori
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 20
Overview
We complement cloud-native technologies with…
▪ a CDS-based Services framework
localIDE
SAPApp
Fiori
UIs?
+ other
Platform Services
Web IDE +Web
with 1st-class support by and for…
CDS
CDS
CDS Domain Logic?
Service SDKs
▪ SAP Web IDE w/ tailored tools
local
SAP
Domain
HANA
Model?
+ other
▪ SAP Fiori
Infrastructure ▪ SAP HANA
▪ S/4 Extension scenarios
Resulting in…
planned:
A consistent end-to-end programming model for
enterprise services & applications
Guidance and best practices leveraging proven
SAP technologies + Open Source software
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 21
Best Practices & Benefits…
SAP Fiori Angular React Vue •••
Capture Intent on Conceptual Level
Accelerate your Projects
SAP Web IDE Cloud Foundry
Core
Leverage proven Methods
Eclipse Kubernetes
Node.js Java
Openness & Flexibility
XSA
VSCode Core Data Services
Enterprise Qualities
local
•••
Cloud Qualities
SAP HANA PostgreSQL sqlite •••
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 22
Join the new SAP PartnerEdge – Build Learning Room
1. Join the learning room: https://enrollment-
ac82d52a4.dispatcher.hana.ondemand.com/index.html?ite
mID=LR_PE_BUILD_EN
2. Webinars
View upcoming webinars for ‘build’ partners
https://jam2.sapjam.com/groups/horvpuOFxQKkR4B
0LCzd0h/overview_page/nmDANxx9GurUtjX2tugf4V
?edit_mode=true
Reference ppt for upcoming / past webinar:
https://jam2.sapjam.com/groups/horvpuOFxQKkR
4B0LCzd0h/content?folder_id=voAe7eMotJd2T0M
0ct3Sns
Join in the discussion regarding upcoming / past
webinar
https://jam2.sapjam.com/groups/horvpuOFxQKkR4B
0LCzd0h/forums?folder_id=xrxFmSJLVPuqRalDvRD
EoT
© 2018 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 23
Thank you!
Sanjay Patil Babu Ganesh V.
Twitter: @sanjaypatil Twitter: @babuganesh1982
Email: sanjay.patil@sap.com) Email: babu.ganesh.v@sap.com)