On 18/02/2014 16:06, Romain Manni-Bucau wrote: > 2014-02-18 17:01 GMT+01:00 Mark Thomas <ma...@apache.org>: >> On 18/02/2014 13:05, Romain Manni-Bucau wrote: >>> 2014-02-18 12:09 GMT+01:00 Mark Thomas <ma...@apache.org>: >> >> <snip/> >> >>>> We can certainly make that easier. Making it non-final, using an >>>> over-ridable protected getter(), adding protected getter and setter etc. >>>> Does TomEE have a preference? >>>> >>> >>> not really while we can change it, we were used to protected field but >>> protected getter would be nice too. >> >> What do you think of >> http://svn.apache.org/r1569398 >> >> If that is OK, I'll back-port it to 7.0.x with the one change that >> j2seClassLoader will be a protected rather than private field in 7.0.x. >> > > > Would be enough, thanks Mark. > > Just few notes: > 1) i think the behavior should be configurable even for tomcat (= use > system classloader)
I disagree. There is a clearly defined set of classes that the web application should not be able to override and classes loaded by the system class loader are not included. I don't mind making things easier for TomEE but I'm not yet convinced of the need to go further. > 2) in the constructor maybe replace the init by a protected method or > a constructor parameter (new constructor WebappClassLoader(parent, > j2seClassLoader)?) I thought about that but: - I'd prefer to avoid having a constructor call a protected method - I prefer (having seen the other extreme in Commons) fewer constructors. I'll get that commit back-ported to 7.0.x. Mark --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org