Re: [Neo4j] Rest API requests

2010-11-26 Thread Max De Marzi Jr.
Try upping the number of nodes created.  Try 200, 500, 1000.

On Fri, Nov 26, 2010 at 9:30 AM, Peter Neubauer
 wrote:
> Ok,
> Andreas helped me to get RVM set up and things working.
>
> When are you getting the problem? My testing ran good ...
>
> /peter
>
> On Wed, Nov 24, 2010 at 5:26 AM, Max De Marzi Jr.  
> wrote:
>> Hum... not sure try just:
>>
>>  rspec spec/integration/rest_experimental_spec.rb
>>
>> On Tue, Nov 23, 2010 at 3:20 PM, Peter Neubauer
>>  wrote:
>>> Mmh,
>>> to start with, I am stuck with some OpenSSL error when trying to run
>>> rspecs:
>>>
>>> bundle exec rspec spec/integration/rest_node_spec.rb
>>> JRuby limited openssl loaded. gem install jruby-openssl for full support.
>>> http://jruby.kenai.com/pages/JRuby_Builtin_OpenSSL
>>> JRuby limited openssl loaded. gem install jruby-openssl for full support.
>>> http://jruby.kenai.com/pages/JRuby_Builtin_OpenSSL
>>> No Extensions Found: /Users/peterneubauer/.neography
>>> FFF
>>>
>>> Failures:
>>>  1) Neography::Rest get_root can get the root node
>>>     Failure/Error: root_node = @neo.get_root
>>>     OpenSSL::SSL requires the jruby-openssl gem
>>>     # ./lib/neography/rest.rb:268:in `get'
>>>     # ./lib/neography/rest.rb:27:in `get_root'
>>>     # ./spec/integration/rest_node_spec.rb:10
>>>     # :1
>>>
>>>  2) Neography::Rest create_node can create an empty node
>>>     Failure/Error: new_node = @neo.create_node
>>>     uninitialized constant OpenSSL::SSL
>>>     # ./lib/neography/rest.rb:272:in `post'
>>>     # ./lib/neography/rest.rb:35:in `create_node'
>>>     # ./spec/integration/rest_node_spec.rb:17
>>>     # :1
>>>
>>>  3) Neography::Rest create_node can create a node with one property
>>>     Failure/Error: new_node = @neo.create_node("name" => "Max")
>>>     uninitialized constant OpenSSL::SSL
>>>     # ./lib/neography/rest.rb:272:in `post'
>>>     # ./lib/neography/rest.rb:33:in `create_node'
>>>     # ./spec/integration/rest_node_spec.rb:22
>>>     # :1
>>>
>>>
>>> Any hints what could be the reason? I have installed
>>>
>>> gem install jruby-openssl but are still getting that error on Mac OSX.
>>> Any hints?
>>>
>>> /peter
>>> ___
>>> 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] NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore

2010-11-26 Thread Craig Taverner
Yes. Neo4j-Spatial 0.2 depends on Neo4j 1.1. From github this should be the
last commit in September. From October on it depends on 1.2-SNAPSHOT.

On Fri, Nov 26, 2010 at 10:58 AM, Axel Morgner  wrote:

> Ok, got everything working again, running on 1.2-SNAPSHOT now.
> Quite faster than 1.1, BTW. :-)
>
> Just in case: Is there a neo4j-spatial version which works well with
> neo4j-1.1?
>
> Thanks
>
> Axel
>
> On 26.11.2010 10:40, Anders Nawroth wrote:
> > Hi!
> >
> > 2010-11-26 10:31, Mattias Persson skrev:
> >> It may be that neo4j-spatial 0.3-SNAPSHOT depends on a later
> kernel/index
> >> version (probably 1.2-SNAPSHOT, i.e. latest trunk).
> > That's exactly how it is according to the pom.xml:
> > https://github.com/neo4j/neo4j-spatial/blob/master/pom.xml
> >
> > /anders
> >
> >> In that case there's a
> >> conflict. Could you instead depend on a stable spatial version or
> upgrade to
> >> latest kernel/index versions?
>
> ___
> 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] Release 1.0.0.beta.22

2010-11-26 Thread Craig Taverner
>
> Any mechanism that make possible to build traversals with geospatial
> information through the REST API would be great.
> So, in some moment in the future, will be possible do traversals with
> geodata?, I mean, build traversals in which I could asking the nodes
> using geospatial operations like near, is a point of, overlap with, to
> a distance less than, etc.
>

I think it should be relatively easy to add spatial extensions to the REST
server, but I've not been involved in the REST project much, so I'd need to
discuss this with others. Since the current REST API is based on JSON, the
preferred choice for the geometries would be GeoJSON, and I think it would
be nice to embed the GeoJSON objects directly in the REST JSON response
itself. Alternatively your idea of WKT embedded in a JSON value might work
well too. We might need some clever tricks to deal with paging large result
sets, but I guess that is an issue for all database queries.

Deployment wise I think it would be great if simply adding the neo4j-spatial
jar to the Neo4j Server deployment would activate a few spatial queries that
could be used. I do not really agree with Peter that spatial can be slipped
behind existing API's. I think many, or most things, will require specific
spatial queries and spatial responses. I certainly believe this is true of
your suggested queries above: near, point of, overlaps with, etc.

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


Re: [Neo4j] Release 1.0.0.beta.22

2010-11-26 Thread Craig Taverner
I must admit I am not happy with the index.add(node,key,value) API for
spatial data. See the line in Peters code:

index.add( n1, "dummy", "value" );

Peter had to put dummy values in the call to 'work around' this requirement.
In fact I'm not happy with this for my composite index either. For both
cases (spatial and composite), you configure the properties to be indexed
once for the index as a whole and then call index.add(node) for each node to
index. This has many advantages:

   - The index can be optimised or specific to the combinations of
   properties configured up-front
   - The index can deal with much more complex things, like the spatial
   index which can even index a complete sub-graph as a geometrical shape in 2D
   space. This is not possible to express as key:value pairs on nodes or
   relationships, and so the initialization of the index itself needs to be
   done with an instance of the GeometryEncoder which explains to the index how
   to map the sub-graph into a Geometry, and thereby allows the RTree to
   understand how to index it. (my composite index also works like this since
   it needs to know up front the complete set of properties to index, because
   the tree is built based on all properties at the same time, and adding a new
   property later is hard, and requires re-balancing the entire tree).

What this means for the Ruby case is that, as far as I am away, neo4j.rb
already simplifies the current index to work better with an object model,
where each node represents an instance of a class and can be added to the
index without properties. So we are already part of the way to what I want.

So IMHO, forcing the spatial index to match the standard index API does not
make like easier for the Ruby (or other) API. I think the Ruby wrappers can
wrap the spatial index in a way that makes it as easy (or even identical) to
the Ruby wrapper on the lucene index, but this does not require any
intermediate java code to make the java spatial index look more like the
lucene one.

On Fri, Nov 26, 2010 at 4:54 PM, Peter Neubauer <
peter.neuba...@neotechnology.com> wrote:

