Re: [Neo4j] IndexHits extends Iterable is evil

2011-12-13 Thread Peter Neubauer
That indeed is evil, JP.

Could you raise an issue on this please? Please copy even your
explanation in there. Fully agree.

Cheers,

/peter neubauer

TC CEO of the year - vote for Emil Eifrém!
http://crunchies2011.techcrunch.com/nominate/

Google:neubauer.peter
Skype:peter.neubauer
Phone: +46 704 106975
LinkedIn   http://www.linkedin.com/in/neubauer
Twitter      @peterneubauer

brew install neo4j  neo4j start
heroku addons:add neo4j



On Fri, Dec 9, 2011 at 4:02 PM, Jean-Pierre Bergamin
jpberga...@gmail.com wrote:
 Dear neo4j community and developers

 For the second time we stumbled about Iterables that are no Iterables
 in Neo4j. IndexHits e.g. extends Iterator and Iterable and states in
 its documentation that is not really an iterable but always returns
 this in calls to iterator(). So far so good.

 Now when using Spring Data Neo4j, the IndexHits is wrapped and hidden
 behind ClosableIterable and IterableAdapter etc. The user has no idea
 anymore that those IterableWrapper and ClosableIterable things he gets
 back are no iterables at all - well the names tell him of course that
 those things *are* Iterables. This leads to very, very strange
 behaviour like this:

 @Test
 public void ouch() {
        Device d1 = new Device(d1).persist();
        Device d2 = new Device(d2).persist();

        ClosableIterableDevice devices = deviceRepository().findAll();
        assertThat(devices, hasItems(d1));
        assertEquals(1, IteratorUtil.count(devices));
 }

 We add two devices to our DB, but the test clearly states that
 findAll() only returns one (assertEquals(1,
 IteratorUtil.count(devices))).
 As an exercise for the reader: explain why this test misleads you

 Iterable should always return a valid iterator for every call to
 iterator(). Implementing Iterable just to be able to use an iterator
 in a for loop is evil. :-)


 Best regards,
 James
 ___
 NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
 and consider posting at https://groups.google.com/forum/#!forum/neo4j

 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user
___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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


Re: [Neo4j] HA starting issue

2011-12-13 Thread Mattias Persson
It seems that ZooKeeper configuration could be invalid. The HA db doesn't
get in contact with it.

2011/12/6 lawrence.bandeira lawrence.bande...@gmail.com

 Follow the logs !!!


 http://neo4j-community-discussions.438527.n3.nabble.com/file/n3565025/console.log
 console.log

 http://neo4j-community-discussions.438527.n3.nabble.com/file/n3565025/neo4j.0.0.log
 neo4j.0.0.log

 http://neo4j-community-discussions.438527.n3.nabble.com/file/n3565025/neo4j-zookeeper.log
 neo4j-zookeeper.log

 --
 View this message in context:
 http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-HA-starting-issue-tp3260535p3565025.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




-- 
Mattias Persson, [matt...@neotechnology.com]
Hacker, Neo Technology
www.neotechnology.com
___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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


Re: [Neo4j] NeoEclipse overlapping relations

2011-12-13 Thread Mattias Persson
You can choose to hide certain relationship types in some menu somewhere...
But in general overlapping relationships is a problem in Neoclipse I think

2011/12/7 nrkkalyan nrkkal...@gmail.com

 I would like to know if there is a way to see the relations on neoeclipse
 propertly, I created a family relation and tried to view the relation in
 neoeclipse, but it seems the relations are been overlapped.

 Image:

 http://neo4j-community-discussions.438527.n3.nabble.com/file/n3565999/neo4j-family-relation.png

 Am I doing something missing in settings?

 --
 View this message in context:
 http://neo4j-community-discussions.438527.n3.nabble.com/NeoEclipse-overlapping-relations-tp3565999p3565999.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




-- 
Mattias Persson, [matt...@neotechnology.com]
Hacker, Neo Technology
www.neotechnology.com
___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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


Re: [Neo4j] allSimplePaths performance

2011-12-13 Thread Petar Dobrev
Hey folks,

just wanted to let you know that I tested it with Neo4j Community 1.6M01
and can't reproduce the problem. It seems that it got fixed somewhere along
the way. :)

Iterating through the depth levels and calling pathsWithLength is still
faster than allSimplePaths for depths  5 for me, so I'm going to stick to
it. Even wrote a small plugin for my server to do that.

Thanks a lot for the great work!

Best regards,
Petar.



