Details
-
Improvement
-
Status: Closed
-
Normal
-
Resolution: Won't Fix
-
4.2.3
-
None
-
Flagged
Description
In the CompositeResourceBundle it is possible to combine resource bundles that contain repeated keys.
When this happens no message is logged reporting this conflict.
Instead the code will return the first Value it finds for the requested Key.
org.hippoecm.hst.resourcebundle.CompositeResourceBundle#CompositeResourceBundle
protected Object handleGetObject(String key) { if (bundles == null) { return null; } for (ResourceBundle bundle : bundles) { if (bundle != null) { try { Object value = bundle.getObject(key); if (value != null) { return value; } } catch (MissingResourceException e) { // ignore } } } return null; }
This is specially important because, to use this feature, developers have to decide what is the strategy to handle this conflict (for example get the last published RB or sort RBs alphabetically, etc..) but still no log message is reported, so the returned value can change in unexpected ways to the editors.