It will purely depend on the system condition at that time. Docs clearly says about onDestroy()
that:
There are situations where the system will simply kill the activity's hosting process without calling this method (or any others) in it, so it should not be used to do things that are intended to remain around after the process goes away.
See Here