> Thanks for the feedback!
>
> On the GoeSpatial side, I am trying to get the setup easier, so for
> "normal" stuff, you don't have to go through GeoTeools but can use the
> Neo4j Index setup, see
>
> https://github.com/neo4j/neo4j-spatial/blob/300f4d1d1fbb92d6252d5be6dc334250c9514bc7/src/test/java/org/neo4j/gis/spatial/IndexProviderTest.java#L51
> after just including Neo4j-Spatial into your dependencies. This syntax
> might make it easier to expose things in Ruby, REST and others, too.
> WDYT?
>
> For the heavy query lifting and GIS stack integration, the GeoTools
> API is the way to go though ...
>
>
> Date support in Neo4j is a very interesting thing that I think needs a
> bit of thought. Thanks for pointing it out - would be a great
> lab-friday project :)
>
> Cheers,
>
> /peter neubauer
>
> GTalk:  neubauer.peter
> Skype   peter.neubauer
> Phone   +46 704 106975
> LinkedIn   http://www.linkedin.com/in/neubauer
> Twitter  http://twitter.com/peterneubauer
>
> http://www.neo4j.org   - Your high performance graph database.
> http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.
>
>
>
> On Fri, Nov 26, 2010 at 3:08 PM, Javier de la Rosa 
> wrote:
> > On Fri, Nov 26, 2010 at 02:03, Peter Neubauer <
> > peter.neuba...@neotechnology.com> wrote:
> >
> >> Btw, what does everyone feel about REST vs. native protocols like RMI,
> >> Protobuffers, etc that can support a full Neo4j remote API for
> >> integration, with TX etc and would be optimized for driver development
> >> in other langs, minicing the Java core API capabilities very close?
> >> Any thoughts or preferences on one or the other? Does REST do a
> >> sufficiently good job for production use from other langs? What would
> >> you like to see in REST to get there - top 3 features?
> >>
> >
> > My 3 cents:
> > - Sockets maybe?
> > - Support for Dates, and not only dates after Linux Epoch.
> > - Support for do traversal with the geospatial information. Using GeoJSON
> or
> > WKT?
> >
> >
> >
> > --
> > Javier de la Rosa
> > http://versae.es
> > ___
> > Neo4j mailing list
> > User@lists.neo4j.org
> > https://lists.neo4j.org/mailman/listinfo/user
> >
> ___
> Neo4j mailing list
> User@lists.neo4j.org
> https://lists.neo4j.org/mailman/listinfo/user
>
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Accessing DB data directory on Elastic MapReduce

2010-11-26 Thread Peter Neubauer
This looks good to me, but then,
I am no Amazon and Hadoop expert. Do you think it would be possible to
do a generic integration component that lets you run travesals on
replicated Neo4j backends as Hadoop map-reduce jobs? I think that
would be interesting to a number of use cases and a very cool use of
Neo4j. Also, Alex Averbuch wants to look at using AKKA (Scala) to do
similar things, so comparing the approaches would be great!

Cheers,

/peter neubauer

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

http://www.neo4j.org               - Your high performance graph database.
http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.



On Thu, Nov 25, 2010 at 6:33 AM, Paddy  wrote:
> Hi Guys,
>
> I was testing out accessing a Neo4j DB from a Hadoop job on Elastic
> Mapreduce,
> I asked a question on the forum regarding loading a file from s3 to each ec2
> at startup: https://forums.aws.amazon.com/thread.jspa?threadID=54919
>
> In case anyone faces the same issue, the following bootstrap action will
> download a compressed
> neo4j database from a s3 bucket to each launched ec2 instance and changes
> the directory
>  permissions to allow access with:
> private static GraphDatabaseService graphDb = new
> EmbeddedGraphDatabase("/home/hadoop/neo-db");
>
>
> #!/bin/bash
> set -e
> sudo wget -S -T 10 -t 5  http://.s3.amazonaws.com/neo-db.tar.gz
> sudo tar -C /home/hadoop -xzf neo-db.tar.gz
> sudo chmod -R 777 /home/hadoop/neo-db
>
>
> Does this sound like the best method to use?
> cheers
> Paddy
> ___
> 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] Release 1.0.0.beta.22

2010-11-26 Thread Javier de la Rosa
On Fri, Nov 26, 2010 at 10:54, Peter Neubauer
 wrote:
> [...] This syntax
> might make it easier to expose things in Ruby, REST and others, too.
> WDYT?
>
> For the heavy query lifting and GIS stack integration, the GeoTools
> API is the way to go though ...

Any mechanism that make possible to build traversals with geospatial
information through the REST API would be great.
So, in some moment in the future, will be possible do traversals with
geodata?, I mean, build traversals in which I could asking the nodes
using geospatial operations like near, is a point of, overlap with, to
a distance less than, etc.

>
>
> Date support in Neo4j is a very interesting thing that I think needs a
> bit of thought. Thanks for pointing it out - would be a great
> lab-friday project :)

Great! I would like to know some more about Java to help in a more useful way.
Thank you.

>
> Cheers,
>
> /peter neubauer
>
> GTalk:      neubauer.peter
> Skype       peter.neubauer
> Phone       +46 704 106975
> LinkedIn   http://www.linkedin.com/in/neubauer
> Twitter      http://twitter.com/peterneubauer
>
> http://www.neo4j.org               - Your high performance graph database.
> http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.
>
>
>
> On Fri, Nov 26, 2010 at 3:08 PM, Javier de la Rosa  wrote:
> > On Fri, Nov 26, 2010 at 02:03, Peter Neubauer <
> > peter.neuba...@neotechnology.com> wrote:
> >
> >> Btw, what does everyone feel about REST vs. native protocols like RMI,
> >> Protobuffers, etc that can support a full Neo4j remote API for
> >> integration, with TX etc and would be optimized for driver development
> >> in other langs, minicing the Java core API capabilities very close?
> >> Any thoughts or preferences on one or the other? Does REST do a
> >> sufficiently good job for production use from other langs? What would
> >> you like to see in REST to get there - top 3 features?
> >>
> >
> > My 3 cents:
> > - Sockets maybe?
> > - Support for Dates, and not only dates after Linux Epoch.
> > - Support for do traversal with the geospatial information. Using GeoJSON or
> > WKT?
> >
> >
> >
> > --
> > Javier de la Rosa
> > http://versae.es
> > ___
> > Neo4j mailing list
> > User@lists.neo4j.org
> > https://lists.neo4j.org/mailman/listinfo/user
> >
> ___
> Neo4j mailing list
> User@lists.neo4j.org
> https://lists.neo4j.org/mailman/listinfo/user



--
Javier de la Rosa
http://versae.es
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore

2010-11-26 Thread Peter Neubauer
Mmh,
I upgraded to latest versions in order to get started with the Neo4j
Index exposure of Neo4j Spatial. I think it is a safe bet to upgrade,
We should do a release after Neo4j 1.2 in a couple of weeks to get a
stable version.

Would that be ok for you?

Cheers,

/peter neubauer

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

http://www.neo4j.org               - Your high performance graph database.
http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.



On Fri, Nov 26, 2010 at 10:58 AM, Axel Morgner  wrote:
> Ok, got everything working again, running on 1.2-SNAPSHOT now.
> Quite faster than 1.1, BTW. :-)
>
> Just in case: Is there a neo4j-spatial version which works well with
> neo4j-1.1?
>
> Thanks
>
> Axel
>
> On 26.11.2010 10:40, Anders Nawroth wrote:
>> Hi!
>>
>> 2010-11-26 10:31, Mattias Persson skrev:
>>> It may be that neo4j-spatial 0.3-SNAPSHOT depends on a later kernel/index
>>> version (probably 1.2-SNAPSHOT, i.e. latest trunk).
>> That's exactly how it is according to the pom.xml:
>> https://github.com/neo4j/neo4j-spatial/blob/master/pom.xml
>>
>> /anders
>>
>>> In that case there's a
>>> conflict. Could you instead depend on a stable spatial version or upgrade to
>>> latest kernel/index versions?
>
> ___
> 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] Release 1.0.0.beta.22

