[infinispan-issues] [JBoss JIRA] (ISPN-5035) DeltaAware support for conditional operations
Radim Vansa (JIRA)
issues at jboss.org
Tue Dec 9 08:23:40 EST 2014
[ https://issues.jboss.org/browse/ISPN-5035?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13026254#comment-13026254 ]
Radim Vansa commented on ISPN-5035:
-----------------------------------
DistributedExecutorService could be better choice, as long as topology does not change (that's probably OK). However, replication to backups wouldn't spare the bandwidth (unless I implement DeltaAware to produce Deltas and setup IGNORE_RETURN_VALUES to reduce bandwith with RPC response). Even more important concern is that the task wouldn't be executed atomically with the lock locked (so that I don't get write skew and don't have to send whole entry for replace - which in fact does not use deltas), so this would require transactional cache.
> DeltaAware support for conditional operations
> ---------------------------------------------
>
> Key: ISPN-5035
> URL: https://issues.jboss.org/browse/ISPN-5035
> Project: Infinispan
> Issue Type: Feature Request
> Components: Core
> Reporter: Radim Vansa
>
> Current delta-aware approach is implemented only in PutKeyValueCommand and ApplyDeltaCommand. This implementation does not allow to execute conditional delta-aware commands - or rather it does not allow to return any kind of value (the condition itself can be implemented inside the delta).
> One use-case when this would be required is equivalent of AtomicLong.getAndIncrement(). Currently we can implement this using
> {code}
> Long previous;
> do {
> previous = cache.get(key);
> } while (cache.replace(key, previous, previous + 1);
> {code}
> which requires at least two RPCs. With more generic interface, such as JCache's EntryProcessor this could be implemented using single RPC.
> (so, this JIRA is basically a request to native support for EntryProcessor)
--
This message was sent by Atlassian JIRA
(v6.3.8#6338)
More information about the infinispan-issues
mailing list