Skip to content

Subscription Startup Resiliency

Ken Stevens edited this page Jan 10, 2019 · 11 revisions

There are two ways to perform Subscription Matching using the HAPI-FHIR JPA Server:

  1. Within a FHIR Server Endpoint using the SubscriptionMatchingInterceptor. Within the FHIR Server:
myDaoConfig.addSupportedSubscriptionType(Subscription.SubscriptionChannelType.RESTHOOK);
myDaoConfig.setSubscriptionMatchingEnabled(true);
mySubscriptionInterceptorLoader.registerInterceptors();
  1. Outside of the FHIR Server Endpoint using a StandaloneSubscriptionMessageHandler: Within the FHIR Server:
myDaoConfig.addSupportedSubscriptionType(Subscription.SubscriptionChannelType.RESTHOOK);
myDaoConfig.setSubscriptionMatchingEnabled(false);
mySubscriptionInterceptorLoader.registerInterceptors();

Also, create your own interceptor within the FHIR Server that sends all Resources to a SubscribableChannel. Then subscribe the StandaloneSubscriptionMessagHandler to that SubcribableChannel:

mySubscribableChannel.subscribe(myStandaloneSubscriptionMessageHandler);
Clone this wiki locally