Collectives™ on Stack Overflow
Find centralized, trusted content and collaborate around the technologies you use most.
Learn more about Collectives
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Learn more about Teams
The
JobIntentService
class appears to be deprecated. Yet the Android
documentation for services
says: "You can use JobIntentService as a replacement for IntentService that is compatible with newer versions of Android."
So what are we supposed to replace JobIntentService with?
–
–
–
–
–
As @CommonsWare pointed out, I had two options for replacing my JobIntentService:
Using a
foreground service
Using a
WorkManager
with a
long-running worker
The Android
documentation on services
states:
The WorkManager API offers a flexible way of scheduling tasks, and is
able to run these jobs as foreground services if needed. In many
cases, using WorkManager is preferable to using foreground services
directly.
Since Google seems to be pushing folks towards WorkManager, that's what I decided to use.
–
–
–
–
Thanks for contributing an answer to Stack Overflow!
-
Please be sure to
answer the question
. Provide details and share your research!
But
avoid
…
-
Asking for help, clarification, or responding to other answers.
-
Making statements based on opinion; back them up with references or personal experience.
To learn more, see our
tips on writing great answers
.