Obtain all keys of a Neo4j index

Posted by MattiSG on Stack Overflow See other posts from Stack Overflow or by MattiSG
Published on 2012-05-15T20:33:33Z Indexed on 2012/06/29 21:16 UTC
Read the original article Hit count: 197

Filed under:
|
|

I have a Neo4j database whose content is generated dynamically from a big dataset.

All “entry points” nodes are indexed on a named index (IndexManager.forNodes(…)). I can therefore look up a particular “entry point” node.

However, I would now like to enumerate all those specific nodes, but I can't know on which key they were indexed.

Is there any way to enumerate all keys of a Neo4j Index?

If not, what would be the best way to store those keys, a data type that is eminently non-graph-oriented?


UPDATE (thanks for asking details :) ): the list would be more than 2 million entries. The main use case would be to never update it after an initialization step, but other use cases might need it, so it has to be somewhat scalable.

Also, I would really prefer avoiding killing my current resilience abilities, so storing all keys at once, as opposed to adding them incrementally, would be a last-resort solution.

© Stack Overflow or respective owner

Related posts about index

Related posts about neo4j