I want to restart my service automatically if the application works. My ideas:
1: BroadcastReceiver when apk fails and service automatically restarts
if("android.intent.action.SOMETHING".equals(intent.getAction()))
{
Intent serviceLauncher = new Intent(context, Service.class);
context.startService(serviceLauncher);
}
2: with uncaughtException (), but I don't know how to handle this
source
share