FHIR Storage Modules
In order to implement a FHIR Repository using Smile CDR, a FHIR Storage module is used to provide the actual data storage.
Typically, this module will be paired with a FHIR Endpoint module in order to provide a REST API that can be used to interact with the repository. It is even possible to pair multiple FHIR Endpoint modules with a single FHIR Storage module, for example if you had different security or validation needs for different modules.
Comparison tables for Smile CDR's support for MongoDB versus Relational (RDBMS) are below. Broader support for MongoDB will be available in future releases.
Feature | Mongo | RDBMS | Notes |
---|---|---|---|
DSTU 2 | ✔ | ||
DSTU 3 | ✔ | ||
R4 | ✔ | ✔ | |
R5 | ✔ | ||
Search | ✔ | ✔ | Mongo does not support search or validation of canonical references. Mongo does not support Document and Message SearchParameters |
Subscriptions | ✔ | ✔ | |
Security | ✔ | ✔ | |
Hybrid Provider | ✔ | ✔ | |
Gateway | ✔ | ✔ | |
Clustering | ✔ | ✔ | |
HL7 V2 | ✔ | ✔ | |
CDA | ✔ | ||
ETL Import | ✔ | ✔ | |
Bulk Export | ✔ | ✔ | Mongo currently only supports system level export, and does not support mdm |
JSON Admin | ✔ | ✔ | |
LiveBundle | ✔ | DSTU 3+ only | |
MDM/EMPI | ✔ | ✔ | DSTU 3+ only, Mongo persistence currently does not support mdm expansion search |
MDM Link History | ✔ | DSTU 3+ only, Mongo persistence currently does not support mdm link history search | |
MDM Expansion | ✔ | Mongo persistence currently does not support mdm expansion | |
Terminology Service | ✔ | ||
Pagination | ✔ | ✔ | |
Partitioning | ✔ | ||
Referential Integrity on Delete | ✔ | See Validating References And Referential Integrity | |
Validating References | ✔ | ✔ | See Validating References And Referential Integrity |
Custom Resource Types | ✔ | ✔ | |
System-to-System Data Exchange | ✔ |
Operation / Level | Mongo | RDBMS | Notes |
---|---|---|---|
Read / Instance | ✔ | ✔ | |
VRead / Instance | ✔ | ✔ | |
Search / Type | ✔ | ✔ | |
Search / Server | |||
History / Instance | ✔ | ✔ | |
History / Type | ✔ | ✔ | |
History / Server | ✔ | In MongoDB, server history is stored but not yet accessible by API | |
Create / Type | ✔ | ✔ | |
Update / Instance | ✔ | ✔ | |
Transaction / Server | ✔ | ✔ | |
Batch / Server | ✔ | ✔ | |
$reindex / Server | ✔ | ✔ | Reindexing on MongoDB must be type specific. |
$reindex / Instance | ✔ | ||
$reindex-dryrun / Instance | ✔ | ||
$everything / Instance / Type | ✔ | ✔ | |
$everything / Instance / Type | ✔ | ✔ | |
$delete-expunge / Type | ✔ | ✔ | Cascading deletes are not supported on MongoDB. |
$trigger-subscription | ✔ |
Parameters for all resources | Mongo | RDBMS | |
---|---|---|---|
_id | ✔ | ✔ | |
_lastUpdated | ✔ | ✔ | |
_tag | * | ✔ | See note on _tag below |
_source | ✔ | ✔ | |
_profile | ✔ | ✔ | |
_security | ✔ | ||
_text | ✔ | ||
_content | ✔ | ||
_list | ✔ | ||
_has | ✔ | ||
_type | |||
_filter | ✔ | ||
Search result parameters | ----- | ----- | |
_sort | ✔ | ✔ | See note on _sort below |
_count | ✔ | ✔ | |
_include | ✔ | ✔ | |
_revinclude | * | ✔ | See note on _revinclude below |
_summary | * | ✔ | |
_total=none | * | ✔ | |
_total=accurate | ✔ | ✔ | |
_total=estimated | |||
_elements | ✔ | ✔ | |
_contained | ✔ | ||
_containedType | ✔ | ||
_fhirpath | ✔ | ✔ |
_tag On RDBMS, tags can be stored as a single collection for all versions of a resource, or can be versioned along with resource contents. For RDBMS and MongoDB, partial searches by System are not supported and the Operation Outcome will be an error stating that the value|code are both required.
_revinclude On MongoDB, the _revinclude
parameter is only currently supported when the target of the _revinclude is a single resource, e.g. Patient?_id=123&_revinclude=*
. Furthermore, _iterate
is currently not supported while using _revinclude
.
_tag On MongoDB, tags on resources are version specific.
_sort On MongoDB, the _sort
parameter currently only supports sorting by a single sort parameter, e.g. Observation?_sort=category
. Combining multiple sort parameters (e.g. Observation?_sort=status,-date,category
) is not supported.
data type | prefix | Mongo | RDBMS | Notes |
---|---|---|---|---|
number | eq | ✔ | ✔ | |
number | ne | ✔ | ✔ | |
number | gt | ✔ | ✔ | |
number | lt | ✔ | ✔ | |
number | ge | ✔ | ✔ | |
number | le | ✔ | ✔ | |
number | ap | ✔ | ||
date | eq | ✔ | ✔ | |
date | ne | ✔ | ✔ | |
date | gt | ✔ | ✔ | |
date | lt | ✔ | ✔ | |
date | ge | * | ✔ | |
date | le | * | ✔ | |
date | sa | |||
date | eb | |||
date | ap | |||
string | contains | ✔ | ||
string | exact | ✔ | ✔ | |
string | text | ✔ | ||
uri | above | ✔ | ||
uri | below | ✔ | ||
token | text | ✔ | ||
token | not | ✔ | ||
token | above | ✔ | ||
token | below | ✔ | ||
token | in | ✔ | ||
token | not-in | ✔ | ||
token | of-type | ✔ | ✔ | |
quantity | eq | ✔ | ✔ | MongoDB: See note on quantity search parameters below |
quantity | ne | ✔ | ✔ | |
quantity | gt | ✔ | ✔ | |
quantity | lt | ✔ | ✔ | |
quantity | ge | ✔ | ✔ | |
quantity | le | ✔ | ✔ | |
quantity | ap | ✔ | ||
reference | mdm | ✔ | ✔ |
On MongoDB, search parameters of type Quantity are supported, but they do not take units of measure into consideration. For example, a search for /Observation?value-quantity=gt5.4|http://unitsofmeasure.org|mg
will match any Observations with Observation.valueQuantity
containing a numeric value above 5.4, regardless of the source units.