Re: [Neo4j] Hybrid Relational + Graph solution

2011-07-23 Thread Michael Hunger
Felipe,

Your approach is sensible if you have a lot of tooling / code around your 
relational model.

Do you use JPA or some other ORM or just plain JDBC ?

You might have a look at Spring Data Graph cross-store approach: 
http://bit-ly/sdg-html#cross-store (and perhaps Spring Data Graph in general 
http://springsource.org/spring-data/neo4j )

If you want to use the properties while traversing the graph it would probably 
more sensible to move the data to the graph? How big is your dataset? 

You wrote I'm _creating_  so if you start out, I'd try to go with the graph 
database. 

I think the APIs are clean and easy enough for your developers to get them, and 
you now also got cypher as query language which should be understandable for a 
developer.

Does your data(base) also contain like large blobs and such? Those should 
perhaps not be stored in the graph (it's not optimized for that kind of data).

I'd like to iterate with you about your use-case.

Perhaps a one day free form coding session (hackathon) with Neo4j would allow 
your developers to easily catch up and have some fun at the same time. I'm sure 
you'll be surprised.

Cheers

Michael

Am 23.07.2011 um 06:52 schrieb Felipe Oliveira Carvalho:

 I'm creating a social network. I would like to use Neo4J to represent the
 relationships between people (FOLLOWS, WENT_TO, LIKES) and other objects I
 have in my network. I already started storing the users (and other objects)
 in PostgreSQL tables.
 
 Is it reasonable to use PostgreSQL to store the objects while using Neo4J to
 store the relationships between these objects? I would use ids as vertex
 properties and would fetch the data for each object from PostgreSQL.
 
 One problem I see with this approach is that if I want to traverse the graph
 and use the data of the objects I would have to duplicate the data and add
 more properties to the vertexes.
 
 But I also think that minimizing the use of Neo4J would make it easier for
 the other developers of the team that are used to relational databases.
 
 Do you see more problems on this approach? Does it make thinks much more
 complicated?
 
 Thanks!
 Felipe
 ___
 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] Hybrid Relational + Graph solution

2011-07-23 Thread Felipe Oliveira Carvalho
 Your approach is sensible if you have a lot of tooling / code around your 
 relational model.

I don't have.

 Do you use JPA or some other ORM or just plain JDBC ?

None. I'm using PHP for the front end and Java for services using
Thrift for communication between the PHP and Java.

 You might have a look at Spring Data Graph cross-store approach:
 http://bit-ly/sdg-html#cross-store (and perhaps Spring Data Graph in general 
 http://springsource.org/spring-data/neo4j )

 If you want to use the properties while traversing the graph it would 
 probably more sensible to move the data to the graph? How big is your dataset?

 You wrote I'm _creating_  so if you start out, I'd try to go with the graph 
 database.

 I think the APIs are clean and easy enough for your developers to get them, 
 and you now also got cypher as query language which should be understandable 
 for a developer.

I will use Neo4J for the data that fits better in a graph and use
PostgreSQL for table-friendly data because I'm really excited about
Neo4J.

 Does your data(base) also contain like large blobs and such? Those should 
 perhaps not be stored in the graph (it's not optimized for that kind of data).

I'm actually starting this project now. I'll have posts and comments
(not really large text fields). I don't think this kind of data should
be modeled as a graph.


I'm trying to make the code cache friendly using these abstractions
used by Facebook:
http://www.infoq.com/presentations/Evolution-of-Code-Design-at-Facebook

I think this approach fits even better with NeoJ4 than any other ORM
based solution.

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


[Neo4j] Hybrid Relational + Graph solution

2011-07-22 Thread Felipe Oliveira Carvalho
I'm creating a social network. I would like to use Neo4J to represent the
relationships between people (FOLLOWS, WENT_TO, LIKES) and other objects I
have in my network. I already started storing the users (and other objects)
in PostgreSQL tables.

Is it reasonable to use PostgreSQL to store the objects while using Neo4J to
store the relationships between these objects? I would use ids as vertex
properties and would fetch the data for each object from PostgreSQL.

One problem I see with this approach is that if I want to traverse the graph
and use the data of the objects I would have to duplicate the data and add
more properties to the vertexes.

But I also think that minimizing the use of Neo4J would make it easier for
the other developers of the team that are used to relational databases.

Do you see more problems on this approach? Does it make thinks much more
complicated?

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