Class DefaultDocumentAssignmentStrategy
java.lang.Object
com.lucidworks.apollo.partitioning.DefaultDocumentAssignmentStrategy
- All Implemented Interfaces:
DocumentAssignmentStrategy,Serializable
Default assignment strategy just selects the configured Solr collection to send documents to, i.e.
no collection-level partitioning.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidDelete all partitions created by this strategy.voiddeletePartition(String partitionId) Deletes a partition managed by this strategy.voidCalled in the background at a regular interval to allow the strategy to perform maintenance on the partitions.getOrCreatePartitionForDoc(com.lucidworks.apollo.common.pipeline.PipelineDocument doc) Returns the name of a Solr collection where a document should be assigned to based on this strategy.getPartitions(boolean activeOnly) Returns a list of Solr collection names where documents have been assigned by this strategy.getPartitionsForQuery(javax.ws.rs.core.MultivaluedMap<String, String> queryParams) Returns a list of Solr collection names that need to be queried to satisfy the query criteria.
-
Constructor Details
-
DefaultDocumentAssignmentStrategy
-
-
Method Details
-
getPartitions
Description copied from interface:DocumentAssignmentStrategyReturns a list of Solr collection names where documents have been assigned by this strategy.- Specified by:
getPartitionsin interfaceDocumentAssignmentStrategy- Throws:
Exception
-
getPartitionsForQuery
public List<String> getPartitionsForQuery(javax.ws.rs.core.MultivaluedMap<String, String> queryParams) throws ExceptionDescription copied from interface:DocumentAssignmentStrategyReturns a list of Solr collection names that need to be queried to satisfy the query criteria.- Specified by:
getPartitionsForQueryin interfaceDocumentAssignmentStrategy- Throws:
Exception
-
getOrCreatePartitionForDoc
public String getOrCreatePartitionForDoc(com.lucidworks.apollo.common.pipeline.PipelineDocument doc) throws Exception Description copied from interface:DocumentAssignmentStrategyReturns the name of a Solr collection where a document should be assigned to based on this strategy.- Specified by:
getOrCreatePartitionForDocin interfaceDocumentAssignmentStrategy- Throws:
Exception
-
deletePartition
Description copied from interface:DocumentAssignmentStrategyDeletes a partition managed by this strategy.- Specified by:
deletePartitionin interfaceDocumentAssignmentStrategy- Throws:
Exception
-
deleteAllPartitions
Description copied from interface:DocumentAssignmentStrategyDelete all partitions created by this strategy.- Specified by:
deleteAllPartitionsin interfaceDocumentAssignmentStrategy- Throws:
Exception
-
doScheduledMaintenanceOnPartitions
Description copied from interface:DocumentAssignmentStrategyCalled in the background at a regular interval to allow the strategy to perform maintenance on the partitions.- Specified by:
doScheduledMaintenanceOnPartitionsin interfaceDocumentAssignmentStrategy- Throws:
Exception
-