That sounds really interesting. From what I understand about AREL, (not a 
lot), you'd simply create a new visitor to translate the nodes into CQL, 
just like there's a visitor to translate the nodes into dot for input into 
graphviz. 

It'll be sometime before I need this. I'm currently developing on 
Postgresql, but if scaling becomes an issue then AREL+CQL to Cassandra will 
be plan B for us.

I'll be watching this thread with interest, and if I do need it I'll chip 
in an help.

John Small


On Tuesday, 26 August 2014 19:13:16 UTC+1, Oleh Novosad wrote:
>
> I have an idea but not sure it is good or not (i am not very familiar with 
> rails internal architecture details yet).
>
> Recently I got interested in Cassandra DB("no sql" db). It has it's uses.
>
> ( I am not in any way related to Cassandra team or Datastax)
>
> And I thought, wouldn't it be cool to use Cassandra in the same way we use 
> other dbs supported by ActiveRecord.
>
> Cassandra uses CQL language (Cassandra Query Language). CQL is similar to 
> SQL with some additional features and some limitations.
> I checked Arel gem. And it looks to me that it will not be hard to make it 
> work with CQL as well. Some nodes should be added like TTL (time to live) - 
> really nice feature of Cassandra. Other some nodes probably will do nothing 
> in case of CQL.
>
> So idea is next:
> + To add support of CQL in Arel. Probably joins are also possible but with 
> two queries (probably in one cassandra batch?)
> + Make ActiveRecord to support Arel's new features like ttl.
> + World is moving to using different databases for different purposes in 
> the same project. So maybe it is not bad idea to make rails support SQL 
> database and CQL database simultaneously? 
>
> I am not sure those are good ideas, so could you please share your 
> thoughts about it? 
> If idea is good enough I can implement it (using cql-rb driver, arel, 
> active_record).
>
> Thank you
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Core" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/rubyonrails-core.
For more options, visit https://groups.google.com/d/optout.

Reply via email to