Download as pdf or txt
Download as pdf or txt
You are on page 1of 11

PUBLIC

openSAP
Build Resilient Applications on SAP BTP with Amazon Web
Services

Week 3 Unit 1

00:00:06 Welcome to this open SAP course on building applications with SAP Business Technology
Platform along with Amazon Web Services.
00:00:16 Welcome to week 3, unit 1. In this unit, we are going to discover Procode app development
on SAP BTP.
00:00:27 Let's look at the agenda. We will be covering SAP Cloud Application Programming Model,
00:00:36 SAP Business Application Studio, and we will also be learning the basics of what SAP
HANA Cloud is, SAP Fiori elements are,
00:00:45 and we will also be learning about Amazon's simple notification service, a comparison
between Amazon's two
00:00:54 services, SQS and SNS. And we'll also be looking at the exercise that we'll be building on
throughout this
00:01:04 week. Let's start with SAP Cloud Application Programming Model, in short called as CAP.
00:01:14 SAP CAP programming model is a framework of languages, libraries and tools for building
enterprise-grade services and applications.
00:01:26 With SAP CAP, we can create applications using popular technologies like Java and
Node.js.
00:01:35 CAP lets you accelerate application development using out-of-box solutions for recurring
tasks.
00:01:43 We can develop business applications based on various databases such as SAP HANA,
SQLite, Postgres, SQLDB.
00:01:55 And we will also be able to integrate these applications with connections to products within
SAP or even outside the world of SAP.
00:02:09 There are numerous benefits to develop your applications with CAP technology in SAP
BDB.
00:02:17 First of all, as we covered in the previous slide, it supports Java and Node.js.
00:02:24 And in CAP, the primary focus is on the domain where we focus on what is to be developed
rather than how.
00:02:34 Many of the recurring tasks are automated and served out of the box. It serves CRUD
requests efficiently and automatically.
00:02:46 We have out-of-the-box support for SAP's UI technology, SAP Fiori UI, and also connection
to SAP HANADB.
00:02:56 With CAP, we have dedicated tools to support the development journey. We have the SAP
Business Application Studio and we also have support
00:03:07 for Visual Studio Code. So what is CAP application programming model?
00:03:16 In CAP application programming model, the term domain refers to a specific business area
or a subject matter within an
00:03:23 organization. The Core Data Services, CDS, is a domain modeling language of SAP CAP
model.
00:03:35 Developers can use CDS to model the problem domain by defining the entities that are
contained in the model.
00:03:46 This model captures the static data-related aspects of a problem domain in terms of
relationships with other entities.
00:03:58 SAP Business Application Studio. So SAP Business Application Studio is a cloud-based
integrated development
00:04:06 environment, and it is fully managed by SAP. It is available as a cloud service on SAP BTP.

00:04:16 With SAP Business Application Studio, we can create business applications based on SAP
CAP model, and it can be done easily and quickly.
00:04:28 We are developing business applications based on CAP programming model with dedicated
tools that are provided under Business Application Studio.
00:04:39 We can design and build user interfaces using SAP UI or SAP Fiori. Within SAP Business
Application Studio, we can easily test and also
00:04:51 debug the application and finally deploy it to SAP BTP. For the exercise that we are going to
do in this week,
00:05:03 we also have to know the basics of SAP HANA Cloud. SAP HANA Cloud is a fully managed
database as a service solution that is provided
00:05:14 under SAP Business Technology Platform. With SAP HANA Cloud, you can build and
deploy applications
00:05:21 that leverage the power of SAP HANADB in SAP Business Application Studio. We will be
able to integrate data sources from on-premise systems,
00:05:31 cloud applications and external data sources. In this lecture, we will be able to run complex
analytical queries and large data
00:05:39 assets. And we will also be able to manage our data platform and less frequently
00:05:47 access data too. With the database covered, we now move to the UI technology
00:05:55 on the front end, which we will be using the SAP Fiori elements.
00:06:01 SAP Fiori elements is a framework provided by SAP that simplifies the development of SAP
Fiori applications.
00:06:10 With SAP Fiori elements, we can create SAP Fiori application based on OData service
without any JavaScript UI coding.
00:06:20 SAP Fiori applications uses the following floor plans. It has the option to create a list report,
object page, analytical list page,
00:06:30 overview pages or work list. All of these provided as templates to jumpstart our
development journey.
00:06:39 In order to do the exercise in this week, we will be needing the following components.
00:06:47 We will be needing access to the Business Technology Platform trial account, where we will
use the cloud application programming model,
00:06:55 the Business Application Studio, HANA Cloud and in turn the HANA DB and theory UI
elements.
00:07:03 And we also need access to AWS free tier account and Amazon's SNS service. With that, I
want to move on to the architecture
00:07:17 diagram or the data flow diagram of the exercise that we will be building this week.
00:07:25 We will be building a CAP application that will be eventually reading the data from the
HANA cloud database and will call the service to trigger
00:07:40 Amazon's SNS service to send a notification. We will be doing this exercise over the course
of the week
00:07:50 and you will be guided along step by step. With that, now I hand it over to our AWS
colleague Ferri to cover
00:08:06 Amazon's SNS topic. Over to you, Ferri.
00:08:10 Thank you, Madan. Before you start building the solution, let's first visit Amazon Simple

