Netbeans 分析器不适用于 JDK 17
当我尝试在我的Web应用程序上运行Profiler时,Netbeans告诉我,我需要先运行校准。所以我去工具>选项> Java> Profiler>一般>管理校准数据并进行校准。
之后开始进行分析,我在控制台中看到了跟随:
ant -f /home/codyline/myApp -Dnb.internal.action.name=profile -Ddirectory.deployment.supported=true
-DforceRedeploy=false -Dnb.wait.for.caches=true "-Drun.jvmargs.ide= -agentpath:/home/codyline/netbeans/
netbeans-13/netbeans/profiler/lib/deployed/jdk16/linux-amd64/libprofilerinterface.so=
/home/codyline/netbeans/netbeans-13/netbeans/profiler/lib, 5140,10 -XX:+HeapDumpOnOutOfMemoryError
-XX:HeapDumpPath=/home/codyline/myApp/nbproject/private/profiler"
-Dbrowser.context=/home/codyline/myApp profile
profile:
init:
deps-module-jar:
deps-ear-jar:
deps-jar:
library-inclusion-in-archive:
library-inclusion-in-manifest:
compile:
compile-jsps:
Starting Payara Server 5.2022.1
Payara Server 5.2022.1 is running.
什么也不会发生! 因此,Netbeans正在尝试使用我的机器上未安装的JDK 16。
我需要与JDK 17进行分析。
注意:Netbeans 12.6的同样问题。
我该如何解决?谢谢
When I try to run the profiler on my web app, netbeans tells me I need to run a calibration first. So I go to Tools > Options > Java > Profiler > General > Manage Calibration Data and do the calibration.
Starting profiling afterwards I see following in the console:
ant -f /home/codyline/myApp -Dnb.internal.action.name=profile -Ddirectory.deployment.supported=true
-DforceRedeploy=false -Dnb.wait.for.caches=true "-Drun.jvmargs.ide= -agentpath:/home/codyline/netbeans/
netbeans-13/netbeans/profiler/lib/deployed/jdk16/linux-amd64/libprofilerinterface.so=
/home/codyline/netbeans/netbeans-13/netbeans/profiler/lib, 5140,10 -XX:+HeapDumpOnOutOfMemoryError
-XX:HeapDumpPath=/home/codyline/myApp/nbproject/private/profiler"
-Dbrowser.context=/home/codyline/myApp profile
profile:
init:
deps-module-jar:
deps-ear-jar:
deps-jar:
library-inclusion-in-archive:
library-inclusion-in-manifest:
compile:
compile-jsps:
Starting Payara Server 5.2022.1
Payara Server 5.2022.1 is running.
And nothing happens!
So Netbeans is trying to use JDK 16 which is not installed on my machine.
I need to do the profiling with JDK 17.
NOTE: same problem with Netbeans 12.6.
How can I fix this? Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
它接缝了您在AMD64体系结构上使用Linux。当您的Java_home环境变量指向错误目录时,可能会发生这种情况。
如果不是JDK 17,请使用此链接更改变量如何在Linux中为所有用户设置Java_home
It seams you are using Linux on amd64 architecture. This can occur when your JAVA_HOME environment variable is pointing wrong directory.
If it is not JDK 17, use this link to change the variable How to set JAVA_HOME in Linux for all users