2010-11-26 Thread Peter Neubauer
Thanks for the feedback!

On the GoeSpatial side, I am trying to get the setup easier, so for
"normal" stuff, you don't have to go through GeoTeools but can use the
Neo4j Index setup, see
https://github.com/neo4j/neo4j-spatial/blob/300f4d1d1fbb92d6252d5be6dc334250c9514bc7/src/test/java/org/neo4j/gis/spatial/IndexProviderTest.java#L51
after just including Neo4j-Spatial into your dependencies. This syntax
might make it easier to expose things in Ruby, REST and others, too.
WDYT?

For the heavy query lifting and GIS stack integration, the GeoTools
API is the way to go though ...


Date support in Neo4j is a very interesting thing that I think needs a
bit of thought. Thanks for pointing it out - would be a great
lab-friday project :)

Cheers,

/peter neubauer

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

http://www.neo4j.org               - Your high performance graph database.
http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.



On Fri, Nov 26, 2010 at 3:08 PM, Javier de la Rosa  wrote:
> On Fri, Nov 26, 2010 at 02:03, Peter Neubauer <
> peter.neuba...@neotechnology.com> wrote:
>
>> Btw, what does everyone feel about REST vs. native protocols like RMI,
>> Protobuffers, etc that can support a full Neo4j remote API for
>> integration, with TX etc and would be optimized for driver development
>> in other langs, minicing the Java core API capabilities very close?
>> Any thoughts or preferences on one or the other? Does REST do a
>> sufficiently good job for production use from other langs? What would
>> you like to see in REST to get there - top 3 features?
>>
>
> My 3 cents:
> - Sockets maybe?
> - Support for Dates, and not only dates after Linux Epoch.
> - Support for do traversal with the geospatial information. Using GeoJSON or
> WKT?
>
>
>
> --
> Javier de la Rosa
> http://versae.es
> ___
> Neo4j mailing list
> User@lists.neo4j.org
> https://lists.neo4j.org/mailman/listinfo/user
>
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] New IndexProvider not registering

2010-11-26 Thread Peter Neubauer
Yup,
I now added a first draft of what this could look like. WDYAT? We can
later start doing Well Known Text queries and more complicated stuff,
we basically need a convention on what a named index would mean (right
now I assume a Layer name), and how we will have dynamic traversals
coming in later ...

https://github.com/neo4j/neo4j-spatial/blob/300f4d1d1fbb92d6252d5be6dc334250c9514bc7/src/test/java/org/neo4j/gis/spatial/IndexProviderTest.java#L51

Cheers,

/peter neubauer

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

http://www.neo4j.org               - Your high performance graph database.
http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.



On Fri, Nov 26, 2010 at 3:08 PM, Mattias Persson
 wrote:
> The best solution currently may be to skip the IndexProvider part and just
> implement a "SpatialIndex implements Index" or something which can be
> instantiated manually in the code.
>
> 2010/11/26 Mattias Persson 
>
>>
>>
>> 2010/11/26 Craig Taverner 
>>
>> This is interesting to me too, not just for the spatial index, but for the
>>> composite index which I'm working on. That too is a tree based index
>>> directly in the graph with the leaf nodes connected directly to the data
>>> nodes (indexed nodes). This is obviously very convenience because the
>>> index
>>> query in internally just a traversal. So there is great value in having
>>> the
>>> index in the same database as the data. It certainly comes as a surprise
>>> to
>>> me that this will be problematic.
>>>
>>> In my own applications, the index code is just like application code,
>>> using
>>> the same transactions and everything. That is clean and simple. Is it
>>> really
>>> necessary to have indexing somehow separated in a way that causes these
>>> issues?
>>>
>>
>> Each index can be associated with different implementations (f.ex. lucene,
>> spatial, whatever), so somewhere needs to be stored a mapping between index
>> name and its configuration. Everything stored in neo4j should go via a
>> logical log to be transactional and safe for recovery and also work well in
>> an HA environment where logical logs are the main means of transferring
>> data.
>>
>> Currently the commands for creating an index (storing a mapping
>> indexName->config) is stored in the lucene logical log (the main
>> implementation of an IndexProvider) because we don't want to mess with those
>> internals of neo4j right before a major release. Since the spatial index
>> uses the nioneo kernel data source there are no such commands to store in
>> that logical log, so doing it "the right way" is impossible a.t.m. Sure we
>> can store index configuration right there when an index is created, skipping
>> the logical log, but it won't work in an HA environment or be transactional
>> safe for recovery or any of that. The actual indexing/querying (which is
>> really operations on the graph) will work just as good as anything.
>>
>> Did that make it any more clear to you?
>>
>>
>>>
>>>
>>> On Fri, Nov 26, 2010 at 12:03 PM, Mattias Persson <
>>> matt...@neotechnology.com
>>> > wrote:
>>>
>>> > 2010/11/26 Peter Neubauer 
>>> >
>>> > > Mhh,
>>> > > it was the public constructors.
>>> > >
>>> > > Also, the Spatial Index will be operating on the same Neo4j graph
>>> > > instance and build an internal index. How am I going to server the XA
>>> > > Datasource etc in that case? Could I get hold of the one for the
>>> > > Kernel and return it maybe, or is there another mechaism signalling
>>> > > that this index is actually belonging to the same XA datasource as the
>>> > > kernel?
>>> > >
>>> >
>>> > That's what I meant in my previous post. I'll try to fix that, but I
>>> just
>>> > realized that there's internal problems which makes the possible
>>> solution
>>> > not work in an HA environment and feel quite "hackish". It's because of
>>> > "create index" and "delete index" commands lives in the lucene-index
>>> > component/logical log. And to move them to kernel could be a mismatch
>>> and
>>> > also it's too close to the next release to touch any of those things.
>>> >
>>> >
>>> > >
>>> > > Cheers,
>>> > >
>>> > > /peter neubauer
>>> > >
>>> > > GTalk:      neubauer.peter
>>> > > Skype       peter.neubauer
>>> > > Phone       +46 704 106975
>>> > > LinkedIn   http://www.linkedin.com/in/neubauer
>>> > > Twitter      http://twitter.com/peterneubauer
>>> > >
>>> > > http://www.neo4j.org               - Your high performance graph
>>> > database.
>>> > > http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing
>>> party.
>>> > >
>>> > >
>>> > >
>>> > > On Thu, Nov 25, 2010 at 9:38 PM, Mattias Persson
>>> > >  wrote:
>>> > > > 2010/11/25 Peter Neubauer 
>>> > > >
>>> > > >> Hi all,
>>> > > >> Craig and me thought of registering Neo4j-Spatial as a new
>>> > > >> IndexProvider, so you can set up a NodeIndex with all the
>>> geographic
>

Re: [Neo4j] Rest API requests

2010-11-26 Thread Peter Neubauer
Ok,
Andreas helped me to get RVM set up and things working.

When are you getting the problem? My testing ran good ...

/peter

