Class ProfilingScheduler

java.lang.Object
io.pyroscope.javaagent.ProfilingScheduler

public class ProfilingScheduler extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
    ProfilingScheduler(Config config, io.pyroscope.javaagent.Profiler profiler, io.pyroscope.javaagent.OverfillQueue<io.pyroscope.javaagent.Snapshot> pushQueue)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static Instant
    alignProfilingIntervalStartTime(Instant profilingIntervalStartTime, Duration uploadInterval)
    Aligns profilingIntervalStartTime to the closest aligned upload time either forward or backward For example if upload interval is 10s and profilingIntervalStartTime is 00:00.01 it will return 00:00 and if profilingIntervalStartTime is 00:09.239 it will return 00:10 ...
    Starts the first profiling interval.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ProfilingScheduler

      public ProfilingScheduler(Config config, io.pyroscope.javaagent.Profiler profiler, io.pyroscope.javaagent.OverfillQueue<io.pyroscope.javaagent.Snapshot> pushQueue)
  • Method Details

    • startFirst

      public Duration startFirst()
      Starts the first profiling interval. profilingIntervalStartTime is set to a current time aligned to upload interval Duration of the first profiling interval will be smaller than uploadInterval for alignment. ...
      Returns:
      Duration of the first profiling interval
    • alignProfilingIntervalStartTime

      public static Instant alignProfilingIntervalStartTime(Instant profilingIntervalStartTime, Duration uploadInterval)
      Aligns profilingIntervalStartTime to the closest aligned upload time either forward or backward For example if upload interval is 10s and profilingIntervalStartTime is 00:00.01 it will return 00:00 and if profilingIntervalStartTime is 00:09.239 it will return 00:10 ...
      Parameters:
      profilingIntervalStartTime - the time to align
      uploadInterval -
      Returns:
      the aligned