Package org.dspace.discovery
Interface IndexingService
-
- All Known Implementing Classes:
SolrServiceImpl
public interface IndexingServiceInterface used for indexing IndexableObject into discovery- Author:
- Kevin Van de Velde (kevin at atmire dot com), Mark Diggory (markd at atmire dot com), Ben Bosman (ben at atmire dot com)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidatomicUpdate(Context context, String uniqueIndexId, String field, Map<String,Object> fieldModifier)Atomically update the index of a single field for an objectvoidbuildSpellCheck()voidcleanIndex()voidcommit()voidcreateIndex(Context context)voiddeleteIndex()voidindexContent(Context context, IndexableObject dso)voidindexContent(Context context, IndexableObject dso, boolean force)voidindexContent(Context context, IndexableObject dso, boolean force, boolean commit)voidindexContent(Context context, IndexableObject dso, boolean force, boolean commit, boolean preDb)Index a given DSOvoidoptimize()voidreIndexContent(Context context, IndexableObject dso)voidunIndexContent(Context context, String uniqueSearchID)voidunIndexContent(Context context, String uniqueSearchID, boolean commit)voidunIndexContent(Context context, IndexableObject dso)voidunIndexContent(Context context, IndexableObject dso, boolean commit)voidupdateIndex(Context context)voidupdateIndex(Context context, boolean force)voidupdateIndex(Context context, boolean force, String type)
-
-
-
Method Detail
-
indexContent
void indexContent(Context context, IndexableObject dso) throws SQLException
- Throws:
SQLException
-
indexContent
void indexContent(Context context, IndexableObject dso, boolean force) throws SQLException
- Throws:
SQLException
-
indexContent
void indexContent(Context context, IndexableObject dso, boolean force, boolean commit) throws SQLException, SearchServiceException
- Throws:
SQLExceptionSearchServiceException
-
indexContent
void indexContent(Context context, IndexableObject dso, boolean force, boolean commit, boolean preDb) throws SQLException, SearchServiceException
Index a given DSO- Parameters:
context- The DSpace Contextdso- The DSpace Object to indexforce- Force update even if not stalecommit- Commit the changespreDb- Add a "preDB" status to the index (only applicable to Items)- Throws:
SQLExceptionSearchServiceException
-
unIndexContent
void unIndexContent(Context context, IndexableObject dso) throws SQLException, IOException
- Throws:
SQLExceptionIOException
-
unIndexContent
void unIndexContent(Context context, IndexableObject dso, boolean commit) throws SQLException, IOException
- Throws:
SQLExceptionIOException
-
unIndexContent
void unIndexContent(Context context, String uniqueSearchID) throws IOException
- Throws:
IOException
-
unIndexContent
void unIndexContent(Context context, String uniqueSearchID, boolean commit) throws IOException
- Throws:
IOException
-
reIndexContent
void reIndexContent(Context context, IndexableObject dso) throws SQLException, IOException
- Throws:
SQLExceptionIOException
-
createIndex
void createIndex(Context context) throws SQLException, IOException
- Throws:
SQLExceptionIOException
-
updateIndex
void updateIndex(Context context)
-
updateIndex
void updateIndex(Context context, boolean force)
-
cleanIndex
void cleanIndex() throws IOException, SQLException, SearchServiceException
-
deleteIndex
void deleteIndex()
-
commit
void commit() throws SearchServiceException- Throws:
SearchServiceException
-
optimize
void optimize() throws SearchServiceException- Throws:
SearchServiceException
-
buildSpellCheck
void buildSpellCheck() throws SearchServiceException, IOException- Throws:
SearchServiceExceptionIOException
-
atomicUpdate
void atomicUpdate(Context context, String uniqueIndexId, String field, Map<String,Object> fieldModifier) throws org.apache.solr.client.solrj.SolrServerException, IOException
Atomically update the index of a single field for an object- Parameters:
context- The DSpace contextuniqueIndexId- The unqiue index ID of the object to update the index forfield- The field to updatefieldModifier- The modifiers for the field to update. More information on how to atomically update a solr field using a field modifier can be found here: https://yonik.com/solr/atomic-updates/- Throws:
org.apache.solr.client.solrj.SolrServerExceptionIOException
-
-