@PublicApi public interface IndexLifecycleManager extends Sized, Shutdown
Modifier and Type | Method and Description |
---|---|
long |
activate(Context context)
Activates search indexes.
|
long |
activate(Context context,
boolean reindex)
Activates search indexes.
|
void |
deactivate()
De-activates indexing (as happens from the admin page) and removes index directories.
|
Collection<String> |
getAllIndexPaths() |
boolean |
isIndexAvailable()
Whether this index is available.
|
boolean |
isIndexConsistent() |
boolean |
isIndexingEnabled()
Deprecated.
since v6.3.3 Use
isIndexAvailable() |
long |
optimize()
Optimize the underlying indexes.
|
long |
reIndexAll(Context context)
Deprecated.
|
long |
reIndexAll(Context context,
IssueIndexingParams issueIndexingParams)
Reindex indexes defined by the
IssueIndexingParams . |
long |
reIndexAllIssuesInBackground(Context context)
Reindex everything, but don't stop the world
Comments and change history will not be reindexed.
|
long |
reIndexAllIssuesInBackground(Context context,
boolean reIndexComments,
boolean reIndexChangeHistory)
|
long |
reIndexIssuesInBackground(Context context,
IssueIndexingParams issueIndexingParams)
Reindex everything, but don't stop the world
|
void |
shutdown()
Shuts down the indexing manager and closes its resources (if any).
|
int |
size() |
long reIndexAll(Context context)
reIndexAll(com.atlassian.jira.task.context.Context, com.atlassian.jira.issue.index.IssueIndexingParams)
instead. Since v6.4.context
- used to report progress back to the user or to the logs. Must not be null.long reIndexAll(Context context, IssueIndexingParams issueIndexingParams)
IssueIndexingParams
.context
- used to report progress back to the user or to the logs. Must not be null.issueIndexingParams
- indexes to reindex.long reIndexAllIssuesInBackground(Context context)
context
- used to report progress back to the user or to the logs. Must not be null.@Deprecated long reIndexAllIssuesInBackground(Context context, boolean reIndexComments, boolean reIndexChangeHistory)
reIndexIssuesInBackground(com.atlassian.jira.task.context.Context, com.atlassian.jira.issue.index.IssueIndexingParams)
context
- used to report progress back to the user or to the logs. Must not be null.reIndexComments
- Also reindex all the issue comments.reIndexChangeHistory
- Also reindex the issue change history.long reIndexIssuesInBackground(Context context, IssueIndexingParams issueIndexingParams)
context
- used to report progress back to the user or to the logs. Must not be null.issueIndexingParams
- determines witch related objects should be indexed together with issue.long optimize()
IndexException
- if the indexes are seriously in troublevoid shutdown()
long activate(Context context)
context
- used to report progress back to the user or to the logs. Must not be null.long activate(Context context, boolean reindex)
context
- used to report progress back to the user or to the logs. Must not be null.reindex
- reindex after activation.void deactivate()
boolean isIndexingEnabled()
isIndexAvailable()
boolean isIndexAvailable()
boolean isIndexConsistent()
false
. Note that false
is also returned if the index
is not available isIndexAvailable()
.Collection<String> getAllIndexPaths()
int size()
size
in interface Sized
reIndexAll(Context)
Copyright © 2002-2021 Atlassian. All Rights Reserved.