<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Mar 18, 2014 at 9:58 AM, Radim Vansa <span dir="ltr"><<a href="mailto:rvansa@redhat.com" target="_blank">rvansa@redhat.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">What does exactly the configName refer to? Some cache name as it appears<br>
in configuration, and then the intermediate cache will copy that<br>
configuration and create new custom cache? That means, that configured<br>
cache will never be instantiated?<br></blockquote><div><br></div><div>Yes. Only usingSharedIntermediateCache(<div class="h5">String cache) uses the same cache name and config name.<br></div> <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
Why don't you use Configuration directly instead, if you want to specify<br>
configuration?<br></blockquote><div><br></div><div>Two reasons:<br></div><div>1. The Configuration classes are not serializable.<br></div><div>2. Some users might prefer to define the configuration via XML.<br><br></div>
<div>Dan<br><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
Radim<br>
<div class=""><div class="h5"><br>
On 03/17/2014 03:58 PM, Vladimir Blagojevic wrote:<br>
> Guys,<br>
><br>
> We need some input on how to design API regarding use of intermediate<br>
> caches [1]. As you might know one of the requirements for improving our<br>
> M/R is allowing applications to use custom defined intermediate<br>
> key/value cache used to store keys/values of map/combine phase before<br>
> being reduced in reduced phase.<br>
><br>
><br>
> Currently we have a constructor where one can specify whether to use<br>
> shared or per-task intermediate cache. And now we wanted to add an<br>
> additional method:<br>
><br>
> usingIntermediateCache(String cacheName, String cacheConfigurationName);<br>
><br>
> that will enable use of custom intermediate cache.<br>
><br>
> Now, Dan, and rightly so, thought this was a bit confusing. Are we<br>
> referring to intermediate shared or per-task intermediate cache when<br>
> using the above mentioned method.<br>
><br>
> His proposal is touse a per-task intermediate cache with our default<br>
> specified intermediate cache configuration. Remove the constructor<br>
> parameter in MapReduceTask regarding shared or non shared cache and add<br>
> configuration methods for both caches:<br>
><br>
><br>
> usingIntermediateCache(String configName) - use a per-task<br>
> intermediate cache with the given configuration<br>
> usingSharedIntermediateCache(String cache) - use a shared cache<br>
> with our default configuration<br>
> usingSharedIntermediateCache(String cache, String configName) - use<br>
> a shared cache with the given configuration<br>
><br>
><br>
> Note that we need a name for shared cache because we want to enable<br>
> application to easily remove/inspect that cache after all m/r tasks<br>
> sharing that intermediate cache have been executed.<br>
><br>
> What are your thoughts here?<br>
><br>
> Vladimir<br>
><br>
><br>
><br>
> [1] <a href="https://issues.jboss.org/browse/ISPN-4021" target="_blank">https://issues.jboss.org/browse/ISPN-4021</a><br>
> _______________________________________________<br>
> infinispan-dev mailing list<br>
> <a href="mailto:infinispan-dev@lists.jboss.org">infinispan-dev@lists.jboss.org</a><br>
> <a href="https://lists.jboss.org/mailman/listinfo/infinispan-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/infinispan-dev</a><br>
<br>
<br>
</div></div><span class=""><font color="#888888">--<br>
Radim Vansa <<a href="mailto:rvansa@redhat.com">rvansa@redhat.com</a>><br>
JBoss DataGrid QA<br>
</font></span><div class=""><div class="h5"><br>
_______________________________________________<br>
infinispan-dev mailing list<br>
<a href="mailto:infinispan-dev@lists.jboss.org">infinispan-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/infinispan-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/infinispan-dev</a><br>
</div></div></blockquote></div><br></div></div>