On Mon, Nov 28, 2011 at 12:16 PM, Mattias Persson matt...@neotechnology.com
 wrote:

 I think I'd need your dataset to be able to reproduce and fix it, would
 that be possible?

 2011/11/25 Petar Dobrev petar.dob...@myphilanthropedia.org

  On Fri, Nov 25, 2011 at 7:59 PM, Mattias Persson
  matt...@neotechnology.comwrote:
 
  
   Correct, it finds paths on that depth only. If other paths are
  encountered
   along the way they aren't returned.
  
  
 
  However, in the example I provided it misses a path that is present on
 the
  desired depth, that's what I was actually wondering about.
 
  In this example:
 
  The source of the testing program is here:
 https://gist.github.com/1391654
  Output before adding the additional relationship:
  https://gist.github.com/1391668
  Output after adding the additional relationship:
  https://gist.github.com/1391661
 
  shortestPath misses one path (at depth 3) unless an additional
 relationship
  is present, which is unrelated to the paths between the nodes.
 
  Petar
  ___
  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




-- 
Petar Dobrev
Engineer
Philanthropedia
http://www.myphilanthropedia.org
___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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


Re: [Neo4j] allSimplePaths performance

2011-12-13 Thread Peter Neubauer
Cool.
Got that plugin somewhere?

Cheers,

/peter neubauer

TC CEO of the year - vote for Emil Eifrém!
http://crunchies2011.techcrunch.com/nominate/

Google:neubauer.peter
Skype:peter.neubauer
Phone: +46 704 106975
LinkedIn   http://www.linkedin.com/in/neubauer
Twitter      @peterneubauer

brew install neo4j  neo4j start
heroku addons:add neo4j



On Tue, Dec 13, 2011 at 4:52 PM, Petar Dobrev
petar.dob...@myphilanthropedia.org wrote:
 Hey folks,

 just wanted to let you know that I tested it with Neo4j Community 1.6M01
 and can't reproduce the problem. It seems that it got fixed somewhere along
 the way. :)

 Iterating through the depth levels and calling pathsWithLength is still
 faster than allSimplePaths for depths  5 for me, so I'm going to stick to
 it. Even wrote a small plugin for my server to do that.

 Thanks a lot for the great work!

 Best regards,
 Petar.



 On Mon, Nov 28, 2011 at 12:16 PM, Mattias Persson matt...@neotechnology.com
 wrote:

 I think I'd need your dataset to be able to reproduce and fix it, would
 that be possible?

 2011/11/25 Petar Dobrev petar.dob...@myphilanthropedia.org

  On Fri, Nov 25, 2011 at 7:59 PM, Mattias Persson
  matt...@neotechnology.comwrote:
 
  
   Correct, it finds paths on that depth only. If other paths are
  encountered
   along the way they aren't returned.
  
  
 
  However, in the example I provided it misses a path that is present on
 the
  desired depth, that's what I was actually wondering about.
 
  In this example:
 
  The source of the testing program is here:
 https://gist.github.com/1391654
  Output before adding the additional relationship:
  https://gist.github.com/1391668
  Output after adding the additional relationship:
  https://gist.github.com/1391661
 
  shortestPath misses one path (at depth 3) unless an additional
 relationship
  is present, which is unrelated to the paths between the nodes.
 
  Petar
  ___
  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




 --
 Petar Dobrev
 Engineer
 Philanthropedia
 http://www.myphilanthropedia.org
 ___
 NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
 and consider posting at https://groups.google.com/forum/#!forum/neo4j

 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user
___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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


Re: [Neo4j] allSimplePaths performance

2011-12-13 Thread Petar Dobrev
Sure, it's based on the shortestPath plugin example from the docs and is
quite simple:
https://gist.github.com/1472918

Best regards,
Petar



On Tue, Dec 13, 2011 at 5:58 PM, Peter Neubauer 
peter.neuba...@neotechnology.com wrote:

 Cool.
 Got that plugin somewhere?

 Cheers,

 /peter neubauer

 TC CEO of the year - vote for Emil Eifrém!
 http://crunchies2011.techcrunch.com/nominate/

 Google:neubauer.peter
 Skype:peter.neubauer
 Phone: +46 704 106975
 LinkedIn   http://www.linkedin.com/in/neubauer
 Twitter  @peterneubauer

 brew install neo4j  neo4j start
 heroku addons:add neo4j



 On Tue, Dec 13, 2011 at 4:52 PM, Petar Dobrev
 petar.dob...@myphilanthropedia.org wrote:
  Hey folks,
 
  just wanted to let you know that I tested it with Neo4j Community 1.6M01
  and can't reproduce the problem. It seems that it got fixed somewhere
 along
  the way. :)
 
  Iterating through the depth levels and calling pathsWithLength is still
  faster than allSimplePaths for depths  5 for me, so I'm going to stick
 to
  it. Even wrote a small plugin for my server to do that.
 
  Thanks a lot for the great work!
 
  Best regards,
  Petar.
 
 
 
  On Mon, Nov 28, 2011 at 12:16 PM, Mattias Persson 
 matt...@neotechnology.com
  wrote:
 
  I think I'd need your dataset to be able to reproduce and fix it, would
  that be possible?
 
  2011/11/25 Petar Dobrev petar.dob...@myphilanthropedia.org
 
   On Fri, Nov 25, 2011 at 7:59 PM, Mattias Persson
   matt...@neotechnology.comwrote:
  
   
