Xamarin.Android Firebase Job Dispatcher: Background Scheduling for all Android Devices

TomOpgenorthTomOpgenorth CAXamarin Team Xamurai

We just published our blog on Firebase Job Dispatcher binding for Xamarin.Android. Please feel free to discuss the contents of this blog here. If you have any questions about open source, the Xamarin.Android project, or just want to stop by and say you enjoyed the content, this is the place to do that!

Posts

  • MarkZhukovskyMarkZhukovsky USMember ✭✭
    Nice! Is there an iOS implementation? And to push the luck- Xamarin Forms abstraction?
  • TomOpgenorthTomOpgenorth CAXamarin Team Xamurai

    I see that there is a project on Github for firebase-dispatcher-ios, but it doesn't seem like anything is happening (going to happen?) with that project. So, I'd expect that this will be Xamarin.Android for now.

  • andrekibaandrekiba ITUniversity ✭✭

    how about the interaction with the Doze mode? same problems that we can find using GcmService or it can be more flexible? I'm try to find a way to avoid the fight with the Doze mode... :-(

  • TomOpgenorthTomOpgenorth CAXamarin Team Xamurai

    @andrekiba : Not sure 100% sure I get what you mean by "interaction with Doze" (although I think I have an idea): When you schedule a job with FJD, you're ultimately just making a request to run some work. FJD will try to honour your request as best as it can, but it's possible that the operating system (i.e. Doze mode) may "devalue" some of the criteria for that request.

    A good way to think of FJD: "Please run this work at some point, and here is a guideline on when".

    I hope that answers your question.

  • andrekibaandrekiba ITUniversity ✭✭
    yes :smile: with GcmTaskService you can setup a task that tries to follow a schedule...but in Doze mode background tasks are deferred (and executed only during active windows) and so the only why to make a sort of “sync in background” when the device is inactive is to move to push notifications. Following your answer I think the same thing is maybe true also for FJD... :-( ...not so good...
  • TomOpgenorthTomOpgenorth CAXamarin Team Xamurai

    You might could try off sending a high priority Firebase Cloud Message. In theory, that should wake the device for a few minutes. Exercise with discretion however.

Sign In or Register to comment.