OutOfMemoryError Reported When Compiling Spring Framework
Symptom
The message "OutOfMemoryError thrown from UncaughtExceptionHandler" is displayed during Spring Framework compilation.
Key Process and Cause Analysis
Memory overflow occurs. Increase the memory setting.
Conclusion and Solution
- Open the build.gradle file.
vim build.gradle
- Add the following configuration to lines 338 and 339:
minHeapSize = "4096m" maxHeapSize = "4096m"

- Press Esc, type :wq!, and press Enter to save the file and exit.
- Recompile Spring Framework.
Parent topic: Troubleshooting