bito-code-review[bot] commented on PR #16102:
URL: https://github.com/apache/grails-core/pull/16102#issuecomment-5250595825

   <!-- Bito Reply -->
   The issue described, where plugins with normalized names that collide 
silently overwrite each other in a `HashMap`, is a known limitation in the 
current implementation of plugin descriptor discovery. Since the `put()` method 
on a standard `HashMap` does not check for existing keys, the second plugin 
effectively replaces the first, leading to lost message bundles and incorrect 
language selector behavior.
   
   To address this, the plugin discovery mechanism should be updated to use a 
map implementation that detects collisions or to explicitly check for existing 
keys before inserting. For example, using `compute()` or `putIfAbsent()` with a 
check could allow you to log a warning or throw an exception when a collision 
is detected, ensuring that ambiguous plugin names are identified rather than 
silently ignored.


-- 
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]

Reply via email to