public class SolrProjectIndexer extends AbstractLogEnabled implements Component, Serviceable, SolrWorkspacesConstants
Modifier and Type | Field and Description |
---|---|
protected SolrClientProvider |
_solrClientProvider
The Solr client provider
|
protected SolrIndexer |
_solrIndexer
The Solr indexer
|
static String |
ROLE
The avalon role.
|
KEYWORDS, PROJECT_ID, TYPE_PROJECT_RESOURCE
ATTACHMENT_PAGE_ID, CONTENT_IDS, CONTENT_INTERESTING_DATES, DATE_FOR_SORTING, DATES_FACET, FACETABLE_CONTENT_FIELD_PREFIX, LASTNAME_FOR_SORTING, ORPHAN, PAGE_ANCESTOR_IDS, PAGE_CONTENT_TYPES, PAGE_DEPTH, PAGE_IDS, PAGE_LONG_TITLE, PAGE_OUTGOING_REFEERENCES_RESOURCE_IDS, PAGE_TITLE, PAGE_TYPE, PRIVACY, SECTION_PAGE_TITLE, SERVICE_IDS, SHARED, SITE_NAME, SITE_TYPE, SITEMAP_NAME, TEMPLATE, TYPE_PAGE, TYPE_PAGE_RESOURCE
ALL_CONTENT_TYPES, ALL_MIXIN_TYPES, ALL_TAGS, ATTACHMENT_CONTENT_ID, CONTENT_COMMENTS, CONTENT_COMMENTS_NONVALIDATED, CONTENT_COMMENTS_VALIDATED, CONTENT_CREATOR, CONTENT_LANGUAGE, CONTENT_LANGUAGES, CONTENT_LAST_CONTRIBUTOR, CONTENT_NAME, CONTENT_OUTGOING_REFEERENCES_RESOURCE_IDS, CONTENT_TITLES, CONTENT_TYPE_RESOURCE, CONTENT_TYPES, CREATION_DATE, DC_CONTRIBUTOR, DC_COVERAGE, DC_CREATOR, DC_DATE, DC_DESCRIPTION, DC_FORMAT, DC_IDENTIFIER, DC_LANGUAGE, DC_PUBLISHER, DC_RELATION, DC_RIGHTS, DC_SOURCE, DC_SUBJECT, DC_TITLE, DC_TYPE, DOCUMENT_TYPE, EXCERPT, FILENAME, FULL_EXACT_WS, FULL_GENERAL, FULL_PREFIX, FULL_STEMMED_PREFIX, ID, IS_AMETYS_OBJECT, LAST_MAJOR_VALIDATION, LAST_MODIFIED, LAST_VALIDATION, LENGTH, MIME_TYPES, MIXIN_TYPES, PATH, REPEATER_ENTRY_POSITION, RESOURCE_ANCESTOR_IDS, RESOURCE_CREATOR, RESOURCE_DATE, RESOURCE_LAST_MODIFIED, RESOURCE_ROOT_ID, SIMPLE_CONTENT_PARENTS, SUB_CONTENT, TAGS, TITLE, TITLE_SORT, TYPE_CONTENT, TYPE_CONTENT_RESOURCE, TYPE_REPEATER, TYPE_RESOURCE, TYPE_WF_ENTRY, TYPE_WF_STEP, WORKFLOW_CURRENT_STEPS, WORKFLOW_CURRENT_STEPS_DV, WORKFLOW_ENTRY_STATE, WORKFLOW_HISTORY_STEPS, WORKFLOW_HISTORY_STEPS_DV, WORKFLOW_NAME, WORKFLOW_REF, WORKFLOW_REF_DV, WORKFLOW_STEP, WORKFLOW_STEP_ACTIONID, WORKFLOW_STEP_CALLER, WORKFLOW_STEP_DUEDATE, WORKFLOW_STEP_FINISHDATE, WORKFLOW_STEP_ID, WORKFLOW_STEP_OWNER, WORKFLOW_STEP_STARTDATE, WORKFLOW_STEP_STATUS
Constructor and Description |
---|
SolrProjectIndexer() |
Modifier and Type | Method and Description |
---|---|
void |
service(ServiceManager manager) |
void |
unindexProject(String projectId)
Unindex all Solr documents related to the given project in all workspaces and commit.
|
void |
unindexProject(String projectId,
String workspaceName,
boolean commit)
Unindex all Solr documents related to the given project
|
getLogger, setLogger
protected SolrClientProvider _solrClientProvider
protected SolrIndexer _solrIndexer
public SolrProjectIndexer()
public void service(ServiceManager manager) throws ServiceException
service
in interface Serviceable
ServiceException
public void unindexProject(String projectId) throws SolrServerException, IOException, QuerySyntaxException
projectId
- The id of the projectSolrServerException
- if there is an error on the solr serverIOException
- If there is a low-level I/O error.QuerySyntaxException
- If there is a low-level I/O error.public void unindexProject(String projectId, String workspaceName, boolean commit) throws SolrServerException, IOException, QuerySyntaxException
projectId
- The id of the projectworkspaceName
- The workspace namecommit
- true to commitSolrServerException
- if there is an error on the solr serverIOException
- If there is a low-level I/O error.QuerySyntaxException
- If there is a low-level I/O error.