<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Also I've updated the comments/method names to be more accurate and less misleading:<div><br></div><div><meta charset="utf-8"><a href="http://fisheye.jboss.org/changelog/Infinispan/trunk/core?cs=1714">http://fisheye.jboss.org/changelog/Infinispan/trunk/core?cs=1714</a></div><div><br></div><div><a href="http://fisheye.jboss.org/changelog/Infinispan/trunk/core?cs=1714"></a><br><div><div>On 22 Apr 2010, at 10:41, Manik Surtani wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Phil,<div><br><div>Sorry if it took me a while to get back to this. &nbsp;This isn't really a problem - as proved by this unit test:<div><br></div><div><a href="http://fisheye.jboss.org/browse/Infinispan/trunk/core/src/test/java/org/infinispan/loaders/CacheLoaderFunctionalTest.java">http://fisheye.jboss.org/browse/Infinispan/trunk/core/src/test/java/org/infinispan/loaders/CacheLoaderFunctionalTest.java</a>&nbsp;-&nbsp;see&nbsp;testLoadingToMemory()</div><div><br></div><div>The explanation is a very poorly named internal method - CacheLoaderInterceptor.putLoadedEntryInContainer() - which is misleading. &nbsp;This method is not supposed to store the entry but simply to notify listeners. &nbsp;(Perhaps it did store the entry once upon a time, but has since then been refactored). &nbsp;</div><div><br></div><div>The actual storage of the entry happens when the entry is wrapped for writing (CacheLoaderInterceptor line 141) which stores the entry in the caller's invocation context. &nbsp;The actual flushing to memory storage happens in the LockingInterceptor (in cleanupLocks()) when the call returns and locks are released. &nbsp;Loading from a CacheStore will inevitably involve acquiring write locks on the in-memory data structure so this is the logical place to flush writes and release locks.</div><div><br></div><div><div><div>On 20 Apr 2010, at 15:43, Philippe Van Dyck wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">Done,&nbsp;<a href="https://jira.jboss.org/jira/browse/ISPN-407">https://jira.jboss.org/jira/browse/ISPN-407</a><div><br></div><div><a href="https://jira.jboss.org/jira/browse/ISPN-407"></a>Cheers,</div><div>
<br></div><div>Phil</div><div><br></div><div>P.S.: I sometimes wonder if anyone actually use Infinispan ;-)<br></div></blockquote><div><br></div><div>Keep wondering. &nbsp;:)</div><div><br></div></div><div><span class="Apple-style-span" style="font-size: 12px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><span class="Apple-style-span" style="font-size: medium;">Cheers</span></div><div><span class="Apple-style-span" style="font-size: medium;">Manik</span></div><div>--</div><div>Manik Surtani</div><div><a href="mailto:manik@jboss.org">manik@jboss.org</a></div><div>Lead, Infinispan</div><div>Lead, JBoss Cache</div><div><a href="http://www.infinispan.org/">http://www.infinispan.org</a></div><div><a href="http://www.jbosscache.org/">http://www.jbosscache.org</a></div><div><br></div></div></span><br class="Apple-interchange-newline"><br class="Apple-interchange-newline">
</div>
<br></div></div></div></div>_______________________________________________<br>infinispan-dev mailing list<br><a href="mailto:infinispan-dev@lists.jboss.org">infinispan-dev@lists.jboss.org</a><br>https://lists.jboss.org/mailman/listinfo/infinispan-dev</blockquote></div><br><div>
<span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>--</div><div>Manik Surtani</div><div><a href="mailto:manik@jboss.org">manik@jboss.org</a></div><div>Lead, Infinispan</div><div>Lead, JBoss Cache</div><div><a href="http://www.infinispan.org">http://www.infinispan.org</a></div><div><a href="http://www.jbosscache.org">http://www.jbosscache.org</a></div><div><br></div></div></span><br class="Apple-interchange-newline"></span><br class="Apple-interchange-newline">
</div>
<br></div></body></html>