firebase-job-dispatcher

Firebase jobdispatcher not triggering within specified window

孤者浪人 提交于 2019-12-03 17:20:43
I am implementing Firebase Jobdispatcher with trigger time specified between 10 to 20 seconds. This is my code to schedule a job: public static void scheduleCompatibleJob(Context context) { FirebaseJobDispatcher dispatcher = new FirebaseJobDispatcher(new GooglePlayDriver(context)); Job myJob = dispatcher.newJobBuilder() .setService(DataTrackerJobService.class) // the JobService that will be called .setTag("api_trigger") .setRecurring(true) .setLifetime(Lifetime.FOREVER) .setTrigger(Trigger.executionWindow(10, 20)) // 10 to 20 seconds .setReplaceCurrent(true) .setRetryStrategy(RetryStrategy

Cant stop Firebase JobDispatcher service

有些话、适合烂在心里 提交于 2019-12-02 06:46:01
问题 Possible Duplicate I have created a JobDispatcher service to keep getting user location in background and post user location to server. For that i have created a Job as follow: private void startLocationJobService() { // Check if location job service already running if(!isMyServiceRunning(LocationJobService.class)) { Context context = config.getActivity(); FirebaseJobDispatcher dispatcher = new FirebaseJobDispatcher(new GooglePlayDriver(context)); Job job = dispatcher.newJobBuilder()

Firebase Job Dispatcher not Scheduling jobs on OREO devices

一曲冷凌霜 提交于 2019-11-29 17:26:06
I have a firebase job dispatcher which is scheduled to run whenever network changes ,the job is working perfectly on a marshmallow device (23 API level) but the same code when run is not scheduling jobs on a oreo device(26 API level) Here is my Job Service code: public class MyJobService extends JobService { @Override public boolean onStartJob(JobParameters job) { Log.d("Executing","Job"); Realm realm = Realm.getDefaultInstance(); RealmResults<JsontoSend> realmResults = realm.where(JsontoSend.class).findAll(); if(!realmResults.isEmpty()) { for (JsontoSend jsontoSend : realmResults) { final

Firebase Job Dispatcher not Scheduling jobs on OREO devices

天涯浪子 提交于 2019-11-28 12:49:39
问题 I have a firebase job dispatcher which is scheduled to run whenever network changes ,the job is working perfectly on a marshmallow device (23 API level) but the same code when run is not scheduling jobs on a oreo device(26 API level) Here is my Job Service code: public class MyJobService extends JobService { @Override public boolean onStartJob(JobParameters job) { Log.d("Executing","Job"); Realm realm = Realm.getDefaultInstance(); RealmResults<JsontoSend> realmResults = realm.where(JsontoSend

Android - Firebase jobdispatcher

空扰寡人 提交于 2019-11-27 19:52:05
I would like to know if it's possible to use Firebase jobdispatcher to schedule an url hit and get the response in order to update the db. I would like it to run once per day at night. Does anyone know if this is possible? I can't find any good example of doing this. I already read android documentation and https://github.com/firebase/firebase-jobdispatcher-android#user-content-firebase-jobdispatcher- . I need to use Firebase jobdispatcher because I'm targeting API 16. Thanks in advance. UPDATE This is what I did to schedule it once per day. final int periodicity = (int) TimeUnit.HOURS

Firebase JobDispatcher - how does it work compared to previous APIs (JobScheduler and GcmTaskService)?

两盒软妹~` 提交于 2019-11-26 23:33:02
Background Google has multiple solutions for job/task scheduling, such as JobScheduler and GcmTaskService . Each has its own advantages and disadvantages. Recently, Google presented a new library called "Firebase JobDispatcher". The problem Sadly, there is very little to read about this new API. In fact, it's really hard to find anything about it. Only thing I've found is their announcement video and a sample . But even their, there is not much to know about this API. The questions Looking at previous questions, investigations and comparisons I had with the other APIs ( here , for example), I

Android - Firebase jobdispatcher

戏子无情 提交于 2019-11-26 22:51:12
问题 I would like to know if it's possible to use Firebase jobdispatcher to schedule an url hit and get the response in order to update the db. I would like it to run once per day at night. Does anyone know if this is possible? I can't find any good example of doing this. I already read android documentation and https://github.com/firebase/firebase-jobdispatcher-android#user-content-firebase-jobdispatcher- . I need to use Firebase jobdispatcher because I'm targeting API 16. Thanks in advance.

Firebase JobDispatcher - how does it work compared to previous APIs (JobScheduler and GcmTaskService)?

三世轮回 提交于 2019-11-26 08:46:24
问题 Background Google has multiple solutions for job/task scheduling, such as JobScheduler and GcmTaskService . Each has its own advantages and disadvantages. Recently, Google presented a new library called \"Firebase JobDispatcher\". The problem Sadly, there is very little to read about this new API. In fact, it\'s really hard to find anything about it. Only thing I\'ve found is their announcement video and a sample. But even their, there is not much to know about this API. The questions Looking