Correct, it finds paths on that depth only. If other paths are
   encountered
along the way they aren't returned.
   
   
  
   However, in the example I provided it misses a path that is present on
  the
   desired depth, that's what I was actually wondering about.
  
   In this example:
  
   The source of the testing program is here:
  https://gist.github.com/1391654
   Output before adding the additional relationship:
   https://gist.github.com/1391668
   Output after adding the additional relationship:
   https://gist.github.com/1391661
  
   shortestPath misses one path (at depth 3) unless an additional
  relationship
   is present, which is unrelated to the paths between the nodes.
  
   Petar
   ___
   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
 
 
 
 
  --
  Petar Dobrev
  Engineer
  Philanthropedia
  http://www.myphilanthropedia.org
  ___
  NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please
 register and consider posting at
 https://groups.google.com/forum/#!forum/neo4j
 
  Neo4j mailing list
  User@lists.neo4j.org
  https://lists.neo4j.org/mailman/listinfo/user
 ___
 NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please
 register and consider posting at
 https://groups.google.com/forum/#!forum/neo4j

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




-- 
Petar Dobrev
Engineer
Philanthropedia
http://www.myphilanthropedia.org
___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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


[Neo4j] Neo4j Events this Week

2011-12-13 Thread Allison Sparrow
Hi all!

Here are the events Neo4j has this week.

** https://www1.gotomeeting.com/register/465612737*Webinar | Getting
Started with Spring Data Neo4j*
Thursday, December 15, 2011, 10:00 PST
The Spring Data project makes it easier to build Spring-powered
applications that use new data access technologies such as non-relational
NOSQL databases, cloud based data services, and graph databases.

This webinar is designed for enterprise developers who are working with
Spring and need to understand if they can benefit from a graph database.
The session will introduce the different types of data management offered
in Spring Data, including graph databases, and will show how easy it is to
get started with the Spring Data Neo4j project.

*Sydney Tutorial: Neo4j and Graph
Databases*http://www.yowconference.com.au/YOW2011/general/workshopDetails.html?eventId=3488
Thursday, December 15, 2011

Graph databases like Neo4j are an esoteric and powerful member of the NOSQL
family. For highly connected data, graph databases can be thousands of
times faster than relational databases, making Neo4j popular for managing
complex data across many domains from finance to social, and telecoms to
geospatial.

This is a (completely open-source) tutorial that provides an intensive
mixture of theory and hands-on practical sessions to demonstrate the
capabilities of graph data and the popular open source Neo4j graph database.

*Sydney Tutorial: REST in
Practice*http://www.yowconference.com.au/YOW2011/general/workshopDetails.html?eventId=3464
Friday, December 16, 2011

The Web is fast becoming a serious competitor to traditional enterprise
architecture approaches. This tutorial will provide an introduction to
RESTful Web Service techniques, both from a theoretical and practical
perspectives.

Laters

@ayeeson

*
*

___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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


Re: [Neo4j] KeyError in python

2011-12-13 Thread Jacopo Farina
I tried again to run the program and still got the same error, at the same 
point. I'm running it on Ubuntu 10.10, but I could try on a pc with Windows 
7 and more RAM.
Cheers,
Jacopo
___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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


Re: [Neo4j] ODBC connection

2011-12-13 Thread Mattias Persson
Rickard, didn't you write a JDBC driver for Cypher recently?

2011/12/7 patenlee leo.de.vr...@bpsolutions.nl

 I want to access from an external application Neo4j objects. Does anybody
 know if a Neo4J ODBC driver is available to access the Neo4j objects.

 --
 View this message in context:
 http://neo4j-community-discussions.438527.n3.nabble.com/ODBC-connection-tp3566658p3566658.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




-- 
Mattias Persson, [matt...@neotechnology.com]
Hacker, Neo Technology
www.neotechnology.com
___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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


Re: [Neo4j] ODBC connection

2011-12-13 Thread Rickard Öberg
Hi,

Yes, I have written an experimental JDBC driver that uses the REST API
to map JDBC calls to Cypher. It is available at:
http://github.com/rickardoberg/neo4j-jdbc

This can be used to access Neo4j data. Since Cypher does not yet
support updates this is read-only, but can be good for reporting
purposes. I have so far tested it with DbVisualizer and
LibreOffice/OpenOffice, and it works there (the driver has quirks
mode for each of these to translate the standard SQL calls these
tools make into Cypher). I have also packaged the driver as an applet
so that it can be used from Javascript in an HTML page:
https://github.com/rickardoberg/neo4j-jdbc-applet

With example:
https://github.com/rickardoberg/neo4j-jdbc-web

These were done yesterday, so not yet production ready, but feel free
to try it out and provide feedback.

This allows Neo4j to be accessed by tools that support JDBC, but not
ODBC. I'm trying to find out if there's a way to do it (the standard
JDBC/ODBC bridge does it in the other direction), but have little hope
that it can be done easily. What is the tool that you want to use to
access Neo4j from, and does it only support ODBC, or would JDBC be
fine?

/Rickard

On Wed, Dec 14, 2011 at 6:44 AM, Mattias Persson
matt...@neotechnology.com wrote:

 Rickard, didn't you write a JDBC driver for Cypher recently?


 2011/12/7 patenlee leo.de.vr...@bpsolutions.nl

 I want to access from an external application Neo4j objects. Does anybody
 know if a Neo4J ODBC driver is available to access the Neo4j objects.

 --
 View this message in context: 
 http://neo4j-community-discussions.438527.n3.nabble.com/ODBC-connection-tp3566658p3566658.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




 --
 Mattias Persson, [matt...@neotechnology.com]
 Hacker, Neo Technology
 www.neotechnology.com
___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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


Re: [Neo4j] ODBC connection

2011-12-13 Thread Rickard Öberg
Hi,

Sooo, I had a look at ODBC, and there is actually a ODBC-JDBC Gateway
available from here:
http://www.easysoft.com/products/data_access/jdbc_odbc_bridge/index.html

I downloaded and installed it, and then tried out a generic ODBC tool with it:
http://www.sliksoftware.co.nz/products/odbcview/

With this I could set up a Neo4j ODBC source in Windows, and send
Cypher requests to a Neo4j Server and view that as a table in the
tool. So, that chain actually works.

But I think it is entirely dependent on what ODBC client you want to
use, as I'm sure each and every one of them will do slightly different
calls. So if you can let me know maybe I can test whichever you are
interested in, to see if it works. I am actually able to remote debug
the driver to see what is going on, so that is pretty simple.

regards, Rickard

On Wed, Dec 14, 2011 at 10:26 AM, Rickard Öberg
rickard.ob...@neotechnology.com wrote:
 Hi,

 Yes, I have written an experimental JDBC driver that uses the REST API
 to map JDBC calls to Cypher. It is available at:
 http://github.com/rickardoberg/neo4j-jdbc

 This can be used to access Neo4j data. Since Cypher does not yet
 support updates this is read-only, but can be good for reporting
 purposes. I have so far tested it with DbVisualizer and
 LibreOffice/OpenOffice, and it works there (the driver has quirks
 mode for each of these to translate the standard SQL calls these
 tools make into Cypher). I have also packaged the driver as an applet
 so that it can be used from Javascript in an HTML page:
 https://github.com/rickardoberg/neo4j-jdbc-applet

 With example:
 https://github.com/rickardoberg/neo4j-jdbc-web

 These were done yesterday, so not yet production ready, but feel free
 to try it out and provide feedback.

 This allows Neo4j to be accessed by tools that support JDBC, but not
 ODBC. I'm trying to find out if there's a way to do it (the standard
 JDBC/ODBC bridge does it in the other direction), but have little hope
 that it can be done easily. What is the tool that you want to use to
 access Neo4j from, and does it only support ODBC, or would JDBC be
 fine?

 /Rickard

 On Wed, Dec 14, 2011 at 6:44 AM, Mattias Persson
 matt...@neotechnology.com wrote:

 Rickard, didn't you write a JDBC driver for Cypher recently?


 2011/12/7 patenlee leo.de.vr...@bpsolutions.nl

 I want to access from an external application Neo4j objects. Does anybody
 know if a Neo4J ODBC driver is available to access the Neo4j objects.

 --
 View this message in context: 
 http://neo4j-community-discussions.438527.n3.nabble.com/ODBC-connection-tp3566658p3566658.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




 --
 Mattias Persson, [matt...@neotechnology.com]
 Hacker, Neo Technology
 www.neotechnology.com
___
NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register 
and consider posting at https://groups.google.com/forum/#!forum/neo4j

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