2016-08-23 17:35 GMT+02:00 Clebert Suconic <[email protected]>:
> > "Redeployments will remove the old classloader" > > > > this is were we "split" I suspect. This is not true since the key is a > > classloader and classloader is the root of most of everything so GC is > > rarely enough > > > > > With a WeakHashMap, the application server should release the > classLoader once a redeployment occurs. This is how apache-commons do > in a lot of places. Once a classLoader is released the element of the > hashmap should go away. > > Not sure I get you there, commons clearly doesn't take in charge any of that but some containers can force some cleanup (not the other way around) - at least for beansutils for instance. > > >> > >> > >> There are serious implications to the application server if that > >> doesn't work this way. So I doubt any application server would behave > >> differently. > >> > >> > >> I may be wrong, but this is what I have seen over the years. > > > > > > Think we agree on what we want but disagree on what actually happens > there. > > > > What about starting with the registry I proposed and enhance/fix it on > > demand? Sounds like a compromise > > > > > I guess I don't understand your proposal. > > Starting with a "leaking" WeakHashMap<ClassLoader, Provider> and see if consumers are complaining. It would solve your issue and I can make it working in tomee for instance > > -- > Clebert Suconic >
