diff --git a/bundles/org.openhab.core.model.rule.runtime/src/org/openhab/core/model/rule/runtime/internal/DSLRuleProvider.java b/bundles/org.openhab.core.model.rule.runtime/src/org/openhab/core/model/rule/runtime/internal/DSLRuleProvider.java index 5001382e1..f211a66e6 100644 --- a/bundles/org.openhab.core.model.rule.runtime/src/org/openhab/core/model/rule/runtime/internal/DSLRuleProvider.java +++ b/bundles/org.openhab.core.model.rule.runtime/src/org/openhab/core/model/rule/runtime/internal/DSLRuleProvider.java @@ -14,13 +14,13 @@ package org.openhab.core.model.rule.runtime.internal; import java.util.ArrayList; import java.util.Collection; -import java.util.HashMap; import java.util.HashSet; import java.util.Iterator; import java.util.List; import java.util.Map; import java.util.Map.Entry; import java.util.Set; +import java.util.concurrent.ConcurrentHashMap; import java.util.stream.Collectors; import org.eclipse.emf.ecore.EObject; @@ -88,9 +88,9 @@ public class DSLRuleProvider private final Logger logger = LoggerFactory.getLogger(DSLRuleProvider.class); private final Collection> listeners = new ArrayList<>(); - private final Map rules = new HashMap<>(); - private final Map contexts = new HashMap<>(); - private final Map xExpressions = new HashMap<>(); + private final Map rules = new ConcurrentHashMap<>(); + private final Map contexts = new ConcurrentHashMap<>(); + private final Map xExpressions = new ConcurrentHashMap<>(); private int triggerId = 0; private Set markers = new HashSet<>();