Re: Relieving some ClassLoader contention in PreferredClassProvider

Gregg Wonderly <[email protected]>
Newsgroups gmane.comp.java.sun.jini
Message-ID <[email protected]>
Bob Scheifler wrote:
>> As URL.equals() is heavily used in the synchronized block from where the
>> class loader creation takes place it means in the case that URL.equals
>> takes a very long time all operation that ultimately result in the
>> creation of a class loader are blocked.
>
> So perhaps one should start by looking at alternate synchronization,
> rather than alternate specification.

I've got a new version in test now which just simply ends the synchronization at
the point that the LoaderKey is created.  It then, uses a factory for LoaderKeys
instead, to get a LoaderKey, synchronizes on that to focus the slow code to lock
only threads interested in that loader.  I'm trying to decide if this still
allows the same problem of things getting removed as they are generated.  I
don't see that it can, but I've been buried in this long enough to cross my eyes
thrice.

Gregg Wonderly

--------------------------------------------------------------------------
Getting Started:     http://www.jini.org/wiki/Category:Getting_Started
Community Web Site:  http://jini.org
jini-users Archive:  http://archives.java.sun.com/archives/jini-users.html
Unsubscribing:       email "signoff JINI-USERS"  to [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.