Re: [Neo4j] Neo4J 1.4.2 on Ubuntu 11.04

2011-10-22 Thread Peter Neubauer
Hi there,
did you manage to solve this and to give the memory mapping enough
space on your computer?

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              - NOSQL for the Enterprise.
http://startupbootcamp.org/    - Öresund - Innovation happens HERE.



On Thu, Oct 20, 2011 at 10:27 PM, fernandobr  wrote:
> Thanks for the answer. I'm using Neo4J embedded and I didn't change the
> default configuration. I just started the database by doing this:
> GraphDatabaseService targetDB = new
> EmbeddedGraphDatabase("/home/fmagalhaes/GraphDB/DistDB");
>
> I'm not creating a HashMap to set properties like described here:
> http://docs.neo4j.org/chunked/milestone/configuration-introduction.html
> http://docs.neo4j.org/chunked/milestone/configuration-introduction.html . Do
> you think this can be the problem?
>
> I'm running this program on a computer with 4 GB of memory and I'm working
> with a relatively small graph (database has around 20 MB).
>
> --
> View this message in context: 
> http://neo4j-community-discussions.438527.n3.nabble.com/Neo4J-1-4-2-on-Ubuntu-11-04-tp3439028p3439197.html
> Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
> ___
> 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] Iterable handling in unmanaged server extension

2011-10-22 Thread Peter Neubauer
Brendan,
the docs for the API are at
http://docs.neo4j.org/chunked/snapshot/rest-api.html, let us know if
this is good info for you.

Regarding the filtering, Jim, do you have any thoughts on this? It
seems that this looks a lot like the security rules that are in the
server, see 
http://docs.neo4j.org/chunked/snapshot/security-server.html#_server_authorization_rules
. In there, you can intercept access to the REST API faine-grained. If
you got access to the database instance, you could even look up nodes
and act according to the content, as you mentioned.

Would having access to a database instance from within a security rule
be a solution to your usecase?

Otherwise, yes, writing your own REST API is of course possible with
the unmanaged extensions. Let me know if I can help you with that.

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              - NOSQL for the Enterprise.
http://startupbootcamp.org/    - Öresund - Innovation happens HERE.



On Sun, Oct 23, 2011 at 2:19 AM, Brendan cheng  wrote:
> I'm trying to write my own restful api so that for each request a check of 
> password with usernode is needed and response will depends who the user is 
> and which method the user request.  Because your restful api only return node 
> relationship and path and their iterable, certain info inside the property 
> will not be able to be hidden for user, it seems there is only the unmanaged 
> way can achieve it. right? so I will have managed something similar to your 
> api.  Your restful api is quite complicated to me to follow. any doc of it?
>
> brendan
>
> -Original Message-
>
> From: Peter Neubauer
> Sent: 23 Oct 2011 01:09:45 GMT
> To: Neo4j user discussions
> Subject: Re: [Neo4j] Iterable handling in unmanaged server extension
>
> Brendan,
> are these iterables of Nodes, Relationships or Properties? If so, you
> should not need to do unmanaged extension but just write your server
> plugin, http://docs.neo4j.org/chunked/snapshot/server-plugins.html
>
> Otherwise, what kind of return are you looking for (maybe pseudo code)?
>
> 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� � � � � � ��- NOSQL for the Enterprise.
> http://startupbootcamp.org/ � �- �resund - Innovation happens HERE.
>
>
>
> On Sat, Oct 22, 2011 at 11:19 AM, Brendan cheng  wrote:
>>
>> Hi,
>> I'm trying to produce Iterable results from unmanaged server extension and 
>> not sure how to achieve it.In your code, this should already be done so. 
>> �Could you show me where the code is which I tried to find but failed?
>> Thanks in advance,
>> Brendan
>> ___
>> 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
> ___
> 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] Iterable handling in unmanaged server extension

2011-10-22 Thread Brendan cheng
I'm trying to write my own restful api so that for each request a check of 
password with usernode is needed and response will depends who the user is and 
which method the user request.  Because your restful api only return node 
relationship and path and their iterable, certain info inside the property will 
not be able to be hidden for user, it seems there is only the unmanaged way can 
achieve it. right? so I will have managed something similar to your api.  Your 
restful api is quite complicated to me to follow. any doc of it?

