Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support REST Traversal API #102

Open
dkushner opened this issue Jan 20, 2014 · 5 comments
Open

Support REST Traversal API #102

dkushner opened this issue Jan 20, 2014 · 5 comments

Comments

@dkushner
Copy link

Neo4j has an excellent REST API module that supports custom graph traversals and path aggregation. It would be great if node-neo4j could expose some access to this functionality, preferably via a method with the following specifications:

GraphDatabase.traverse({
    type: 'node' | 'relationship' | 'path' | 'fullpath',
    order: 'breadthFirst' | 'depthFirst',
    relationships: [{
        direction: 'all' | 'in' | 'out',
        type: STRING
    }, {...}],
    uniqueness: 'nodeGlobal' | 'none' | 'relationshipGlobal' | 'nodePath' | 'relationshipPath',
    pruneEvaluator: FUNCTION,
    returnFilter: FUNCTION | 'all' | 'allButStartNode',
    maxDepth: INTEGER
}, function(err, res) {});

Just an idea, based on the documentation here.

@aseemk
Copy link
Member

aseemk commented Feb 2, 2014

Sorry for the delay in responding here, @dkushner! Thanks for submitting your PR, I'll review it.

Just for curiosity, any reason you prefer the traversal API over Cypher? That's the reason we never bothered implementing this — because Cypher lets you do this in such a nicer way.

(We did implement the simple/convenience getRelationshipNodes method before Cypher was added.)

@hackintoshrao
Copy link

Using Cypher for Standard graph traversals like DFS,BFS makes the understanding of these algorithms as bottleneck to execute it . This reduces the usability of the module . It shouldnt be a necessity to understand these standard algorithms to be able to execute them .

@aseemk
Copy link
Member

aseemk commented Aug 10, 2014

Good point, @Karthic-Hackintosh! Out of curiosity, are you using this traversal API yourself?

@hackintoshrao
Copy link

Currently i'm not , but i want contribute to this repo . May be i can start with fixing this up first !!Need some help on starting to contribute to this repo !

@aseemk
Copy link
Member

aseemk commented Oct 12, 2015

Good news: it's now possible to use the traversal API in node-neo4j v2, even though it's not implemented directly, because you can now make arbitrary & custom HTTP / REST API calls (issue #100).

https://github.com/thingdom/node-neo4j/tree/v2#http--plugins

So I'm going to go ahead mark this issue as fixed in v2. Let me know if you have any q's!

@aseemk aseemk added this to the v2 redesign milestone Oct 12, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants