mariofusco commented on code in PR #6520:
URL: 
https://github.com/apache/incubator-kie-drools/pull/6520#discussion_r2548792427


##########
drools-ruleunits/drools-ruleunits-impl/src/main/java/org/drools/ruleunits/impl/RuleUnitProviderImpl.java:
##########
@@ -66,21 +68,33 @@ public class RuleUnitProviderImpl implements 
RuleUnitProvider {
 
     private static final boolean USE_EXEC_MODEL = true;
 
-    private final Map<String, RuleUnit> ruleUnitMap;
+    private final ConcurrentMap<String, RuleUnit> ruleUnitMap;
+    private final Object generationLock = new Object();

Review Comment:
   Nitpick: using a `synchronized` block is mostly considered an antipattern 
nowadays and we should actually get rid of all of them throughout our codebase. 
Please consider replacing it with a proper `ReentrantLock`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to