|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface DistributionScheme
The DistributionScheme
interface provides a standard
for implementing various distribution schemes that simplify
interaction with the ReplicationManager
.
Method Summary | |
---|---|
HostSet |
assignReplicas(AppConfig app)
Assign the host location for the specified application. |
HostSet |
collocateReplicas(AppConfig app,
AppConfig collocateWithApp)
|
Host |
reassignReplica(AppConfig app,
Host host)
Reassign the application replica running on the specified host. |
HostSet |
removeReplicas(AppConfig app)
Remove replica assignments for the specified application. |
void |
viewChangeEvent(View view)
Update the distribution scheme according to the specified view for the given application. |
Methods inherited from interface jgroup.core.MergingListener |
---|
getState, putState |
Method Detail |
---|
HostSet assignReplicas(AppConfig app) throws RedundancyException, GroupExistsException
AppConfig
object also contains the required redundancy.
app
- An AppConfig
object specifying the class parameters
and redundancy requirements, and group identifier.
HostSet
specifying the locations where the replicas
should be created.
RedundancyException
- Is raised if the specified redundancy could not be satisfied.
GroupExistsException
- Raised if the specified application group already exists (has been
assigned to some hostset).HostSet removeReplicas(AppConfig app) throws UnknownGroupException
app
- An AppConfig
object specifying the class parameters
and redundancy requirements, and group identifier.
HostSet
specifying the locations where the replicas
was located prior to the remove.
UnknownGroupException
HostSet collocateReplicas(AppConfig app, AppConfig collocateWithApp) throws GroupExistsException, RedundancyException, UnknownGroupException
GroupExistsException
RedundancyException
UnknownGroupException
Host reassignReplica(AppConfig app, Host host) throws UnknownGroupException, RedundancyException
app
- The application group to which the replica belongs.host
- The host from which to remove the replica.
UnknownGroupException
- The given application group is unknown.
RedundancyException
- Raised if the system could not reassign the replica to any host
in the system.void viewChangeEvent(View view)
Note that the method behavior should be idempotent.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |