Package org.alfresco.repo.index.shard
Interface ShardRegistry
-
public interface ShardRegistryA registry which collects all the active shard subscriptions.- Author:
- Andy, agazzarini, eporciani
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Map<org.alfresco.repo.index.shard.Floc,java.util.Map<org.alfresco.repo.index.shard.Shard,java.util.Set<org.alfresco.repo.index.shard.ShardState>>>getFlocs()java.util.List<org.alfresco.repo.index.shard.ShardInstance>getIndexSlice(org.alfresco.service.cmr.search.SearchParameters searchParameters)java.util.OptionalIntgetShardInstanceByTransactionTimestamp(java.lang.String coreId, long txnTimestamp)Returns the shard instance (i.e.voidpurge()voidpurgeAgedOutShards()voidregisterShardState(org.alfresco.repo.index.shard.ShardState shardState)Registers (or updates the existing subscription) of a shard.
-
-
-
Method Detail
-
registerShardState
void registerShardState(org.alfresco.repo.index.shard.ShardState shardState)
Registers (or updates the existing subscription) of a shard.- Parameters:
shardState- the shard state, which contains the information about the shard that wants to subscribe/register.
-
getIndexSlice
java.util.List<org.alfresco.repo.index.shard.ShardInstance> getIndexSlice(org.alfresco.service.cmr.search.SearchParameters searchParameters)
-
purge
void purge()
-
getFlocs
java.util.Map<org.alfresco.repo.index.shard.Floc,java.util.Map<org.alfresco.repo.index.shard.Shard,java.util.Set<org.alfresco.repo.index.shard.ShardState>>> getFlocs()
-
purgeAgedOutShards
void purgeAgedOutShards()
-
getShardInstanceByTransactionTimestamp
java.util.OptionalInt getShardInstanceByTransactionTimestamp(java.lang.String coreId, long txnTimestamp)Returns the shard instance (i.e. shard number) which owns (or should own) the transaction associated with the given timestamp.- Parameters:
coreId- an identifier (e.g. core name, base url) of the core / collection whose requested shard belongs to.txnTimestamp- the transaction timestamp used as search criteria.- Returns:
- the shard instance (i.e. shard number) which owns (or should own) the transaction associated with the given timestamp.
-
-