On Wed, Nov 24, 2010 at 5:26 AM, Max De Marzi Jr.  wrote:
> Hum... not sure try just:
>
>  rspec spec/integration/rest_experimental_spec.rb
>
> On Tue, Nov 23, 2010 at 3:20 PM, Peter Neubauer
>  wrote:
>> Mmh,
>> to start with, I am stuck with some OpenSSL error when trying to run
>> rspecs:
>>
>> bundle exec rspec spec/integration/rest_node_spec.rb
>> JRuby limited openssl loaded. gem install jruby-openssl for full support.
>> http://jruby.kenai.com/pages/JRuby_Builtin_OpenSSL
>> JRuby limited openssl loaded. gem install jruby-openssl for full support.
>> http://jruby.kenai.com/pages/JRuby_Builtin_OpenSSL
>> No Extensions Found: /Users/peterneubauer/.neography
>> FFF
>>
>> Failures:
>>  1) Neography::Rest get_root can get the root node
>>     Failure/Error: root_node = @neo.get_root
>>     OpenSSL::SSL requires the jruby-openssl gem
>>     # ./lib/neography/rest.rb:268:in `get'
>>     # ./lib/neography/rest.rb:27:in `get_root'
>>     # ./spec/integration/rest_node_spec.rb:10
>>     # :1
>>
>>  2) Neography::Rest create_node can create an empty node
>>     Failure/Error: new_node = @neo.create_node
>>     uninitialized constant OpenSSL::SSL
>>     # ./lib/neography/rest.rb:272:in `post'
>>     # ./lib/neography/rest.rb:35:in `create_node'
>>     # ./spec/integration/rest_node_spec.rb:17
>>     # :1
>>
>>  3) Neography::Rest create_node can create a node with one property
>>     Failure/Error: new_node = @neo.create_node("name" => "Max")
>>     uninitialized constant OpenSSL::SSL
>>     # ./lib/neography/rest.rb:272:in `post'
>>     # ./lib/neography/rest.rb:33:in `create_node'
>>     # ./spec/integration/rest_node_spec.rb:22
>>     # :1
>>
>>
>> Any hints what could be the reason? I have installed
>>
>> gem install jruby-openssl but are still getting that error on Mac OSX.
>> Any hints?
>>
>> /peter
>> ___
>> 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] Traversal RelationshipExpander

2010-11-26 Thread Kalin Wilson Development
Thanks again, Craig. I think we're on the same track. I agree about the 'join' 
node. I'm not quite sure what to call it yet in my model but the concept looks 
right.
Thanks for the traversal tips, they make sense too.

Kalin

On Nov 25, 2010, at 4:50 AM, Craig Taverner wrote:

> Hi Kalin,
> 
> I'm not sure I follow about duplicating. The suggestion I made did not
> involve any duplicating. The AssetType nodes would contain properties
> appropriate to the type of asset, and the Asset node would contain
> properties only appropriate to that instance (or none if none are
> appropriate). Perhaps it is easier if I rather revert back to your original
> names, and use Asset for the type again, and come up with a new name for the
> specific instance? Then you get something like:
> 
> Producer[1] --(contributes_to)--> [X] <--(subscribes_to)-- Consumer1
>   |
> (IS_A)
>   |
>   V
>   Asset[P] <--(subscribes_to)-- Consumer2
> 
> 
> Now you can see that the X is really just like a join table in a relational
> database. In fact my suggestion is very similar to a common refactoring that
> occurs in a relational database when you have a foreign key to another table
> and then need to add properties to that relationship, you create an
> intermediate 'join table' and add the properties there.
> 
> I definitely still think you will need to expand your
> producer-asset-consumer triple to be a producer-x-asset-consumer, where the
> 'x' is the 'join table' that allows a consumer to subscribe to assets by a
> particular producer. Which is what you want, right?
> 
> I will answer, based on my model suggestion, each of the queries you ask
> below:
> 
> 1. Given a Consumer, what Assets does it subscribe to?
>> 
> 
> Traverse from consumer along both outgoing 'subscribes_to' and outgoing
> 'is_a' relationships, and you will get all assets regardless of whether the
> consumer subscribes to the asset in general, or the specific producer-asset.
> 
> 
>> 2. Given a Consumer, what Producers is it dependent upon?
>> 
> 
> Traverse from consumer along outgoing 'subscribes_to', incoming 'is_a' and
> incoming 'contributes_to' relationships, and you will get all producers of
> all assets (specific or otherwise) that the consumer subscribes to.
> 
> 
>> 3. Given a Producer, what Assets does it contribute to?
>> 
> 
> Traverse from producer along outgoing 'contributes_to', and outgoing 'is_a'
> relationships, and you get the Assets they they contribute to.
> 
> 
>> 4. Given a Producer, what Consumers are dependent on it?
>> 
> 
> Traverse from producer along outgoing 'contributes_to', outgoing 'is_a'
> relationships and incoming 'subscribes_to' and you get all Consumers that
> depend on assets that producer contributes to. This one is more subtle,
> though, because it depends on what you mean by 'dependent on'. Since the
> traverser I described will not exclude consumers that subscribe_to assets
> that are produced by both the given producer and others also (giving the
> consumer the choice of producer). If you only want consumers that have no
> choice, leave the 'is_a' relationship out of the traverser.
> 
> 
>> 5. Given an Asset, what Producers contribute to it and what Consumers
>> subscribe to it?
>> 
> 
> For producers traverse on incoming 'is_a' and incoming *contributes_to'. For
> consumers traverse on incoming 'is_a' and incoming 'subscribes_to'.
> 
> There's other node types and properties within the graph that aren't
>> important or that I can't discuss (this is a mock model anyway).
>> 
> 
> Hopefully the fact that I renamed my AssetType back to your original Asset,
> and have a new 'join table', possibly called 'producer-asset' for the
> additional concept I added before will make it easier to see how to fit this
> model into your existing structures.
> 
> What is the consensus about duplicating node data within a network? I can
>> see how using indexing or a hierarchy, as you've pointed out, might help
>> with that.
>> Part of my hangup is that I'm looking at using Neo4J as an adjunct to a
>> RDBMS to store dependency relationships. Each node will have information
>> that ties back to the RDBMS for lookups. But that doesn't require absolutely
>> unique nodes. Keeping the two DBs in sync will be a challenge but I don't
>> have the option to push all of the data into Neo4J and I'd rather not manage
>> the dependencies in the RDBMS.
>> 
> 
> I dislike duplicating data in neo4j as much as I dislike duplicating it in a
> RDBMS. I'm sorry if I gave the impression in my previous email that I was
> suggestion duplication. My suggestion was just the addition of this
> 'join-table' idea (an extra node in the graph), so make it possible to
> capture the concept of a consumer subscribing to an asset and an asset by a
> particular producer.
> 
> Actually, now that I've talked around it, I 

Re: [Neo4j] Release 1.0.0.beta.22

2010-11-26 Thread Javier de la Rosa
On Fri, Nov 26, 2010 at 02:03, Peter Neubauer <
peter.neuba...@neotechnology.com> wrote:

> Btw, what does everyone feel about REST vs. native protocols like RMI,
> Protobuffers, etc that can support a full Neo4j remote API for
> integration, with TX etc and would be optimized for driver development
> in other langs, minicing the Java core API capabilities very close?
> Any thoughts or preferences on one or the other? Does REST do a
> sufficiently good job for production use from other langs? What would
> you like to see in REST to get there - top 3 features?
>

My 3 cents:
- Sockets maybe?
- Support for Dates, and not only dates after Linux Epoch.
- Support for do traversal with the geospatial information. Using GeoJSON or
WKT?



