I don't see the particular thing you're referencing in the Lifecycle page. One notable time when apps are killed without warning is during an upgrade or removal.
My understanding of the normal lifecycle is that Activities and Services are always shutdown using the whole sequence (onPause(), onStop(), onDestroy() etc.) before being killed. Maybe that's based on my wishful thinking. One thing to help tracking low memory conditions is creating onTrimMemory() and onLowMemory() in an Application subclass. Android should call those when memory is getting low as the first step before killing things. That's how I understand it at least. .hc that's Michael Rogers: > Sorry if I'm misunderstanding the issue, but hasn't it always been > possible for a service (even a foreground service) to be killed by the > system without any methods being called? > > https://developer.android.com/guide/components/processes-and-threads.html#Lifecycle > > Cheers, > Michael > > On 01/12/14 08:14, Hans-Christoph Steiner wrote: > >> Is there any documentation about onDestroy() no longer being >> called? That would be a pretty big change. Maybe something in >> TorService is crashing? Then onDestroy() wouldn't be called. > >> .hc > >> Nathan of Guardian: >>> I think we've finally gotten all the background service longevity >>> sorted out, especially on Lollipop where it seemed to be much >>> more brutal, in outright killing of the TorService instant, even >>> without calling onDestroy(). Anyhow, now startForeground() is >>> doing what it should be, we aren't binding any more (Just use >>> broadcasts and startService() calls), and Orbot doesn't show up >>> in recent apps anymore, so no more swiping away.... >>> >>> >>> /** 14.1.4 / 29-Nov-2014 / >>> b7fcbdc4e85071191cc95c3824e7b5a90d36d1e8 **/ >>> >>> * Stop background service being killed 1e0f640 adding >>> dummyactivity to stop task/broadcast from killing foreground >>> service ec9204a clean-up of code to make service more long-lived >>> and stable da4866c update polipo to latest head >>> >>> * Activity and theme updates 917cfa1 support SDK 16, add custom >>> theme, make Orbot singleTop activity 91f4fa0 cleanup landscape >>> layout ad7d92f clean-up / remove un-used code d5823e3 updates to >>> layout to make it cleaner 2d6c26a show exit node info in log >>> >>> APK Lollipop: >>> https://guardianproject.info/releases/Orbot-v14.1.4-LollipopPIE.apk >>> >>> > (.asc) >>> APK <= KitKat: >>> https://guardianproject.info/releases/Orbot-v14.1.4-UpToKitKat-nonPIE.apk >>> >>> > (.asc) >>> >>> Souirce: >>> https://gitweb.torproject.org/orbot.git/commit/b34d971193d843f1258904cba55779a58c819d0f >>> >>> >>> >>> > _______________________________________________ >>> Guardian-dev mailing list >>> >>> Post: [email protected] List info: >>> https://lists.mayfirst.org/mailman/listinfo/guardian-dev >>> >>> To Unsubscribe Send email to: >>> [email protected] Or visit: >>> https://lists.mayfirst.org/mailman/options/guardian-dev/hans%40guardianproject.info >>> >>> >>> > You are subscribed as: [email protected] >>> > > > >> _______________________________________________ Guardian-dev >> mailing list > >> Post: [email protected] List info: >> https://lists.mayfirst.org/mailman/listinfo/guardian-dev > >> To Unsubscribe Send email to: >> [email protected] Or visit: >> https://lists.mayfirst.org/mailman/options/guardian-dev/michael%40briarproject.org > >> You are subscribed as: [email protected] > > -- PGP fingerprint: 5E61 C878 0F86 295C E17D 8677 9F0F E587 374B BE81 https://pgp.mit.edu/pks/lookup?op=vindex&search=0x9F0FE587374BBE81
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Guardian-dev mailing list Post: [email protected] List info: https://lists.mayfirst.org/mailman/listinfo/guardian-dev To Unsubscribe Send email to: [email protected] Or visit: https://lists.mayfirst.org/mailman/options/guardian-dev/archive%40mail-archive.com You are subscribed as: [email protected]
