FHIR Chat · Importing SNOMED terminology into HAPI server · hapi

Stream: hapi

Topic: Importing SNOMED terminology into HAPI server


view this post on Zulip David Cagigal (May 05 2020 at 22:08):

I have created a HAPI FHIR Server running in tomcat with a mySQL database. I am trying to import the SNOMED dataset into it.

While executing this command on the web server, it generates the following error:
java -jar hapi-fhir-cli.jar upload-terminology -d data/SnomedCT_USEditionRF2_PRODUCTION_20200301T120000Z.zip -v r4 -t http://localhost:8080/hapi-fhir-jpaserver/fhir/ -u http://snomed.info/sct -l

Server:
"resourceType": "CapabilityStatement",
"status": "active",
"date": "2020-05-05T22:24:18+00:00",
"publisher": "Not provided",
"kind": "instance",
"software": {
"name": "HAPI FHIR Server",
"version": "4.2.0"
},
"implementation": {
"description": "HAPI FHIR R4 Server",
"url": "http://localhost:8080/hapi-fhir-jpaserver/fhir/"
},
"fhirVersion": "4.0.1",
"format": [
"application/fhir+xml",
"application/fhir+json"
]

C:\data\4.2>java -Xms2048m -Xmx4092m -jar hapi-fhir-cli.jar upload-terminology -d C:\data\4.2\data\SnomedCT_USEditionRF2_PRODUCTION_20200301T120000Z.zip -v r4 -t http://localhost:8080/hapi-fhir-jpaserver/fhir -u http://snomed.info/sct -l


? HAPI FHIR 4.2.0 - Command Line Tool


Process ID : 5304@h365hapi-web
Max configured JVM memory (Xmx) : 3.6GB
Detected Java version : 1.8.0_221


2020-05-05 22:39:58.925 [main] INFO c.u.f.c.UploadTerminologyCommand Adding ZIP file: C:\data\4.2\data\SnomedCT_USEditionRF2_PRODUCTION_20200301T120000Z.zip
2020-05-05 22:40:00.191 [main] INFO c.u.f.c.UploadTerminologyCommand File size is greater than 10 MB - Going to use a local file reference instead of a direct HTTP transfer. Note that this will only work when executing this command on the same server as the FHIR server itself.
2020-05-05 22:40:19.167 [main] INFO c.u.f.c.UploadTerminologyCommand Beginning upload - This may take a while...
2020-05-05 22:40:58.945 [main] ERROR ca.uhn.fhir.cli.App Error during execution:
ca.uhn.fhir.rest.client.exceptions.FhirClientConnectionException: Failed to parse response from server when performing POST to URL http://localhost:8080/hapi-fhir-jpaserver/fhir/CodeSystem/$upload-external-code-system - org.apache.http.NoHttpResponseException: localhost:8080 failed to respond
at ca.uhn.fhir.rest.client.impl.BaseClient.invokeClient(BaseClient.java:398)
at ca.uhn.fhir.rest.client.impl.GenericClient$BaseClientExecutable.invoke(GenericClient.java:434)
at ca.uhn.fhir.rest.client.impl.GenericClient$OperationInternal.execute(GenericClient.java:1173)
at ca.uhn.fhir.cli.UploadTerminologyCommand.invokeOperation(UploadTerminologyCommand.java:204)
at ca.uhn.fhir.cli.UploadTerminologyCommand.run(UploadTerminologyCommand.java:113)
at ca.uhn.fhir.cli.BaseApp.run(BaseApp.java:251)
at ca.uhn.fhir.cli.App.main(App.java:43)

Thanks!

view this post on Zulip Jens Villadsen (May 06 2020 at 09:21):

Have you had a look into snowstorm https://github.com/IHTSDO/snowstorm ?

view this post on Zulip David Cagigal (May 06 2020 at 13:37):

I have not looked into snowstorm. Do you recommend keeping the terminology separate from the FHIR server itself?

view this post on Zulip Jens Villadsen (May 06 2020 at 13:39):

I would say that depends on your needs. If using all or a lot of SNOMED is core business I would probably go for loading it into the FHIR server itself. If not, I would consider keeping it separate and cache the stuff you need eg. like https://hapifhir.io/hapi-fhir/docs/validation/validation_support_modules.html#recipe-using-a-remote-terminology-server

view this post on Zulip Jens Villadsen (May 06 2020 at 13:40):

@Patrick Werner might be able to assist you further on that part

view this post on Zulip Patrick Werner (May 06 2020 at 13:47):

Never tried snowstorm before, but looks promising.

view this post on Zulip Patrick Werner (May 06 2020 at 13:47):

For such huge CodeSystems i would go with a remote terminology server, but cache the results.

view this post on Zulip Patrick Werner (May 06 2020 at 13:49):

In general i keep Terminology items (VS, small CS) on the server itself. LOINC, SnomedCT, HGNC i keep on a dedicated server.

view this post on Zulip Jens Villadsen (May 06 2020 at 14:30):

@Patrick Werner - would you have a validation chain open sourced somewhere that sort of does that? I mean filtering out what should be looked up locally and what code systems that should be looked up externally - being a hybrid between the strategies on https://hapifhir.io/hapi-fhir/docs/validation/validation_support_modules.html#validation-support-modules

view this post on Zulip David Cagigal (May 07 2020 at 16:50):

Thanks for the snowstorm suggestion! I was able to get that up & running and successfully imported the dataset. I am not sure that it will be a long term solution, but at least I have a terminology server ready for use.

view this post on Zulip Jens Villadsen (May 07 2020 at 17:27):

Credits for inspiration goes to @Espen Stranger Seland ;)

view this post on Zulip Jens Villadsen (May 07 2020 at 17:27):

And @Øyvind Aassve

view this post on Zulip Patrick Werner (May 08 2020 at 07:31):

Jens Villadsen said:

Patrick Werner - would you have a validation chain open sourced somewhere that sort of does that? I mean filtering out what should be looked up locally and what code systems that should be looked up externally - being a hybrid between the strategies on https://hapifhir.io/hapi-fhir/docs/validation/validation_support_modules.html#validation-support-modules

Still have some open questions on the new hapi5 Validation architecture and experimenting. Planning to extend the hapi doc on this.

view this post on Zulip Keerthivasan Ramanathan (Jul 31 2020 at 05:25):

We have a huge use of LOINC and SNOMEDs as we are implementing for a HIE. What is your recommendation? Do we load the LOINC and SNOMED into FHIR server itself? Is there any docs on how to upload the definitions into FHIR server? Please provide references, repo or examples.

Addition to that, how does the validation of code systems and valuesets happen if we store internally? Do we make use of PrePopulatedValidationSupport? Is that right?

Thanks for your guidance and support.


Last updated: Apr 12 2022 at 19:14 UTC