-- 
Javier de la Rosa
http://versae.es
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] New IndexProvider not registering

2010-11-26 Thread Mattias Persson
The best solution currently may be to skip the IndexProvider part and just
implement a "SpatialIndex implements Index" or something which can be
instantiated manually in the code.

2010/11/26 Mattias Persson 

>
>
> 2010/11/26 Craig Taverner 
>
> This is interesting to me too, not just for the spatial index, but for the
>> composite index which I'm working on. That too is a tree based index
>> directly in the graph with the leaf nodes connected directly to the data
>> nodes (indexed nodes). This is obviously very convenience because the
>> index
>> query in internally just a traversal. So there is great value in having
>> the
>> index in the same database as the data. It certainly comes as a surprise
>> to
>> me that this will be problematic.
>>
>> In my own applications, the index code is just like application code,
>> using
>> the same transactions and everything. That is clean and simple. Is it
>> really
>> necessary to have indexing somehow separated in a way that causes these
>> issues?
>>
>
> Each index can be associated with different implementations (f.ex. lucene,
> spatial, whatever), so somewhere needs to be stored a mapping between index
> name and its configuration. Everything stored in neo4j should go via a
> logical log to be transactional and safe for recovery and also work well in
> an HA environment where logical logs are the main means of transferring
> data.
>
> Currently the commands for creating an index (storing a mapping
> indexName->config) is stored in the lucene logical log (the main
> implementation of an IndexProvider) because we don't want to mess with those
> internals of neo4j right before a major release. Since the spatial index
> uses the nioneo kernel data source there are no such commands to store in
> that logical log, so doing it "the right way" is impossible a.t.m. Sure we
> can store index configuration right there when an index is created, skipping
> the logical log, but it won't work in an HA environment or be transactional
> safe for recovery or any of that. The actual indexing/querying (which is
> really operations on the graph) will work just as good as anything.
>
> Did that make it any more clear to you?
>
>
>>
>>
>> On Fri, Nov 26, 2010 at 12:03 PM, Mattias Persson <
>> matt...@neotechnology.com
>> > wrote:
>>
>> > 2010/11/26 Peter Neubauer 
>> >
>> > > Mhh,
>> > > it was the public constructors.
>> > >
>> > > Also, the Spatial Index will be operating on the same Neo4j graph
>> > > instance and build an internal index. How am I going to server the XA
>> > > Datasource etc in that case? Could I get hold of the one for the
>> > > Kernel and return it maybe, or is there another mechaism signalling
>> > > that this index is actually belonging to the same XA datasource as the
>> > > kernel?
>> > >
>> >
>> > That's what I meant in my previous post. I'll try to fix that, but I
>> just
>> > realized that there's internal problems which makes the possible
>> solution
>> > not work in an HA environment and feel quite "hackish". It's because of
>> > "create index" and "delete index" commands lives in the lucene-index
>> > component/logical log. And to move them to kernel could be a mismatch
>> and
>> > also it's too close to the next release to touch any of those things.
>> >
>> >
>> > >
>> > > Cheers,
>> > >
>> > > /peter neubauer
>> > >
>> > > GTalk:  neubauer.peter
>> > > Skype   peter.neubauer
>> > > Phone   +46 704 106975
>> > > LinkedIn   http://www.linkedin.com/in/neubauer
>> > > Twitter  http://twitter.com/peterneubauer
>> > >
>> > > http://www.neo4j.org   - Your high performance graph
>> > database.
>> > > http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing
>> party.
>> > >
>> > >
>> > >
>> > > On Thu, Nov 25, 2010 at 9:38 PM, Mattias Persson
>> > >  wrote:
>> > > > 2010/11/25 Peter Neubauer 
>> > > >
>> > > >> Hi all,
>> > > >> Craig and me thought of registering Neo4j-Spatial as a new
>> > > >> IndexProvider, so you can set up a NodeIndex with all the
>> geographic
>> > > >> hints and setup you need, and then just index geometry nodes and
>> ask
>> > > >> spatial queries over it in order to make the component better
>> usable,
>> > > >> hopefully as easy as Lucene.
>> > > >>
>> > > >> Now, upon implementing
>> > > >>
>> > > >>
>> > >
>> >
>> https://github.com/neo4j/neo4j-spatial/blob/master/src/main/java/org/neo4j/gis/spatial/indexprovider/SpatialIndexProvider.java
>> > > >> and registering it like
>> > > >>
>> > > >>
>> > >
>> >
>> https://github.com/neo4j/neo4j-spatial/blob/master/src/main/resources/META-INF/services/org.neo4j.kernel.KernelExtension
>> > > >> ,
>> > > >> the test
>> > > >>
>> > >
>> >
>> https://github.com/neo4j/neo4j-spatial/blob/master/src/test/java/org/neo4j/gis/spatial/IndexProviderTest.java
>> > > >> is failing, saying that no index provider "spatial" was found.
>> > > >> Anything wrong in the process?
>> > > >>
>> > > >
>> > > > Sounds great, and be sure to express any difficulties/shortcomings

Re: [Neo4j] Release 1.0.0.beta.22

2010-11-26 Thread Rick Bullotta
Any time you introduce an unnecessary transformation step (native types ->
XML/JSON -> native types), you're introducing multiple types of overhead.
Perhaps a more native/binary protocol would enable a better generic remote
invocation layer (with multiple types of formats supported based on the
requestor's preference).  Also, the "atomicity" of the way many REST-ful
API's are designed/optimized often makes it difficult/undesirable to
maintain a 1:1 correlation with the Neo API. You might want to offer both a
"raw" (ability to do TX stuff) and an "atomic" (implicit transactions)
version.  I suppose another consideration if doing very granular API calls
remotely is connection and communications management (socket vs HTTP vs
whatever) and the implications of this in an HA environment.

I guess what I'm suggesting is that there probably is no single answer, and
the most functional solution may require multiple ways of surfacing Neo's
functionality to remote consumers.



-Original Message-
From: user-boun...@lists.neo4j.org [mailto:user-boun...@lists.neo4j.org] On
Behalf Of Peter Neubauer
Sent: Friday, November 26, 2010 2:04 AM
To: neo4jrb; Neo4j user discussions
Subject: Re: [Neo4j] Release 1.0.0.beta.22

Great stuff Andreas,
we had a great evening in Barcelona yesterday, showing off the great
work you, Ben and all the others are doing! Fantastic API and
features!

Craig and me are working on getting the Neo4j Spatial supported (at
least the basic features) as a normal index provider in Neo4j. That
would mean that you then in Neo4j.rb can directly ask not only text
queries with Lucene but even spatial queries. Would be very cool to
get that in, too :)

Btw, what does everyone feel about REST vs. native protocols like RMI,
Protobuffers, etc that can support a full Neo4j remote API for
integration, with TX etc and would be optimized for driver development
in other langs, minicing the Java core API capabilities very close?
Any thoughts or preferences on one or the other? Does REST do a
sufficiently good job for production use from other langs? What would
you like to see in REST to get there - top 3 features?

We are just trying to figure out the best way to expose and support
the different Remote options ...

Cheers,

/peter neubauer

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

http://www.neo4j.org               - Your high performance graph database.
http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.



On Thu, Nov 25, 2010 at 8:00 PM, Andreas Ronge 
wrote:
> Hi
>
> I've just released 1.0.0.beta.22
>
> The big news is that you can now use the rails console while the rails
> application is already running.
>
> I first tried to access neo4j remotely via RMI and DRb but there were
> to many problems doing that, so
> instead I simply create a read only neo4j db when needed.
>
> CHANGELOG
> * If a neo4j write instance is already running it will instead start a
> read only neo4j db instance.
> * Upgrade JARS to 1.2.M04
> * Does not automatically start Neo4j when used in Rails. E.g. now you
> can type rails routes without the database starting.
>
> --
> You received this message because you are subscribed to the Google Groups
"neo4jrb" group.
> To post to this group, send email to neo4...@googlegroups.com.
> To unsubscribe from this group, send email to
neo4jrb+unsubscr...@googlegroups.com.
> For more options, visit this group at
http://groups.google.com/group/neo4jrb?hl=en.
>
>
___
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] New IndexProvider not registering

2010-11-26 Thread Mattias Persson
2010/11/26 Craig Taverner 

> This is interesting to me too, not just for the spatial index, but for the
> composite index which I'm working on. That too is a tree based index
> directly in the graph with the leaf nodes connected directly to the data
> nodes (indexed nodes). This is obviously very convenience because the index
> query in internally just a traversal. So there is great value in having the
> index in the same database as the data. It certainly comes as a surprise to
> me that this will be problematic.
>
> In my own applications, the index code is just like application code, using
> the same transactions and everything. That is clean and simple. Is it
> really
> necessary to have indexing somehow separated in a way that causes these
> issues?
>

Each index can be associated with different implementations (f.ex. lucene,
spatial, whatever), so somewhere needs to be stored a mapping between index
name and its configuration. Everything stored in neo4j should go via a
logical log to be transactional and safe for recovery and also work well in
an HA environment where logical logs are the main means of transferring
data.

Currently the commands for creating an index (storing a mapping
indexName->config) is stored in the lucene logical log (the main
implementation of an IndexProvider) because we don't want to mess with those
internals of neo4j right before a major release. Since the spatial index
uses the nioneo kernel data source there are no such commands to store in
that logical log, so doing it "the right way" is impossible a.t.m. Sure we
can store index configuration right there when an index is created, skipping
the logical log, but it won't work in an HA environment or be transactional
safe for recovery or any of that. The actual indexing/querying (which is
really operations on the graph) will work just as good as anything.

Did that make it any more clear to you?


>
>
> On Fri, Nov 26, 2010 at 12:03 PM, Mattias Persson <
> matt...@neotechnology.com
> > wrote:
>
> > 2010/11/26 Peter Neubauer 
> >
> > > Mhh,
> > > it was the public constructors.
> > >
> > > Also, the Spatial Index will be operating on the same Neo4j graph
> > > instance and build an internal index. How am I going to server the XA
> > > Datasource etc in that case? Could I get hold of the one for the
> > > Kernel and return it maybe, or is there another mechaism signalling
> > > that this index is actually belonging to the same XA datasource as the
> > > kernel?
> > >
> >
> > That's what I meant in my previous post. I'll try to fix that, but I just
> > realized that there's internal problems which makes the possible solution
> > not work in an HA environment and feel quite "hackish". It's because of
> > "create index" and "delete index" commands lives in the lucene-index
> > component/logical log. And to move them to kernel could be a mismatch and
> > also it's too close to the next release to touch any of those things.
> >
> >
> > >
> > > Cheers,
> > >
> > > /peter neubauer
> > >
> > > GTalk:  neubauer.peter
> > > Skype   peter.neubauer
> > > Phone   +46 704 106975
> > > LinkedIn   http://www.linkedin.com/in/neubauer
> > > Twitter  http://twitter.com/peterneubauer
> > >
> > > http://www.neo4j.org   - Your high performance graph
> > database.
> > > http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing
> party.
> > >
> > >
> > >
> > > On Thu, Nov 25, 2010 at 9:38 PM, Mattias Persson
> > >  wrote:
> > > > 2010/11/25 Peter Neubauer 
> > > >
> > > >> Hi all,
> > > >> Craig and me thought of registering Neo4j-Spatial as a new
> > > >> IndexProvider, so you can set up a NodeIndex with all the geographic
> > > >> hints and setup you need, and then just index geometry nodes and ask
> > > >> spatial queries over it in order to make the component better
> usable,
> > > >> hopefully as easy as Lucene.
> > > >>
> > > >> Now, upon implementing
> > > >>
> > > >>
> > >
> >
> https://github.com/neo4j/neo4j-spatial/blob/master/src/main/java/org/neo4j/gis/spatial/indexprovider/SpatialIndexProvider.java
> > > >> and registering it like
> > > >>
> > > >>
> > >
> >
> https://github.com/neo4j/neo4j-spatial/blob/master/src/main/resources/META-INF/services/org.neo4j.kernel.KernelExtension
> > > >> ,
> > > >> the test
> > > >>
> > >
> >
> https://github.com/neo4j/neo4j-spatial/blob/master/src/test/java/org/neo4j/gis/spatial/IndexProviderTest.java
> > > >> is failing, saying that no index provider "spatial" was found.
> > > >> Anything wrong in the process?
> > > >>
> > > >
> > > > Sounds great, and be sure to express any difficulties/shortcomings
> with
> > > the
> > > > API so that it can improved for these kinds of scenarios.
> > > >
> > > > It may be that you have to make the constructor public (I don't know
> in
> > > what
> > > > way the service API uses reflection and all that). Also there's this
> > > > assumption that an IndexProvider provides its own data source. The
> > > spatial
> > > > index provider us

Re: [Neo4j] New IndexProvider not registering

2010-11-26 Thread Craig Taverner
This is interesting to me too, not just for the spatial index, but for the
composite index which I'm working on. That too is a tree based index
directly in the graph with the leaf nodes connected directly to the data
nodes (indexed nodes). This is obviously very convenience because the index
query in internally just a traversal. So there is great value in having the
index in the same database as the data. It certainly comes as a surprise to
me that this will be problematic.

In my own applications, the index code is just like application code, using
the same transactions and everything. That is clean and simple. Is it really
necessary to have indexing somehow separated in a way that causes these
issues?


On Fri, Nov 26, 2010 at 12:03 PM, Mattias Persson  wrote:

