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
497 stars 296 forks source link

Build a Benchmark Testing app #1378

Open vitorpamplona opened 2 years ago

vitorpamplona commented 2 years ago

Is your feature request related to a problem? Please describe. Benchmarking certain FHIR Features in instrumented tests and/or benchmark modules is quite difficult. The team could use an app to constantly measure the performance of several elements and help identify appropriate phone configurations to run certain types of applications.

Describe the solution you'd like Build and ship a FHIR Benchmarking app to allow easy evaluation of certain FHIR features for different phones. The basic structure is a simple collection of runners that measure time, battery consumption, networking needs, and memory usage for registered tasks. The app should display the list of runners with their individual time/memory results as well as an aggregate result at the bottom. A single button restarts all tests.

A few immediate runners could already be extremely helpful.

  1. FhirContext loading times.
  2. Parsing FHIR results from REST API/JSON (and other representations)
  3. Saving and retrieving FHIR objects from the database
  4. Saving and retrieving CQL libraries from the database.
  5. Running CQL-to-ELM compilation
  6. Evaluating small and large CQL expressions

Describe alternatives you've considered I have tried building a Benchmark Module, but the results are too inconsistent and lack added information about the use of Network/Memory/Processing power/Battery per element of the test.

Additional context Add any other context or screenshots about the feature request here.

Would you like to work on the issue? Please state if this issue should be assigned to you or who you think could help to solve this issue.

Tarun-Bhardwaj commented 2 years ago

@vitorpamplona , is there an ETA by when PR can be created for review?

vitorpamplona commented 2 years ago

Hum.. we have not prioritized this one yet. I suggested this idea at the same time other team members suggested a Benchmark module connected to a Google Cloud service to test on real devices inside the project. I am not sure where the discussion landed, but I believe other team members were testing the Benchmark idea out to see if we really need a new app.

@jingtang10 @ktarasenko what do you think? I am happy to start putting something together for this app.

ktarasenko commented 2 years ago

sounds great, I'd love to see something like that. @jingtang10 were there already any other efforts for benchmarking the SDK?

Tarun-Bhardwaj commented 2 years ago

sounds great, I'd love to see something like that. @jingtang10 were there already any other efforts for benchmarking the SDK?

@ktarasenko you may visit this PR https://github.com/google/android-fhir/pull/1414