[infinispan-dev] keySet(), values() and entrySet() not implemented

Galder Zamarreno galder.zamarreno at redhat.com
Thu Jun 4 05:29:56 EDT 2009



Mircea Markus wrote:
> Manik Surtani wrote:
>> </snip>
>>
>> I still reckon that these methods should just query the local, 
>> in-memory data container.  And be documented such that this is what is 
>> expected.  Like I said the potential for OOMs is huge otherwise - 
>> regardless of DIST.
> that would 'lay' to the user and break the API as well. We can add Cache 
> (vs Map) methods for that.

Hmmmm, I suppose you mean lie? As long as we document it correctly, I 
think we should be fine. We could even show an info message when DIST is 
in use to further remain them that the view they get only contains the 
local data.

I don't think it breaks the API. It has limitations but I don't a break. 
It's a bit like size() with ConcurrentHashMap. It does not give you an 
accurate number. The same with keySet()/entrySet() and DIST mode, it 
does not give an accurate view because of the pitfalls mentioned.

>> Cheers
>> -- 
>> Manik Surtani
>> manik at jboss.org
>> Lead, Infinispan
>> Lead, JBoss Cache
>> http://www.infinispan.org
>> http://www.jbosscache.org
>>
>>
>>
>>
> 

-- 
Galder Zamarreño
Sr. Software Maintenance Engineer
JBoss, a division of Red Hat



More information about the infinispan-dev mailing list