Created attachment 33219 [details] Replaced new Integer/Long with valueOf calls Discovered cases where an inefficient Number constructor is being called instead of the static valueOf. Using new Integer(int) is guaranteed to always result in a new object whereas Integer.valueOf(int) allows caching of values to be done by the compiler, class library, or JVM. Using of cached values avoids object allocation and the code will be faster. See http://findbugs.sourceforge.net/bugDescriptions.html#DM_NUMBER_CTOR
Hi, Thanks for the report and the patch. I applied the same fix on other places in the code also. The fix is available in trunk, 8.0.x (for 8.0.29 onwards) and 7.0.x (for 7.0.66 onwards) Regards, Violeta