kwin commented on code in PR #216: URL: https://github.com/apache/maven-enforcer/pull/216#discussion_r1059778363
########## maven-enforcer-plugin/src/main/java/org/apache/maven/plugins/enforcer/internal/EnforcerRuleManager.java: ########## @@ -93,6 +112,16 @@ public List<EnforcerRuleDesc> createRules(PlexusConfiguration rules) throws Enfo private EnforcerRuleDesc createRuleDesc(String name, String implementation) throws EnforcerRuleManagerException { + // component name should always start at lowercase character + String ruleName = Character.toLowerCase(name.charAt(0)) + name.substring(1); + + try { + return new EnforcerRuleDesc(ruleName, plexusContainer.lookup(EnforcerRuleBase.class, ruleName)); Review Comment: What is the default scope of Sisu components? How does it work, if the same rule is being used more than once with different parameters in parallel? Shouldn't rules having the singleton scope lead to a warn at least to prevent race conditions with multi-threading? What about allowing to reuse rule objects but always pass the current parametrisation as argument to the execute method (e.g. for custom rules having complex global initialisation) -- 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: issues-unsubscr...@maven.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org