Perform long running operations when receiving SMS on API < 21
问题 I'm building an app that will listen for incoming SMS messages, perform some potentially long running operations and send back a reply if some conditions are met. I've got the listening part working using a BroadcastReceiver , but I'm not sure how/where to perform the potentially long running operations. The Android Developer Documentation states that After onReceive(), the system can kill the process at any time to reclaim memory, and in doing so, it terminates the spawned thread running in