Differences between revisions 5 and 6
Revision 5 as of 2009-09-20 23:34:46
Size: 1523
Editor: localhost
Comment: converted to 1.6 markup
Revision 6 as of 2013-11-13 00:56:57
Size: 1584
Editor: GehrigKunz
Comment: statcounter
Deletions are marked like this. Additions are marked like this.
Line 37: Line 37:

{{https://c.statcounter.com/9397521/0/fe557aad/1/|stats}}

Case Study 1: Delicious clone

Our first case study is an example of how one would structure the schema for a Delicious clone. We'll also provide some examples of 'insert'ing and 'get'ing data.

Here's our schema:

<Keyspace Name="DeliciousClone">
  <KeysCachedFraction>0.01</KeysCachedFraction>
  <ColumnFamily CompareWith="UTF8Type" Name="Users"/>
  <ColumnFamily CompareWith="UTF8Type" Name="Bookmarks"/>
  <ColumnFamily CompareWith="UTF8Type" Name="Tags"/>
  <ColumnFamily CompareWith="UTF8Type" Name="UserTags"/>
  <ColumnFamily CompareWith="UTF8Type" CompareSubcolumnsWith="TimeUUIDType" ColumnType="Super" Name="UserBookmarks"/>
</Keyspace>

Case Study 2: Twitter clone

Our schema:

<Keyspace Name="TwitterClone">
  <KeysCachedFraction>0.01</KeysCachedFraction>
  <ColumnFamily CompareWith="UTF8Type" Name="Users" />
  <ColumnFamily CompareWith="UTF8Type" Name="UserAudits" />
  <ColumnFamily CompareWith="UTF8Type" CompareSubcolumnsWith="TimeUUIDType" ColumnType="Super" Name="UserRelationships" />
  <ColumnFamily CompareWith="UTF8Type" Name="Usernames" />
  <ColumnFamily CompareWith="UTF8Type" Name="Statuses" />
  <ColumnFamily CompareWith="UTF8Type" Name="StatusAudits" />
  <ColumnFamily CompareWith="UTF8Type" CompareSubcolumnsWith="TimeUUIDType" ColumnType="Super" Name="StatusRelationships" />
</Keyspace>

Taken from Evan Weaver's Ruby Cassandra client: http://github.com/fauna/cassandra/

More to come

stats

CaseStudies (last edited 2013-11-13 00:56:57 by GehrigKunz)