Ecto: Cassandra Support

Created on 26 Jan 2016  Â·  12Comments  Â·  Source: elixir-ecto/ecto

Is it reasonable to add Cassandra support to Ecto? I'd definitely be interested in contributing this support.

Most helpful comment

Personally exploring Phoenix for its streaming capability for live and historical financial data series into client fixed income analysis endpoint which I plan to write. Cassandra is a must-have in this domain. Its data model ensures contiguous data storage which, for time series, is crucial, considering the quantities of data involved in range queries.

As an example, client queries a series, of which there are thousands, each with potentially up to millions of data points. This is a terrible use case for SQL. It's a huge use case for time series data. I plan to explore using Phoenix to stream both the historical, on demand requests, and then, live data updates (up to several times per second for each series).

All 12 comments

I am not that familiar with Cassandra to have an answer for this question. I think some folks were working on a Cassandra driver and that would be the first step. I am copying @lexmag but you can ping him here or on IRC for more info. :) Once the driver is built, this will definitely be a discussion worth having and I will be glad to help.

I believe it doesn't worth the efforts. Cassandra does have SQL-like syntax but it lacks very much of existing features from SQL (e.g. no GROUP BY). Most importantly data model is different: partition and clustering keys, wide rows, etc.

Personally exploring Phoenix for its streaming capability for live and historical financial data series into client fixed income analysis endpoint which I plan to write. Cassandra is a must-have in this domain. Its data model ensures contiguous data storage which, for time series, is crucial, considering the quantities of data involved in range queries.

As an example, client queries a series, of which there are thousands, each with potentially up to millions of data points. This is a terrible use case for SQL. It's a huge use case for time series data. I plan to explore using Phoenix to stream both the historical, on demand requests, and then, live data updates (up to several times per second for each series).

@vegabook Cassandra is definitely a great database and a life-saviour in many use cases. However, I agree with @lexmag, IMO an Ecto adapter would have a very hard time "mapping" to Cassandra concepts.

@whatyouhide Would I be able to bypass ecto via the Erlang Cassandra tools? Could I use a nominal Postgres installation alongside Cassandra and use Phoenix effectively? Apols the silly questions - exploring only here as want to get the tech stack right to avoid problems down the line.

@vegabook you can certainly use Erlang drivers for Cassandra with Phoenix. Anyways, the issue tracker is not a place for discussing these things :smiley: You can try asking these questions in the phoenix-talk mailing list, on IRC or on Elixir's Slack room.

@vegabook maybe a little bit late, but... https://github.com/vintikzzz/cassandra_ecto

oooh - not late at all. Many thanks! Will check it out.

On Wed, Dec 7, 2016 at 8:08 PM, Pavel Tatarskiy notifications@github.com
wrote:

@vegabook https://github.com/vegabook maybe a little bit late, but...
https://github.com/vintikzzz/cassandra_ecto

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/elixir-ecto/ecto/issues/1220#issuecomment-265558902,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ADmxE5_6nh71V-gglTvM64A0JR6T__n2ks5rFxIxgaJpZM4HMqvc
.

@vintikzzz Glad to see more ppl are using Elixir/Ecto and Cassandra.

Have you saw https://github.com/cafebazaar/ecto-cassandra? Wondering what are your thoughts on what difference there are between the packages if any.

I think we have a very small community for Elixir/Cassandra users, may make faster progresses if we all joint forces.

@hisea both projects were made just in the same time and have quite close functionality. When I've started cassandra_ecto there were no alternatives at all. Main difference between projects that ecto-cassandra stays on top of elixir library elixir-cassandra and cassandra_ecto stays on top of erlang library cqerl. Also I should notice that ecto-cassandra has very poor documentation.
If you want to help please feel free to contribute to cassandra_ecto or to ecto-cassandra.

Thanks @vintikzzz I will try it out.

Any updates on this? :)

Was this page helpful?
0 / 5 - 0 ratings