google / android-fhir

The Android FHIR SDK is a set of Kotlin libraries for building offline-capable, mobile-first healthcare applications using the HL7® FHIR® standard on Android.
https://google.github.io/android-fhir/
Apache License 2.0
465 stars 246 forks source link

Wrap FHIREngine API calls with "withContext(Dispatcher.IO) {}" #2556

Open MJ1998 opened 3 weeks ago

MJ1998 commented 3 weeks ago

Describe the Issue The CRUD + Search APIs are suspend function which application can invoke in main thread also. We should wrap these function within `withContext(Dispatcher.IO){}" to ensure that this call runs on IO thread and does not block the Main thread.

Would you like to work on the issue?