[infinispan-dev] Dist.exec failover

Vladimir Blagojevic vblagoje at redhat.com
Mon Oct 22 14:48:25 EDT 2012


Hey guys,

Erik noted that we should by default have no failover policy installed 
rather the default random policy we currently have. Also he noted that 
keys are never supplied to failover policy and they might be important 
when it comes to a deciding where to dispatch the failed over task.

Our current interface is :

public interface DistributedTaskFailoverPolicy {
Address failover(Address failedExecution, List<Address> 
executionCandidates, Exception cause);
}

Rather than adding yet another parameter here maybe we should make a 
simple container class

public class FailoverContext {

Address failedExecution;
List<Address> executionCandidates;
Exception cause;
List<Object> inputKeys;
}

and have


public interface DistributedTaskFailoverPolicy {
Address failover(FailoverContext context);
}

WDYT?

Regards,
Vladimir


More information about the infinispan-dev mailing list