【发布时间】:2016-05-07 10:15:35
【问题描述】:
我正在尝试在 DynamoDB 上使用复合索引,但索引永远不会从 INSTALLED 切换到 REGISTERED 状态。
这是我用来创建它的代码
graph.tx().rollback(); //Never create new indexes while a transaction is active
TitanManagement mgmt=graph.openManagement();
PropertyKey propertyKey=getOrCreateIfNotExist(mgmt, "propertyKeyName");
String indexName = makePropertyKeyIndexName(propertyKey);
if (mgmt.getGraphIndex(indexName)==null) {
mgmt.buildIndex(indexName, Vertex.class).addKey(propertyKey).buildCompositeIndex();
mgmt.commit();
graph.tx().commit();
ManagementSystem.awaitGraphIndexStatus(graph, indexName).status(SchemaStatus.REGISTERED).call();
}else {
mgmt.rollback();
}
日志样本是:
... ...
612775 [主要] 信息 com.thinkaurelius.titan.graphdb.database.management.GraphIndexStatusWatcher - 索引 myIndex 上的某些键当前没有注册状态:type=INSTALLED 613275 [main] INFO com.thinkaurelius.titan.graphdb.database.management.GraphIndexStatusWatcher - 索引 typeIndex 上的某些键当前没有状态已注册:type=INSTALLED 613275 [main] INFO com.thinkaurelius.titan.graphdb.database.management.GraphIndexStatusWatcher - 等待索引 typeIndex 收敛到 REGISTERED 状态时超时 (PT1M)
【问题讨论】:
-
嘿 M-T-A,你能做到吗,我在使用 titan + cassandra 时遇到了类似的问题。
-
不,希望能得到泰坦人对此的回应。
-
我观察到的是,如果给定标签没有数据,则索引会转移到启用状态,但如果已经存在一些数据,则它会卡在已安装状态
-
此外,即使没有其他实例处于停滞/非活动状态,这也是相同的行为
标签: amazon-dynamodb titan