Pacer:
https://github.com/pangloss/pacer
http://ofallpossibleworlds.wordpress.com/2010/12/19/introducing-pacer/
Gremlin:
https://github.com/tinkerpop/gremlin/wiki
> --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-...@googlegroups.com.
> To unsubscribe from this group, send email to
> rails-oceani...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/rails-oceania?hl=en.
>
Take a look at neo4j:
http://neo4j.org/
http://wiki.neo4j.org/content/Getting_Started_With_Ruby
https://github.com/andreasronge/neo4j
Cheers,
Chris
Yeah, thanks.
I know about neo4j but have been reluctant to try it due to the Java roots.
I also thought to try MagLev for a while, but couldn't get my hands onto it.
If possible, I would prefer not to diverge from SQL Db. So maybe I am just after a good way of denormalising data...
Or maybe just optimise relational DB for reads, and process the "propagations" as the backgrond job (It's ok to have a delay of a. couple of minutes)...
Thanks Andrew. I'll definitely keep that in mind.
But I'll try to avoid using Java libs if other solutions available.
Maybe I really just have to denormalise some of the data...
The graph itself is not massive (5000-10000 objects). But takes 10 seconds to traverse/update in some cases.
Probably I can multithread it. Just need to make sure DB is not in an exclusive lock :)
Or even offloading it into queue may do the job.
What do you think about it?
--
You received this message because you are subscribed to the Google Groups "Ruby or Rails Oceania" group.
To view this discussion on the web visit https://groups.google.com/d/msg/rails-oceania/-/FqGMliNa4I4J.
I wonder how you guys work with the persistent ordered graph structures.What I need to be able to do is to propagate all the changes from a node to all its child nodes recursively.A node is basically a permission (loaded with the information, such as subject, user, company etc) that is propagated through to the other nodes.
A node is basically a permission (loaded with the information, such as subject, user, company etc) that is propagated through to the other nodes.Is "propagating changes to all child node recursively" a strategy to improve query performance?
If so, you might look at an ActiveRecord extension such as my "Arboreal" (shameless plug), or DHH's "acts_as_nested_set", to allow efficient queries on a tree structure.I did presentation last year, that included an example of using Arboreal to query down a hierarchy (e.g. of roles or groups) while joining with another table (e.g. permissions). See page 10 of:
I used to work (2000-2004) for a company that built a graph DB, this
kind of performance was pretty standard back then, actually from
memory we were loading ~4-8K records (well triples) per second
linearly with DB sizes in the hundreds of millions of records [2].
It's really about having the right kind of structure for the data,
sounds like your data just isn't right for an SQL DB. For nostalgia, I
did some more digging & found this old whitepaper [3] which kind of
explains it (~p10), may be helpful.
Tom
[1] http://www.brosql.org/events/40496652/
[2] http://www.w3.org/2004/04/13-swdd/#rdfstore
[3] http://itee.uq.edu.au/~dwood/docs/new_type_of_data_management.pdf
--
tom adams
e:tomjadams<at>gmail.com
Inserting ~1000 relationships (batched and transactional!) already having the DB with ~4 million entries.It took ~450 ms. And it's over HTTP, not native bindings.I am really, really now considering neo4j.Even if I'll have to give up all the ActiveRecord goodness and all the current code.