java - jProfiler 不提供方法级别的统计信息

标签 java profiling jprofiler

我已经在我的 Linux 机器上安装了 jProfiler,我正在将数据保存到 .jps 文件中。然后,我将此文件加载到我本地计算机的 jProfiler UI 中。

这是我的配置文件:

<?xml version="1.0" encoding="UTF-8"?>
<config>
  <nextId id="104" />
  <generalSettings setupHasRun="false">
    <recordingProfiles>
      <recordingProfile  id="10" name="CPU recording">
            <actionKey id="cpu"/>
      </recordingProfile>
    </recordingProfiles>
  </generalSettings>
  <templates>
    <template id="50" name="Instrumentation, all features supported" startFrozen="false" recordCPUOnStartup="false" vmCannotExit="false" instrumentationType="1" samplingNoFilters="false" lineNumbers="false" samplingFrequency="5" timeType="1" disableCPUProfiling="false" recordAllocOnStartup="true" recordArrayAlloc="true" enableTriggersOnStartup="true" allocTreeRecordingType="1" disableMonitorContentions="false" componentDetection="true" chronoHeap="false" autoUpdatePeriodLong="5" autoUpdatePeriodShort="2" allUrls="false" payloadCap="50" eventCap="20000" showSystemThreads="false" utilConcurrentHandling="true" libraryDebugParameters="" exceptionalCap="5" exceptionalTimeType="4" autoTuneInstrumentation="true" autoTuneMaxAverage="100" autoTuneMinPerMille="10" samplingPayloadCallStacks="true" description="This is JProfiler's fully featured mode. In this setting, call stack information is accurate, but CPU overhead and distortion of measured call times may be high, depending on your filter settings. You should define inclusive filters for your own packages." system="true" />
    <template id="51" name="Sampling for CPU profiling, some features not supported" startFrozen="false" recordCPUOnStartup="false" vmCannotExit="false" instrumentationType="3" samplingNoFilters="false" lineNumbers="false" samplingFrequency="5" timeType="1" disableCPUProfiling="false" recordAllocOnStartup="true" recordArrayAlloc="true" enableTriggersOnStartup="true" allocTreeRecordingType="1" disableMonitorContentions="false" componentDetection="true" chronoHeap="false" autoUpdatePeriodLong="5" autoUpdatePeriodShort="2" allUrls="false" payloadCap="50" eventCap="20000" showSystemThreads="false" utilConcurrentHandling="true" libraryDebugParameters="" exceptionalCap="5" exceptionalTimeType="4" autoTuneInstrumentation="true" autoTuneMaxAverage="100" autoTuneMinPerMille="10" samplingPayloadCallStacks="true" description="This template is particularly suitable for CPU profiling and for memory profiling when accurate allocation information is not important. Sampling has a very low overhead and does not distort measured call tines. Some views, like the method statistics are no available. JEE payloads cannot be annotated in the call tree, but payload hotspots without backtraces are available." system="true" />
  </templates>
  <sessions>
    <session id="80" templateId="50" name="Animated Bezier Curve Demo" type="1" isStartupWorkingDirectory="true" mainClass="bezier.BezierAnim">
      <filters>
        <filter type="inclusive" name="com." />
      </filters>
      <exceptionalMethods/>
      <classPath>
        <classPathEntry path="demo/bezier/classes" />
      </classPath>
      <sourcePath>
        <sourcePathEntry path="demo/bezier/src" />
      </sourcePath>
      <probes>
        <probe name="com.jprofiler.agent.probe.interceptor.TrackingInterceptor" enabled="true" startProbeRecording="false" events="false" annotatePayloads="false">
          <id value="3" />
        </probe>
      </probes>
    </session>

我面临的问题是,我无法在 jProfiler UI 的 CPU views 选项卡下获得有关方法统计信息的任何详细信息。

但我能够获取 Telemetrics 中的其他字段。

正在使用的版本:JProfiler 9.1,我使用示例 config.xml 开始我的测试。我是否需要在我的配置文件中进行任何更改才能在我的 .jps 文件中获取方法级统计信息

最佳答案

方法统计单独记录,因为开销太大,总是和CPU数据一起记录。

当 session 处于实时状态时,转到方法统计 View 并启用记录。对于离线分析,有一个启动方法统计记录的触发操作。

关于java - jProfiler 不提供方法级别的统计信息,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33832700/

相关文章:

java - jprofiler支持alpine linux吗?

java - JProfiler 可以在没有 GUI 的情况下运行吗?

java - 如何使用 JPopupmenu 的 JMenuItem 禁用特定单元格?

java - 对数组使用 Nullness 注释

java - 如何调试在 spring mvc rest 中找不到的 404 资源?

java - 单击按钮时使用 session 将动态值从一个 jsp 页面传递到另一个 jsp 页面

用于多个输入和平均结果的 Python 配置文件

java - 使用JProfiler进行性能分析时,可以显示滑动窗口最后X秒 View 吗?

go - 如何打印golang程序中执行的所有方法

haskell - 如何在 Haskell 中获取程序的运行时间