2 / 11
00:08:16 Notification Services, or Amazon SNS, which is a managed service that provides message
delivery from publishers or subscribers,
00:08:25 also known as producers and consumers. Publishers communicate asynchronously with
subscribers by sending messages
00:08:32 to a topic, which is a logical access point and communication channel. Clients can subscribe
to the SNS topic and receive published messages
00:08:42 using a supported endpoint type, such as Amazon Kinesis Data Firehose, Amazon SQS,
mobile text messages, and others.
00:08:52 It is a highly reliable and scalable service that you can use to create event-based
architecture applications
00:08:58 through AWS SDK and CLI. In the application-to-application construct,
00:09:04 SNS can send various subscribers as you can see from the diagram, be it SQS for further
message queuing, Lambda for application processing,
00:09:14 HTTPS for integration, and Kinesis Data Firehose for streaming-related services, including
archiving to S3 bucket.
00:09:23 In the application to person construct, SNS can send various subscribers such as wild text
messages or SMS
00:09:30 mobile push and email notification. Let's do a contrast and compare with another service
called Amazon Simple
00:09:38 Queue Services or SQS which has the following features. Fully managed message queue
services, scales almost infinitely
00:09:47 with simple and easy-to-use API and that letter Q support. Standard and VIFO options, the
buffering capability makes consumer easy to scale in
00:09:57 the event that we have a sudden search of messages coming from senders. Amazon SNS
on the other hand, send notifications to various subscribers
00:10:07 based on publisher's messages without buffering. So, when there's a surge of messages
coming from publishers, consumers
00:10:14 must take care of its own scaling mechanism. Let's examine this first SNS architecture
example.
00:10:23 You can create two paths from publishers, in this case CAP application, that creates
business partner to route the respective SNS subscription,
00:10:33 one for the US business partner and the other one for EU business partners, which will then
be routed to the client,
00:10:39 which in this case SQS or Simple Queuing System or NLAMDA for further processing such
as force code validation, text code validation and so on.
00:10:49 The SQS is inserted here to ensure that subscriber scaling is predictable.
00:10:55 So when there is a search from publishers, there are no messages lost, and the messages
are processed accordingly.
00:11:01 This architecture is easy to understand, but not optimized as we can make it simpler on the
SNS deployment part.
00:11:08 Let's look at our next slide. In this alternative architecture, you let Amazon SNS route the
events
00:11:21 in accordance to the subscription by the SQS to the related respective queuing system or
SQS for US orders and EU orders queue and lambda for further
00:11:32 processing. This architecture will provide simpler and lower cost of implementation
00:11:37 compared to the first one, as you deploy only one SNS to manage routing based on
message attributes.
00:11:44 In summary, SNS is great when you want to distribute notifications from publishers to one or
more subscribers, including sending
00:11:53 messages through mobile push, SMS, and emails. If you want to learn more about these
topics, you can further explore these

3 / 11
00:12:01 links, such as SAP CapModel, Business Application Studio, SAP Fiori, SAP HANA Cloud,
and Amazon SNS.
00:12:10 You can see how we can combine SAP CAP and Amazon SNS to solve your business
problem.
00:12:16 From this unit, you have learned how to build a use case with SAP CAP, HANA Cloud, and
SAP Business Application Studio,
00:12:23 and stitch together Amazon SNS service for notification or event-based decoupling.
00:12:29 I hope this unit will be useful for you to use and solve your business problems. Thank you
for joining us to dive deep into this topic.