brendan

-Original Message-

From: Peter Neubauer
Sent: 23 Oct 2011 01:09:45 GMT
To: Neo4j user discussions
Subject: Re: [Neo4j] Iterable handling in unmanaged server extension

Brendan,
are these iterables of Nodes, Relationships or Properties? If so, you
should not need to do unmanaged extension but just write your server
plugin, http://docs.neo4j.org/chunked/snapshot/server-plugins.html

Otherwise, what kind of return are you looking for (maybe pseudo code)?

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� � � � � � ��- NOSQL for the Enterprise.
http://startupbootcamp.org/ � �- �resund - Innovation happens HERE.



On Sat, Oct 22, 2011 at 11:19 AM, Brendan cheng  wrote:
>
> Hi,
> I'm trying to produce Iterable results from unmanaged server extension and 
> not sure how to achieve it.In your code, this should already be done so. 
> �Could you show me where the code is which I tried to find but failed?
> Thanks in advance,
> Brendan
> ___
> 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
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Iterable handling in unmanaged server extension

2011-10-22 Thread Peter Neubauer
Brendan,
are these iterables of Nodes, Relationships or Properties? If so, you
should not need to do unmanaged extension but just write your server
plugin, http://docs.neo4j.org/chunked/snapshot/server-plugins.html

Otherwise, what kind of return are you looking for (maybe pseudo code)?

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              - NOSQL for the Enterprise.
http://startupbootcamp.org/    - Öresund - Innovation happens HERE.



On Sat, Oct 22, 2011 at 11:19 AM, Brendan cheng  wrote:
>
> Hi,
> I'm trying to produce Iterable results from unmanaged server extension and 
> not sure how to achieve it.In your code, this should already be done so.  
> Could you show me where the code is which I tried to find but failed?
> Thanks in advance,
> Brendan
> ___
> 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] WebAdmin - incorrect data

2011-10-22 Thread Peter Neubauer
Yeah,
sorry for that - the number of IDs in use is what is reported, we
should make this clear. Raised
https://github.com/neo4j/community/issues/72 for this - thanks!

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              - NOSQL for the Enterprise.
http://startupbootcamp.org/    - Öresund - Innovation happens HERE.



On Sat, Oct 22, 2011 at 11:33 AM, sometime  wrote:
> In the database is constantly adding / deleting relationships by REST (new
> relationships put in the index).
> Sometimes I stop the database and using the java to create / delete
> relationships  (the faster than REST) and put them in the index.
> I recently created a 600k relationships, but then I realized that they are
> wrong and removed - but the webadmin's statistics are not refreshed after
> deleting.
>
> --
> View this message in context: 
> http://neo4j-community-discussions.438527.n3.nabble.com/WebAdmin-incorrect-data-tp3443183p3443422.html
> Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
> ___
> 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] Gremlin help

2011-10-22 Thread Nuo Yan
Thanks very much Marko. I researched the query one step at a time and gained
much more knowledge about gremlin.

However, I wanted to do something a little bit different, instead of
comparing the "name" property of the children nodes to the source node, I
wanted to compare among the siblings of the children nodes (only first level
under the source node) and if there are duplicates, only keep the one with
the biggest degree of "bar" relationship. (The source node doesn't have a
"name" property).

For example,

v(1) --foo--> v(2) name: "abc" --bar--> (15 nodes)
v(1) --foo--> v(3) name: "abc --bar --> (20 nodes)
v(1) --foo--> v(4) name "xyz" --bar--> (15 nodes)
v(1) --foo--> v(5) name "xyz" --bar--> (25 nodes)

would become:

v(1) --foo--> v(3) name: "abc --bar --> (20 nodes)
v(1) --foo--> v(5) name "xyz" --bar--> (25 nodes)

So instead of doing

g.v(1).sideEffect{x =
it.getProperty('name')}.out('foo').filter{it.getProperty('name').equals(x)}

I proposed doing:

g.v(1).out("foo").transform{[it, it.name,
it.out("bar").count]}.aggregate.cap

to get an array of first level children nodes, their names, and degree of
"bar" edges like [v(2), "abc", 15], [v(3), "abc", 20], [v(4), "xyz", 15],
[v(5), "xyz", 20]

And then I can sort the array by the name property, and iterate through that
array to delete nodes that have a smaller count based on the count value
specified in each sub array.

But since my gremlin knowledge is still very limited, before digging too
much into this proposed solution I want to verify with you that it would
work and see if you have better or easier approach to do it (i.e. maybe one
simple method that I can make use that I'm not aware of).  Thanks very much
again.


On Sat, Oct 22, 2011 at 9:40 AM, Marko Rodriguez wrote:

> Hi,
>
> > Currently I'm doing the following in my own code with multiple requests
> to the standalone neo4j server. I wonder if it's possible to achieve in one
> gremlin query/script so that I can post the gremlin query to the server as 1
> request and done. What I'm trying to achieve is:
> >
> > Start from one given node (e.g. v1), get all of the nodes connected
> through a given type of relationship (e.g. relationship "foo"), within all
> of these nodes, see if their "name" property has the same value, and if so,
> delete the node (and the "foo" relationship connected to it) with smaller
> outgoing degree (on a specific type of relationship, say, "bar"). If there
> are more than two nodes with the same "name" property, only keep the one
> with biggest outgoing degree (on type "bar").
>
>
> The query below is to warm you up. It will delete all vertices with same
> property value as source vertex that are 'foo' related to source vertex.
> Given that you are mutating the graph, you will want to deal with
> transaction buffers so you don't do one transaction per mutations:
>https://github.com/tinkerpop/blueprints/wiki/Graph-Transactions
>
> g.v(1).sideEffect{x =
> it.getProperty('name')}.out('foo').filter{it.getProperty('name').equals(x)}.sideEffect{g.removeVertex(it)}
>
> -
>
> To do the stuff with the smaller counts, etc. You can do:
>
> g.v(1).sideEffect{x =
> it.getProperty('name')}.out('foo').filter{it.getProperty('name').equals(x)}.transform{[it,
> it.outE('bar').count()]}.filter{it[1] > 0}.aggregate.cap.next().sort{a,b ->
> b[1] <=> a[1]}.eachWithIndex{a,i -> if(i > 0) g.removeVertex(a[0])}
>
> There you go! One big fatty Gremlin query to solve your problem.
>
> I would recommend going through each step and seeing what it returns so you
> understand what is going on Again, given that you are mutating the
> graph, be sure to be wise about transactions.
>
> Enjoy!,
> Marko.
>
> http://markorodriguez.com
>
> ___
> 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] Possible problem with LuceneBatchInserterIndex

2011-10-22 Thread Peter Neubauer
Chris,
glad to hear it worked out! If you have any input on how to improve
the manual, let us know as Disqus comments on the relevant pages,
would be great to make sure you don't get lost next time!

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              - NOSQL for the Enterprise.
http://startupbootcamp.org/    - Öresund - Innovation happens HERE.



On Sat, Oct 22, 2011 at 3:39 PM, Chris Wroe  wrote:
> Peter,
>
>>Maybe you can try to assign
>>the node-ids you got in the node insert phase directly to your
>>relationship file so you can skip index lookups and just write when
>>inserting relationships?
>
> I did get the index cache working ok with the LuceneBatchInserterIndex in
> the end. I'll try and post the trivial change as a patch file on github to
> see what you guys think.
> The index cache needed quite a bit of memory, so in the end I just created a
> simpler map of entity primary key to node id.
>
> I think the thing that really speeded up adding relationships was increasing
> "neostore.relationshipstore.db.mapped_memory" in the configuration to 1Gb or
> more. In hindsight I should have been able to work that out from the manual.
>
> I'm really impressed with what you are doing with Neo4J. I'm experimenting
> with using it to store something called the Unified Medical Language
> System.
> Now that I have the core of it loaded, I hope to do some interesting graph
> based queries on it.
>
> Thanks for your help.
>
> Chris
> ___
> 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] Gremlin help

2011-10-22 Thread Marko Rodriguez
Hi,

> Currently I'm doing the following in my own code with multiple requests to 
> the standalone neo4j server. I wonder if it's possible to achieve in one 
> gremlin query/script so that I can post the gremlin query to the server as 1 
> request and done. What I'm trying to achieve is:
> 
> Start from one given node (e.g. v1), get all of the nodes connected through a 
> given type of relationship (e.g. relationship "foo"), within all of these 
> nodes, see if their "name" property has the same value, and if so, delete the 
> node (and the "foo" relationship connected to it) with smaller outgoing 
> degree (on a specific type of relationship, say, "bar"). If there are more 
> than two nodes with the same "name" property, only keep the one with biggest 
> outgoing degree (on type "bar").


