I'm working on transferring an existing Ruby on Rails project from Postgres to Cassandra and I have a couple questions about the Ruby client libraries and client libraries in general.
1.) Is it the opinion of the community and the Datastax engineers that client libraries should migrate away from thrift and should use CQL instead?
2.) Is anyone working on a CQL Ruby client?
3.) Other than the fauna/twitter client what are other people using for Ruby?
4.) If someone were to take it upon themselves to write yet another Ruby cassandra client is there any particular library that is generally accepted as good and could act as an archetype for other implementations (Hector)?
This is definitely not at all an authoritative opinion... I am still figuring things out with Cassandra... Others may want to correct me...
Charles Maxwood(sp?) started a 'Sandra' project on github to make access to Cassandra, more or less, similar to Active Record... it is very early stage work, but you may want to check with him and see what is happening... I forked it thinking that I can push hard and get it working, but elas... haven't gotten to it yet...
I think 'Sandra' uses the fauna 'cassandra' gem, but I may be wrong..
Good luck, and keep us informed... I may be able to help early in January 2012..
On Mon, Dec 5, 2011 at 1:59 AM, Matthew Stump <[hidden email]> wrote:
In reply to this post by mrevilgnome
From: "Matthew Stump" <[hidden email]>The CQL interface is a bit more insulated from the internals of Cassandra. It was designed so that you would be able to use the same CQL version across different versions of Cassandra. This makes CQL quite a bit easier for the client/driver developers as well.
There already is a great CQL ruby client. It is hosted in apache-extras on Google Code . A little while back I did a simple comparison between the cassandra-cql client and the twitter(formerly fauna) cassandra client. Rick Olson then made another quick comparison amongst twitter/cassandra, cassandra-cql, and pycassa (Python client). In both sets of tests the cassandra-cql client came out doing quite well.
4.) If someone were to take it upon themselves to write yet another Ruby cassandra client is there any particular library that is generally accepted as good and could act as an archetype for other implementations (Hector)?Not sure on this one. We have been using twitter/cassandra and are migrating to cassandra-cql. Two of the things that we are working on internally are an ActiveModel implementation, and some sort of search API. These are trivially implemented on top of the cassandra-cql library, but sometimes it is nice not having to construct the CQL/SQL manually.
 - https://rubygems.org/gems/cassandra-cql
 - http://code.google.com/a/apache-extras.org/p/cassandra-ruby/
 - https://gist.github.com/1185026
 - https://gist.github.com/1363336
Ah yes, I should clarify. What I should have said was an ORM type library which uses cassandra-cql as it's base. What I was looking for was someone that had wrapped cassandra-cql with an active record or data mapper compatibility layer.
My concern is that it i'm looking for a ruby client that I can base a bunch of code around for the next couple years. I didn't want to hop on one bandwagon and then have myself limited or run into compatibility issues as new releases of C* come out. As I understand it CQL was created to provide that stable interface for library developers. If that is true it would make sense for me to search out an ORM which uses CQL underneath?
Basically what I'm trying to do is validate these assumptions, and if they are true possibly finance the work for a CQL based ORM, or if not then write a bunch of code around one of the other libraries.
Until then I'll search out the resources you mentioned. Thanks.
On Dec 5, 2011, at 6:17 AM, Robert Jackson wrote:
In reply to this post by mrevilgnome
On Sun, Dec 4, 2011 at 11:59 PM, Matthew Stump <[hidden email]> wrote:
> 3.) Other than the fauna/twitter client what are other people using for Ruby?
I'm probably the only person using JRuby + Hector. This ended up
being a big win since to get high performance with Cassandra you
either need many clients or a multi-threaded client and JRuby is fully
threaded/supports native threads.
The downside of being the only person doing it is trying to debug
things. I'm not a Java guy by any means so going down this path has
added extra complexity and occasional JRuby specific bugs (mostly on
the Rails side, not Hector/Cassandra which has been pretty rock solid
so far in my testing).
I basically wrote my own custom ORM on top of Hector. It's not AR
compliant or anything like that and pretty application specific.
Mostly it just tries to simplify the Hector API.
http://synfin.net/ Twitter: @synfinatic
http://tcpreplay.synfin.net/ - Pcap editing and replay tools for Unix & Windows
Those who would give up essential Liberty, to purchase a little temporary
Safety, deserve neither Liberty nor Safety.
-- Benjamin Franklin
"carpe diem quam minimum credula postero"
|Free forum by Nabble||Edit this page|