Class SearchService
- java.lang.Object
-
- com.atlassian.confluence.plugins.retentionrules.impl.service.SearchService
-
@Component public class SearchService extends Object
This service is used for searching spaces. It expands lucene search with additional features, f.e. ability to run additional checks against the database.- Since:
- 7.16
-
-
Constructor Summary
Constructors Constructor Description SearchService(SearchManager searchManager, SpaceService spaceService, com.atlassian.sal.api.features.DarkFeatureManager darkFeatureManager, SiteSearchPermissionsQueryFactory siteSearchPermissionsQueryFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SearchResultsspaces(String titleOrSpaceKey, boolean spacesWithRetentionPoliciesOnly)Method performs full-text search of the Spaces based on provided space titleOrSpaceKey using lucene index.
-
-
-
Constructor Detail
-
SearchService
@Autowired public SearchService(SearchManager searchManager, SpaceService spaceService, @Qualifier("darkFeatureManager") com.atlassian.sal.api.features.DarkFeatureManager darkFeatureManager, SiteSearchPermissionsQueryFactory siteSearchPermissionsQueryFactory)
-
-
Method Detail
-
spaces
public SearchResults spaces(String titleOrSpaceKey, boolean spacesWithRetentionPoliciesOnly) throws InvalidSearchException
Method performs full-text search of the Spaces based on provided space titleOrSpaceKey using lucene index. This method allows only to search all spaces, or only spaces with re-defined retention rules. Retention rules are checked against database, and not based on retention rules information in the index.- Parameters:
titleOrSpaceKey- - title or space key of the space. Wildcard search is performed against the title AND space keyspacesWithRetentionPoliciesOnly- -trueif search needs to be performed only among spaces with overridden retention rules- Returns:
SearchResultswith all the spaces with retention rules, which satisfytitleOrSpaceKeycriteria- Throws:
InvalidSearchException- if the search failed
-
-