I'm researching Neo4j to compare it's performance for implementing an access control list. It seems like this is a great fit.
Here's an article from a few years ago describing this exact use case. http://blog.neo4j.org/2010/02/access-control-lists-graph-database-way.html .
The has_access
method though is written in ruby. I would think that using gremlin to process the query on the server would be more efficient for large graphs. How would I determine if a user has access to a node using Gremlin?
Thanks!
It turns out that for this problem, access to a folder can be determined by parsing the shortest paths between the user and the user and the folder.
Here is a cypher query that returns the shortest paths between two nodes, where the user is at node 157 and the folder is at node 160.
START u=node(157),f=node(160)
MATCH p=allShortestPaths(u-[*]->f)
RETURN p
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.