From ba1eca70b9e4959efeef27bd005fa50606ba4cc0 Mon Sep 17 00:00:00 2001 From: Kai Kewley Date: Wed, 12 May 2021 10:59:56 +0100 Subject: [PATCH] PIP-62 Synchronise MRCM ungrouped roles map to avoid US Edition error. --- .../org/snomed/otf/owltoolkit/taxonomy/SnomedTaxonomy.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/java/org/snomed/otf/owltoolkit/taxonomy/SnomedTaxonomy.java b/src/main/java/org/snomed/otf/owltoolkit/taxonomy/SnomedTaxonomy.java index 5dcc229..c3763b1 100644 --- a/src/main/java/org/snomed/otf/owltoolkit/taxonomy/SnomedTaxonomy.java +++ b/src/main/java/org/snomed/otf/owltoolkit/taxonomy/SnomedTaxonomy.java @@ -50,7 +50,9 @@ public class SnomedTaxonomy { private Map axiomsById = new ConcurrentHashMap<>(); private Map> inferredSubTypesMap = new Long2ObjectOpenHashMap<>(); - private Map> ungroupedRolesByContentType = new HashMap<>(); + + // Ungrouped roles map must be synchronised because international and extension refset members are loaded in parallel. The US Edition package contains the full MRCM. + private Map> ungroupedRolesByContentType = Long2ObjectMaps.synchronize(new Long2ObjectOpenHashMap<>()); private Set inactivatedConcepts = new LongOpenHashSet(); private Map> conceptDescriptionMap = Long2ObjectMaps.synchronize(new Long2ObjectOpenHashMap<>()); private Map descriptionMap = Long2ObjectMaps.synchronize(new Long2ObjectOpenHashMap<>());