incubator-cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ran Tavory <ran...@gmail.com>
Subject Re: Announcing OCM - The Object Cassandra Mapper
Date Mon, 22 Mar 2010 08:35:12 GMT
This looks very interesting, thank for contributing and I'm glad you found
hector useful :)
You mention indexing - iirc, cassandra is adding this as an internal feature
in 0.7.0, just fyi (and if I'm not mistaken). But I'm also wondering, how do
you deal with consistency here? For example, what if a value was written
successfully but writing the index failed? The word "transaction" comes to
mind, but I feel like transactions are a bit odd to cassandra's spirit, so I
was wondering what's your take on it?

On Mon, Mar 22, 2010 at 12:07 AM, Charlie Mason <charlie.mas@gmail.com>wrote:

> Hi All,
>
> I am going to be using Cassandra for a project I am working on. To
> enable me to use it more easily I have built a relatively simple ORM
> to simplify access to Cassandra and to provide some extra
> functionality. When I say ORM I am not talking about developing a
> Hibernate for Cassandra, OCM is much more light weight than that and
> tailored to the Cassandra data model.
>
> It has a simple Specification file format that defines how you want to
> map your data to objects in your chosen programming language.  This is
> then fed into the OCM complier which generates a series of human
> readable source files in the specified language. This combined with
> base OCM library can be used by your app. It also generates the
> storage-config.xml file for you.
>
> Currently there is only a Java backend for the OCM complier, although
> it should be relatively straight forward to add support for other
> languages as all the code generation is done form simple Velocity
> templates. The Java backend uses the Hector library to interface with
> Cassandra and so benefits from load balancing and connection pooling.
>
> OCM has a few extra features on top of basic CRUD style persistence:
>
> Any column can be marked as Indexed. OCM automatically maintains a
> secondary table mapping the column to the key of parent Column Family.
> Changes made through OCM automatically update the index. It also
> provides a static method in the Java language to obtain a row using
> the indexed field e.g. usersByEmail for a standard user table with the
> user id as the key.
>
> Many2Many relationships can also be defined. These are implemented as
> a Supper Column in both tables. OCM maintains both of these
> automatically as and when they are updated or removed.
>
> The Range Scanner provides a simple interface to obtain records by
> scanning a accross a number of keys. It splits the range scan into a
> number of range slice calls, so you can gradually progress through
> very large scan ranges just be asking for the next row form OCM.
>
>
> Its available under the Apache license on Git Hub.
>
> http://github.com/charliem/OCM
>
> Let me know what you think or if you have any questions. Contributions
> are more than welcome if anyone else is interested in using it. Its
> still a bit rough around the edges although most of the basic
> functionality is working, at least for Java apps.
>
>
> Charlie M
>

Mime
View raw message