The query below is to warm you up. It will delete all vertices with same 
property value as source vertex that are 'foo' related to source vertex. Given 
that you are mutating the graph, you will want to deal with transaction buffers 
so you don't do one transaction per mutations:
https://github.com/tinkerpop/blueprints/wiki/Graph-Transactions

g.v(1).sideEffect{x = 
it.getProperty('name')}.out('foo').filter{it.getProperty('name').equals(x)}.sideEffect{g.removeVertex(it)}

-

To do the stuff with the smaller counts, etc. You can do:

g.v(1).sideEffect{x = 
it.getProperty('name')}.out('foo').filter{it.getProperty('name').equals(x)}.transform{[it,
 it.outE('bar').count()]}.filter{it[1] > 0}.aggregate.cap.next().sort{a,b -> 
b[1] <=> a[1]}.eachWithIndex{a,i -> if(i > 0) g.removeVertex(a[0])}

There you go! One big fatty Gremlin query to solve your problem. 

I would recommend going through each step and seeing what it returns so you 
understand what is going on Again, given that you are mutating the graph, 
be sure to be wise about transactions.

Enjoy!,
Marko.

http://markorodriguez.com

___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Possible problem with LuceneBatchInserterIndex

2011-10-22 Thread Chris Wroe
Peter,

>Maybe you can try to assign
>the node-ids you got in the node insert phase directly to your
>relationship file so you can skip index lookups and just write when
>inserting relationships?

I did get the index cache working ok with the LuceneBatchInserterIndex in
the end. I'll try and post the trivial change as a patch file on github to
see what you guys think.
The index cache needed quite a bit of memory, so in the end I just created a
simpler map of entity primary key to node id.

I think the thing that really speeded up adding relationships was increasing
"neostore.relationshipstore.db.mapped_memory" in the configuration to 1Gb or
more. In hindsight I should have been able to work that out from the manual.

I'm really impressed with what you are doing with Neo4J. I'm experimenting
with using it to store something called the Unified Medical Language
System.
Now that I have the core of it loaded, I hope to do some interesting graph
based queries on it.

Thanks for your help.

Chris
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] WebAdmin - incorrect data

2011-10-22 Thread sometime
In the database is constantly adding / deleting relationships by REST (new
relationships put in the index).
Sometimes I stop the database and using the java to create / delete
relationships  (the faster than REST) and put them in the index.
I recently created a 600k relationships, but then I realized that they are
wrong and removed - but the webadmin's statistics are not refreshed after
deleting.

--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/WebAdmin-incorrect-data-tp3443183p3443422.html
Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


[Neo4j] Iterable handling in unmanaged server extension

2011-10-22 Thread Brendan cheng

Hi,
I'm trying to produce Iterable results from unmanaged server extension and not 
sure how to achieve it.In your code, this should already be done so.  Could you 
show me where the code is which I tried to find but failed?
Thanks in advance,
Brendan   
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] WebAdmin - incorrect data

2011-10-22 Thread Peter Neubauer
Hi there,
The Webadmin is flowing the jmx value for the number of ids in use, which is
higher than the actual number if you have deleted things. Exact numbers
would require more aggressive reuse of ids, which is in the roadmap. Your
traversal numbers are right. Could you please raise an issue to have better
explanation in Webadmin on this?
On Oct 22, 2011 10:27 AM, "sometime"  wrote:

