2010/3/12 Konstantin Kolinko <kkoli...@apache.org>: > 2010/3/12 <kkoli...@apache.org>: >> Author: kkolinko >> Date: Fri Mar 12 15:41:55 2010 >> New Revision: 922300 >> >> URL: http://svn.apache.org/viewvc?rev=922300&view=rev >> Log: >> proposal >> > > My concern, leading to the above proposal, is that > ClassLoader.resolveClass() should perform "Linking" of the class and > JLS says that that can incur loading of the dependent classes [1], > thus I think it could lead to a deadlock. >
>From thread dump that I attached to https://issues.apache.org/bugzilla/show_bug.cgi?id=48903 1. It looks that it is ClassLoader.defineClass() call that performs linking and loading of related classes in Sun JRE 6u18 2. Certain methods e.g. ClassLoader.checkCerts(), require a lock on the whole ClassLoader instance. 3. I do not understand what holds a lock on the ClassLoader instance in "http-8080-1" thread. Can it be inside the native method (ClassLoader.defineClass1()) ?? 4. The above 2.+3. may mean that we need sync() on the classloader as a whole. That is, the sync(name.intern()) trick fails. More comments to the issue 48903 are welcome. Best regards, Konstantin Kolinko --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org