|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SynchronizationPolicy
Policy to decide how to handle content updates from nodes attempting to join the cluster or from cluster merges. The policy is consulted on the "authoritative" node, i.e. the master node for the service on the cluster.
Method Summary | |
---|---|
boolean |
acceptJoinAddition(RepositoryItemMetadata toAdd,
RepositoryItemMetadata joinersPrevious)
Should the item represented by toAdd that is available
on a newly joining node be accepted for use around the cluster
when the cluster's records show no record of an item with the same path?
Such a case potentially could mean newly joining node was unaware of an
earlier removal that occurred while it was offline and that the cluster
has also purged
from its records . |
boolean |
acceptJoinReincarnation(RepositoryItemMetadata reincarnation,
RepositoryItemMetadata current)
Should the item represented by reincarnation that is available
on a newly joining node be accepted for use around the cluster when
the cluster's records show an item with the same path was previously
removed? Such a case potentially could mean the newly joining node
was unaware of a removal that occurred while it was offline. |
boolean |
acceptJoinRemoval(RepositoryItemMetadata current,
RepositoryItemMetadata joinersItem)
Should the item represented by toRemove that is unavailable
on a merging set of nodes be removed from around the cluster when
the cluster's records show an item with the same path? Such a case
potentially could mean the newly joining node was unaware of a new
deployment of the item that occurred while it was offline. |
boolean |
acceptJoinUpdate(RepositoryItemMetadata update,
RepositoryItemMetadata current)
Should the item represented by update that is available
on a newly joining node be accepted for use around the cluster when the
cluster's records show an item with the same path with a different version?
Such a case potentially could mean the newly joining node was unaware of
changes that occurred while it was offline. |
boolean |
acceptMergeAddition(RepositoryItemMetadata toAdd)
Should the item represented by toAdd that is available
on a merging set of nodes be accepted for use around the cluster when the
cluster's records show no record of an item with the same path? Such a
case potentially could mean the merging nodes were unaware of an earlier
removal that occurred while the cluster was split and that the cluster
has also purged
from its records . |
boolean |
acceptMergeReincarnation(RepositoryItemMetadata reincarnation,
RepositoryItemMetadata current)
Should the item represented by reincarnation that is available
on a merging set of nodes be accepted for use around the cluster when the
cluster's records show an item with the same path was previously removed?
Such a case potentially could mean the merging nodes were unaware of a
removal that occurred while the cluster was split. |
boolean |
acceptMergeRemoval(RepositoryItemMetadata current,
RepositoryItemMetadata mergersView)
Should the item represented by toRemove that is unavailable
on a newly joining node be removed from around the cluster when
the cluster's records show an item with the same path? Such a case
potentially could mean the newly joining node was unaware of a new
deployment of the item that occurred while the cluster was split. |
boolean |
acceptMergeUpdate(RepositoryItemMetadata update,
RepositoryItemMetadata current)
Should the item represented by update that is available
on a merging set of nodes be accepted for use around the cluster when the
cluster's records show an item with the same path with a different version?
Such a case potentially could mean the merging nodes were unaware of
changes that occurred while the cluster was split. |
boolean |
purgeRemovedItems(RepositoryContentMetadata content)
Request that the policy remove any RepositoryItemMetadata objects
that are listed as removed
if the policy no longer wishes to consider them in its decision making. |
Method Detail |
---|
boolean acceptJoinAddition(RepositoryItemMetadata toAdd, RepositoryItemMetadata joinersPrevious)
toAdd
that is available
on a newly joining node be accepted for use around the cluster
when the cluster's records show no record of an item with the same path?
Such a case potentially could mean newly joining node was unaware of an
earlier removal that occurred while it was offline and that the cluster
has also purged
from its records
.
toAdd
- the item to addjoinersPrevious
- information, if available, on the timestamp of the
item that was present on the joining node when
it stopped. May be null
, indicating
the joining node was unaware of the item when stopped.
true
if the addition should be acceptedboolean acceptJoinReincarnation(RepositoryItemMetadata reincarnation, RepositoryItemMetadata current)
reincarnation
that is available
on a newly joining node be accepted for use around the cluster when
the cluster's records show an item with the same path was previously
removed? Such a case potentially could mean the newly joining node
was unaware of a removal that occurred while it was offline.
reincarnation
- the new version of the itemcurrent
- the cluster's current version of the item, showing when
it was removed and by whom. The "when" should reflect this
node's time of removal, not the time on the node that originated
the removal.
true
if the reincarnation should be acceptedboolean acceptJoinRemoval(RepositoryItemMetadata current, RepositoryItemMetadata joinersItem)
toRemove
that is unavailable
on a merging set of nodes be removed from around the cluster when
the cluster's records show an item with the same path? Such a case
potentially could mean the newly joining node was unaware of a new
deployment of the item that occurred while it was offline.
current
- the cluster's current version of the itemjoinersItem
- the joining node's view of item to remove. May be null,
indicating the sender is unaware of the item. If not null,
the timestamp of this item should reflect when the item
was removed, if known. If the time the item was removed is
not known, the timestamp should reflect the last known
timestamp of the item that was removed.
true
if the removal should be acceptedboolean acceptJoinUpdate(RepositoryItemMetadata update, RepositoryItemMetadata current)
update
that is available
on a newly joining node be accepted for use around the cluster when the
cluster's records show an item with the same path with a different version?
Such a case potentially could mean the newly joining node was unaware of
changes that occurred while it was offline.
update
- the new version of the itemcurrent
- the cluster's current version of the item
true
if the update should be acceptedboolean acceptMergeAddition(RepositoryItemMetadata toAdd)
toAdd
that is available
on a merging set of nodes be accepted for use around the cluster when the
cluster's records show no record of an item with the same path? Such a
case potentially could mean the merging nodes were unaware of an earlier
removal that occurred while the cluster was split and that the cluster
has also purged
from its records
.
toAdd
- the item to add
true
if the addition should be acceptedboolean acceptMergeReincarnation(RepositoryItemMetadata reincarnation, RepositoryItemMetadata current)
reincarnation
that is available
on a merging set of nodes be accepted for use around the cluster when the
cluster's records show an item with the same path was previously removed?
Such a case potentially could mean the merging nodes were unaware of a
removal that occurred while the cluster was split.
reincarnation
- the new version of the itemcurrent
- the cluster's current version of the item, showing when
it was removed and by whom
true
if the reincarnation should be acceptedboolean acceptMergeRemoval(RepositoryItemMetadata current, RepositoryItemMetadata mergersView)
toRemove
that is unavailable
on a newly joining node be removed from around the cluster when
the cluster's records show an item with the same path? Such a case
potentially could mean the newly joining node was unaware of a new
deployment of the item that occurred while the cluster was split.
current
- the cluster's current version of the itemmergersView
- the merging node's view of item to remove. May be null,
indicating the sender is unaware of the item. If not null,
the timestamp of this item should reflect when the item
was removed, if known. If the time the item was removed is
not known, the timestamp should reflect the last known
timestamp of the item that was removed.
true
if the removal should be acceptedboolean acceptMergeUpdate(RepositoryItemMetadata update, RepositoryItemMetadata current)
update
that is available
on a merging set of nodes be accepted for use around the cluster when the
cluster's records show an item with the same path with a different version?
Such a case potentially could mean the merging nodes were unaware of
changes that occurred while the cluster was split.
update
- the new version of the itemcurrent
- the cluster's current version of the item
true
if the update should be acceptedboolean purgeRemovedItems(RepositoryContentMetadata content)
RepositoryItemMetadata
objects
that are listed as removed
if the policy no longer wishes to consider them in its decision making.
Used to prevent perpetual growth in the size of the RepositoryContentMetadata
by eventually purging records of removed items.
content
- the content. Cannot be null
.
true
if any items were purged, false
if not
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |