WorkManager
The WorkManager library was born to perform background processing (outside MainThread ) of applications that the user is not interacting with, dealing with the restrictions imposed on background processing by Android and integrating and simplifying some existing solutions. Remember that an app is considered to be running in the background as long as each of the following conditions are satisfied: None of the app's activities are currently visible to the user. The app isn't running any foreground services that started while an activity from the app was visible to the user. Restrictions Doze mode If a user leaves a device unplugged and stationary for a period of time, with the screen off, the device enters Doze mode. This mode prevents apps from accessing the network and defers their jobs, syncs, and standard alarms. It, therefore, restricts the use of background services, which can only use these resources in a short period of time called the maintenance window. Android Oreo Whe