CRM and CX Blogs by SAP
Stay up-to-date on the latest developments and product news about intelligent customer experience and CRM technologies through blog posts from SAP experts.
cancel
Showing results for 
Search instead for 
Did you mean: 
ythomas_schroeder
Associate
Associate
813
Maybe you get notified by SAP that your application on SAP Commerce Cloud is overusing the infrastructure. In this article I am showing how to check the amount of memory that is used by the different services and how to decide if some of the services can be scaled down.

The analysis shown here is only for the quick wins, e.g. shutting down services that are not used.

Current usage


The first question is how much memory is my application using, and for which service? The answer is in the Dynatrace dashboard "SAP - Infra Usage". It can look like this


From this overview it can be derived how many replicas for each service are running and how much memory is assigned for them.

Check Services


The following sections showing quick strategies for the different services.

JS Storefront vs Storefront


The question here is if your application is using the legacy Storefront with JSP pages or the new JS Storefront (aka Composable Storefront aka Spartacus)?

Maybe the setup is using both, in that case there is not that much that can be done quickly here.

But if only one or the other is in use, then the other service does not need to run and can be scaled down to 0 replicas.

API


The API service is usually used for OCC workloads. OCC is typically used by Composable Storefront with the storefront implemented in JavaScript. It is also possible to use the OCC service from other applications, that is why it is necessary to check if the API service is used at all.

But if JS Storefront is not used there is a good chance that the API service is also not used and can be scaled down to 0 replicas.

If the OCC service is not used heavily it would also be possible to run this service on the Storefront service.

Backgroundprocessing and Backoffice


Usually it is not possible (and useful) to scale these service down to 0, but again in Dynatrace it can be monitored how much memory is really used by the cronjobs (usually running on the Backgroundprocessing service) or by Backoffice users.

Often it is possible to reduce the amount of memory that is allocated to these services.

Solr


The default setup for Solr in production environments is with four servers. The Solr admin console can be used to determine if all four servers are in use. Also the memory consumption should be checked during a full index.

The following screenshot shows a Solr admin console in which two servers are not used and can be removed.



Next steps


If during the investigation some optimisations could be found the services can be adjusted by SAP Support, which means you have to contact the SAP Support through a ticket.

This article is only about quick wins, if you need deeper analysis there are other articles that can help in that case or you can buy our Performance Review package. Other articles are:

It is also possible to buy additional memory usage, please contact your sales representative.