Added in API level 24

PidHealthStats


class PidHealthStats
kotlin.Any
   ↳ android.os.health.PidHealthStats

Keys for HealthStats returned from HealthStats.getStats(int) with the UidHealthStats.STATS_PIDS key.

The values coming from PidHealthStats are a little bit different from the other HealthStats values. These values are not aggregate or historical values, but instead live values from when the snapshot is taken. These tend to be more useful in debugging rogue processes than in gathering aggregate metrics across the fleet of devices.

Summary

Constants
static Int

Key for a measurement of the current nesting depth of wakelocks for this process.

static Int

Key for a measurement of the time in the android.os.SystemClock#elapsedRealtime timebase that a wakelock was first acquired in this process.

static Int

Key for a measurement of the total number of milleseconds that this process has held a wake lock.

Constants

MEASUREMENT_WAKE_NESTING_COUNT

Added in API level 24
static val MEASUREMENT_WAKE_NESTING_COUNT: Int

Key for a measurement of the current nesting depth of wakelocks for this process. That is to say, the number of times a nested wakelock has been started but not stopped. A high number here indicates an improperly paired wakelock acquire/release combination.

More details on the individual wake locks is available by getting the UidHealthStats#TIMERS_WAKELOCKS_FULL, UidHealthStats#TIMERS_WAKELOCKS_PARTIAL, UidHealthStats#TIMERS_WAKELOCKS_WINDOW and UidHealthStats#TIMERS_WAKELOCKS_DRAW keys.

Value: 20001

MEASUREMENT_WAKE_START_MS

Added in API level 24
static val MEASUREMENT_WAKE_START_MS: Int

Key for a measurement of the time in the android.os.SystemClock#elapsedRealtime timebase that a wakelock was first acquired in this process.

More details on the individual wake locks is available by getting the UidHealthStats#TIMERS_WAKELOCKS_FULL, UidHealthStats#TIMERS_WAKELOCKS_PARTIAL, UidHealthStats#TIMERS_WAKELOCKS_WINDOW and UidHealthStats#TIMERS_WAKELOCKS_DRAW keys.

Value: 20003

MEASUREMENT_WAKE_SUM_MS

Added in API level 24
static val MEASUREMENT_WAKE_SUM_MS: Int

Key for a measurement of the total number of milleseconds that this process has held a wake lock.

More details on the individual wake locks is available by getting the UidHealthStats#TIMERS_WAKELOCKS_FULL, UidHealthStats#TIMERS_WAKELOCKS_PARTIAL, UidHealthStats#TIMERS_WAKELOCKS_WINDOW and UidHealthStats#TIMERS_WAKELOCKS_DRAW keys.

Value: 20002