【问题标题】:ResourceExhausted error in Pivotal cloud foundryPivotal 云代工厂中的 ResourceExhausted 错误
【发布时间】:2022-04-19 00:28:06
【问题描述】:

每当尝试调用部署在 PCF 中的 SOAP 端点时,我都会收到以下错误。

2019-03-07T06:55:22.817-05:00 [APP/PROC/WEB/0] [ERR] Resource 
exhaustion event.
 2019-03-07T06:55:22.817-05:00 [APP/PROC/WEB/0] [ERR] 
  ResourceExhausted! (1/0)
  2019-03-07T06:55:26.668-05:00 [APP/PROC/WEB/0] [OUT] | Instance 
  Count | Total Bytes | Class Name |
2019-03-07T06:55:26.669-05:00 [APP/PROC/WEB/0] [OUT] | 447836 | 
32342112 | [C |
2019-03-07T06:55:26.671-05:00 [APP/PROC/WEB/0] [OUT] | 297596 | 
11903840 | Ljava/util/LinkedHashMap$Entry; |

2019-03-07T06:55:26.796-05:00 [APP/PROC/WEB/0] [OUT] Memory usage:
2019-03-07T06:55:26.797-05:00 [APP/PROC/WEB/0] [OUT] Heap memory: init 
16777216, used 169257280, committed 409534464, max 409534464
2019-03-07T06:55:26.798-05:00 [APP/PROC/WEB/0] [OUT] Hint: Heap memory 
 is over 95% full. To increase it, increase the container size.
2019-03-07T06:55:26.799-05:00 [APP/PROC/WEB/0] [OUT] Non-heap memory: 
init 2555904, used 175238384, committed 180928512, max 495026176
2019-03-07T06:55:26.800-05:00 [APP/PROC/WEB/0] [OUT] Memory pool 
 usage:

该问题的任何解决方法。

【问题讨论】:

    标签: spring-boot cloud-foundry


    【解决方案1】:

    确保 PCF 应用程序有足够的内存(根据您的输出,当前最大堆大小为 400MB):

    您需要增加应用程序本机大小和 JVM 最大堆大小:

    cf scale my-application -m 1G
    cf set-env my-app JAVA_OPTS '-Xmx768m'
    cf cf restage my-application
    

    【讨论】:

    • 堆大小可以设置哪些最大值?
    • 在哪种情况下?您最好提出一个新问题来确定您的环境。
    猜你喜欢
    • 2018-10-17
    • 1970-01-01
    • 2018-03-28
    • 1970-01-01
    • 2012-12-31
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多