> 2010/11/26 Peter Neubauer 
>
> > Mhh,
> > it was the public constructors.
> >
> > Also, the Spatial Index will be operating on the same Neo4j graph
> > instance and build an internal index. How am I going to server the XA
> > Datasource etc in that case? Could I get hold of the one for the
> > Kernel and return it maybe, or is there another mechaism signalling
> > that this index is actually belonging to the same XA datasource as the
> > kernel?
> >
>
> That's what I meant in my previous post. I'll try to fix that, but I just
> realized that there's internal problems which makes the possible solution
> not work in an HA environment and feel quite "hackish". It's because of
> "create index" and "delete index" commands lives in the lucene-index
> component/logical log. And to move them to kernel could be a mismatch and
> also it's too close to the next release to touch any of those things.
>
>
> >
> > Cheers,
> >
> > /peter neubauer
> >
> > GTalk:  neubauer.peter
> > Skype   peter.neubauer
> > Phone   +46 704 106975
> > LinkedIn   http://www.linkedin.com/in/neubauer
> > Twitter  http://twitter.com/peterneubauer
> >
> > http://www.neo4j.org   - Your high performance graph
> database.
> > http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.
> >
> >
> >
> > On Thu, Nov 25, 2010 at 9:38 PM, Mattias Persson
> >  wrote:
> > > 2010/11/25 Peter Neubauer 
> > >
> > >> Hi all,
> > >> Craig and me thought of registering Neo4j-Spatial as a new
> > >> IndexProvider, so you can set up a NodeIndex with all the geographic
> > >> hints and setup you need, and then just index geometry nodes and ask
> > >> spatial queries over it in order to make the component better usable,
> > >> hopefully as easy as Lucene.
> > >>
> > >> Now, upon implementing
> > >>
> > >>
> >
> https://github.com/neo4j/neo4j-spatial/blob/master/src/main/java/org/neo4j/gis/spatial/indexprovider/SpatialIndexProvider.java
> > >> and registering it like
> > >>
> > >>
> >
> https://github.com/neo4j/neo4j-spatial/blob/master/src/main/resources/META-INF/services/org.neo4j.kernel.KernelExtension
> > >> ,
> > >> the test
> > >>
> >
> https://github.com/neo4j/neo4j-spatial/blob/master/src/test/java/org/neo4j/gis/spatial/IndexProviderTest.java
> > >> is failing, saying that no index provider "spatial" was found.
> > >> Anything wrong in the process?
> > >>
> > >
> > > Sounds great, and be sure to express any difficulties/shortcomings with
> > the
> > > API so that it can improved for these kinds of scenarios.
> > >
> > > It may be that you have to make the constructor public (I don't know in
> > what
> > > way the service API uses reflection and all that). Also there's this
> > > assumption that an IndexProvider provides its own data source. The
> > spatial
> > > index provider uses the graph itself (right?) so it could be a problem.
> > Let
> > > me look at and fix that, and then document how that's done for such a
> > > scenario (hopefully tomorrow).
> > >
> > >
> > >>
> > >> Cheers,
> > >>
> > >> /peter neubauer
> > >>
> > >> GTalk:  neubauer.peter
> > >> Skype   peter.neubauer
> > >> Phone   +46 704 106975
> > >> LinkedIn   http://www.linkedin.com/in/neubauer
> > >> Twitter  http://twitter.com/peterneubauer
> > >>
> > >> http://www.neo4j.org   - Your high performance graph
> > database.
> > >> http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing
> party.
> > >> ___
> > >> 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
> _

Re: [Neo4j] New IndexProvider not registering

2010-11-26 Thread Mattias Persson
2010/11/26 Peter Neubauer 

> Mhh,
> it was the public constructors.
>
> Also, the Spatial Index will be operating on the same Neo4j graph
> instance and build an internal index. How am I going to server the XA
> Datasource etc in that case? Could I get hold of the one for the
> Kernel and return it maybe, or is there another mechaism signalling
> that this index is actually belonging to the same XA datasource as the
> kernel?
>

That's what I meant in my previous post. I'll try to fix that, but I just
realized that there's internal problems which makes the possible solution
not work in an HA environment and feel quite "hackish". It's because of
"create index" and "delete index" commands lives in the lucene-index
component/logical log. And to move them to kernel could be a mismatch and
also it's too close to the next release to touch any of those things.


>
> Cheers,
>
> /peter neubauer
>
> GTalk:  neubauer.peter
> Skype   peter.neubauer
> Phone   +46 704 106975
> LinkedIn   http://www.linkedin.com/in/neubauer
> Twitter  http://twitter.com/peterneubauer
>
> http://www.neo4j.org   - Your high performance graph database.
> http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.
>
>
>
> On Thu, Nov 25, 2010 at 9:38 PM, Mattias Persson
>  wrote:
> > 2010/11/25 Peter Neubauer 
> >
> >> Hi all,
> >> Craig and me thought of registering Neo4j-Spatial as a new
> >> IndexProvider, so you can set up a NodeIndex with all the geographic
> >> hints and setup you need, and then just index geometry nodes and ask
> >> spatial queries over it in order to make the component better usable,
> >> hopefully as easy as Lucene.
> >>
> >> Now, upon implementing
> >>
> >>
> https://github.com/neo4j/neo4j-spatial/blob/master/src/main/java/org/neo4j/gis/spatial/indexprovider/SpatialIndexProvider.java
> >> and registering it like
> >>
> >>
> https://github.com/neo4j/neo4j-spatial/blob/master/src/main/resources/META-INF/services/org.neo4j.kernel.KernelExtension
> >> ,
> >> the test
> >>
> https://github.com/neo4j/neo4j-spatial/blob/master/src/test/java/org/neo4j/gis/spatial/IndexProviderTest.java
> >> is failing, saying that no index provider "spatial" was found.
> >> Anything wrong in the process?
> >>
> >
> > Sounds great, and be sure to express any difficulties/shortcomings with
> the
> > API so that it can improved for these kinds of scenarios.
> >
> > It may be that you have to make the constructor public (I don't know in
> what
> > way the service API uses reflection and all that). Also there's this
> > assumption that an IndexProvider provides its own data source. The
> spatial
> > index provider uses the graph itself (right?) so it could be a problem.
> Let
> > me look at and fix that, and then document how that's done for such a
> > scenario (hopefully tomorrow).
> >
> >
> >>
> >> Cheers,
> >>
> >> /peter neubauer
> >>
> >> GTalk:  neubauer.peter
> >> Skype   peter.neubauer
> >> Phone   +46 704 106975
> >> LinkedIn   http://www.linkedin.com/in/neubauer
> >> Twitter  http://twitter.com/peterneubauer
> >>
> >> http://www.neo4j.org   - Your high performance graph
> database.
> >> http://www.thoughtmade.com - Scandinavia's coolest Bring-a-Thing party.
> >> ___
> >> 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


Re: [Neo4j] Problems with neo4j-shell

2010-11-26 Thread Mattias Persson
standalone-shell is deprecated... please download the neo4j distribution
(f.ex. 1.2.M04) and use bin/neo4j-shell from there as your shell. You are
getting this error because you run the old standalone-shell distribution
which uses an older kernel (w/ NeoStore v0.9.5) on a db created with a newer
neo4j version.

http://neo4j.org/download


2010/11/26 Sebastian Stober 

> Dear list,
>
> I have been using neo4j-shell for debugging for quiet a while now but
> recently have run into some problems. Always, when I'm trying to connect
> to the database (using StartClient with the parameter var/tmp/neo ),
> there is the following message:
> --
> NOTE: Local Neo4j graph database service at 'var/tmp/neo'
> Welcome to the Neo4j Shell! Enter 'help' for a list of commands
>
> neo4j-sh[readonly] (0)$ java.lang.NullPointerException: nullnull
> neo4j-sh[readonly] (0)$ java.lang.NullPointerException: nullnull
> neo4j-sh[readonly] (0)$ java.lang.NullPointerException: nullnull
> neo4j-sh[readonly] (0)$ java.lang.NullPointerException: nullnull
>
> the last line repeats in a loop. This message appears, when using the
> 1.2.M03-shell.
> ---
> The standalone-shell throws the following exception:
> Caused by:
> org.neo4j.kernel.impl.nioneo.store.IllegalStoreVersionException: Store
> version [NeoStore v0.9.6]. Please make sure you are not running old
> Neo4j kernel  towards a store that has been created by newer version  of
> Neo4j.
> ---
> I have tested it with a database, which operates well with the
> neo4j-release 1.2 and the standalone-shell and I have tested it with a
> fresh database generated from the following code:
>
>  GraphDatabaseService neo = new EmbeddedGraphDatabase("var/tmp/neo");
>  neo.shutdown();
>
> Using 1.2.M03, the standalone-shell and the 1.2.M03-shell do not work
> anymore. An update to M04 did not change anything.
>
> It seems to me that at least since M03 something in the shell is broken
> or I am missing something that since then changed in the handling of the
> shell.
>
> Any help on how to resolve this problem would be very much appreciated.
>
> Best regards,
> Sebastian Stober
> ___
> 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] Problems with neo4j-shell

