|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectdarx.ReplicationManager
public abstract class ReplicationManager
LA DEFINITION QUI SUIT EST CELLE A COURT TERME
Ce composant sert a traduire le changement de valeur de la criticite
en modification de strategie.
LA DEFINITION QUI SUIT EST CELLE A LONG TERME
This is the component, used alongside each TaskShell
,
which defines a task's replication group, that is its members and its scheme,
and handles its consistency.
This class provides methods to manage the information a specific task
possesses about its replication group in terms of replicant (un)registration,
that is it maintains up to date the number of replicants for this particular
task, the location of each replicant and the strategy it belongs to.
NB: EVERY replicant, independently of its being leader of the replication
group or not, carries and maintains this information up to date so as to be
available to take the leadership in case of the current leader's failure.
NB2: A scheme may be composed of multiple replication strategies.
ReplicationStrategy
Constructor Summary | |
---|---|
ReplicationManager(TaskShell shell,
ReplicationPolicy policy,
double criticity)
Constructs a new ReplicationManager. |
Method Summary | |
---|---|
abstract void |
adaptPolicy()
Adapts the current replication scheme using a specific heuristic. |
int |
compareStrategies(ReplicationStrategy rep_strat_a,
ReplicationStrategy rep_strat_b)
Compares two replication strategies. |
double |
getCriticity()
|
double |
setCriticity(double new_criticity)
Updates the criticity of the replication group. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ReplicationManager(TaskShell shell, ReplicationPolicy policy, double criticity)
Method Detail |
---|
public double getCriticity()
public double setCriticity(double new_criticity)
new_criticity
- the newly computed value for the criticity.
public abstract void adaptPolicy()
public int compareStrategies(ReplicationStrategy rep_strat_a, ReplicationStrategy rep_strat_b)
rep_strat_a
- the first strategy to be comparedrep_strat_b
- the second strategy to be compared
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |