[concurrency-interest] ConcurrentSkipListMap toArray() - "too" safe?

Dawid Kurzyniec dawidk at mathcs.emory.edu
Sun Jul 23 19:18:42 EDT 2006


Hello,

I noticed that ConcurrentSkipListMap in the JSR 166 CVS has been changed 
(back) so that toArray() methods take ArrayList snapshots. The comment 
says that it is in response to 6377302, "AbstractCollection.toArray is 
not safe for concurrent collections". But, the problem has been 
concurrently addressed in AbstractCollection.toArray; the method *is* 
now safe for concurrent collections, and it is so for 8 months now, as 
it appears to me. Does that mean that the extra snapshot in CSLMap is 
redundant? Or am I missing something?

Regards,
Dawid



More information about the Concurrency-interest mailing list