4 / 11
Week 3 Unit 2

00:00:05 Welcome to this open SAP course on building business applications on SAP Business
Technology Platform with AWS.
00:00:17 We are in week 3 unit 2 and in this unit 2 we are going to set up our SAP BTP and our AWS
and get ready for the exercise.
00:00:30 So in this unit, we will be covering the basics of setting up your business application studio
on the trial account.
00:00:38 And as part of this, we will be setting up the HANA Cloud, the HANA DB, and the necessary
services for doing the exercise.
00:00:50 We will also be setting up our SAP Business Application Studio. We will be configuring it for
the trial account by subscribing to the Business
00:01:03 Application Studio and we will be granting developer access for our user. So then we later
we'll be able to login and create the development space
00:01:15 in Business Application Studio. With that introduction, let's now dive into the demo.
00:01:23 In this demo, we are going to see how to set up our BTP account to enable Business
Application Studio and how to create our dev space where we will be
00:01:35 working on our exercise. To start, let's go to account.hannatrial.com,
00:01:40 hannatrial.ondemand.com. At this point, you should have already set up your trial account in
week one.
00:01:48 So, you can click on go to your trial account. You can close the pop-up and then you can
open your sub-account.
00:02:09 Let's quickly verify in instances and subscriptions. We do not have Business Application
Studio yet.
00:02:19 So let's go to entitlements. And let's create configure.
00:02:26 Let's click on configure entitlement and click add service plan and let's search for business
application studio and it is already selected here.
00:02:41 If it is not selected for you, you would click on this and click on add one service plan and
eventually click save.
00:02:51 After doing this entitlement, we can go back to Instances and Subscription and you can click
Create on the top here
00:03:08 and choose SAP Business Application Studio, Trial Plan and click Create.
00:03:22 This will take a moment. You will then be shown this screen where it says you are
subscribed.
00:03:43 You can click on go to application here or go to application here or this particular icon that
will open the business application
00:03:55 studio in a new tab. And we will be able to click on my dev spaces here.
00:04:09 At this point, we don't have any dev space, so let's create our first dev space and this is
going to be a full stack cloud
00:04:17 application. Let's enter the name, open SAP V3 and click on create dev space.
00:04:36 This will provision your dev space and then you will be able to open it after it is processed.
00:04:44 Once the development space is created, you will see a green success message called
running and then we will be able to click on the development space
00:04:54 which loads up our business application studio. And here is where, in the future weeks, we
will be building our application.
00:05:12 There is one last step for us to do before we conclude this demo, that is to go back to a trial
account, click on users under security,
00:05:24 pick your own user and assign role collection and select business application studio
developer.

5 / 11
00:05:32 This access is required for us to continue our development in the Business Application
Studio.
00:05:40 That's it for this demo. We have successfully created an instance of Business Application
Studio.
00:05:47 In this video we have created our dev space for a full stack application and we have also
given our user the necessary access.
00:05:57 Welcome back after that demo. Now that our business application studio is set up, what's
left is to set up
00:06:06 the SAP HANA cloud and the SAP HANA database. For this we will configure the quota
plans for the space and then we will navigate
00:06:16 to the space and then we will set up the HANA cloud and we will create the SAP HANA
database inside the SAP HANA cloud.
00:06:28 Now, let's see how to do that. In this demo, we are going to create an instance of SAP
HANA Cloud and also
00:06:37 the build work zone. Let's start by logging into our trial account at
account.hannatrial.online.com
00:06:45 and we are going to start by going into entitlements. Let's click on configure entitlement, add
service plans and search for SAP HANA.
00:07:02 And under HANA Cloud, you will be, if in my account it is already selected, but if you don't
have it, please select all of this and go to SAP HANA
00:07:16 Schemas and HDI containers and select all of these and you would click on add service
plan and click on save.
00:07:29 After setting up the entitlement, let's go back to our div space by clicking on the spaces
here.
00:07:44 And here we will have the HANA cloud option here and we will be able to click create a SAP
HANA database.
00:07:56 This will open a new pop-up. Sign in with your default identity provider.
00:08:06 And it will take you to SAP HANA Cloud Central. You will be taken to this screen after the
HANA Cloud Central has loaded.
00:08:16 You can click on SAP HANA database and then choose next step. Here we can enter a
meaningful instance name
00:08:33 and then choose a password for the administrator. And then click on next step.
00:08:51 Review and click next step again. One more time.
00:08:55 And here make sure to choose allow all IP addresses. This will allow all the communication
to the HANA database.
00:09:06 You can review and create. Click on create instance.
00:09:16 This will create an instance of nRDB that we will be using in our exercise. It will take a while
for it to get provisioned, but you will see the updated
00:09:28 status here. In the next part of the demo, we are going to create the SAP Build Work
00:09:41 Zone. So let's go back to entitlements and check if we have build work zone
00:09:47 already added. Click on add service plans.
00:09:54 Search for build work zone standard edition. It's already added in my account.
00:10:00 Otherwise, select these and click on the service plan button and save. Now, let's go back to
instances and subscriptions.
00:10:11 Click on create, select build work zone, make sure to select subscription and click on create.

