In the wake-lock training doc it says:
If you need to keep the CPU running in order to complete some work before the device goes to sleep, you can use a PowerManager system service feature called wake locks.
It was my impression that "before the device goes to sleep" referred to doze mode. However, the answer to the SO post Wakelock and doze mode states:
Holding a PARTIAL_WAKE_LOCK is insufficient to block Doze mode
So, if a wake-lock doesn't prevent doze mode, then what exactly is meant by "keep the CPU running in order to complete some work before the device goes to sleep"?
Also, in the doze standby training doc it says:
An app that is partially exempt can use the network and hold partial wake locks during Doze and App Standby.
If (for some reason) "before the devices goes to sleep" does refer to doze mode, then does this mean that wake-locks have absolutely no effect unless you are on the white list for no battery optimizations?
Specifically, I'm talking about partial wake-locks on API 31+.