In fact I do not understand why you use a ConcurrentHashMap in JDK14LoggerFactory. You can just create a new object all the time in getLogger. Since most users use this method only once in the constructor (or in the static declaration), it won't change much. Even if you use repeatedly getLogger, the JDK14LoggerAdapter are not expensive to create, you can leave it to the garbage collection to deal with them.
I can create a patch either way: making use of a weakmap or getting rid of the hashmap, pls let me know.
|