00:10:33 This will create a new subscription for us for SAP Build Work Zone. The subscription for the
build work zone has been successfully created.
00:10:46 We can click on go to application here or select here and this should open a new popup.
00:10:58 If you see this error message, that's because we have not given the necessary access to
the user.

6 / 11
00:11:06 So go back to security users, click on assigned role collections and select Launchpad
Admin.
00:11:20 I'm going to show you how to logout and sign-in to your own collection and now let's go
back and check it one more time.
00:11:28 You might have to log off and log in again. Let's log out.
00:11:54 Now if we open it again, we will be able to successfully see the site manager. That
concludes our demo for this unit.
00:12:08 We have successfully created an instance of SAP HANA Cloud DB and we have also
successfully subscribed to the Build Work Zone.
00:12:19 Welcome back after the demo. We have come to the end of this unit and in this unit we
have set up
00:12:29 our business application studio in our SAP BTP trial account and we have configured the
necessary settings to set up our SAP HANA cloud and SAP HANA database
00:12:42 in the SAP BTP trial account. Thank you, see you in the next unit.

7 / 11
Week 3 Unit 3

00:00:05 Hello, and welcome back to this OpenSAP course on building business applications on SAP
Business Technology Platform with AWS.
00:00:17 We are in week three, unit three. In this unit, we'll be learning how to build our CAP
application, the backend
00:00:25 service, and the frontend UI application. And then finally, how to connect this UI application
into SAP Build work soon.
00:00:36 We will start with the backend service and then move on to the front-end UI based on SAP
Fiori elements.
00:00:43 And we will also learn how to deploy these applications into business technology platform.
00:00:50 Let's now jump into the demo of the final application. In this demo, we are going to see how
the final application
00:01:00 would look like after developing the CAP back-end service, the front-end UI and integrating
them.
00:01:09 At this point, if you have followed all the instructions, you would have also integrated this
application into SAP Build Work Zone.
00:01:18 Let's start by going into SAP Build Work Zone site directory. From there, we can click on our
site, which will take us to the home page.
00:01:30 And this is where we will see the tile that takes us to our application. When the application
first loads, we are taken to a search page where we
00:01:41 can hit go to fetch the business partners from the mock server we have created in the
previous weeks.
00:01:53 This response can be validated from a Spagger UI, where we can do a get for business
partners, pick try it out, and execute to see the same response.
00:02:20 We will also be able to click on a particular business partner and go into the details page
and also use the Swagger UI
00:02:34 to trigger the get of a single business partner by filling the business partner ID.
00:02:51 Let's click try it out fill the business partner and we can also select the expand business
partner address to look at the address.
00:03:02 So this way, we will be able to verify the address as well, which is shown here. We will also
be able to edit the business partner, change its verification status,
00:03:27 change the postal code, mark it as modified and we'll be able to save the changes.
00:03:44 That concludes our demo. In the next unit, we will be integrating this application
00:03:51 into AWS SNS service to trigger the notification. Welcome back.
00:03:58 So what have we learned in this unit so far? We have learned how to build our CAP
application in SAP Business Application
00:04:07 Studio. We have learned how to define our CDS model, the domain model and the service
00:04:13 model, and how to add custom service implementations. We have also learned how to
consume external services with CAP remote service
00:04:23 and we have also built our front-end with SAP Fiori elements. We were able to connect this
frontend to the backend service and we have also
00:04:34 learned how to deploy it into our SAP BTP trial account. Finally, we were able to configure
this SAP Fiori UI to be shown up as a tile
00:04:46 in our SAP Build Work Zone website. For further readings, we have some materials linked
here where
00:04:55 you can explore more about each of these topics, CAP model, SAP Fiori, HANA Cloud,
Business Application Studio and SAP Build Work Zone.
00:05:05 We have some very good getting started materials for beginners and also some tutorials for
experienced developers. Thank you, meet you in the next unit.

8 / 11
Week 3 Unit 4

00:00:05 Hello and welcome to OpenSAP course on building business applications with SAP
Business Technology Platform and AWS.
00:00:15 We are in week 3, unit 4. In this unit, we are going to integrate the CAP
00:00:21 application we built with Amazon SNS service. We will cover the AWS SDK for JavaScript,
how the look and feel of this SDK is,
00:00:36 and we will also use this SDK to connect the CAP application we built in our last week to
send out email notifications with AWS SNS service.
00:00:55 Amazon provides this SDK for JavaScript which is very helpful to integrate into AWS
services and to call their services.
00:01:09 It is a development kit provided by AWS and it's an npm package that could be installed and
used in SAP Capp application.
00:01:18 With AWS SDK for JavaScript, you can interact with AWS Managed Services by coding in
JavaScript.
00:01:27 We can build a Node.js application that could communicate with any of AWS managed
services.
00:01:34 To install this service, all the instructions have been provided. For example you would use
the npm command and install function
00:01:45 and select the service name. Now let's jump into the demo of how the final application
00:01:54 along with the notification would look like. Welcome to the demo of Week 3 Unit 4.
00:02:02 At this point, we have completed the integration between the application, the CAP
application that we built
00:02:09 and the Amazon SNS notification service. Let's now see a demo of the application.
00:02:17 We fire the search and then we open the application. Let's pick a business partner which is
already in status verified.
00:02:28 Let's change the status back to in process. Mark it as centrally blocked.
00:02:39 Change a field in the address. Make sure that it's modified is selected and now let's save
the data.
00:02:52 This should now update the data in our mock server, and it should also trigger a notification.

00:03:03 Let's check for the notification. We see that a new email has come just now.
00:03:22 This email will give us a link to go back into the site. It has the summary that it has been
triggered from the SAP Business Partner
00:03:36 Validation, and we have to review the changes. Now, clicking on this link will take us back to
the application
00:03:48 directly into the business partner that we just edited. And we can now review the changes.
00:03:59 And if we are satisfied with the changes, we can set the status to verify and remove the
block.
00:04:08 And click save. We can also verify that the data that we updated is reflected in the swagger
ui.
00:04:24 So, let's now check the postal code in the address and we see the new information.
00:04:37 That brings us to the end of the demo, so we were successfully able to build the application
and trigger a notification by using the Amazon SNS service.
00:04:51 Thank you. Welcome back from the demo.
00:04:54 For further readings, here are some links that would take you to the Amazon AWS SDK for
Node.js and SDK for Java as well.
00:05:05 There are also some get-started links for these SDKs, for JavaScript, for Node.js, for React
Native and so on.

9 / 11
00:05:15 There are also links to samples for SNS services and how to consume them. So, in this unit
we have learned about AWS SDK for Node.js, how to install this SDK
00:05:33 and how to use this SDK to consume Amazon SNL service inside a SAP CAP application.
That brings us to the end of week 3.
00:05:48 In this week, we have learned about SAP Cloud Application Programming Model.
00:05:55 We have learned how to create a simple CAP application that will integrate with SAP HANA
Cloud, SAP S4 HANA and AWS services in SAP Business Application Studio.
00:06:10 We have learned how to navigate and use the SAP S4 HANA services from SAP Business
Accelerator Hub.
00:06:18 In the coming week, you will learn more about advanced concepts in SAP BTP and AWS for
building resilient business
00:06:26 applications on SAP BTP. Thank you and good luck.

10 / 11
© 2023 SAP SE or an SAP affiliate company. All rights reserved.
See Legal Notice on www.sap.com/legal-notice for use terms,
disclaimers, disclosures, or restrictions related to SAP Materials
for general audiences.

You might also like