[infinispan-issues] [JBoss JIRA] (ISPN-3289) PutForExternalRead should only write the value on the originator once

Mircea Markus (JIRA) jira-events at lists.jboss.org
Wed Jul 10 12:24:20 EDT 2013


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

Mircea Markus updated ISPN-3289:
--------------------------------

        Status: Resolved  (was: Pull Request Sent)
    Resolution: Done

    
> PutForExternalRead should only write the value on the originator once
> ---------------------------------------------------------------------
>
>                 Key: ISPN-3289
>                 URL: https://issues.jboss.org/browse/ISPN-3289
>             Project: Infinispan
>          Issue Type: Bug
>            Reporter: Dan Berindei
>            Assignee: Dan Berindei
>             Fix For: 6.0.0.Final
>
>
> putForExternalRead behaves as an asynchronous, non-transactional write operation even in tx caches, and as such it uses lock delegation.
> Let's say we have a cluster with two nodes: [A, B], and a key k with owners(k) = [A, B].
> If B is the originator of a PFER(k, v) operation, the command is first executed locally on B, then it is invoked asynchronously on the primary owner A, and A invokes it asynchronously on B (because of the FORCE_ASNCHRONOUS flag).
> For regular non-tx write operations, the entry k=v is only written to the data container on B during the second invocation. For PFER, however, the entry is written twice: once during each execution.
> This causes random failures in {{PutForExternalRead*Test.testNoOpWhenKeyPresent}}, because the test assumes that the PFER finished once the entry was written once on each owner.
> Arguably the fact that the primary owner forwards the PFER command asynchronously is also a problem, because the put command will write the value on B without holding a lock on A, the primary owner.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the infinispan-issues mailing list