Re: [Neo4j] Node#getRelationshipTypes

2011-08-02 Thread Niels Hoogeveen

I would like to make a suggestion that would both address my feature request 
and increase performance of the database.

Right now the NodeRecord (org.neo4j.kernel.impl.nioneo.store.NodeRecord) 
contains the ID of the first Relationship, while the RelationshipRecord contain 
the ID's of the previous and next relationship for both sides of the 
relationship.

My suggestion is as follows:

Create a new store:

noderelationshiptypestore.db

The layout of this store is given by the NodeRelationshipTypeRecord:

id
previousrelationshiptype
nextrelationshiptype
firstrelationship

The NodeRecord would now need to point to the first outgoing 
NodeRelationshipType and to the first incoming NodeRelationshipType instead of 
to the first Relationship.

On insert of a Relationship, one side of the relationship will update the store 
from the outgoing side, the other side will update the store for the incoming 
side.

I will list the steps to take here for the outgoing side (the incoming side is 
almost identical).

>From the NodeRecord getFirstNodeRelationType (outgoing).

Keep following NextRelationshipType until the desired record is found. If no 
record exists, create one, make the current FirstNodeRelationshipType in the 
NodeRecord (if it exists) the NextRelationshipType of the created 
NodeRelationshipType (and make the created one the previous of the current one) 
and make the created NodeRelationshipType the FirstNodeRelationshipType in the 
NodeRecord.

In other words: find the NodeRelationshipTypeRecord in the linked list. If none 
exists, create a NodeRelationshipTypeRecord, prepend it to the existing list 
and change the entry point in the NodeRecord.

We now have found the requested NodeRelationshipTypeRecord. 

>From NodeRelationshipTypeRecord getFirstRelationship.

Create a new RelationshipRecord and make it the FirstRelationship in the 
NodeRelationshipTypeRecord. 

Make the old first RelationshipRecord (if it exists) the nextRelationship of 
the new first RelationshipRecord and make the new first RelationshipRecord the 
previous of the old first RelationshipRecord.

In other words: prepend a new RelationshipRecord to the existing list of 
Relationships and change the entry point in the NodeRelationshipTypeRecord.

Do the same for the incoming side (except for the creation of the 
RelationshipRecord, we only need one of those).

Instead of a linked list of Relationships per Node we now have two linked lists 
of RelationshipTypes per Node (one incoming, one outgoing), with a linked list 
of Relationships per NodeRelationshipType.

With this approach only those Relationships need to be read that match the 
RelationshipType and Direction given. 

Worst case this approach leads to an extra read operation per RelationshipType: 

Worst case example 1: Retrieve all Relationships, regardless of Relationship or 
Direction. Here we have extra reads for all NodeRelationshipType records. If 
the number of Relationships per NodeRelationshipType is equal to 1, we have 
twice as many reads.

Worst case example 2: If we retrieve Relationships by RelationshipType by 
Direction, we have at most one extra read to fetch the Relationship, and only 
in the case where the number of Relationships per NodeRelationshipType is equal 
to 1 and the requested RelationshipType happens to be the last in the list.

On average partitioning Relationships the way suggested here improves 
performance, while the worst case situations only take a constant time hit of 
no more than a factor 2. On top of that the absolute worst case situation, 
where the performance is reduced by a factor 2 is likely to be uncommon in 
practical Neo4j applications. 

Certainly there will be situations where users want to iterate over all 
relationships of one particular node, which will still be very fast. It is much 
less likely that users would frequently want to iterate over all relationships 
of a huge number of nodes (where all those relationships happen to be 
functional as well). Most traversals will be much more discriminate and be 
based on certain particular RelationshipType where the performance penalty is 
at most one read operation per RelationshipType, but on average the number of 
reads will be lower, certainly if there is more than one Relationship 
associated to the NodeRelationshipType.The potential performance increase can 
be enormous, especially if we want to fetch a relationship of a 
RelationshipType that has few associated Relationships, while some other 
NodeRelationshipType has a huge number of Reltionships.Best case scenario: A 
node has one Relationship of type A and 1 million Relationships of type B and 
we want to fetch t
 hat one Relationship of type A. In the current situation we have to do 
1,000,001 reads to fetch that one Relationship. With this proposal this would 
be reduced to at most 3 reads for that particular request.
Altogether this proposal has advantages in most practical situations. In some 
corner cases the perform

Re: [Neo4j] Composable traversals

2011-08-02 Thread Niels Hoogeveen

It looks like this does the same I suggested. It's a bit clunkier, but I 
understand you don't want to changed the Node interface. OTOH is there any 
reason not to extend the Node interface, after all it is only one "extends" 
more? Since Nodes are all created in the neo4j-kernel component, there is no 
real reason to maintain strict binary backwards compatibility between versions, 
or do you expect people having projects with two separate neo4j-kernel jars 
having different versions?
Niels

