8010309 : PlatformLogger: isLoggable performance / waste due to HashMap<Integer, Level> leads to Integer allocations (boxing)
David M. Lloyd
david.lloyd at redhat.com
Thu Mar 21 13:39:19 UTC 2013
On 3/21/13 12:04 PM, Holger Hoffstaette wrote:
> On Thu, 21 Mar 2013 12:12:07 +0100, Laurent Bourgès wrote:
>> FYI, I removed completely the Map<Integer, Object> levelObjects and used
>> two arrays to perform the PlatformLogger's level (int) to j.u.l.Level
> FWIW I know of at least one (quite old) project that declares custom
> j.u.l. Levels and which would be broken by this change. I personally don't
> care (since I think both j.u.l. and custom log levels are wrong to begin
> with :), but it's something to keep in mind. Maybe a Map-based mapping
> could be used as fallback, while the array-indexed lookups take the heat
> off of the common case. Just a suggestion.
Why would the platform logger ever use custom levels though?
More information about the core-libs-dev