IDEA编译项目出现:OutOfMemoryError: insufficient memory报错

问题:IDEA编译项目出现:OutOfMemoryError: insufficient memory报错

原因:IDEA设置中,默认共享构建进程堆大小设置对于项目小了,默认是700Mbytes

方案:

根据项目,把设置大小改大就可以

设置路径如下

  • File -> Setting -> Compiler -> Shared build process heap size(Mbytes)