[infinispan-issues] [JBoss JIRA] Commented: (ISPN-721) Change CacheStore.store() to return the previous value instead of void.

Galder Zamarreño (JIRA) jira-events at lists.jboss.org
Wed Oct 20 12:38:54 EDT 2010


    [ https://jira.jboss.org/browse/ISPN-721?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12558221#action_12558221 ] 

Galder Zamarreño commented on ISPN-721:
---------------------------------------

Once again, similar to comment to what I said on ISPN-717. Why do this? Which 'current implementation' are you talking about? There're a fair few cache store impls out there... :). And again, IIRC, the loading is done by the CacheLoaderInterceptor (CLI) unless I'm mistaken. If a particular CacheStore impl is also loading again, that shouldn't be the case.

I agree that it'd be a good optimization to be able to store something and get previous value in just one roundtrip to the cache store, but how many cache stores impls can do that? And how would that work with the current CLI and CSI architecture?

> Change CacheStore.store() to return the previous value instead of void.
> -----------------------------------------------------------------------
>
>                 Key: ISPN-721
>                 URL: https://jira.jboss.org/browse/ISPN-721
>             Project: Infinispan
>          Issue Type: Task
>          Components: Core API
>    Affects Versions: 4.2.0.Final
>            Reporter: Trustin Lee
>            Assignee: Trustin Lee
>             Fix For: 5.0.0.BETA1
>
>
> Cache.put(key, value) operation returns a previous value.  However, CacheStore.store() does not return a previous value but void.  To overcome the impedance mismatch, the current implementation calls CacheStore.load() to simply get the previous value.  CacheStore.store() could be improved to reduce this unnecessary round trip.

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

       



More information about the infinispan-issues mailing list