Class CleanupRevalidationUtil
java.lang.Object
org.exoplatform.addons.documents.cleanup.util.CleanupRevalidationUtil
Single definition of the revalidation-outcome to item-state mapping, shared
by the freshness refresh (observation glue) and the execution-time
revalidation so both stay strictly identical.
-
Method Summary
Modifier and TypeMethodDescriptionstatic booleanapplyRevalidation(CleanupCampaignItem item, CleanupRevalidation revalidation) Applies a revalidation outcome to a campaign item: outcome unknown (transient JCR read failure): the item is left UNTOUCHED — never spared, never gone, never deleted on doubt; callers needing a distinct handling (e.g.
-
Method Details
-
applyRevalidation
Applies a revalidation outcome to a campaign item:- outcome unknown (transient JCR read failure): the item is left UNTOUCHED — never spared, never gone, never deleted on doubt; callers needing a distinct handling (e.g. the execution skipping the item) check CleanupRevalidation.isUnknown() first
- node gone:
CleanupItemState.GONE - node exempted:
CleanupItemState.EXEMPTED - node no longer a candidate:
CleanupItemState.SPARED_BY_MODIFICATION - node still a candidate: refreshes the item's path, action, fileSize, versionsSize, candidacy dates (last-modified and created) and computedAt
- Parameters:
item- campaign item to updaterevalidation- revalidation outcome- Returns:
- true when the node is still a candidate (the item's action was refreshed), false when the item left the candidate state or the outcome is unknown
-