Package org.apache.maven.index.updater
Class DefaultIndexUpdater
java.lang.Object
org.apache.maven.index.updater.DefaultIndexUpdater
- All Implemented Interfaces:
IndexUpdater
A default index updater implementation
- Author:
- Jason van Zyl, Eugene Kuleshov
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classFilesystem-based ResourceFetcher implementation -
Constructor Summary
ConstructorsConstructorDescriptionDefaultIndexUpdater(IncrementalHandler incrementalHandler, List<IndexUpdateSideEffect> sideEffects) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidcleanCacheDirectory(File dir) Cleans specified cache directory.fetchAndUpdateIndex(IndexUpdateRequest updateRequest) protected org.slf4j.LoggergetTimestamp(Properties properties, String key) unpackIndexData(InputStream is, org.apache.lucene.store.Directory d, IndexingContext context)
-
Constructor Details
-
DefaultIndexUpdater
@Inject public DefaultIndexUpdater(IncrementalHandler incrementalHandler, List<IndexUpdateSideEffect> sideEffects)
-
-
Method Details
-
getLogger
protected org.slf4j.Logger getLogger() -
fetchAndUpdateIndex
- Specified by:
fetchAndUpdateIndexin interfaceIndexUpdater- Returns:
- IndexUpdateResult
- Throws:
IOException
-
getTimestamp
-
unpackIndexData
public static IndexDataReader.IndexDataReadResult unpackIndexData(InputStream is, org.apache.lucene.store.Directory d, IndexingContext context) throws IOException - Parameters:
is- an input stream to unpack index data fromd-context-- Throws:
IOException
-
cleanCacheDirectory
Cleans specified cache directory. If present, Locker.LOCK_FILE will not be deleted.- Throws:
IOException
-