Community
Participate
Working Groups
Build: 3.1 M6 After loading all properties files, MessageResourceBundle iterates over all Fields in the message key class, and does: if (field.get(clazz) == null) field.set(null, "Unused message..."); The reflective get() calls are unneccesary in the common case where the field value is already assigned. This should be optimized.
Fix released. I now assign a special "ASSIGNED" placeholder value in the field map after each field has been assigned. Now, to check if a field is unassigned, I simply get the value in the field map and check if it is the "ASSIGNED" placeholder. This is much faster than a reflective field access.
John can you give me some numbers to report?
The optimization on load time is hard to measure because it was already pretty fast on individual bundles. I wouldn't bother reporting any numbers there. I have also heavily optimized the NLS#bind methods. See bug 90803 comment 17 for performance numbers (generally 160% faster to bind messages than in 3.0).