Eclipse WildFly 8 和 Java 8 中的 MaxPermSize 警告

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/31672778/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-11 11:23:48  来源:igfitidea点击:

MaxPermSize Warning in Eclipse WildFly 8 and Java 8

javaeclipsejava-8wildfly-8

提问by Johnny2012

i have upgraded to WildFly 8.2.0from JBoss 7and to Java 8from Java 7.

我已经升级到WildFly 8.2.0fromJBoss 7和 to Java 8from Java 7

I get everytime I stop the serverin Eclipsethis warning:

每次我serverEclipse这个警告中停止时我都会得到:

Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0

Java HotSpot(TM) 64 位服务器 VM 警告:忽略选项 MaxPermSize=256m;在 8.0 中移除了支持

If I start and stop the Server from the CMDthere is no warning like this, just in Eclipse. I have removed all MaxPermSize Settings from WildFlyand can't find any setting about that in my Project. It just happens in Eclipse.

如果我启动和停止服务器从CMD没有像这样没有报警,只是Eclipse。我已经删除了所有 MaxPermSize 设置,WildFly并且在我的项目中找不到任何关于它的设置。它只是发生在Eclipse.

I have already checked this questions:

我已经检查过这个问题:

Where to find all the MaxPermSize in Eclipse-WildFly system?

在哪里可以找到 Eclipse-WildFly 系统中的所有 MaxPermSize?

Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize

Java HotSpot(TM) 64 位服务器 VM 警告:忽略选项 MaxPermSize

How do I make the "Java Hot Spot MaxPermSize" warning go away when using IntelliJ or Play?

使用 IntelliJ 或 Play 时,如何使“Java Hot Spot MaxPermSize”警告消失?

and this page

和这个页面

How do I make the "Java Hot Spot MaxPermSize" warning go away when using IntelliJ or Play?

使用 IntelliJ 或 Play 时,如何使“Java Hot Spot MaxPermSize”警告消失?

采纳答案by sprockets

You need to remove this argument from the "launch configuration" in your Wildfly server configuration in eclipse. It is no longer required when you are using java 8.

您需要从 eclipse 的 Wildfly 服务器配置中的“启动配置”中删除此参数。使用 java 8 时不再需要它。

1) open server overview

1) 开放服务器概述

2) click "open launch configuration"

2)点击“打开启动配置”

3) edit "VM arguments" remove the " -XX:MaxPermSize=256m " argument.

3) 编辑“VM 参数”删除“-XX:MaxPermSize=256m”参数。

4) save everything and start your wildfly via eclipse.

4)保存所有内容并通过eclipse启动您的wildfly。

Message should be gone.

消息应该没了。

回答by Foncu

In Java8 the Perm partition of memory has changed to Metaspace. In this way, the parameters has changed from "-XX:PermSize" and "-XX:MaxPermSize" to "-XX:MetaspaceSize" and "-XX:MaxMetaspaceSize".

在 Java8 中,内存的 Perm 分区已更改为 Metaspace。这样,参数就从“-XX:PermSize”和“-XX:MaxPermSize”变成了“-XX:MetaspaceSize”和“-XX:MaxMetaspaceSize”。

Instead of removing the parameter, change it for bla

不要删除参数,而是将其更改为 bla