Class RenameCascadeService
java.lang.Object
org.alfresco.elasticsearch.batchindexing.cascade.RenameCascadeService
Cascades a rename to descendants by swapping the old path segment for the new one in each descendant's
PATH / UNPREFIXED_PATH arrays.
Descendants are matched via a term query on STANDARD_ANCESTOR ∪ CATEGORY_ANCESTOR. The update runs as a single _update_by_query with a Painless script doing delimiter-bracketed replacement per entry — idempotent, and version conflicts are set to proceed so concurrent live-indexing writes don't abort the cascade.
-
Constructor Summary
ConstructorsConstructorDescriptionRenameCascadeService(org.opensearch.client.opensearch.OpenSearchClient openSearchClient, org.alfresco.indexing.shared.ElasticsearchProperties elasticsearchProperties, CascadeProperties cascadeProperties) -
Method Summary
Modifier and TypeMethodDescriptionlongapply(RenameCascadeSource source) Apply the rename cascade for one source.
-
Constructor Details
-
Method Details
-
apply
Apply the rename cascade for one source. Skipped (info log) when the descriptor is incomplete or the rename is a no-op.- Returns:
- number of descendant docs mutated, or 0 when skipped.
-