2010-11-26 Thread Sebastian Stober
Dear list,

I have been using neo4j-shell for debugging for quiet a while now but
recently have run into some problems. Always, when I'm trying to connect
to the database (using StartClient with the parameter var/tmp/neo ),
there is the following message:
--
NOTE: Local Neo4j graph database service at 'var/tmp/neo'
Welcome to the Neo4j Shell! Enter 'help' for a list of commands

neo4j-sh[readonly] (0)$ java.lang.NullPointerException: nullnull
neo4j-sh[readonly] (0)$ java.lang.NullPointerException: nullnull
neo4j-sh[readonly] (0)$ java.lang.NullPointerException: nullnull
neo4j-sh[readonly] (0)$ java.lang.NullPointerException: nullnull

the last line repeats in a loop. This message appears, when using the
1.2.M03-shell.
---
The standalone-shell throws the following exception:
Caused by:
org.neo4j.kernel.impl.nioneo.store.IllegalStoreVersionException: Store
version [NeoStore v0.9.6]. Please make sure you are not running old
Neo4j kernel  towards a store that has been created by newer version  of
Neo4j.
---
I have tested it with a database, which operates well with the
neo4j-release 1.2 and the standalone-shell and I have tested it with a
fresh database generated from the following code:

  GraphDatabaseService neo = new EmbeddedGraphDatabase("var/tmp/neo");
  neo.shutdown();

Using 1.2.M03, the standalone-shell and the 1.2.M03-shell do not work
anymore. An update to M04 did not change anything.

It seems to me that at least since M03 something in the shell is broken
or I am missing something that since then changed in the handling of the
shell.

Any help on how to resolve this problem would be very much appreciated.

Best regards,
Sebastian Stober
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore

2010-11-26 Thread Axel Morgner
Ok, got everything working again, running on 1.2-SNAPSHOT now.
Quite faster than 1.1, BTW. :-)

Just in case: Is there a neo4j-spatial version which works well with 
neo4j-1.1?

Thanks

Axel

On 26.11.2010 10:40, Anders Nawroth wrote:
> Hi!
>
> 2010-11-26 10:31, Mattias Persson skrev:
>> It may be that neo4j-spatial 0.3-SNAPSHOT depends on a later kernel/index
>> version (probably 1.2-SNAPSHOT, i.e. latest trunk).
> That's exactly how it is according to the pom.xml:
> https://github.com/neo4j/neo4j-spatial/blob/master/pom.xml
>
> /anders
>
>> In that case there's a
>> conflict. Could you instead depend on a stable spatial version or upgrade to
>> latest kernel/index versions?

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


Re: [Neo4j] NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore

2010-11-26 Thread Anders Nawroth
Hi!

2010-11-26 10:31, Mattias Persson skrev:
> It may be that neo4j-spatial 0.3-SNAPSHOT depends on a later kernel/index
> version (probably 1.2-SNAPSHOT, i.e. latest trunk).

That's exactly how it is according to the pom.xml:
https://github.com/neo4j/neo4j-spatial/blob/master/pom.xml

/anders

> In that case there's a
> conflict. Could you instead depend on a stable spatial version or upgrade to
> latest kernel/index versions?
>
> 2010/11/26 Axel Morgner
>
>> Hi,
>>
>> since yesterday late evening I'm getting an exception when doing
>> GraphDatabaseServicegraphDb = new EmbeddedGraphDatabase(dbPath):
>>
>> Could not create data source [lucene-index], see nested exception for
>> cause of error
>> java.lang.NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore
>>
>> This is my neo4j part of pom.xml:
>>
>> 
>> org.neo4j
>> neo4j-kernel
>> 1.1
>> 
>> 
>> org.neo4j
>> neo4j-index
>> 1.1
>> jar
>> false
>> 
>> 
>> org.neo4j
>> neo4j-spatial
>> 0.3-SNAPSHOT
>> 
>>
>> Was there an API change lately?
>>
>> Regards
>>
>> Axel
>> ___
>> 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] NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore

2010-11-26 Thread Axel Morgner
Yes, that's I figured out just a second ago. :-)

I'll try both options.

Thanks

On 26.11.2010 10:31, Mattias Persson wrote:
> It may be that neo4j-spatial 0.3-SNAPSHOT depends on a later kernel/index
> version (probably 1.2-SNAPSHOT, i.e. latest trunk). In that case there's a
> conflict. Could you instead depend on a stable spatial version or upgrade to
> latest kernel/index versions?
>
> 2010/11/26 Axel Morgner
>
>> Hi,
>>
>> since yesterday late evening I'm getting an exception when doing
>> GraphDatabaseServicegraphDb = new EmbeddedGraphDatabase(dbPath):
>>
>> Could not create data source [lucene-index], see nested exception for
>> cause of error
>> java.lang.NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore
>>
>> This is my neo4j part of pom.xml:
>>
>> 
>> org.neo4j
>> neo4j-kernel
>> 1.1
>> 
>> 
>> org.neo4j
>> neo4j-index
>> 1.1
>> jar
>> false
>> 
>> 
>> org.neo4j
>> neo4j-spatial
>> 0.3-SNAPSHOT
>> 
>>
>> Was there an API change lately?
>>
>> Regards
>>
>> Axel
>> ___
>> 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] NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore

2010-11-26 Thread Mattias Persson
It may be that neo4j-spatial 0.3-SNAPSHOT depends on a later kernel/index
version (probably 1.2-SNAPSHOT, i.e. latest trunk). In that case there's a
conflict. Could you instead depend on a stable spatial version or upgrade to
latest kernel/index versions?

2010/11/26 Axel Morgner 

> Hi,
>
> since yesterday late evening I'm getting an exception when doing
> GraphDatabaseServicegraphDb = new EmbeddedGraphDatabase(dbPath):
>
> Could not create data source [lucene-index], see nested exception for
> cause of error
> java.lang.NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore
>
> This is my neo4j part of pom.xml:
>
> 
> org.neo4j
> neo4j-kernel
> 1.1
> 
> 
> org.neo4j
> neo4j-index
> 1.1
> jar
> false
> 
> 
> org.neo4j
> neo4j-spatial
> 0.3-SNAPSHOT
> 
>
> Was there an API change lately?
>
> Regards
>
> Axel
> ___
> 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] NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore

2010-11-26 Thread Axel Morgner
Hi,

since yesterday late evening I'm getting an exception when doing 
GraphDatabaseServicegraphDb = new EmbeddedGraphDatabase(dbPath):

Could not create data source [lucene-index], see nested exception for 
cause of error
java.lang.NoClassDefFoundError: org/neo4j/kernel/impl/index/IndexStore

This is my neo4j part of pom.xml:


org.neo4j
neo4j-kernel
1.1


org.neo4j
neo4j-index
1.1
jar
false


org.neo4j
neo4j-spatial
0.3-SNAPSHOT


Was there an API change lately?

Regards

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