SAP Note 558250 - Memory problems with J2EE and SAP Java Connector

Component : Java-Connector - Enterprise Runtime, Core J2EE FrameworkBC-UPG-ADDON Upgrade

Solution : https://service.sap.com/sap/support/notes/558250 (SAP Service marketplace login required)

Summary :
SAP JCo and J2EE applications may encounter OutOfMemoryError and StackOverflowError due to insufficient memory allocation or recursive loops consuming stack space. For StackOverflowError in environments like True64, increasing JVM stack size with the -Xss option (e.g., -Xss2M) is recommended. For OutOfMemoryError, adjust the Java heap size using -Xmx and -Xms settings, ensuring optimal memory use without exceeding 50-70% of available memory to prevent heap fragmentation. Ensure both -Xms and -Xmx are set equally to avoid dynamic heap expansion issues. Memory settings should be tailored according to specific JDK and application requirements.

Key words :
preset stack size depends, reserved java heap memory, j2ee application throws outofmemoryerror, terms java connector, java heap dynamically, multiple internal errors, initial heap sizes, stop unnecessary services, general recommendations apply, insufficient stack size

Related Notes :

729178Java VM setting for applications running on J2EE Engine 6.20
634689Central Note for Memory Issues, SAP J2EE Engine 6.20