Hi All,
For a project in Zambia we have to setup a synchronization service between a Client Registry and a Point of Service (Immunization Registry) application. As I suspect that this would be generically useful, I thought it would be good to implement this as a mediator for OpenHIM and discuss with this group some of the priority features and expected future features.
The first workflow what we will want to concentrate on at first would be a mediator that runs on a routine (e.g. nightly, hourly basis)
- meditator make a request to a Point of Service application to get a list of changed patient resource records using the _history operation. Some notes here:
- the mediator would request the patient resources in pages.
- because an initial data load could result in a large number of records, we may want to loop through the paged results sequentially so we don't get a "too many open files" error
- the mediator would transform each page of results into a transaction to submit to a Client Registry
- because we are going to rely on timestamps to keep track of changes
- if all transactions are run successfully we update the time timestamp
- we need a place to store the timestamp of the last time that the synchronization was run. In our case we are using DHIS2 Tracker as our Point of Service application which allows us to use the Data Store API. This will meet our short term needs, but limits this mediator to work only with DHIS2. Are there are any plans to add a similar type of service to hold mediator specific metadata to the OpenHIM Core?
Some future needs that we will want to consider:
- We may want the synchronization service to work on one or more different resources
- We may want to easily add a hook to perform a translation of the individual resource. For example we may need to do a translation from a FHIR DSTU resource to a STU3 Resource, as the CR we are looking at MedicCR only supports DSTU while for DHIS2 we are targeting STU3. We will start with a HAPI server in lieu of MedicCR as it can already support STU3.
- At some point we will want to point the mediator to a second (and more) source of client demographics from other points of service. Would it be better to have multiple instances of the same mediator or use the same mediator that can handle multiple sources of information.
- At some point, we will want to use identified duplicate records on the CR to trigger merge of clinical information in POS application. I think this is likely this is one (or more) different mediators.
I would appreciate your thoughts on this setup, a recommend a good starting point within the OpenHIM mediator documentation as well as any examples of mediators that may be similar.
On a related note, do you have any recommendations for a testing environment for the mediators?
Finally, have you found any of the node.js FHIR module (e.g.
this one) useful?
Gerard, one of our developers, will be doing a lot of this work. I hope that you will be able to extend to him some guidance and suggestions.
Thanks all!
Cheers,
-carl