diff --git a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/DaoConfig.java b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/DaoConfig.java
index 75f549f18fc..a0e0766db0d 100644
--- a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/DaoConfig.java
+++ b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/DaoConfig.java
@@ -1392,7 +1392,8 @@ public class DaoConfig {
}
/**
- * If set to false
(default is true) the server will not match incoming resources against active subscriptions.
+ * If set to true
(default is true) the server will match incoming resources against active subscriptions
+ * and send them to the subscription channel. If set to false
no matching or sending occurs.
* @since 3.7.0
*/
@@ -1401,10 +1402,12 @@ public class DaoConfig {
}
/**
- * If set to false
(default is true) the server will not match incoming resources against active subscriptions.
+ * If set to true
(default is true) the server will match incoming resources against active subscriptions
+ * and send them to the subscription channel. If set to false
no matching or sending occurs.
* @since 3.7.0
*/
+
public void setSubscriptionMatchingEnabled(boolean theSubscriptionMatchingEnabled) {
mySubscriptionMatchingEnabled = theSubscriptionMatchingEnabled;
}
diff --git a/src/changes/changes.xml b/src/changes/changes.xml
index 04448c1b1af..ae549874c08 100644
--- a/src/changes/changes.xml
+++ b/src/changes/changes.xml
@@ -38,9 +38,13 @@
by two new interceptors: SubscriptionActivatingInterceptor that is responsible for activating subscriptions
and SubscriptionMatchingInterceptor that is responsible for matching incoming resources against activated
subscriptions. Call DaoConfig.addSupportedSubscriptionType(type) to configure which subscription types
- are supported in your environment. The helper method SubscriptionInterceptorLoader.registerInterceptors()
+ are supported in your environment. If you are processing subscriptions on a separate server and only want
+ to activate subscriptions on this server, you should set DaoConfig.setSubscriptionMatchingEnabled to false.
+ The helper method SubscriptionInterceptorLoader.registerInterceptors()
will check if any subscription types are supported, and if so then load active subscriptions into the
- SubscriptionRegistry and then register both the activating and matching interceptors.
+ SubscriptionRegistry and register the subscription activating interceptor. This method also registers
+ the subscription matching interceptor (that matches incoming resources and sends matches to subscription
+ channels) only if DaoConfig.isSubscriptionMatchingEnabled is true.
See https://github.com/jamesagnew/hapi-fhir/wiki/Proposed-Subscription-Design-Change for more
details.