HAPIFHIR Client Library Performance

91 views
Skip to first unread message

Greg Harabedian

unread,
Nov 2, 2017, 4:39:37 PM11/2/17
to HAPI FHIR
We are processing and constructing tens of thousands (eventually millions) of bundles from flat files and generating JSON so that they can be sent via RESTful calls.  These JSON bundles are complex and can range in size from <1MB to 60MB.  We use the HAPI FHIR libraries to construct and validate the JSON/RESTful calls.  However, constructing and validating the bundles can take anywhere from 1 second to several seconds.  I know the client libraries are doing a lot when it comes to validating structure and content.  I'm just wondering if there are any options for using HAPI to improve performance and only perform minimal validation/operations on the resources in order to improve performance?  We know that that the performance issues are related to HAPI and mostly seem to be around instantiating FHIR resource objects.  Any advice would be appreciated.

James Agnew

unread,
Nov 4, 2017, 4:05:43 PM11/4/17
to Greg Harabedian, HAPI FHIR
Hi Greg,

What type of validation are you doing? There are three validation forms (parser validation, schema validation, and profile validation) and each one has its own performance characteristics.

If you just want basic syntax validation the parser validation is definitely the most bang for your buck. Profile validation is always the slowest, as it does terminology validation using terminology services, advanced structure validation, etc, but it is certainly also the most complete. Schema validation falls somewhere in the middle.

The profile validation definitely has room for improvement. We've been doing profiling bit by bit to find trouble spots, but there is plenty left to do. If you happen to have a good test case Bundle that takes a particularly long time, I'd love to see it.

Cheers,
James

On Thu, Nov 2, 2017 at 4:39 PM, Greg Harabedian <greg.ha...@gmail.com> wrote:
We are processing and constructing tens of thousands (eventually millions) of bundles from flat files and generating JSON so that they can be sent via RESTful calls.  These JSON bundles are complex and can range in size from <1MB to 60MB.  We use the HAPI FHIR libraries to construct and validate the JSON/RESTful calls.  However, constructing and validating the bundles can take anywhere from 1 second to several seconds.  I know the client libraries are doing a lot when it comes to validating structure and content.  I'm just wondering if there are any options for using HAPI to improve performance and only perform minimal validation/operations on the resources in order to improve performance?  We know that that the performance issues are related to HAPI and mostly seem to be around instantiating FHIR resource objects.  Any advice would be appreciated.

--
You received this message because you are subscribed to the Google Groups "HAPI FHIR" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hapi-fhir+unsubscribe@googlegroups.com.
To post to this group, send email to hapi...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/hapi-fhir/5c3aee5f-06ab-4220-bf87-1b1e9ca55ca0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages