Logo Search packages:      
Sourcecode: visualvm version File versions  Download package

void org::netbeans::lib::profiler::server::TakeHeapdumpProfilingPointHandler::profilingPointHit ( int  id ) [inline]

Invoked by the JFluid server whan the profiling point hits.

Parameters:
idunique ID of the profiling point

Reimplemented from org::netbeans::lib::profiler::global::ProfilingPointServerHandler.

Definition at line 88 of file TakeHeapdumpProfilingPointHandler.java.

References org::netbeans::lib::profiler::server::system::Timers::getCurrentTimeInCounts(), org::netbeans::lib::profiler::global::Platform::getJDKVersionNumber(), and org::netbeans::lib::profiler::global::CommonConstants::JDK_15.

                                          {
        int instrType = ProfilerInterface.getCurrentInstrType();
        boolean cpuProfiling = (instrType == CommonConstants.INSTR_RECURSIVE_FULL)
                               || (instrType == CommonConstants.INSTR_RECURSIVE_SAMPLED);

        if (cpuProfiling) { // CPU profiling
            ProfilerRuntimeCPU.suspendCurrentThreadTimer();
        }

        long absTimeStamp = Timers.getCurrentTimeInCounts();

        if (!remoteProfiling) { // take heap dump is supported only for local profiling

            String heapdumpName = getHeapDumpName(absTimeStamp);
            String error = HeapDump.takeHeapDump(Platform.getJDKVersionNumber() == Platform.JDK_15, heapdumpName);

            if (error != null) {
                System.err.println("Dump to " + heapdumpName + " failed with " + error); // NOI18N
            }
        }

        super.profilingPointHit(id, absTimeStamp);

        if (cpuProfiling) {
            ProfilerRuntimeCPU.resumeCurrentThreadTimer();
        }
    }

Here is the call graph for this function:


Generated by  Doxygen 1.6.0   Back to index