<div dir="ltr"><br><br><div class="gmail_quote"><div dir="ltr">On Sat, Jun 10, 2017 at 12:56 AM Radim Vansa &lt;<a href="mailto:rvansa@redhat.com">rvansa@redhat.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi guys,<br>
<br>
when the functional API has been outline, the interfaces were put into<br>
infinispan-commons to make it possible to share these between remote<br>
clients and embedded use case. However, it seems that reusing this as-is<br>
impossible or at least impractical as we cannot send the lambdas in a<br>
language neutral way. In the future, we may implement a way to share<br>
functions between client and a server but that will most likely result<br>
in an interface accepting something else than Function&lt;ReadWriteEntry,<br>
R&gt;. Also, it&#39;s rather weird to have two EntryVersion interfaces.<br>
<br>
Therefore I suggest moving org.infinispan.commons.api.functional to<br>
infinispan-core, package org.infinispan.api.functional<br>
<br>
You might say that the server-side code would use the interfaces, but<br>
once it&#39;s running on server, it should depend on core (or core-api) -<br>
commons is what is shared with the client, and if the client will in<br>
future register a new function on the server, the user code should<br>
depend on core-api as well (client-hotrod itself does not have to).<br>
<br>
If you wonder what led me to this is that I&#39;ve tried to add<br>
SerializableFunction overloads to the FunctionalMap and found out that<br>
SerializableFunction et all are only in infinispan-core (for good).<br></blockquote><div><br></div><div>We could move these into commons in a major version if we need to as well. I never thought about using them in the client code as we never planned on supporting serialized lambdas there, but if it makes other things easier I am for it.</div><div><br></div><div>Also there is nothing stopping us from having these in commons right now, there is nothing special about the interfaces, they can just be copied over.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Please let me know if you have objections/if there something I have missed.<br>
<br>
Radim<br>
<br>
--<br>
Radim Vansa &lt;<a href="mailto:rvansa@redhat.com" target="_blank">rvansa@redhat.com</a>&gt;<br>
JBoss Performance Team<br>
<br>
_______________________________________________<br>
infinispan-dev mailing list<br>
<a href="mailto:infinispan-dev@lists.jboss.org" target="_blank">infinispan-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/infinispan-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/infinispan-dev</a><br>
</blockquote></div></div>