schema dilema, is neo4j the right choice

I want to create the following schema User <-> Tag <-> Content -> SubContent <-> User

There are many-to-many connections between user and tag

There are many-to-many connections between tag and content

There is one-to-many connections between content and subcontent

There are many-to-many connections between subcontent and user

So there is a lot of connections here, Thats why I thought that neo4j would be a right choice.

My main queries would be to get the relationships of certain tags and access subcontent that is connected to certain users.

What do you think?

Answers


I think a graph db, and neo4j in particular, would be ideally suited. Having the multiple many-to-many relationships, and given how you are planning on 'browsing' the data are really in the graphdb sweet spot.


Fully agree with Dan G. A Graph db and Neo4j makes sense here. I have a very similar domain model and it feels like "cheating" everytime i query for something (coming from SQL). Also adding properties to the relationship themselfs can add extra info, like "stength" or "amount" on the content CONTAINS subcontent relationship.

Also "future proof" architecture if you would like to add something else in the future like SIMILARTY relationship between tags.


Need Your Help

Xcode code documentation

ios xcode4

Are there any guidelines/standards about how to document the code written in XCode? I mean, is there a way to document the code if you want to make it easily understandable to others? Does XCode pr...

Putting MQ message in a queue

c# .net ibm-mq

I have a software where i drop MQMessages through C# software.