Tag Info

New answers tagged


There is no need to leave as service running to perform regular polling, and doing so may annoy your users, as it will consume memory for no good reason. You should look at the AlarmManager API. This has three potential advantages: it can be configured to send an Intent that will start your app in the background even if it is not running, meaning you ...


Create a runnable and call it with handler using postDelayed() method in your service. private final Handler handler = new Handler(); private Runnable getResponceAfterInterval = new Runnable() { public void run() { try { new RequestTask().execute("URL of your GET request"); //RequestTask() is a AsynchTask ...

Top 50 recent answers are included