> Date: Tue, 2 Aug 2011 23:05:17 +0200
> From: matt...@neotechnology.com
> To: user@lists.neo4j.org
> Subject: Re: [Neo4j] Composable traversals
> 
> Cool. To not mess around with interfaces too much I'm thinking of having:
> 
> TraversalDescription#traverse( Node startNode, Node...
> additionalStartNodes );
> TraversalDescription#traverse( Path startPath, Path...
> additionalStartPaths );
> TraversalDescription#traverse( Iterable startPaths );
> 
> that would be rather similar, wouldn't it?
> 
> 2011/7/30 Niels Hoogeveen 
> 
> >
> > I would be all for it if this could become part of 1.5.
> > I am willing to put time into this.
> > > Date: Sat, 30 Jul 2011 11:33:01 +0200
> > > From: matt...@neotechnology.com
> > > To: user@lists.neo4j.org
> > > Subject: Re: [Neo4j] Composable traversals
> > >
> > > Yes, FYI that's the exact thing we've been discussing :)
> > >
> > > 2011/7/29 Niels Hoogeveen 
> > >
> > > >
> > > > Great, I would much rather see this become part of the core API than
> > have
> > > > this as part of the Enhanced API.
> > > > To make things work correctly, one important change to core is needed:
> > The
> > > > Node interface needs to extends Traverser (the interface in
> > > > org.neo4j.graphdb.traversal, not the one in org.neo4j.graphdb).
> > > > This is actually not a big deal. There Traverser interface supports
> > three
> > > > methods:
> > > > Iterator iterator() [return 1 path with 1 element in the path,
> > being
> > > > the node itself]Iterable nodes() [return an iterable over the
> > node
> > > > itself]Iterable relationships() [return an empty
> > iterable]
> > > > With that addition, it's not all too difficult to enhance the current
> > > > implementation of Traverser. It only adds one more iteration level over
> > the
> > > > current implementation. Instead of having one start node, we now have
> > > > multiple start paths. When returning values from the Traverser, the
> > start
> > > > paths and the result paths need to be concatenated.
> > > > In the new scenario, all "old" traverse() methods can remain the same,
> > > > since Node becomes a Traverser, so those methods are just special cases
> > > > where Iterable consists of 1 path, with just 1 element.
> > > > Niels
> > > > > Date: Fri, 29 Jul 2011 18:36:28 +0200
> > > > > From: matt...@neotechnology.com
> > > > > To: user@lists.neo4j.org
> > > > > Subject: Re: [Neo4j] Composable traversals
> > > > >
> > > > > There have been thoughts a long while to make something like this
> > with
> > > > the
> > > > > traversal framework, but time has never been allocated to evolve it.
> > I'm
> > > > > adding stuff to the framework in a side track and will surely add
> > some
> > > > > aspect of composable traversers also.
> > > > >
> > > > > 2011/7/29 Niels Hoogeveen 
> > > > >
> > > > > >
> > > > > > I'd like to take a stab at implementing traversals in the Enhanced
> > API.
> > > > One
> > > > > > of the things I'd like to do, is to make traversals composable.
> > > > > >
> > > > > > Right now a Traverser is created by either calling the traverse
> > method
> > > > on
> > > > > > Node, or to call the traverse(Node) method on TraversalDescription.
> > > > > >
> > > > > > This makes traversals inherently non-composable, so we can't define
> > a
> > > > > > single traversal that returns the parents of all our friends.
> > > > > >
> > > > > > To make Traversers composable we need a function:
> > > > > >
> > > > > > Traverser traverse(Traverser, TraversalDescription)
> > > > > >
> > > > > > My take on it is to make Element (which is a superinterface of
> > Node)
> > > > into a
> > > > > > Traverser.
> > > > > >
> > > > > > Traverser is basically another name for Iterable.
> > > > > >
> > > > > > Every Node (or more generally every Element) can be seen as an
> > > > > > Iterabe, returning a single Path, which contains a single
> > > > > > path-element, the Node/Element itself.
> > > > > >
> > > > > > Composing traversals would entail the concatenation of the paths
> > > > returned
> > > > > > with the paths supplied, so when we ask for the parents of all our
> > > > friends,
> > > > > > the returned paths would take the form:
> > > > > >
> > > > > > Node --FRIEND--> Node --> PARENT --> Node
> > > > > >
> > > > > > Niels
> > > > > >
> > > > > > ___
> > > > > > Neo4j mailing list
> > > > > > User@lists.neo4j.org
> > > > > > https://lists.neo4j.org/mailman/listinfo/user
> > > > > >
> > > > >
> > > > 

Re: [Neo4j] Composable traversals

2011-08-02 Thread Mattias Persson
Cool. To not mess around with interfaces too much I'm thinking of having:

TraversalDescription#traverse( Node startNode, Node...
additionalStartNodes );
TraversalDescription#traverse( Path startPath, Path...
additionalStartPaths );
TraversalDescription#traverse( Iterable startPaths );

that would be rather similar, wouldn't it?

2011/7/30 Niels Hoogeveen 

>
> I would be all for it if this could become part of 1.5.
> I am willing to put time into this.
> > Date: Sat, 30 Jul 2011 11:33:01 +0200
> > From: matt...@neotechnology.com
> > To: user@lists.neo4j.org
> > Subject: Re: [Neo4j] Composable traversals
> >
> > Yes, FYI that's the exact thing we've been discussing :)
> >
> > 2011/7/29 Niels Hoogeveen 
> >
> > >
> > > Great, I would much rather see this become part of the core API than
> have
> > > this as part of the Enhanced API.
> > > To make things work correctly, one important change to core is needed:
> The
> > > Node interface needs to extends Traverser (the interface in
> > > org.neo4j.graphdb.traversal, not the one in org.neo4j.graphdb).
> > > This is actually not a big deal. There Traverser interface supports
> three
> > > methods:
> > > Iterator iterator() [return 1 path with 1 element in the path,
> being
> > > the node itself]Iterable nodes() [return an iterable over the
> node
> > > itself]Iterable relationships() [return an empty
> iterable]
> > > With that addition, it's not all too difficult to enhance the current
> > > implementation of Traverser. It only adds one more iteration level over
> the
> > > current implementation. Instead of having one start node, we now have
> > > multiple start paths. When returning values from the Traverser, the
> start
> > > paths and the result paths need to be concatenated.
> > > In the new scenario, all "old" traverse() methods can remain the same,
> > > since Node becomes a Traverser, so those methods are just special cases
> > > where Iterable consists of 1 path, with just 1 element.
> > > Niels
> > > > Date: Fri, 29 Jul 2011 18:36:28 +0200
> > > > From: matt...@neotechnology.com
> > > > To: user@lists.neo4j.org
> > > > Subject: Re: [Neo4j] Composable traversals
> > > >
> > > > There have been thoughts a long while to make something like this
> with
> > > the
> > > > traversal framework, but time has never been allocated to evolve it.
> I'm
> > > > adding stuff to the framework in a side track and will surely add
> some
> > > > aspect of composable traversers also.
> > > >
> > > > 2011/7/29 Niels Hoogeveen 
> > > >
> > > > >
> > > > > I'd like to take a stab at implementing traversals in the Enhanced
> API.
> > > One
> > > > > of the things I'd like to do, is to make traversals composable.
> > > > >
> > > > > Right now a Traverser is created by either calling the traverse
> method
> > > on
> > > > > Node, or to call the traverse(Node) method on TraversalDescription.
> > > > >
> > > > > This makes traversals inherently non-composable, so we can't define
> a
> > > > > single traversal that returns the parents of all our friends.
> > > > >
> > > > > To make Traversers composable we need a function:
> > > > >
> > > > > Traverser traverse(Traverser, TraversalDescription)
> > > > >
> > > > > My take on it is to make Element (which is a superinterface of
> Node)
> > > into a
> > > > > Traverser.
> > > > >
> > > > > Traverser is basically another name for Iterable.
> > > > >
> > > > > Every Node (or more generally every Element) can be seen as an
> > > > > Iterabe, returning a single Path, which contains a single
> > > > > path-element, the Node/Element itself.
> > > > >
> > > > > Composing traversals would entail the concatenation of the paths
> > > returned
> > > > > with the paths supplied, so when we ask for the parents of all our
> > > friends,
> > > > > the returned paths would take the form:
> > > > >
> > > > > Node --FRIEND--> Node --> PARENT --> Node
> > > > >
> > > > > Niels
> > > > >
> > > > > ___
> > > > > Neo4j mailing list
> > > > > User@lists.neo4j.org
> > > > > https://lists.neo4j.org/mailman/listinfo/user
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Mattias Persson, [matt...@neotechnology.com]
> > > > Hacker, Neo Technology
> > > > www.neotechnology.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
> > >
> >
> >
> >
> > --
> > Mattias Persson, [matt...@neotechnology.com]
> > Hacker, Neo Technology
> > www.neotechnology.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/list

