cancel
Showing results for 
Search instead for 
Did you mean: 

SAP CAP Application Raises Out of Memory error when call action API

leon_chen_sap
Explorer
0 Kudos

out-of-memory-error-logs.txtHi Expert,

I developed an application using SAP CAP and deployed it to SAP BTP. I implemented an "unbound action" API, it worked well with CDS 5.4.5, but it raised an out-of-memory runtime error when a user called this API after I upgraded CDS to version 5.9.5 or 6.0.4. I cannot roll back CDS to version 5.4.5 as it doesn't support "Hana-cloud". I'm using the below Node and CDS version:

Nodejs: neither 14.x nor 16.x didn't work

CDS: neither 5.9.5 nor 6.x didn't work

Any suggestion is great appreciated.

Willem_Pardaens
Product and Topic Expert
Product and Topic Expert
0 Kudos

Did you try to increase the memory allocation of the application on BTP?

gregorw
Active Contributor
0 Kudos

Have you done a local memory analysis e.g. with the Chrome developer tools?

Accepted Solutions (0)

Answers (1)

Answers (1)

leon_chen_sap
Explorer

I resolved the issue. It seems it's cds.ApplicationService caused the issue. I created a custom class by extending cds.ApplicationService to implement the action handler. I re-implemented this handler with function, it resolved the issue.

gregorw
Active Contributor
0 Kudos

Would be great if you could provide more details that the CAP Team and Community can benefit from this.