IDEA报错:GC overhead limit exceeded?

1. 问题描述

在运行代码之后,出现以下错误:

Exception in thread "main" org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 107.0 failed 1 times, most recent failure: Lost task 0.0 in stage 107.0 (TID 208, localhost, executor driver): java.lang.OutOfMemoryError: GC overhead limit exceeded

经查询之后,是由于JVM花费太长时间执行GC且只能回收很少的堆内存时抛出的
一般可以通过更改JVM启动配置增加堆大小来解决
参考:https://blog.csdn.net/github_32521685/article/details/89953796

2. 解决方法

  1. file -> settings
  2. 搜索maven,点击importing,修改JVM启动项

猜你喜欢

转载自www.cnblogs.com/cjq10029/p/12688693.html
今日推荐