Services
Service is one of the component of Android, runs in the background to perform long-running operations. It doesn't require user interaction.
It works even if the component(ex. activity) which started is destroyed or the app destroyed.
A started service must manage its own lifecycle.
You can start a service from an activity or other application component by passing an Intent to startService().
The Android system calls the service's onStartCommand() method and passes it the Intent, which specifies which service to start. The system doesn't stop or destroy the service unless it must recover system memory.
The service must stop itself by calling stopSelf(), or another component can stop it by calling stopService().
The service either can run in the thread where it has called or it runs in the same thread as the component which has started the service.
Android Jetpack using Work manager !