0
在部署到帶有Java堆空間問題的JBoss/WildFly 8時,My Jenkins構建有時會失敗。通過Java堆空間部署到JBoss/WildFly 8失敗
[ERROR] Failed to execute goal org.wildfly.plugins:wildfly-maven-plugin:1.1.0.Alpha2:deploy (default-cli) on project Prometheus: Deployment failed: Operation failed: "JBAS014749: Operation handler failed: Java heap space" -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
我每次發生這種情況都要重新啓動我的JBoss/WildFly部署到服務器。請幫我清除問題,以免妨礙我的自動化。
您使用的是什麼版本的Java?而且,你可能需要用更多的堆空間來啓動它。 –
Java 1.8.0_25,我應該在哪裏更改堆空間? –
你要添加['javaOpts'(https://docs.jboss.org/wildfly/plugins/maven/latest/start-mojo.html),並指定了'-Xmx'和'-XX: MaxMetaspaceSize'(兩者取等號,隨後的值,然後尺寸後綴,'= 1g'和'= 1024m'指定的數字值是相同的)。至於合適的尺寸,您需要以機器內存限制爲指導。 –