androidserviceintentservice

IntentService in android


please its a request to dont mark my question as irrelevent ,duplicate,etc

i want to clear the point

in one of stackoverflow answer--> https://stackoverflow.com/a/57018094/12553303

this user saying that

The job given to the IntentService would get lost when the application is killed

and in one of the site --> https://guides.codepath.com/android/starting-background-services

this blog says -->

The IntentService class used to be the way for running an operation on a single background thread. IntentService runs outside the application in a background process, so the process would run even if your application is closed.

Thanks need clarification


Solution

  • Since Android 8.0 IntentService changed so the System can kill your background process when it consider necessary and now, since API 30 it is deprecated.

    If you want something that survive when app get closed, consider using WorkManager or JobIntentService.