Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Table to keyspace.

  • Loading branch information...
commit 679eb243f255d991507fd0c9c4e5f96a82dd350e 1 parent e49622b
Evan Weaver authored
Showing with 10 additions and 8 deletions.
  1. +2 −0  CHANGELOG
  2. +6 −6 conf/storage-conf.xml
  3. +2 −2 lib/cassandra/cassandra.rb
View
2  CHANGELOG
@@ -1,4 +1,6 @@
+v0.5. More API changes. Working temporal comparators.
+
v0.4. Use new comparator API. Namespace Thrift bindings; rename gem and class to Cassandra. Make tokens and limits actually work. Retry UnavailableExceptions.
v0.3. Use new Thrift API.
View
12 conf/storage-conf.xml
@@ -28,8 +28,8 @@
There is an implicit table named 'system' for Cassandra internals.
-->
- <Tables>
- <Table Name="Twitter">
+ <Keyspaces>
+ <Keyspace Name="Twitter">
<KeysCachedFraction>0.01</KeysCachedFraction>
<ColumnFamily CompareWith="UTF8Type" Name="Users" />
<ColumnFamily CompareWith="UTF8Type" Name="UserAudits" />
@@ -38,14 +38,14 @@
<ColumnFamily CompareWith="UTF8Type" Name="Statuses" />
<ColumnFamily CompareWith="UTF8Type" Name="StatusAudits" />
<ColumnFamily CompareWith="UTF8Type" CompareSubcolumnsWith="TimeUUIDType" ColumnType="Super" Name="StatusRelationships" />
- </Table>
+ </Keyspace>
- <Table Name="Multiblog">
+ <Keyspace Name="Multiblog">
<KeysCachedFraction>0.01</KeysCachedFraction>
<ColumnFamily CompareWith="UTF8Type" Name="Blogs"/>
<ColumnFamily CompareWith="UTF8Type" Name="Comments"/>
- </Table>
- </Tables>
+ </Keyspace>
+ </Keyspaces>
<!-- Partitioner: any IPartitioner may be used, including your own
as long as it is on the classpath. Out of the box,
View
4 lib/cassandra/cassandra.rb
@@ -31,12 +31,12 @@ def initialize(keyspace, host = '127.0.0.1', port = 9160)
CassandraThrift::Cassandra::Client.new(Thrift::BinaryProtocol.new(@transport)),
@transport)
- keyspaces = @client.get_string_list_property("tables")
+ keyspaces = @client.get_string_list_property("keyspaces")
unless keyspaces.include?(@keyspace)
raise AccessError, "Keyspace #{@keyspace.inspect} not found. Available: #{keyspaces.inspect}"
end
- @schema = @client.describe_table(@keyspace)
+ @schema = @client.describe_keyspace(@keyspace)
end
def inspect
Please sign in to comment.
Something went wrong with that request. Please try again.