Interface ShardDistributionStrategy


  • public interface ShardDistributionStrategy
    Author:
    Joost van de Wijgerd
    • Method Detail

      • signalRelease

        void signalRelease​(ActorShard localShard,
                           PhysicalNode nextOwner)
                    throws Exception
        Signal to the cluster that a Local ActorShard has been given up
        Parameters:
        localShard -
        nextOwner -
        Throws:
        Exception
      • registerWaitForRelease

        void registerWaitForRelease​(ActorShard localShard,
                                    PhysicalNode currentOwner)
                             throws Exception
        Wait for signal from the current shard owner, when the signal comes in ActorContainer.init() should be called within the implementation
        Parameters:
        localShard -
        currentOwner -
        Throws:
        Exception
      • waitForReleasedShards

        boolean waitForReleasedShards​(long waitTime,
                                      TimeUnit unit)
        Block until all Shard that were registered to wait for release are handled, or the specified waitTime has run out.
        Parameters:
        waitTime -
        unit -