atg.endeca.index
Interface Indexable

All Known Implementing Classes:
EndecaIndexingOutputConfig, LocaledExporter, RepositoryTypeHierarchyExporter, SchemaExporter, ScriptIndexable

public interface Indexable

A basic interface for things that support baseline/bulk and partial/incremental indexing. These are typically called by the SimpleIndexingAdmin via an IndexingTask.

Created: November 23 2011

See Also:
SimpleIndexingAdmin, atg.endeca.index.admin.IndexingTask

Field Summary
static java.lang.String CLASS_VERSION
          Class version string from source code control system.
 
Method Summary
 boolean cancel(IndexingTask pTask, boolean pBaseline)
          Cancel the currently in-process performBulkLoad or processQueuedIncrementalUpdates.
 java.util.Set<java.lang.String> getIndexingOutputConfigPaths()
          Return the set of IndexingOutputConfigs associated with this Indexable.
 boolean isNeededForIncremental()
          Whether this Indexable is needed for an incremental update.
 boolean isSupportsStatusCounts()
          Whether this object supports returning/updating status counts.
 boolean mayNeedCleanup()
          Whether this task may need cleanup.
 atg.repository.search.indexing.BulkLoaderResults performBaselineUpdate(IndexingTask pTask)
          Do a full/bulk load.
 atg.repository.search.indexing.LoaderResults performPartialUpdate(IndexingTask pTask)
          Do an incremental load (that is, process any Queued incremental updates.
 void postIndexingCleanup(IndexingTask pTask, boolean pSuccess, atg.repository.search.indexing.LoaderResults pResults)
          Perform any post indexing cleanup.
 

Field Detail

CLASS_VERSION

static final java.lang.String CLASS_VERSION
Class version string from source code control system.

See Also:
Constant Field Values
Method Detail

performBaselineUpdate

atg.repository.search.indexing.BulkLoaderResults performBaselineUpdate(IndexingTask pTask)
                                                                       throws atg.repository.search.indexing.IndexingException
Do a full/bulk load. Note that the any results property but "successful" may not be filled except by IndexingOutputConfigs.

This is called "performBulkLoad" rather than "bulkLoad" so that MultiConfigLoader could implement it.

Parameters:
pTask - the indexing task invoking the update. May be null if called via another means.
Throws:
atg.repository.search.indexing.IndexingException

performPartialUpdate

atg.repository.search.indexing.LoaderResults performPartialUpdate(IndexingTask pTask)
                                                                  throws atg.repository.search.indexing.IndexingException
Do an incremental load (that is, process any Queued incremental updates. Note that the any results property but "successful" may not be filled except by IndexingOutputConfigs.

Parameters:
pTask - the indexing task invoking the update. May be null if called via another means.
Throws:
atg.repository.search.indexing.IndexingException

isNeededForIncremental

boolean isNeededForIncremental()
Whether this Indexable is needed for an incremental update.

Returns:
true if this Indexable should be invoked for an incremental update, false if this Indexable should not be involved at an incremental update.

postIndexingCleanup

void postIndexingCleanup(IndexingTask pTask,
                         boolean pSuccess,
                         atg.repository.search.indexing.LoaderResults pResults)
                         throws atg.repository.search.indexing.IndexingException
Perform any post indexing cleanup.

Parameters:
pSuccess - true if we are cleaning up from a successful index, false otherwise.
pTask - the current indexing task, if any.
pSuccess - whether the indexing job has been successful up until now.
pResults - the loader results (if any) returns from performBaselineUpdate and performPartialUpdate.
Throws:
atg.repository.search.indexing.IndexingException

mayNeedCleanup

boolean mayNeedCleanup()
Whether this task may need cleanup. If true is returned, postIndexingCleanup will be called at some point after performPartialUpdate or performBaselineUpdate.


cancel

boolean cancel(IndexingTask pTask,
               boolean pBaseline)
               throws atg.repository.search.indexing.IndexingException
Cancel the currently in-process performBulkLoad or processQueuedIncrementalUpdates. Quick running indexables may not support cancel.

Parameters:
pBaseline - true if this is a baseline/full index, false if this is an incremental/partial index.
Returns:
true if current task was found to cancel, false otherwise.
Throws:
atg.repository.search.indexing.IndexingException

isSupportsStatusCounts

boolean isSupportsStatusCounts()
Whether this object supports returning/updating status counts. This is mostly so the admin will not display meaningless "0" even though work may be progressing.


getIndexingOutputConfigPaths

java.util.Set<java.lang.String> getIndexingOutputConfigPaths()
Return the set of IndexingOutputConfigs associated with this Indexable. May return an empty set, but should always return non-null.