> WebAdmin shows me the following information:
> 1204697 nodes
> 6113395 relationships
> 3 relationship types
>
> I run this code:
>
> GraphDatabaseService graphDb = new
> EmbeddedGraphDatabase("/neo4j-enterprise-1.4.1/data/graph.db");
>
> int nodes = 0;
> int relationships = 0;
> List types = new ArrayList();
> for(Node n: graphDb.getAllNodes())
> {
>nodes++;
>
>for (Relationship r : n.getRelationships(Direction.OUTGOING))
>{
>relationships++;
>String typeName = r.getType().name();
>if (!types.contains(typeName)) types.add(typeName);
>}
> }
>
> System.out.println(nodes);
> System.out.println(relationships);
> for(String t : types) System.out.println(t);
>
> graphDb.shutdown();
>
>
> and result:
> 1204646 nodes
> 5467850 relationships
> KNOWS, MEMBEROF types (only 2 types, not 3)
>
> Why incorrect data? I am very important to show the correct data webadmin!
>
> What should I do to show the correct date webadmin?
>
> --
> View this message in context:
> http://neo4j-community-discussions.438527.n3.nabble.com/WebAdmin-incorrect-data-tp3443183p3443183.html
> Sent from the Neo4j Community Discussions mailing list archive at
> Nabble.com.
> ___
> 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


[Neo4j] WebAdmin - incorrect data

2011-10-22 Thread sometime
WebAdmin shows me the following information:
1204697 nodes
6113395 relationships
3 relationship types

I run this code:

GraphDatabaseService graphDb = new
EmbeddedGraphDatabase("/neo4j-enterprise-1.4.1/data/graph.db");

int nodes = 0;
int relationships = 0;
List types = new ArrayList();
for(Node n: graphDb.getAllNodes())
{
nodes++;

for (Relationship r : n.getRelationships(Direction.OUTGOING))
{
relationships++;
String typeName = r.getType().name();
if (!types.contains(typeName)) types.add(typeName);
}
}

System.out.println(nodes);
System.out.println(relationships);
for(String t : types) System.out.println(t);

graphDb.shutdown();


and result:
1204646 nodes
5467850 relationships
KNOWS, MEMBEROF types (only 2 types, not 3)

Why incorrect data? I am very important to show the correct data webadmin!

What should I do to show the correct date webadmin?

--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/WebAdmin-incorrect-data-tp3443183p3443183.html
Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Gremlin help

2011-10-22 Thread Peter Neubauer
Nuo,
In principle this looks ok except you will have to take care that you are
not deleting nodes that are in the current traversal and would recursively
change your traversal result.

Dunno the Groovy expression for this, but if you can do it in Java, you can
do it in Groovy, for instance
http://docs.neo4j.org/chunked/snapshot/gremlin-plugin.html#rest-api-send-an-arbitrary-groovy-script---lucene-sorting


HTH

/peter

On Friday, October 21, 2011, Nuo Yan  wrote:
> Hi Marko and Gremlin gurus:
>
> Currently I'm doing the following in my own code with multiple requests to
> the standalone neo4j server. I wonder if it's possible to achieve in one
> gremlin query/script so that I can post the gremlin query to the server as
1
> request and done. What I'm trying to achieve is:
>
> Start from one given node (e.g. v1), get all of the nodes connected
through
> a given type of relationship (e.g. relationship "foo"), within all of
these
> nodes, see if their "name" property has the same value, and if so, delete
> the node (and the "foo" relationship connected to it) with smaller
outgoing
> degree (on a specific type of relationship, say, "bar"). If there are more
> than two nodes with the same "name" property, only keep the one with
biggest
> outgoing degree (on type "bar").
>
>
> For example, for the following graph:
>
> v1 --foo--> v2("name" => "abc") --"bar"--> (15 nodes)
> v1 --foo--> v3("name" => "abc") --"bar"--> (5 nodes)
> v1 --foo--> v4("name" => "abc") --"bar"--> (8 nodes)
> v1 --foo--> v5("name" => "xyz")--"bar"-->(16 nodes)
> v1 --foo--> v6("name" => "abc")--"not_bar"--> (20 nodes)
>
> Ideally, after running the gremlin script, it should be:
>
> v1 --foo--> v2("name" => "abc") --"bar"--> (15 nodes)
> v1 --foo--> v5("name" => "xyz")--"bar"-->(16 nodes)
> v1 --foo--> v6("name" => "abc")--"not_bar"--> (20 nodes)
>
> with v3 and v4 (and the "foo" relationships connecting them to v1) deleted
> because they have the same "name" attributes with v2 but a smaller degree
> with outgoing "bar" relationship.
>
> It this possible to achieve relatively easily with Gremlin?
> ___
> Neo4j mailing list
> User@lists.neo4j.org
> https://lists.neo4j.org/mailman/listinfo/user
>

-- 
Sent from Gmail Mobile
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user