Written by Caren Chang, Developer Relations Engineer

In case you missed it, we just finished a MAD Skills series on WorkManager. We first introduced WorkManager for those new to the library and then talked more about advanced uses, including testing and debugging your WorkManager code. The series ended with an episode about how to migrate your old code from GCMNetworkManager and FirebaseJobDispatcher to use WorkManager instead.

Here is a quick recap of what we covered.

Episode 1: WorkManager: Basics

In our first installment, we explored the basics of WorkManager through the WorkManager Codelab. We first understood how we define the work we want to do and how we plan the work. Then we implemented different types of work: unique and periodic. Finally, we ended the episode by looking at the app standby buckets to better understand how WorkManager schedules work.

Also, if you are new to WorkManager, we recommend reading the following articles:

Episode 2: WorkManager: Working in the background

The series continued, with Ben providing an in-depth look at how WorkManager handled multithreading. If you’re working with threads, you have the option to use Executors, Coroutines, or RxJava, and Ben has demonstrated each of these approaches with WorkManager. The episode ended with a demonstration of how to return a result when the work is done so that the user interface can be updated.

If you want to use WorkManager with coroutines, we also recommend this article from Florina: WorkManager – Kotlin APIs

Episode 3: WorkManager: Advanced Configuration and Testing

In Episode 3, we looked at how you can customize WorkManager’s initialization and support apps that span multiple processes. We received a lot of questions from developers about testing and debugging, so Ben also looked into testing your workers and useful debugging techniques.

Episode 4: Migration from GCM NetworkManager and FirebaseJobDispatcher to WorkManager

In episode 4 we focused on migrating legacy job scheduling libraries (GCMNetworkManager and FirebaseJobDispatcher) to WorkManager. Once your app is targeted to API level 30 and higher, GCM NetworkManager and FirebaseJobDispatcher will no longer work on devices with Android Marshmallow (6.0) and higher. If your app is still using one of these libraries, now is the time to update your apps to use WorkManager instead!

Episode 5: WorkManager with Hugo

Android GDE Hugo Visser talked about why he used WorkManager in a health app that he recently worked on and how the library helped his development process.

Episode 6: Live Questions and Answers

The series ended with a live Q&A session where we answered your WorkManager-related questions. Watch the recording to see how all of your questions have been answered, including future plans for WorkManager, handling duplicate work, repeating failed work, and more!


Please enter your comment!
Please enter your name here