Merge pull request #2324 from hapifhir/single-threading-mdm
Ensure Single threading mdm
This commit is contained in:
commit
96b4e5ab38
|
@ -51,7 +51,9 @@ public class MdmQueueConsumerLoader {
|
||||||
public void startListeningToMdmChannel() {
|
public void startListeningToMdmChannel() {
|
||||||
if (myMdmChannel == null) {
|
if (myMdmChannel == null) {
|
||||||
ChannelConsumerSettings config = new ChannelConsumerSettings();
|
ChannelConsumerSettings config = new ChannelConsumerSettings();
|
||||||
|
|
||||||
config.setConcurrentConsumers(myMdmSettings.getConcurrentConsumers());
|
config.setConcurrentConsumers(myMdmSettings.getConcurrentConsumers());
|
||||||
|
|
||||||
myMdmChannel = myChannelFactory.getOrCreateReceiver(IMdmSettings.EMPI_CHANNEL_NAME, ResourceModifiedJsonMessage.class, config);
|
myMdmChannel = myChannelFactory.getOrCreateReceiver(IMdmSettings.EMPI_CHANNEL_NAME, ResourceModifiedJsonMessage.class, config);
|
||||||
if (myMdmChannel == null) {
|
if (myMdmChannel == null) {
|
||||||
ourLog.error("Unable to create receiver for {}", IMdmSettings.EMPI_CHANNEL_NAME);
|
ourLog.error("Unable to create receiver for {}", IMdmSettings.EMPI_CHANNEL_NAME);
|
||||||
|
|
|
@ -26,7 +26,6 @@ import java.util.stream.Collectors;
|
||||||
|
|
||||||
public interface IMdmSettings {
|
public interface IMdmSettings {
|
||||||
|
|
||||||
String MDM_CHANNEL_NAME = "mdm";
|
|
||||||
String EMPI_CHANNEL_NAME = "empi";
|
String EMPI_CHANNEL_NAME = "empi";
|
||||||
|
|
||||||
// Parallel processing of MDM can result in missed matches. Best to single-thread.
|
// Parallel processing of MDM can result in missed matches. Best to single-thread.
|
||||||
|
|
|
@ -68,11 +68,6 @@ public class MdmSettings implements IMdmSettings {
|
||||||
return myConcurrentConsumers;
|
return myConcurrentConsumers;
|
||||||
}
|
}
|
||||||
|
|
||||||
public MdmSettings setConcurrentConsumers(int theConcurrentConsumers) {
|
|
||||||
myConcurrentConsumers = theConcurrentConsumers;
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getScriptText() {
|
public String getScriptText() {
|
||||||
return myScriptText;
|
return myScriptText;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue