Skip to content

Commit

Permalink
Removed node scan when looking up nodes from index
Browse files Browse the repository at this point in the history
  • Loading branch information
tinwelint committed Mar 14, 2013
1 parent 8ce5933 commit fdb8adc
Showing 1 changed file with 1 addition and 6 deletions.
Expand Up @@ -85,14 +85,9 @@ class EntityProducerFactory(planContext: PlanContext) {
val expression = valueExp getOrElse val expression = valueExp getOrElse
(throw new InternalException("Something went wrong trying to build your query.")) (throw new InternalException("Something went wrong trying to build your query."))


val label = DynamicLabel.label(labelName)

(m: ExecutionContext, state: QueryState) => { (m: ExecutionContext, state: QueryState) => {
val value = expression(m)(state) val value = expression(m)(state)
state.query.exactIndexSearch(indexId, value) // This is the real call. The next is not the call you are looking for state.query.exactIndexSearch(indexId, value)
state.query.nodeOps.all.filter {
case node:Node => node.hasLabel(label) && node.getProperty(propertyName, null) == value
}
} }
} }


Expand Down

0 comments on commit fdb8adc

Please sign in to comment.