public class RedisIndexStorage extends Object implements IndexStorage
Stores a list of indices and vertex ids representing those indices which need to be post processed
| Modifier and Type | Method and Description |
|---|---|
void |
addIndex(ai.grakn.Keyspace keyspace,
String index,
Set<ai.grakn.concept.ConceptId> conceptIds)
Add an index to the list of indices which needs to be post processed
|
static RedisIndexStorage |
create(redis.clients.util.Pool<redis.clients.jedis.Jedis> jedisPool,
com.codahale.metrics.MetricRegistry metricRegistry) |
static String |
getConceptIdsKey(ai.grakn.Keyspace keyspace,
String index)
The key which refers to a set of vertices currently pointing to the same index
|
static String |
getIndicesKey(ai.grakn.Keyspace keyspace)
The key which refers to a list of all the indices in a certain
Keyspace which need to be post processed |
Set<ai.grakn.concept.ConceptId> |
popIds(ai.grakn.Keyspace keyspace,
String index)
Gets and removes all the ids which we need to post process
|
String |
popIndex(ai.grakn.Keyspace keyspace)
Gets and removes the next index to post process
|
public static RedisIndexStorage create(redis.clients.util.Pool<redis.clients.jedis.Jedis> jedisPool, com.codahale.metrics.MetricRegistry metricRegistry)
public void addIndex(ai.grakn.Keyspace keyspace,
String index,
Set<ai.grakn.concept.ConceptId> conceptIds)
IndexStorageaddIndex in interface IndexStorage@Nullable public String popIndex(ai.grakn.Keyspace keyspace)
IndexStoragepopIndex in interface IndexStoragepublic Set<ai.grakn.concept.ConceptId> popIds(ai.grakn.Keyspace keyspace, String index)
IndexStoragepopIds in interface IndexStoragepublic static String getIndicesKey(ai.grakn.Keyspace keyspace)
Keyspace which need to be post processedCopyright © 2018 Grakn Labs Ltd. All rights reserved.