ano*_*ave 5 java jvm jvm-arguments deprecated
我使用的java -XX:+PrintFlagsFinal -version是每 打印所有JVM标志的问题,我升级到JVM 11上比较差的JDK之间的结果。
我注意到,尽管的结果PrintFlagsFinal仍将返回不推荐使用的选项-例如PrintGC,即使运行-XX:+PrintGC发出警告并运行,它仍然存在-Xlog:gc。
因此,是否有一个类似于PrintFlagsFinal我可以用来查找当前不推荐使用的所有选项的选项,从而可以避免使用它们?
(知道我可以手动检查发行说明,但是想知道是否存在一种内置的从JVM中查找的方法,类似于jdeprscan不推荐使用的模块依赖项)
弃用有多个“级别”:ALIASED、DEPRECATED、OBSOLETE 和 EXPIRED 标志,其含义在arguments.cpp中描述。
除了上述类别之外,还有已弃用的跟踪标志,这些标志已替换为统一 JVM 日志记录选项。
最后,还有一些上面未列出的标志,只是在说明中“已弃用”。
我不知道有哪个地方将所有这些已弃用的标志收集在一起,但从 JVM 源中提取它们相当容易:提到的arguments.cpp和globals*.hpp系列。我还推荐VM Options Explorer站点,其中包含按版本划分的 HotSpot JVM 标志结构良好的表。
从 JDK 11 开始,已弃用/过时/过期以及其他不支持的标志列表包括:
AggressiveOpts
AllowNonVirtualCalls
AssumeMP
CheckAssertionStatusDirectives
CheckEndorsedAndExtDirs
CompilerThreadHintNoPreempt
CreateMinidumpOnCrash
DefaultMaxRAMFraction
DeferPollingPageLoopCount
DeferThrSuspendLoopCount
EnableTracing
FastTLABRefill
FreqCountInvocations
IgnoreUnverifiableClassesDuringDump
InitialRAMFraction
InlineNotify
MaxGCMinorPauseMillis
MaxPermSize
MaxRAMFraction
MinRAMFraction
MonitorInUseLists
MustCallLoadClassInternal
NativeMonitorFlags
NativeMonitorSpinLimit
NativeMonitorTimeout
PermSize
PrintCompressedOopsMode
PrintGC
PrintGCDetails
PrintMalloc
PrintMallocFree
PrintSafepointStatistics
PrintSafepointStatisticsCount
PrintSafepointStatisticsTimeout
PrintSharedSpaces
SafepointSpinBeforeYield
SharedMiscCodeSize
SharedMiscDataSize
SharedReadOnlySize
SharedReadWriteSize
ShowSafepointMsgs
TraceBiasedLocking
TraceClassLoading
TraceClassLoadingPreorder
TraceClassPaths
TraceClassResolution
TraceClassUnloading
TraceExceptions
TraceJVMTIObjectTagging
TraceLoaderConstraints
TraceMonitorInflation
TraceRedefineClasses
TraceSafepointCleanupTime
TraceScavenge
UnlinkSymbolsALot
UnsyncloadClass
UseAppCDS
UseConcMarkSweepGC
UseLockedTracing
UseMembar
UseUTCFileTimestamp
VMThreadHintNoPreempt
Run Code Online (Sandbox Code Playgroud)
更新
感谢 @chriswhocodes,VM Options Explorer现在显示已弃用的 JVM 标志。
| 归档时间: |
|
| 查看次数: |
577 次 |
| 最近记录: |