Class MigrationTask

  • All Implemented Interfaces:
    java.util.concurrent.Callable<java.lang.Integer>, DistributedCallable<java.lang.Object,​java.lang.Object,​java.lang.Integer>

    public class MigrationTask
    extends java.lang.Object
    implements DistributedCallable<java.lang.Object,​java.lang.Object,​java.lang.Integer>
    • Constructor Summary

      Constructors 
      Constructor Description
      MigrationTask​(java.util.Set<java.lang.Integer> segments, int readBatch, int threads)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Integer call()  
      void setEnvironment​(Cache<java.lang.Object,​java.lang.Object> cache, java.util.Set<java.lang.Object> inputKeys)
      Invoked by execution environment after DistributedCallable has been migrated for execution to a specific Infinispan node.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MigrationTask

        public MigrationTask​(java.util.Set<java.lang.Integer> segments,
                             int readBatch,
                             int threads)
    • Method Detail

      • call

        public java.lang.Integer call()
                               throws java.lang.Exception
        Specified by:
        call in interface java.util.concurrent.Callable<java.lang.Integer>
        Throws:
        java.lang.Exception
      • setEnvironment

        public void setEnvironment​(Cache<java.lang.Object,​java.lang.Object> cache,
                                   java.util.Set<java.lang.Object> inputKeys)
        Description copied from interface: DistributedCallable
        Invoked by execution environment after DistributedCallable has been migrated for execution to a specific Infinispan node.
        Specified by:
        setEnvironment in interface DistributedCallable<java.lang.Object,​java.lang.Object,​java.lang.Integer>
        Parameters:
        cache - cache whose keys are used as input data for this DistributedCallable task
        inputKeys - keys used as input for this DistributedCallable task