Re: [Neo4j] How to run webadmin for high availability neo4j custer?

2011-08-02 Thread Andreas Kollegger
Ah, you're using Neo4j as an embedded database but using High Availability. Is 
that correct?

Webadmin is not currently available outside of the server. It's technically 
possible, but not easily separable at the moment. 

-Andreas

On Aug 2, 2011, at 1:59 PM, dhsieh wrote:

> I am not clear how HA clsuter configuration inlcudes other neo4j property
> files so that webserver can start since in your wiki the recommended way to
> start HA clsuter includes only "ha-server1.conf" as shown below:
> 
> $ java -cp  StartLocalHaDb hadb1
> ha-server1.conf
> 
> --
> View this message in context: 
> http://neo4j-community-discussions.438527.n3.nabble.com/How-to-run-webadmin-for-high-availability-neo4j-custer-tp3216706p3220207.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] Node#getRelationshipTypes

2011-08-02 Thread Niels Hoogeveen

Building an API on top of Neo4j of course pushes the standard API to its 
limits. So for that matter it is already a good exercise.
Any chance this feature request will find its way into 1.5?
Niels

> Date: Tue, 2 Aug 2011 22:33:03 +0200
> From: matt...@neotechnology.com
> To: user@lists.neo4j.org
> Subject: Re: [Neo4j] Node#getRelationshipTypes
> 
> Those methods will of course be more efficient if implemented in the kernel
> compared to iterating through all relationships if the whole relationship
> chain have already been loaded for that node, otherwise it will require a
> full iteration (or at least making sure the whole chain have been loaded).
> I've never found a use case for it myself and this is the first I've heard.
> 
> 2011/8/1 Niels Hoogeveen 
> 
> >
> > I have two specific use cases for these methods:
> > I'd like to present a node with the property types (names) it has content
> > for and with the relationship types it has relationships for, while loading
> > those properties/relationships on demand (ie. click here to see details).
> > This can be done for properties: there is a getPropertyKeys() method, but
> > there is no getRelationshipTypes() method.
> > The other use case has to do with the Enhanced API. There I want to have
> > pluggable relationships and properties. With respect to relationships there
> > are already three implementations: the regular Relationship, SortedRelations
> > (which use an in-graph Btree for storage) and HyperRelationships which allow
> > n-ary relationships.
> > Every Element in Enhanced API has a getRelationships() method, much like
> > the getRelationships() method in Node, which should return every
> > relationship attached to an Element, irrespective of its implementation.
> > Right now the Element implementation has to perform the logic to distinguish
> > which relationship is used for what implementation (under the hood it all
> > works using normal Relationships). It would be much more elegant to iterate
> > over the RelationshipTypes and dispatch the getRelationships() method to the
> > appropriate RelationshipType implementations. That way the logic for
> > SortedRelationships, HyperRelationships remains in their associated classes
> > and is not spread around the implementation.
> >
> > Niels
> > > From: michael.hun...@neotechnology.com
> > > Date: Sun, 31 Jul 2011 23:20:50 +0200
> > > To: user@lists.neo4j.org
> > > Subject: Re: [Neo4j] Node#getRelationshipTypes
> > >
> > > Imho it would have to iterate as well.
> > >
> > > As the type is stored with the relationship record and so can only be
> > accessed after having read it.
> > >
> > > It might be to have some minimal performance improvements that
> > relationships would not have to be fully loaded, nor put into the cache for
> > that. But this is always a question of the use-case. What will be done next
> > with those rel-types.
> > >
> > > What was the use-case for this operation again?
> > >
> > > Cheers
> > >
> > > Michael
> > >
> > > Am 31.07.2011 um 18:59 schrieb Niels Hoogeveen:
> > >
> > > >
> > > > Good point.
> > > > It could for all practical purposes even be Iterable
> > so they can be lazily fetched, as long as the underlying implementation
> > makes certain that any iteration of the RelationshipTypes forms a set (no
> > duplicates).
> > > > There is no need to have RelationshipTypes in any particular order, and
> > if that is needed in the application, they can usually be sorted locally
> > since Nodes will generally have associated Relationships of only a handful
> > of RelationshipTypes.
> > > >
> > > > That said, the more important question is, if the Neo4j store can
> > produce this meta-information. For sparsely connected nodes, it is possible
> > to iterate over the relationships and return the set of RelationshipTypes,
> > but this is not a proper solution when nodes are densely connected. So there
> > is no general solution for this question yet.
> > > > Niels
> > > >
> > > >> From: j...@neotechnology.com
> > > >> Date: Sun, 31 Jul 2011 17:29:29 +0100
> > > >> To: user@lists.neo4j.org
> > > >> Subject: Re: [Neo4j] Node#getRelationshipTypes
> > > >>
> > > >> Hi Niels,
> > > >>
> > > >> Ignoring the operational use for getting relationship types, I do
> > think these should be generalised from:
> > > >>
> > > >>> RelationshipType[] getRelationshipTypes();
> > > >>> RelationshipType[] getRelationshipTypes(Direction);
> > > >>
> > > >> to:
> > > >>
> > > >> Set getRelationshipTypes();
> > > >> Set getgetRelationshipTypes(Direction);
> > > >>
> > > >> Unless you need the ordering and you think the overhead of creating a
> > some kind of Set is too onerous from a performance point of view.
> > > >>
> > > >> Jim
> > > >> ___
> > > >> Neo4j mailing list
> > > >> User@lists.neo4j.org
> > > >> https://lists.neo4j.org/mailman/listinfo/user
> > > >
> > > > ___
> > > > Neo4j mailing list
> > > > Use

Re: [Neo4j] How to run webadmin for high availability neo4j custer?

2011-08-02 Thread dhsieh
I am not clear how HA clsuter configuration inlcudes other neo4j property
files so that webserver can start since in your wiki the recommended way to
start HA clsuter includes only "ha-server1.conf" as shown below:

$ java -cp  StartLocalHaDb hadb1
ha-server1.conf

--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/How-to-run-webadmin-for-high-availability-neo4j-custer-tp3216706p3220207.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] Node#getRelationshipTypes

2011-08-02 Thread Mattias Persson
Those methods will of course be more efficient if implemented in the kernel
compared to iterating through all relationships if the whole relationship
chain have already been loaded for that node, otherwise it will require a
full iteration (or at least making sure the whole chain have been loaded).
I've never found a use case for it myself and this is the first I've heard.

2011/8/1 Niels Hoogeveen 

>
> I have two specific use cases for these methods:
> I'd like to present a node with the property types (names) it has content
> for and with the relationship types it has relationships for, while loading
> those properties/relationships on demand (ie. click here to see details).
> This can be done for properties: there is a getPropertyKeys() method, but
> there is no getRelationshipTypes() method.
> The other use case has to do with the Enhanced API. There I want to have
> pluggable relationships and properties. With respect to relationships there
> are already three implementations: the regular Relationship, SortedRelations
> (which use an in-graph Btree for storage) and HyperRelationships which allow
> n-ary relationships.
> Every Element in Enhanced API has a getRelationships() method, much like
> the getRelationships() method in Node, which should return every
> relationship attached to an Element, irrespective of its implementation.
> Right now the Element implementation has to perform the logic to distinguish
> which relationship is used for what implementation (under the hood it all
> works using normal Relationships). It would be much more elegant to iterate
> over the RelationshipTypes and dispatch the getRelationships() method to the
> appropriate RelationshipType implementations. That way the logic for
> SortedRelationships, HyperRelationships remains in their associated classes
> and is not spread around the implementation.
>
> Niels
> > From: michael.hun...@neotechnology.com
> > Date: Sun, 31 Jul 2011 23:20:50 +0200
> > To: user@lists.neo4j.org
> > Subject: Re: [Neo4j] Node#getRelationshipTypes
> >
> > Imho it would have to iterate as well.
> >
> > As the type is stored with the relationship record and so can only be
> accessed after having read it.
> >
> > It might be to have some minimal performance improvements that
> relationships would not have to be fully loaded, nor put into the cache for
> that. But this is always a question of the use-case. What will be done next
> with those rel-types.
> >
> > What was the use-case for this operation again?
> >
> > Cheers
> >
> > Michael
> >
> > Am 31.07.2011 um 18:59 schrieb Niels Hoogeveen:
> >
> > >
> > > Good point.
> > > It could for all practical purposes even be Iterable
> so they can be lazily fetched, as long as the underlying implementation
> makes certain that any iteration of the RelationshipTypes forms a set (no
> duplicates).
> > > There is no need to have RelationshipTypes in any particular order, and
> if that is needed in the application, they can usually be sorted locally
> since Nodes will generally have associated Relationships of only a handful
> of RelationshipTypes.
> > >
> > > That said, the more important question is, if the Neo4j store can
> produce this meta-information. For sparsely connected nodes, it is possible
> to iterate over the relationships and return the set of RelationshipTypes,
> but this is not a proper solution when nodes are densely connected. So there
> is no general solution for this question yet.
> > > Niels
> > >
> > >> From: j...@neotechnology.com
> > >> Date: Sun, 31 Jul 2011 17:29:29 +0100
> > >> To: user@lists.neo4j.org
> > >> Subject: Re: [Neo4j] Node#getRelationshipTypes
> > >>
> > >> Hi Niels,
> > >>
> > >> Ignoring the operational use for getting relationship types, I do
> think these should be generalised from:
> > >>
> > >>> RelationshipType[] getRelationshipTypes();
> > >>> RelationshipType[] getRelationshipTypes(Direction);
> > >>
> > >> to:
> > >>
> > >> Set getRelationshipTypes();
> > >> Set getgetRelationshipTypes(Direction);
> > >>
> > >> Unless you need the ordering and you think the overhead of creating a
> some kind of Set is too onerous from a performance point of view.
> > >>
> > >> Jim
> > >> ___
> > >> 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
>



-- 
Mattias Persson, [matt...@neotechnology.com]
Hacker, Neo Technology
www.neotechnology.com
___
Neo4j mailing list
User@lists.neo4j.org
htt

Re: [Neo4j] how to scale and view or generate reports for complex graphs?

2011-08-02 Thread sambodhi
Hi Niels

Thanks for your reply! Adding meta info should certainly help but what I
exactly mean from complexity her  is huge size of the graph with thousands
of nodes. For example, in RDBMS if there is some problem with a some user
information, I can fire a select query or I can use tools like sql developer
which allows me to debug where the problem is. But in case of graph database
am not sure if it would be feasible with neoeclipse to navigate through
thousands of nodes and debug.

--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-how-to-scale-and-view-or-generate-reports-for-complex-graphs-tp3205010p3219983.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] Synchronization of EmbeddedReadOnlyGraphDatabase - Bug?

2011-08-02 Thread Utility Mail
I agree!
In my opinion a remote access to a live instance of a GD is really to be hoped. 
Let me explain my current test case with neo4j: I created an instance of an 
EmbeddedGraphDatabase that ingests continously csv files coming froma a polling 
service. At the same time I need to create an indipendent service indipentent 
from the first one that query (to retrive and not to modify) the GD. I'm tried 
with EROGD but the active index segment has become corrupted! Even if EGD is 
thread safe and I can create multiple thread sharing the same instance of GD 
what to do when, like in my case, I need to have indipendent service (app) 
accessing at the same time to the EGD?


Paolo Forte

p.s.
I'm not sure is correlated and for sure is a lack of my knowledge of webadmin, 
but how can I control my EGD status (number of nodes,edges, etc.) via webadmin 
while it is ingesting new data?



Il giorno 01/ago/2011, alle ore 20:52, Tobias Ivarsson 
 ha scritto:

> I think a bit of elaboration might be in order.
> 
> EmbeddedReadOnlyGraphDatabase was created for one specific purpose:
> 
> Being able to interactively introspect a graph without having to shut down
> the application that uses it.
> 
> Specifically the tools that we wanted to support with this were the Neo4j
> shell and Neoclipse.
> 
> EmbeddedReadOnlyGraphDatabase (EROGD) has two major issues with way caching
> is done internally in Neo4j (one issue with each cache):
> 
>   - When the EROGD reads data from the file system it will, like a normal
>   EGD, cache the node and relationship objects. If a normal EGD modifies the
>   graph "under the feet" of the EROGD, there is no way for the EROGD to know
>   that the data in cache is now stale, which will lead to an inconsistent view
>   of the graph. If for example the EROGD has cached Node[15] with the
>   information that it is connected to some other node through
>   Relationship[344], and Relationship[344] is deleted you will get
>   InvalidRecordException (as you described). And of course if relationships
>   are added to Node[15] these will not be seen at all by the EROGD (until
>   Node[15] is evicted from the cache due to not being used for a while).
>   - Neo4j also caches data on the filesystem level by memory mapping (mmap)
>   hot regions of the store files. Writes to these regions will not be flushed
>   to the actual file until the mmapped window is evicted due to being less hot
>   than other windows, or when the transaction log for Neo4j is rotated. This
>   means that from the p.o.v. of the EROGD the actual data written to disk will
>   look inconsistent. Which would also lead to InvalidRecordExcaption. This
>   situation is actually made even more complicated by the fact that unix
>   operating systems will attempt to share memory mapped data from the same
>   file between multiple processes, but the normal EGD and the EROGD will not
>   make the same decisions on which regions to mmap, they might not even decide
>   on the same size for mmap windows. We haven't tested how well different
>   operating systems deal with reading data that was written to an mmap region
>   through non-mmap syscalls from a different process, most likely this varies
>   from OS to OS.
> 
> The second of these problems is of course the worst, since it cannot be
> worked around. The first one can be mitigated by configuring Neo4j to not
> use the object cache, by passing the cache_type=none parameter to the
> constructor of the EROGD. This should really be made default for EROGD,
> unless we decide to completely remove EROGD.
> 
> I hope that sheds some light on the reasons why you experience these
> problems with EmbeddedReadOnlyGraphDatabase, and what the intention of
> creating it was.
> 
> As a side note I can mention that I had a different idea for how to solve
> the introspection-of-live-graph problem at the time
> EmbeddedReadOnlyGraphDatabase was created: Create network based
> implementation of the GraphDatabaseService API and connect directly to the
> running instance. This would completely avoid the cache staleness problem,
> but at the cost of network overhead for each graph operation, which is
> probably fine for tooling purposes. With the JVM agent attach protocol it
> would be possible to inject such a server into a running graph database that
> wasn't originally configured for it. I in fact implemented this as the
> RemoteGraphDatabase subproject.
> Since my colleagues did not share my vision about that idea, this project
> didn't receive much attention after its initial inception. It was also never
> really used for these purposes, but rather misused for building
> applications, leading us to deprecate the project. When we then later
> discovered a severe bug in the implementation of the remote transaction
> handling logic, we completely removed the project.
> I still believe this to be a superior model for tools, but would build it
> differently if I were to build it today.
> 
> -tobias
> 
> On Mon,

[Neo4j] Remove nodes from Neo4j-spatial layers

2011-08-02 Thread kriti sharma
I have a basic question here,
How can I remove nodes / point geometry from a layer in Neo4j spatial?
I could find function (delete()) to remove nodes from the layer, but this
also deletes the nodes from the database.

So, I would like to remove nodes from the spatial layer after I perform
findClosestPointsTo calculation and then insert new nodes to the layer and
so on.
I could make new layers each time, but then I would be left with many
useless layers in the database.

The API description for the delete() method is confusing me further:
delete

void *delete*(Listener

monitor)

Delete the entire layer, including the index. The specific layer
implementation will decide if this method should delete also the geometry
nodes indexed by this layer. Some implementations have data that only has
meaning within a layer, and so will be deleted. Others are simply views onto
other more complex data models and deleting the geometry nodes might imply
damage to the model. Keep this in mind when coding implementations of the
Layer.


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


Re: [Neo4j] Local neo4j environment Dsetup

2011-08-02 Thread noppanit
You might want to consider some DI framework as well, if you use Java, 
Picocontainer. This is to maintain the instance of EmbeddedDatabase instead of 
using Singleton. This is just from my experience.

T.
Sent from my BlackBerry® wireless device

-Original Message-
From: "Manav Goel [via Neo4j Community Discussions]" 

Date: Tue, 2 Aug 2011 01:11:32 
To: noppanit
Subject: [Neo4j] Local neo4j environment setup



Hey
  After playing around with neo4j and understanding its API, now I
want to create a sample web app to be tested locally on my machine.  I am
using embedded version of database
Kindly guide me how to set this up locally.

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


___
If you reply to this email, your message will be added to the discussion below:
http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-Local-neo4j-environment-setup-tp3218289p3218289.html
To start a new topic under Neo4j Community Discussions, email 
ml-node+438527-1202596511-399...@n3.nabble.com
To unsubscribe from Neo4j Community Discussions, visit 
http://neo4j-community-discussions.438527.n3.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=438527&code=bm9wcGFuaXQuY0BnbWFpbC5jb218NDM4NTI3fDExOTIzNzAyNjk=


--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-Local-neo4j-environment-setup-tp3218289p3219577.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] neo4j maven config

2011-08-02 Thread Peter Neubauer
John,
I am online tomorrow so we can sort this out over skype then?

/peter

Sent from my phone.
On Aug 2, 2011 4:38 PM, "John cyuczieekc"  wrote:
> I even installed scala plugin for eclipse, and switched from embedded
mevan
> 3.0.3 to external..
> neo4j-cypher still has errors
> I failed and I'm giving up... everything
> good byez
> fml
>
> On Tue, Aug 2, 2011 at 2:31 PM, John cyuczieekc wrote:
>
>> mvn test
>> [INFO] Scanning for projects...
>> [WARNING]
>> [WARNING] Some problems were encountered while building the effective
model
>> for
>> org.neo4j:neo4j-cypher:jar:1.5-SNAPSHOT
>> [WARNING] 'parent.relativePath' points at org.neo4j.build:community-build
>> instea
>> d of org.neo4j:parent-central, please verify your project structure @
line
>> 3, co
>> lumn 11
>> [WARNING]
>> [WARNING] It is highly recommended to fix these problems because they
>> threaten t
>> he stability of your build.
>> [WARNING]
>> [WARNING] For this reason, future Maven versions might no longer support
>> buildin
>> g such malformed projects.
>> [WARNING]
>> [INFO]
>> [INFO]
>> 
>> [INFO] Building Neo4j - Cypher 1.5-SNAPSHOT
>> [INFO]
>> 
>>
>> but that seems to be right:
>> parent>
>> org.neo4j
>> parent-central
>> 22
>> 
>>
>> pretty much wherever I look it's parent-central, tho I didn't look
>> everywhere/on each project
>>
>> am I in the twilight-zone again?
>>
>>
>> On Tue, Aug 2, 2011 at 2:07 PM, John cyuczieekc wrote:
>>
>>> Something's odd now, last time I exited eclipse no projects had errors,
>>> now after starting it I've noticed that
>>> neo4j-cypher
>>> neo4j-server
>>> neo4j-shell
>>>
>>> have errors,
>>> in the latter there are only 2 errors:
>>> Query cannot be resolved to a type
>>> SyntaxException cannot be resolved to a type
>>> these are supposed to be in the first project:
>>> import org.neo4j.cypher.SyntaxException;
>>> import org.neo4j.cypher.commands.Query;
>>>
>>> I don't understand :) but something does get updated when I start
eclipse,
>>> like maven index something
>>> The import org.neo4j.cypher.commands cannot be resolved
>>> Where is this import and why is it gone? something got updated meanwhile
?
>>>
>>> wicked O_o
>>>
>>>
>>> On Tue, Aug 2, 2011 at 7:49 AM, John cyuczieekc wrote:
>>>
 ok I finally fixed them all, no errors anymore
 the most important error was:
 "Project configuration is not up-to-date with pom.xml. Run project
 configuration update"

 seems it's all good now, no need to reply
 Thanks,
 John


 On Tue, Aug 2, 2011 at 6:22 AM, John cyuczieekc wrote:

> I should mention that I've already imported neo4j-community from
github
> as a maven project, and I've a lot of neo4j-* projects in my workspace
but
> most of them are red/errors and I am getting this error in pom.xml:
> GroupId is duplicate of parent groupId
>
> I ran a maven test, seems to be successful
> but ie. neo4j-cypher has errors like:
> The import org.neo4j.cypher.SyntaxException cannot be resolved
>
> and something like this in pom.xml:
> wrap: org.apache.commons.exec.ExecuteException: Process exited with an
> error: 1(Exit value: 1)
>
(org.scala-tools:maven-scala-plugin:2.15.2:testCompile:test-compile:test-compile)
>
>
> On Tue, Aug 2, 2011 at 6:12 AM, John cyuczieekc wrote:
>
>> Hi,
>> in this wiki here:
>> http://wiki.neo4j.org/content/Getting_Started_With_Java
>> there is a separate snapshot repository:
>> http://m2.neo4j.org/snapshots/
>>
>> since I kind of want to use the latest neo4j, how do I use this
>> repository, when using m2e and eclipse ?
>> I am new to maven, maybe this is trivial to config... is this done
>> somewhere globally or in my own project's pom.xml ?
>>
>> in my own pom.xml I've specified this:
>> 
>> org.neo4j
>> neo4j
>> 1.5-SNAPSHOT
>> 
>>
>> but maven cannot find it (on maven central):
>> [ERROR] Failed to execute goal on project neo4john: Could not resolve
>> dependencies for project neo4john:neo4john:jar:0.0.1-SNAPSHOT: Could
not
>> find artifact org
>> .neo4j:neo4j:jar:1.5-SNAPSHOT -> [Help 1]
>>
>> I need to tell maven to use your own repository:
>> http://m2.neo4j.org/snapshots/
>>
>> Thanks in advance,
>> John
>>
>
>

>>>
>>
> ___
> 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] Neo4j 1.4.1 “Kiruna Stol” GA

2011-08-02 Thread Alistair Jones
Hello fellow graphistas,

My name is Alistair Jones, and as the newest engineer on the Neo4j team, I
get to introduce myself* and announce our newest release all in one go.

Since we recently released Neo4j 1.4 GA, the devs have been busy working on
improvements to the codebase based on feedback from customers and from our
awesome community. Usually we’d roll these improvements into a milestone,
but this time around we think they’re important enough to warrant a stable
release, and so today we’re announcing the release of Neo4j 1.4.1 GA.

The 1.4.1 GA release is store- and API-compatible with the 1.4GA but a few
kinks have been ironed out. One minor behavioral change you might need to
watch out for is that the graph store predictably commits before any indexes
in a two-phase commit. Otherwise you’ll just find fewer rough edges in this
release.

Neo4j 1.4.1 GA is now available from the Neo4j web site ,
and details are in the blog
post.
As always your feedback is welcomed on the mailing
list.
Download  it now!

-Alistair

* I’ve spent the last 8 years consulting as a developer, technical lead and
architect. It’s great to be joining the Neo4j development team, and I’m
looking forward to the exciting features on the horizon.
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Synchronization of EmbeddedReadOnlyGraphDatabase - Bug?

2011-08-02 Thread Mathias Hensel
Thank you all very much for your answers and ideas around this, especially
for the detailed elaboration of Tobias. In the mailing list I sometimes see
the recommendation of EROGD, f.x. a few days ago in another thread around
multiple processes, so I think it would be good to simultaneously mention
that it is planned to become deprecated.

Regards,
Mathias

--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-Synchronization-of-EmbeddedReadOnlyGraphDatabase-Bug-tp3174626p3219409.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] neo4j maven config

2011-08-02 Thread John cyuczieekc
I even installed scala plugin for eclipse, and switched from embedded mevan
3.0.3 to external..
neo4j-cypher still has errors
I failed and I'm giving up... everything
good byez
fml

On Tue, Aug 2, 2011 at 2:31 PM, John cyuczieekc wrote:

> mvn test
> [INFO] Scanning for projects...
> [WARNING]
> [WARNING] Some problems were encountered while building the effective model
> for
> org.neo4j:neo4j-cypher:jar:1.5-SNAPSHOT
> [WARNING] 'parent.relativePath' points at org.neo4j.build:community-build
> instea
> d of org.neo4j:parent-central, please verify your project structure @ line
> 3, co
> lumn 11
> [WARNING]
> [WARNING] It is highly recommended to fix these problems because they
> threaten t
> he stability of your build.
> [WARNING]
> [WARNING] For this reason, future Maven versions might no longer support
> buildin
> g such malformed projects.
> [WARNING]
> [INFO]
> [INFO]
> 
> [INFO] Building Neo4j - Cypher 1.5-SNAPSHOT
> [INFO]
> 
>
> but that seems to be right:
> parent>
> org.neo4j
> parent-central
> 22
>   
>
> pretty much wherever I look it's parent-central, tho I didn't look
> everywhere/on each project
>
> am I in the twilight-zone again?
>
>
> On Tue, Aug 2, 2011 at 2:07 PM, John cyuczieekc wrote:
>
>> Something's odd now, last time I exited eclipse no projects had errors,
>> now after starting it I've noticed that
>> neo4j-cypher
>> neo4j-server
>> neo4j-shell
>>
>> have errors,
>> in the latter there are only 2 errors:
>> Query cannot be resolved to a type
>> SyntaxException cannot be resolved to a type
>> these are supposed to be in the first project:
>> import org.neo4j.cypher.SyntaxException;
>> import org.neo4j.cypher.commands.Query;
>>
>> I don't understand :) but something does get updated when I start eclipse,
>> like maven index something
>> The import org.neo4j.cypher.commands cannot be resolved
>> Where is this import and why is it gone? something got updated meanwhile ?
>>
>> wicked O_o
>>
>>
>> On Tue, Aug 2, 2011 at 7:49 AM, John cyuczieekc wrote:
>>
>>> ok I finally fixed them all, no errors anymore
>>> the most important error was:
>>> "Project configuration is not up-to-date with pom.xml. Run project
>>> configuration update"
>>>
>>> seems it's all good now, no need to reply
>>> Thanks,
>>> John
>>>
>>>
>>> On Tue, Aug 2, 2011 at 6:22 AM, John cyuczieekc wrote:
>>>
 I should mention that I've already imported neo4j-community from github
 as a maven project, and I've a lot of neo4j-* projects in my workspace but
 most of them are red/errors and I am getting this error in pom.xml:
 GroupId is duplicate of parent groupId

 I ran a maven test, seems to be successful
 but ie. neo4j-cypher has errors like:
 The import org.neo4j.cypher.SyntaxException cannot be resolved

 and something like this in pom.xml:
 wrap: org.apache.commons.exec.ExecuteException: Process exited with an
 error: 1(Exit value: 1)
 (org.scala-tools:maven-scala-plugin:2.15.2:testCompile:test-compile:test-compile)


 On Tue, Aug 2, 2011 at 6:12 AM, John cyuczieekc 
 wrote:

> Hi,
> in this wiki here:
> http://wiki.neo4j.org/content/Getting_Started_With_Java
> there is a separate snapshot repository:
> http://m2.neo4j.org/snapshots/
>
> since I kind of want to use the latest neo4j, how do I use this
> repository, when using m2e and eclipse ?
> I am new to maven, maybe this is trivial to config... is this done
> somewhere globally or in my own project's pom.xml ?
>
> in my own pom.xml I've specified this:
> 
>   org.neo4j
>   neo4j
>   1.5-SNAPSHOT
>   
>
> but maven cannot find it (on maven central):
> [ERROR] Failed to execute goal on project neo4john: Could not resolve
> dependencies for project neo4john:neo4john:jar:0.0.1-SNAPSHOT: Could not
> find artifact org
> .neo4j:neo4j:jar:1.5-SNAPSHOT -> [Help 1]
>
> I need to tell maven to use your own repository:
> http://m2.neo4j.org/snapshots/
>
> Thanks in advance,
> John
>


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


[Neo4j] doing some house keeping, and fitting, in neo4j.

2011-08-02 Thread Pere Urbon Bayes
Hi!
   I am now just doing some house keeping, so removing properties, etc...
For example we are removing a set of properties that where arrays, this is
cause we want to reduce the size our database a bit.

The interesting thing is that the file *neostore.propertystore.db.arrays.id
* is getting fit, but the related *neostore.propertystore.db.arrays*,
doesn't. I need to reduce the size of both files.

Do you have any idea cause this is happening? I would love to reduce the
size of both files.

/purbon

-- 
Pere Urbon-Bayes
moviepilot GmbH | Mehringdamm 33 | 10961 Berlin | Germany
Telefon +49 30 616 512 -110 | Fax +49 30 616 512 -133
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] neo4j maven config

2011-08-02 Thread John cyuczieekc
mvn test
[INFO] Scanning for projects...
[WARNING]
[WARNING] Some problems were encountered while building the effective model
for
org.neo4j:neo4j-cypher:jar:1.5-SNAPSHOT
[WARNING] 'parent.relativePath' points at org.neo4j.build:community-build
instea
d of org.neo4j:parent-central, please verify your project structure @ line
3, co
lumn 11
[WARNING]
[WARNING] It is highly recommended to fix these problems because they
threaten t
he stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support
buildin
g such malformed projects.
[WARNING]
[INFO]
[INFO]

[INFO] Building Neo4j - Cypher 1.5-SNAPSHOT
[INFO]


but that seems to be right:
parent>
org.neo4j
parent-central
22
  

pretty much wherever I look it's parent-central, tho I didn't look
everywhere/on each project

am I in the twilight-zone again?

On Tue, Aug 2, 2011 at 2:07 PM, John cyuczieekc wrote:

> Something's odd now, last time I exited eclipse no projects had errors, now
> after starting it I've noticed that
> neo4j-cypher
> neo4j-server
> neo4j-shell
>
> have errors,
> in the latter there are only 2 errors:
> Query cannot be resolved to a type
> SyntaxException cannot be resolved to a type
> these are supposed to be in the first project:
> import org.neo4j.cypher.SyntaxException;
> import org.neo4j.cypher.commands.Query;
>
> I don't understand :) but something does get updated when I start eclipse,
> like maven index something
> The import org.neo4j.cypher.commands cannot be resolved
> Where is this import and why is it gone? something got updated meanwhile ?
>
> wicked O_o
>
>
> On Tue, Aug 2, 2011 at 7:49 AM, John cyuczieekc wrote:
>
>> ok I finally fixed them all, no errors anymore
>> the most important error was:
>> "Project configuration is not up-to-date with pom.xml. Run project
>> configuration update"
>>
>> seems it's all good now, no need to reply
>> Thanks,
>> John
>>
>>
>> On Tue, Aug 2, 2011 at 6:22 AM, John cyuczieekc wrote:
>>
>>> I should mention that I've already imported neo4j-community from github
>>> as a maven project, and I've a lot of neo4j-* projects in my workspace but
>>> most of them are red/errors and I am getting this error in pom.xml:
>>> GroupId is duplicate of parent groupId
>>>
>>> I ran a maven test, seems to be successful
>>> but ie. neo4j-cypher has errors like:
>>> The import org.neo4j.cypher.SyntaxException cannot be resolved
>>>
>>> and something like this in pom.xml:
>>> wrap: org.apache.commons.exec.ExecuteException: Process exited with an
>>> error: 1(Exit value: 1)
>>> (org.scala-tools:maven-scala-plugin:2.15.2:testCompile:test-compile:test-compile)
>>>
>>>
>>> On Tue, Aug 2, 2011 at 6:12 AM, John cyuczieekc wrote:
>>>
 Hi,
 in this wiki here:
 http://wiki.neo4j.org/content/Getting_Started_With_Java
 there is a separate snapshot repository:
 http://m2.neo4j.org/snapshots/

 since I kind of want to use the latest neo4j, how do I use this
 repository, when using m2e and eclipse ?
 I am new to maven, maybe this is trivial to config... is this done
 somewhere globally or in my own project's pom.xml ?

 in my own pom.xml I've specified this:
 
   org.neo4j
   neo4j
   1.5-SNAPSHOT
   

 but maven cannot find it (on maven central):
 [ERROR] Failed to execute goal on project neo4john: Could not resolve
 dependencies for project neo4john:neo4john:jar:0.0.1-SNAPSHOT: Could not
 find artifact org
 .neo4j:neo4j:jar:1.5-SNAPSHOT -> [Help 1]

 I need to tell maven to use your own repository:
 http://m2.neo4j.org/snapshots/

 Thanks in advance,
 John

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


Re: [Neo4j] neo4j maven config

2011-08-02 Thread John cyuczieekc
Something's odd now, last time I exited eclipse no projects had errors, now
after starting it I've noticed that
neo4j-cypher
neo4j-server
neo4j-shell

have errors,
in the latter there are only 2 errors:
Query cannot be resolved to a type
SyntaxException cannot be resolved to a type
these are supposed to be in the first project:
import org.neo4j.cypher.SyntaxException;
import org.neo4j.cypher.commands.Query;

I don't understand :) but something does get updated when I start eclipse,
like maven index something
The import org.neo4j.cypher.commands cannot be resolved
Where is this import and why is it gone? something got updated meanwhile ?

wicked O_o

On Tue, Aug 2, 2011 at 7:49 AM, John cyuczieekc wrote:

