harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nathan Beyer (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-1936) [classlib][rmi] improper class loader creation in DefaultRMIClassLoaderSpi due to race condition
Date Tue, 24 Oct 2006 04:10:17 GMT
    [ http://issues.apache.org/jira/browse/HARMONY-1936?page=comments#action_12444187 ] 
            
Nathan Beyer commented on HARMONY-1936:
---------------------------------------

I understand the problem, but I think it be more appropriate and simple to just synchronize
on the 'table' field itself and just surround the entire region that uses the field.

I've committed a fix based on this approach, check the SVN Commits page to see it. I've also
changed the field to be a Map instead of a Hashtable, since the synchronization is at a higher
level. I've changed the field name to be more appropriate as well.

Let me know what you think and whether or not this resolves the issue. Thanks.

> [classlib][rmi] improper class loader creation in DefaultRMIClassLoaderSpi due to race
condition
> ------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-1936
>                 URL: http://issues.apache.org/jira/browse/HARMONY-1936
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: IA32, WinXP
>            Reporter: Mikhail Markov
>         Assigned To: Nathan Beyer
>         Attachments: DefaultRMIClassLoaderSpi.patch
>
>
> I've identified that DefaultRMIClassLoaderSpi sometimes creates 2 different URLClassLoaders
(inside the class) for the same codebase. This is due to the gap between the moments of checking
of inner hashtable with created loaders and table updating with new created loaders when 2
threads could enter at the same time.
> Unfortunately, i was not able to provide a stand-alone simple reproducer for this bug,
but it is reproducible on heavy multi-threading application.
> The patch will come... It is easy understandable so i hope it demonstrates the problem
by itself. 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message