Netbeans(蚂蚁)无法描述

时间:2017-09-15 18:37:11

标签: java netbeans ant profiling

按照说明here,我无法让NetBeans分析简单(模板)应用程序。 在NetBeans中,我选择了Profile菜单的“Profile Project(xxx)”菜单项(切换到遥测视图)。在该视图中,我单击“配置文件”按钮...程序启动...我将日志输出到输出视图(在NetBeans中)......就是这样。没有遥测更新或任何东西。

跟进:按照说明here:我能够将anagram示例项目分析(YAY!)但是我仍然无法将我现有的项目分析。所有内容都会构建和启动,但遥测数据不会更新。 有人建议我将此行添加到我的build.xml文件中(对于nb-profiler目标):

<fail unless="profiler.info.jvmargs.agent">Must set profiler agent JVM arguments in profiler.info.jvmargs.agent</fail>

果然,现在当我运行探查器时,NetBeans会记录“必须设置探查器代理JVM ...”消息。那么......我该怎么做? (谷歌没有帮助)TIA!

这是当前的build.xml目标:

<target name="profile-nb" depends="runtime-library-selection" description="build and run app with NetBeans profiling"> <fail unless="netbeans.home">This target can only run inside the NetBeans IDE.</fail> <startprofiler/> <nbprofiledirect> <classpath> <pathelement location="${jartarget}/app.jar"/> <pathelement path="${java.class.path}"/> </classpath> </nbprofiledirect> <!-- commenting out this next line prevents the "Must set profiler agent JVM arguments..." message --> <!-- <fail unless="profiler.info.jvmargs.agent">Must set profiler agent JVM arguments in profiler.info.jvmargs.agent</fail> --> <java classname="${application.classname}" dir="${basedir}" fork="yes" resultproperty="application.returncode"> <classpath refid="project.class.path"/> <sysproperty key="java.security.policy" value="${libdir}/security.policy"/> <sysproperty key="java.library.path" path=".:${arch.lib.path}:${libdir}"/> <sysproperty key="file.encoding" value="UTF-8"/> <!-- commenting out this next line prevents the "can't find main class..." message --> <!-- <jvmarg value="${profiler.info.jvmargs.agent}"/> --> <jvmarg line="${profiler.info.jvmargs}"/> <jvmarg value="-Xms256m"/> <jvmarg value="-Xmx640m"/> <jvmarg line="${jvm.args}"/> <arg value="${antargline}"/> </java> </target> 注意:按原样,它将启动应用程序并设置“进度...”对话框:“连接到目标虚拟机...”(在我退出应用程序之前保持打开状态)。

0 个答案:

没有答案
相关问题