> ok I finally fixed them all, no errors anymore
> the most important error was:
> "Project configuration is not up-to-date with pom.xml. Run project
> configuration update"
>
> seems it's all good now, no need to reply
> Thanks,
> John
>
>
> On Tue, Aug 2, 2011 at 6:22 AM, John cyuczieekc wrote:
>
>> I should mention that I've already imported neo4j-community from github as
>> a maven project, and I've a lot of neo4j-* projects in my workspace but most
>> of them are red/errors and I am getting this error in pom.xml:
>> GroupId is duplicate of parent groupId
>>
>> I ran a maven test, seems to be successful
>> but ie. neo4j-cypher has errors like:
>> The import org.neo4j.cypher.SyntaxException cannot be resolved
>>
>> and something like this in pom.xml:
>> wrap: org.apache.commons.exec.ExecuteException: Process exited with an
>> error: 1(Exit value: 1)
>> (org.scala-tools:maven-scala-plugin:2.15.2:testCompile:test-compile:test-compile)
>>
>>
>> On Tue, Aug 2, 2011 at 6:12 AM, John cyuczieekc wrote:
>>
>>> Hi,
>>> in this wiki here:
>>> http://wiki.neo4j.org/content/Getting_Started_With_Java
>>> there is a separate snapshot repository:
>>> http://m2.neo4j.org/snapshots/
>>>
>>> since I kind of want to use the latest neo4j, how do I use this
>>> repository, when using m2e and eclipse ?
>>> I am new to maven, maybe this is trivial to config... is this done
>>> somewhere globally or in my own project's pom.xml ?
>>>
>>> in my own pom.xml I've specified this:
>>> 
>>>   org.neo4j
>>>   neo4j
>>>   1.5-SNAPSHOT
>>>   
>>>
>>> but maven cannot find it (on maven central):
>>> [ERROR] Failed to execute goal on project neo4john: Could not resolve
>>> dependencies for project neo4john:neo4john:jar:0.0.1-SNAPSHOT: Could not
>>> find artifact org
>>> .neo4j:neo4j:jar:1.5-SNAPSHOT -> [Help 1]
>>>
>>> I need to tell maven to use your own repository:
>>> http://m2.neo4j.org/snapshots/
>>>
>>> Thanks in advance,
>>> John
>>>
>>
>>
>
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] java.lang.UnsupportedOperationException question

2011-08-02 Thread Michael Hunger
With Batch Inserter you should use the  BatchInserterIndexProvider

Please see here: http://docs.neo4j.org/chunked/1.4/indexing-batchinsert.html

Cheers

Michael

Am 02.08.2011 um 13:17 schrieb Ahmed El-Sharkasy:

> I am receiving java.lang.UnsupportedOperationException with new
> BatchInserterImpl(neo4j_directory).getGraphDbService().index()
> 
> can you please help me ?
> 
> -- 
> yours,
> 
> A.sharkasy
> ___
> 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] java.lang.UnsupportedOperationException question

2011-08-02 Thread Ahmed El-Sharkasy
I am receiving java.lang.UnsupportedOperationException with new
BatchInserterImpl(neo4j_directory).getGraphDbService().index()

can you please help me ?

-- 
yours,

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


[Neo4j] java.lang.UnsupportedOperationException

2011-08-02 Thread ahmed.elsharkasy
I am receiving java.lang.UnsupportedOperationException with new
BatchInserterImpl(neo4j_directory).getGraphDbService().index()

can you please help me ?

--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/java-lang-UnsupportedOperationException-tp3218626p3218626.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] Traverse Order By

2011-08-02 Thread Igor Dovgiy
Just my two cents: I actually wrote sort of a similar plugin: it implemented
a slightly modified 'breadth-first' logic, where nodes were added to
PriorityQueue (rather than simple queue, as in original ordering class).
Hope this'll help... )

On 29 July 2011 17:02, Jim Webber  wrote:

> Hey,
>
> Retrieving "popular" nodes not directly possible with the REST API.
>
> Even in Java, you'd have to sort your result set manually since you don't
> know ahead of time how the search is going to traverse your graph.
>
> It is only once you have your result set (which may be large) that you can
> sort, and then deliver popular nodes back ahead of unpopular ones.
>
> If you're keen to do this via the REST API, I would suggest a writing
> plugin that implements this logic in Java, and have that plugin exposed to
> your client application. Be aware that such a plugin might have interesting
> memory requirements if you end up processing large graphs.
>
> Jim
> ___
> Neo4j mailing list
> User@lists.neo4j.org
> https://lists.neo4j.org/mailman/listinfo/user
>



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


Re: [Neo4j] Local neo4j environment setup

2011-08-02 Thread Michael Hunger
You just use any web-framework you'd like and create the 
EmbeddedGraphDatabaseService at startup and shut it down at shutdown.

Can be done with ServletContextListeners or whatever means the web-framework 
provides for lifecycle methods.

Then pass the graphdb around or put it in the application-scope (context) and 
use it in your domain / service classes (probably not in controllers).

Cheers

Michael

Am 02.08.2011 um 10:11 schrieb Manav Goel:

> Hey
>  After playing around with neo4j and understanding its API, now I
> want to create a sample web app to be tested locally on my machine.  I am
> using embedded version of database
> Kindly guide me how to set this up locally.
> 
> -- 
> Manav Goel
> ___
> 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] "body" returned from batch rest call inconsistent

2011-08-02 Thread Mattias Persson
Some operations return array results and some single results... that may be
the cause of it.

2011/7/19 Boris Kizelshteyn 

> Howdy,
>
> When I do create node batches, I get a mix of return data some of which has
> body={} and others that have body=[{}], is this for a reason or is it a
> bug?
>
> Many thanks!
> ___
> Neo4j mailing list
> User@lists.neo4j.org
> https://lists.neo4j.org/mailman/listinfo/user
>



-- 
Mattias Persson, [matt...@neotechnology.com]
Hacker, Neo Technology
www.neotechnology.com
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


[Neo4j] Local neo4j environment setup

2011-08-02 Thread Manav Goel
Hey
  After playing around with neo4j and understanding its API, now I
want to create a sample web app to be tested locally on my machine.  I am
using embedded version of database
Kindly guide me how to set this up locally.

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


Re: [Neo4j] How to run webadmin for high availability neo4j custer?

2011-08-02 Thread Jim Webber
Hi,

> (1) The wiki only shows example on "ha-server[x].conf" file but not other
> properties files as in default standalone server. That beg the question on
> how to setup webserver for each cluster node.

The properties will be the same as for individual instances of Neo4j, with the 
exception that you'll have to pick a non-clashing Web server port if you're 
co-locating the instances.

> (2) The wiki suggests coping an empty standalone db to hadb1 and runs a
> custom Java program to start the node --> This seems a rather ad-hoc way to
> install a Production HA cluster, doesnt' it?

I believe there are some chef recipes available - Andreas?

Jim

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