[concurrency-interest] ConcurrentReferenceMap enhancement to 166 - Feedback Requested
crazybob at crazybob.org
Thu Apr 17 12:06:47 EDT 2008
On Thu, Apr 17, 2008 at 7:32 AM, Jason T. Greene <jason.greene at redhat.com>
> - Can't do standard equality with weak/soft
Standard equality doesn't make sense for weak/soft. Weak/soft references are
fundamentally identity based.
You're "interning" use case is a red herring--ReferenceMap is not an
efficient way to implement that.
> - Requires a separate application thread for stale entry cleanup
We use one thread for the whole VM (or optionally more threads). The VM
could even reuse it's reference-enqueing thread like it does for other
internal things. You have a *concurrent* map now. Why make clients do the
work and make the durations of their operations less consistent?
> - Needs a lot of extra method dispatch
I agree that it should not delegate, but I doubt we need to copy CHM 100%,
especially if we're in the same package.
> Doug and I have been talking with some of the folks at Google about
> this. They have been after a standardized solution as well.
I've talked to Doug, in that I've sent him a couple ReferenceMap revisions
for review over the past three years. His latest feedback was that he wanted
to wait for the new key/value reference type he's been working on, so we've
been holding off for that.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Concurrency-interest