Interface ResourceMonitoringService

    • Method Detail

      • getUsedCpuPercentPerModule

        PackedMap<String,​Float> getUsedCpuPercentPerModule()
        Retrieves the CPU usage for each module from the previous monitoring cycle, expressed as a percentage.
        Returns:
        a map where each entry contains a module name as the key and its CPU usage percentage (0.0 to 1.0) as the value.
      • getUsedMemoryPercentPerModule

        PackedMap<String,​Float> getUsedMemoryPercentPerModule()
        Retrieves the RAM usage values expressed as a percentage (a value between 0 and 1.0).

        The percentage indicates the ratio between a module's current heap consumption and the total heap.

        Returns:
        a map where each entry contains the module name as the key and its current RAM usage percentage as the value.
      • getUsedMemoryPerModule

        PackedMap<String,​Long> getUsedMemoryPerModule()
        Retrieves the current RAM usage for each module.
        Returns:
        a map where each entry contains a module identifier as the key and its current RAM usage in bytes as the value.
      • getFreeMemory

        long getFreeMemory()
        Returns the free memory.
        Returns:
        the free memory.
      • getMaxMemory

        long getMaxMemory()
        Returns the max memory.
        Returns:
        the max memory.
      • getTotalMemory

        long getTotalMemory()
        Returns the total memory.
        Returns:
        the total memory.