Package com.atlassian.confluence.it
Class ReIndexJobHelper
- java.lang.Object
-
- com.atlassian.confluence.it.ReIndexJobHelper
-
public class ReIndexJobHelper extends Object
- Since:
- 7.11
-
-
Constructor Summary
Constructors Constructor Description ReIndexJobHelper(@NonNull com.atlassian.confluence.test.rest.api.ConfluenceRestClient restClient)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isReindexImprovementsEnabled()
Will tell you if the reindex improvements are enabled and thus if the bandana store for the ReIndexJobJson is available to query for the status.void
waitForPossibleReindex(@NonNull ConfluenceRpc rpc, @NonNull TimePeriod timeout, @Nullable Runnable runnable)
Waits for a possible rebuild of the index.
-
-
-
Method Detail
-
isReindexImprovementsEnabled
public boolean isReindexImprovementsEnabled()
Will tell you if the reindex improvements are enabled and thus if the bandana store for the ReIndexJobJson is available to query for the status.- Returns:
- boolean true if the improvements are available.
-
waitForPossibleReindex
public void waitForPossibleReindex(@NonNull ConfluenceRpc rpc, @NonNull TimePeriod timeout, @Nullable Runnable runnable)
Waits for a possible rebuild of the index. Triggers are for instance a global import or explicit calls to rebuild. If the reindex improvements are enabled, this will wait for propagation across a cluster. If not, it will wait using a latch on the ReindexFinishedEvent happening.- Parameters:
rpc
- ConfluenceRpc needed for the EventWaitingLatchperiod
- TimePeriod before this method throws an exceptionrunnable
- Runnable optional task to perform that may cause reindexing
-
-