modified implementation of partitionId in CanonicalSubscription
This commit is contained in:
parent
50bfa3e844
commit
3c39011b08
|
@ -4,7 +4,6 @@ import ca.uhn.fhir.context.FhirContext;
|
|||
import ca.uhn.fhir.interceptor.api.HookParams;
|
||||
import ca.uhn.fhir.interceptor.api.IInterceptorBroadcaster;
|
||||
import ca.uhn.fhir.interceptor.api.Pointcut;
|
||||
import ca.uhn.fhir.interceptor.model.RequestPartitionId;
|
||||
import ca.uhn.fhir.jpa.searchparam.matcher.InMemoryMatchResult;
|
||||
import ca.uhn.fhir.jpa.subscription.channel.subscription.SubscriptionChannelRegistry;
|
||||
import ca.uhn.fhir.jpa.subscription.match.matcher.matching.ISubscriptionMatcher;
|
||||
|
@ -125,9 +124,9 @@ public class SubscriptionMatchingSubscriber implements MessageHandler {
|
|||
|
||||
for (ActiveSubscription nextActiveSubscription : subscriptions) {
|
||||
// skip if the partitions don't match
|
||||
RequestPartitionId subscriptionPartitionId = nextActiveSubscription.getSubscription().getPartitionId();
|
||||
Integer subscriptionPartitionId = nextActiveSubscription.getSubscription().getPartitionId();
|
||||
if (subscriptionPartitionId != null && theMsg.getPartitionId() != null
|
||||
&& !theMsg.getPartitionId().getPartitionIds().retainAll(subscriptionPartitionId.getPartitionIds())) {
|
||||
&& !theMsg.getPartitionId().hasPartitionId(subscriptionPartitionId)) {
|
||||
continue;
|
||||
}
|
||||
String nextSubscriptionId = getId(nextActiveSubscription);
|
||||
|
|
|
@ -21,7 +21,6 @@ package ca.uhn.fhir.jpa.subscription.model;
|
|||
*/
|
||||
|
||||
import ca.uhn.fhir.context.FhirContext;
|
||||
import ca.uhn.fhir.interceptor.model.RequestPartitionId;
|
||||
import ca.uhn.fhir.model.api.IModelJson;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import org.apache.commons.lang3.builder.EqualsBuilder;
|
||||
|
@ -72,7 +71,7 @@ public class CanonicalSubscription implements Serializable, Cloneable, IModelJso
|
|||
@JsonProperty("payloadSearchCriteria")
|
||||
private String myPayloadSearchCriteria;
|
||||
@JsonProperty("partitionId")
|
||||
private RequestPartitionId myPartitionId;
|
||||
private Integer myPartitionId;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
|
@ -219,11 +218,11 @@ public class CanonicalSubscription implements Serializable, Cloneable, IModelJso
|
|||
myStatus = theStatus;
|
||||
}
|
||||
|
||||
public RequestPartitionId getPartitionId() {
|
||||
public Integer getPartitionId() {
|
||||
return myPartitionId;
|
||||
}
|
||||
|
||||
public void setPartitionId(RequestPartitionId thePartitionId) {
|
||||
public void setPartitionId(Integer thePartitionId) {
|
||||
myPartitionId = thePartitionId;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue