[jbosscache-issues] [JBoss JIRA] Resolved: (JBCACHE-1368) Optimize the CacheLoader.putAll() method so reads are not necessary

Manik Surtani (JIRA) jira-events at lists.jboss.org
Fri Sep 26 07:55:21 EDT 2008


     [ https://jira.jboss.org/jira/browse/JBCACHE-1368?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Manik Surtani resolved JBCACHE-1368.
------------------------------------

    Fix Version/s: 3.0.0.CR1
       Resolution: Done


> Optimize the CacheLoader.putAll() method so reads are not necessary
> -------------------------------------------------------------------
>
>                 Key: JBCACHE-1368
>                 URL: https://jira.jboss.org/jira/browse/JBCACHE-1368
>             Project: JBoss Cache
>          Issue Type: Task
>      Security Level: Public(Everyone can see) 
>            Reporter: Elias Ross
>            Assignee: Manik Surtani
>             Fix For: 3.0.0.CR1, 3.0.0.GA
>
>
> Almost all CacheLoader implementations do a read of the existing data map when "putAll" is called but this may be unnecessary as the Cache likely has loaded the cache loader data at some point.
> Manik suggests: "[We] need to analyse in the interceptors and see if that can be done away with. No real reason to do a read here. From the cache loader javadoc for the put(Fqn, Map) method: 
>   'Puts all entries of the map into the existing map of the given node, overwriting existing keys, but not clearing the existing map before insertion. '
> "
> One improvement would be to check in the CacheLoader impl. if the Node was already loaded, then the Map merge can happen without the read. However, this logic might better belong in the cache loader interceptor. It might work okay to do this check in the base class for existing CacheLoader impl. as well.
> Relates all JBCACHE-1221 - JDBC cache loader optimization.

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

        



More information about the jbosscache-issues mailing list