Closed allan-on closed 1 year ago
Following further conversations with the implementers:
KnowledgeManager
Library only supports importing Knowledge Resources via importing FilesBasically, any loading of the Resources from the server will be provided later in the Support downloading IGs from the remote Package Manager issue
Maintaining a similar workflow to the current one on FHIR Core would be ideal. That, we're able to sync them from the server and import them to the KnowledgeManager instead of working with Files.
Context
With the introduction of the
KnowledgeManager
library in the Google Android FHIR SDK in https://github.com/google/android-fhir/issues/1729 Knowledge Resources essentially packaged up in an Implementation Guide such as ValueSets, Plan/Activity Definitions and Library Resources containing CQL should be provided using the KnowledgeManager.Based on the Deploying Knowledge Resources via Android FHIR SDK doc,
It is a unified library that should be able to handle the loading, storage, caching, and versioning of knowledge resources and provide these resources to individual Android FHIR SDK libraries where needed
How the introduction of the lib affects FHIR Core
Refactors are required to make use of the
KnowledgeManager
and related Workflow module changes in the FHIR Core MeasureReports implementations. The changes on the SDK introduce loading of Resources, for instance, a Library that is used for evaluation of Immunizations/Measures, from the KnowledgeManager. The KnowledgeManager persists them in a separate database and when we do evaluate any Measure there's a call to theknowledgeManager.loadResources()
.These changes break FHIR Core FhirEngine.loadLibraryAtPath(fhirOperator: FhirOperator, path: String) The
loadLib()
was removed from the nowinternal FhirOperator
class and instead there's install(implementationGuide: ImplementationGuide, rootDirectory: File) or install(file: File)Future updates to the workflow dependency in FHIR Core will have to either include the new KnowledgeManager changes or have be on a separate branch/fork that doesn't include the KnowledgeManager implementations
Additional context See https://github.com/opensrp/fhircore/pull/2289#discussion_r1179590438 and https://github.com/opensrp/fhircore/pull/2289#discussion_r1180337649