Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-369

InvalidateL1Command should not be invoked if the keys are local

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Done
    • Icon: Major Major
    • 4.1.0.ALPHA1, 4.1.0.Final
    • 4.0.0.Final
    • Core
    • None
    • Medium

      InvalidateL1Command currently is broadcast cluster-wide (multicast) for the sake of efficiency. This means that even other owners will receive this command. The command's perform() method will prevent such owners from evicting the keys though, so this does not affect correctness.

      However it does affect performance since the command is still passed up the interceptor stack and, crucially, locks are acquired for the keys in question.

      A better solution would be for ReplicableCommand to expose a boolean shouldInvoke() method. By default this always returns true, but in the case of the InvalidateL1Command, the ownership of keys is checked here. The InboundInvocationHandler can then choose whether to invoke the command or not.

              manik_jira Manik Surtani (Inactive)
              manik_jira Manik Surtani (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: