Re: [Neo4j] Accessing node relationships via the Python REST client
On Wed, Dec 29, 2010 at 17:40, Peter Neubauer peter.neuba...@neotechnology.com wrote: Javier, you have any example of that? Just tried the default example plugins, they look like I mean, I was talking about the keys extensions-info, node-index and relationship-index. reference_node is already using the underscore. [~/code/tmp] $curl http://localhost:7474/db/data/ { extensions-info : http://localhost:7474/db/data/ext;, node : http://localhost:7474/db/data/node;, node-index : http://localhost:7474/db/data/index/node;, relationship-index : http://localhost:7474/db/data/index/relationship;, reference_node : http://localhost:7474/db/data/node/0;, extensions : { GetAll : { get_all_nodes : http://localhost:7474/db/data/ext/GetAll/graphdb/get_all_nodes;, getAllRelationships : http://localhost:7474/db/data/ext/GetAll/graphdb/getAllRelationships; }, Spatial : { addPointToLayer : http://localhost:7474/db/data/ext/Spatial/graphdb/addPointToLayer; } } meaning that they expose the plugin class and the method, or the name (get_all_nodes) that is user-defined ... Cheers, /peter neubauer GTalk: neubauer.peter Skype peter.neubauer Phone +46 704 106975 LinkedIn http://www.linkedin.com/in/neubauer Twitter http://twitter.com/peterneubauer http://www.neo4j.org - Your high performance graph database. http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party. On Tue, Dec 28, 2010 at 5:55 PM, Javier de la Rosa ver...@gmail.com wrote: On Tue, Dec 28, 2010 at 17:05, Peter Neubauer peter.neuba...@neotechnology.com wrote: is there anything we need to change in the Neo4j REST API before 1.2 in order to be done here? I'm not sure, but I think the new plugins feature exposes URL's with hyphens instead of underscores. It seems the only thing required here are changes on the Python side? Yes. I'm trying update the code on each milestone. -- Javier de la Rosa http://versae.es ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user -- Javier de la Rosa http://versae.es ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user
Re: [Neo4j] Accessing node relationships via the Python REST client
Javier, changed as of revision 8182, hope it will make it into the release! Cheers, /peter neubauer GTalk: neubauer.peter Skype peter.neubauer Phone +46 704 106975 LinkedIn http://www.linkedin.com/in/neubauer Twitter http://twitter.com/peterneubauer http://www.neo4j.org - Your high performance graph database. http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party. On Wed, Dec 29, 2010 at 6:33 PM, Javier de la Rosa ver...@gmail.com wrote: On Wed, Dec 29, 2010 at 17:40, Peter Neubauer peter.neuba...@neotechnology.com wrote: Javier, you have any example of that? Just tried the default example plugins, they look like I mean, I was talking about the keys extensions-info, node-index and relationship-index. reference_node is already using the underscore. [~/code/tmp] $curl http://localhost:7474/db/data/ { extensions-info : http://localhost:7474/db/data/ext;, node : http://localhost:7474/db/data/node;, node-index : http://localhost:7474/db/data/index/node;, relationship-index : http://localhost:7474/db/data/index/relationship;, reference_node : http://localhost:7474/db/data/node/0;, extensions : { GetAll : { get_all_nodes : http://localhost:7474/db/data/ext/GetAll/graphdb/get_all_nodes;, getAllRelationships : http://localhost:7474/db/data/ext/GetAll/graphdb/getAllRelationships; }, Spatial : { addPointToLayer : http://localhost:7474/db/data/ext/Spatial/graphdb/addPointToLayer; } } meaning that they expose the plugin class and the method, or the name (get_all_nodes) that is user-defined ... Cheers, /peter neubauer GTalk: neubauer.peter Skype peter.neubauer Phone +46 704 106975 LinkedIn http://www.linkedin.com/in/neubauer Twitter http://twitter.com/peterneubauer http://www.neo4j.org - Your high performance graph database. http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party. On Tue, Dec 28, 2010 at 5:55 PM, Javier de la Rosa ver...@gmail.com wrote: On Tue, Dec 28, 2010 at 17:05, Peter Neubauer peter.neuba...@neotechnology.com wrote: is there anything we need to change in the Neo4j REST API before 1.2 in order to be done here? I'm not sure, but I think the new plugins feature exposes URL's with hyphens instead of underscores. It seems the only thing required here are changes on the Python side? Yes. I'm trying update the code on each milestone. -- Javier de la Rosa http://versae.es ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user -- Javier de la Rosa http://versae.es ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user
Re: [Neo4j] Accessing node relationships via the Python REST client
All, is this ok now, and is there anything we need to change in the Neo4j REST API before 1.2 in order to be done here? It seems the only thing required here are changes on the Python side? Cheers, /peter neubauer GTalk: neubauer.peter Skype peter.neubauer Phone +46 704 106975 LinkedIn http://www.linkedin.com/in/neubauer Twitter http://twitter.com/peterneubauer http://www.neo4j.org - Your high performance graph database. http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party. On Tue, Dec 21, 2010 at 5:37 PM, Javier de la Rosa ver...@gmail.com wrote: On Tue, Dec 21, 2010 at 17:27, Peter Neubauer peter.neuba...@neotechnology.com wrote: Ahh, yes, this is due to the RESTies not wanting to see keys with whitespaces, so Jim and me changed it. Sorry for not communicating it! But the change affects to all keys in URL returned? I mean, all these keys must be changed to be underscored? # Order BREADTH_FIRST = breadth first DEPTH_FIRST = depth first # Return RETURN_ALL_NODES = all RETURN_ALL_BUT_START_NODE = all but start node # Uniqueness NODE_GLOBAL = node global NODE_PATH = node path NODE_RECENT = node recent RELATIONSHIP_GLOBAL = relationship global RELATIONSHIP_PATH = relationship path RELATIONSHIP_RECENT = relationship recent Cheers, /peter neubauer GTalk: neubauer.peter Skype peter.neubauer Phone +46 704 106975 LinkedIn http://www.linkedin.com/in/neubauer Twitter http://twitter.com/peterneubauer http://www.neo4j.org - Your high performance graph database. http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party. On Tue, Dec 21, 2010 at 1:20 PM, Javier de la Rosa ver...@gmail.com wrote: On Tue, Dec 21, 2010 at 02:31, Chris Diehl di...@alumni.cmu.edu wrote: For those of you using the Python REST client ( https://github.com/versae/neo4j-rest-client) with neo4j 1.2.M05, are you able to successfully access the relationships associated with a given node? When I tried this today with my data, I saw the following. Any thoughts as to what might be going on? I think is due to the change in the new server versions of the keys outgoing_relationships, ingoing_relationships and all_relationships instead of outgoing relationships, ingoing relationships and all relationships. I will take a look. Thanks for report the bug. Thanks, Chris n = gdb.node[252] n.properties {'fullyObserved': False, 'type': 'Email Address', 'address': 'tim.bel...@enron.com'} n.relationships.all() Traceback (most recent call last): File , line 1, in File neo4j_rest_client.py, line 430, in get_relationships url = self._node._dic[key] KeyError: 'all relationships' n.relationships.incoming() Traceback (most recent call last): File , line 1, in File neo4j_rest_client.py, line 430, in get_relationships url = self._node._dic[key] KeyError: 'incoming relationships' n.relationships.outgoing() Traceback (most recent call last): File , line 1, in File neo4j_rest_client.py, line 430, in get_relationships url = self._node._dic[key] KeyError: 'outgoing relationships' ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user -- Javier de la Rosa http://versae.es ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user -- Javier de la Rosa http://versae.es ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user
Re: [Neo4j] Accessing node relationships via the Python REST client
On Tue, Dec 28, 2010 at 17:05, Peter Neubauer peter.neuba...@neotechnology.com wrote: is there anything we need to change in the Neo4j REST API before 1.2 in order to be done here? I'm not sure, but I think the new plugins feature exposes URL's with hyphens instead of underscores. It seems the only thing required here are changes on the Python side? Yes. I'm trying update the code on each milestone. -- Javier de la Rosa http://versae.es ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user
Re: [Neo4j] Accessing node relationships via the Python REST client
On Tue, Dec 21, 2010 at 02:31, Chris Diehl di...@alumni.cmu.edu wrote: For those of you using the Python REST client ( https://github.com/versae/neo4j-rest-client) with neo4j 1.2.M05, are you able to successfully access the relationships associated with a given node? When I tried this today with my data, I saw the following. Any thoughts as to what might be going on? I think is due to the change in the new server versions of the keys outgoing_relationships, ingoing_relationships and all_relationships instead of outgoing relationships, ingoing relationships and all relationships. I will take a look. Thanks for report the bug. Thanks, Chris n = gdb.node[252] n.properties {'fullyObserved': False, 'type': 'Email Address', 'address': 'tim.bel...@enron.com'} n.relationships.all() Traceback (most recent call last): File , line 1, in File neo4j_rest_client.py, line 430, in get_relationships url = self._node._dic[key] KeyError: 'all relationships' n.relationships.incoming() Traceback (most recent call last): File , line 1, in File neo4j_rest_client.py, line 430, in get_relationships url = self._node._dic[key] KeyError: 'incoming relationships' n.relationships.outgoing() Traceback (most recent call last): File , line 1, in File neo4j_rest_client.py, line 430, in get_relationships url = self._node._dic[key] KeyError: 'outgoing relationships' ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user -- Javier de la Rosa http://versae.es ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user
[Neo4j] Accessing node relationships via the Python REST client
Hi All, For those of you using the Python REST client ( https://github.com/versae/neo4j-rest-client) with neo4j 1.2.M05, are you able to successfully access the relationships associated with a given node? When I tried this today with my data, I saw the following. Any thoughts as to what might be going on? Thanks, Chris n = gdb.node[252] n.properties {'fullyObserved': False, 'type': 'Email Address', 'address': 'tim.bel...@enron.com'} n.relationships.all() Traceback (most recent call last): File , line 1, in File neo4j_rest_client.py, line 430, in get_relationships url = self._node._dic[key] KeyError: 'all relationships' n.relationships.incoming() Traceback (most recent call last): File , line 1, in File neo4j_rest_client.py, line 430, in get_relationships url = self._node._dic[key] KeyError: 'incoming relationships' n.relationships.outgoing() Traceback (most recent call last): File , line 1, in File neo4j_rest_client.py, line 430, in get_relationships url = self._node._dic[key] KeyError: 'outgoing relationships' ___ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user