Multitenant SaaS apps on SAP BTP using CAP? Tried-and-True! – The Expert Scope
Hello and welcome again to the fourth and last part of the blog post series on building your own “Multitenant SaaS application on SAP BTP using CAP”. This blog post will summarize the extensive Expert Scope.
In the Overview blog post, you have learned the general idea and motivation of developing multitenant SaaS applications on SAP BTP, in the Basic Scope blog post you learned the essential implementation specifics of a multitenant SaaS application. The Advanced Scope blog post demonstrated how to incorporate central user management or integrate On-Premise systems like SAP S/4HANA to get your SaaS application one step closer to being ready for production.
In this final blog post of our series, you will be focusing on the Expert Scope, which is again provided in our sample repository. This scope covers a plethora of SaaS-related expert topics and provides a variety of valuable tutorials, documentation as well as tips and tricks that will jump-start your project.
Let’s first grasp the expert scenario and the derived scope requirements for the existing SaaS application of our ancient SAP sample partner, CaveStone. After checking the architecture solution diagram, we will move on to summarize the various Expert Scope topics! Excited to see what we have in store for this last part of our blog post series? Promised, it will be a gold mine!
Scenario & Requirements
In this scenario, CaveStone has completed and deployed the Basic and Advanced Scope. The developer team is very excited by what they have seen so far. Still, before they can get their own SaaS solution to the SAP Store, there are some more questions and requirements they would like to clarify first. In addition to the Basic and Advanced Scope, an understanding of how to implement the following expert requirements was determined:
- How can the team develop CAP-based SaaS apps locally or in a hybrid setup?
- How can a SaaS solution be deployed to multiple SAP BTP regions?
- Does SAP BTP provide services to support DevOps requirements?
- Can a custom domain be used for the SaaS consumer tenants?
- If there is a need to back up database containers, how can that be done?
- Is there a way that SaaS consumers can extend the existing SaaS application?
- Can e-mails be sent from within the SaaS application logic easily?
- What if a SaaS consumer requires a custom theme? Is that possible and how?
- Let’s assume a consumer has its own Identity Provider – Can we integrate that?
As you can see, the partner has a lot of interesting requirements and questions you might also ask yourself after completing the Basic and Advanced Scope. Well, let us have a look at the architectural diagram of the Expert Scope first, which contains some more components to cover the above requirements.
As you probably noticed, the architecture is quite similar to the Advanced Scope and only contains three more services namely SAP Continuous Integration and Delivery, SAP Cloud Transport Management, SAP Custom Domain, and an additional SAP IAS tenant. All these additional services and usage samples will be covered in detail by the respective Expert Scope chapters.
The Expert Scope does not provide a separate code base or an additional GitHub branch. The various topics covered by this scope are located in the respective docs (click here) of the main branch. If code snippets are required for any of the Expert Scope topics, they are provided in a separate folder among the docs.
The essential requirement to support local and hybrid development is described in great detail by the following documentation (click here – available soon) and provides guidance on how to work in a local environment with CAP multitenancy features, master API testing, and many other tips and tricks that will ease a developer’s life!
If you are planning to deploy your SaaS solution to multiple SAP BTP regions, you should not miss the following documentation (click here), which comes with a lot of aspects and considerations on this topic. As the requirement is very diverse and detailed guidance can fill books, the provided samples shall give you a very first idea of how to get your personal multi region architecture and account setup started.
Smart DevOps processes are essential when planning and designing a production deployment. Check the respective Expert Scope documentation on how to use the SAP CI/CD service (click here) in combination with the SAP Cloud Transport Management service (click here). The provided code snippets and detailed step-by-step guides will help you set up a basic DevOps flow for the sample application.
A professional SaaS application should make use of a proper Custom Domain. While for test and validation scenarios the default domain (cfapps) might be sufficient, in a production scenario you most likely have to provide your consumers with a dedicated subdomain xyz.susaas.com. In this part (click here) of the Expert Scope, you will learn in detail how to set up a custom domain for your sample application.
As with most SaaS applications, the data of your SaaS consumers is at the heart of the solution. Being able to manage (click here) and administrate (click here) SAP HDI database containers including backups (click here) is essential when productizing your SaaS solution. You will get an idea of how to get started by visiting the linked Expert Scope chapters.
Closely related to the management of database containers are data model updates. Whenever you update your data model definition, the respective changes need to be distributed and deployed to your tenant database containers. Check the following part of the Expert Scope (click here) to learn how such updates can be done using sample HTTP requests.
Your SaaS solution might be great and fit the requirements of your consumers to 99 % but let us guarantee you something. There will always be that one consumer who needs an additional field in one of the available forms. Fortunately, CAP supports extension scenarios using Consumer Extensibility (click here) or Feature Toggles (click here). Both topics will be covered in detail including sample code snippets in our documentation.
You already learned how to use the Alert Notification service to receive application notifications. While this is a nice feature for monitoring purposes, it will most likely not be sufficient for the messaging requirements of a productive SaaS application. If you plan to send emails from within your application logic to the users of your SaaS solution, consult the following sample documentation (click here) of the Expert Scope.
A company’s theme and style are usually among the most important selling points and help employees and customers when it comes to brand recognition. So why not giving your SaaS consumers the option to create an own theme for their SaaS tenant? Learn how to do so using the SAP Theme Designer service in the following Expert Scope (click here – available soon)!
Let’s assume for the moment that you intend to provide your SaaS service to a significant B2C client with hundreds or perhaps thousands of users. This will change the game in a number of ways. One requirement that will be taken to another level is user management. Learn in the following chapter (click here) of the Expert Scope, how to integrate a consumer’s own Identity Provider like Azure Active Directory with your SaaS application. Learn about several alternatives and select the one that best satisfies the needs of your customers.
This is just a very brief summary of the various topics that the Expert Scope covers in detail. Start right away by digging deeper into the very first subject that is at the top of your list!
With this blog post, you have finally concluded your SaaS journey. You started with the Overview blog post, learned how to deploy a simple SaaS application in the Basic Scope, sharpened your knowledge in the Advanced Scope, and now spiced up your skills to enhance own SaaS solutions with our Expert Scope topics on your road to production.
From tips and tricks for local development, a simple DevOps setup, the administration, and management of database containers, or the usage of a custom domain for your solution – This Scope wraps up the topic of Multitenant SaaS application on SAP BTP using CAP, and releases you into the wild with a bag full of useful knowledge and resources for your reference!
Feel free to try out the Expert Scope with your own SAP BTP account and share your feedback! We are looking forward to hearing from you. To stay up to date or to get in contact, follow my colleague Alper Dedeoglu and myself Martin Frick!
Regarding this Expert Scope, you will find a lot of further content linked in the different chapters provided in the GitHub documentation. The following list contains just some selected highlights.