You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by jb...@apache.org on 2009/08/31 21:48:24 UTC
svn commit: r809718 - in /incubator/cassandra/trunk:
interface/cassandra.thrift
src/java/org/apache/cassandra/service/CassandraDaemon.java
Author: jbellis
Date: Mon Aug 31 19:48:24 2009
New Revision: 809718
URL: http://svn.apache.org/viewvc?rev=809718&view=rev
Log:
organize api methods by type (retrieval or modification). patch by jbellis
Modified:
incubator/cassandra/trunk/interface/cassandra.thrift
incubator/cassandra/trunk/src/java/org/apache/cassandra/service/CassandraDaemon.java
Modified: incubator/cassandra/trunk/interface/cassandra.thrift
URL: http://svn.apache.org/viewvc/incubator/cassandra/trunk/interface/cassandra.thrift?rev=809718&r1=809717&r2=809718&view=diff
==============================================================================
--- incubator/cassandra/trunk/interface/cassandra.thrift (original)
+++ incubator/cassandra/trunk/interface/cassandra.thrift Mon Aug 31 19:48:24 2009
@@ -114,46 +114,48 @@
service Cassandra {
- list<ColumnOrSuperColumn> get_slice(1:string keyspace, 2:string key, 3:ColumnParent column_parent, 4:SlicePredicate predicate, 5:ConsistencyLevel consistency_level=1)
+ # retrieval methods
+ ColumnOrSuperColumn get(1:string keyspace, 2:string key, 3:ColumnPath column_path, 4:ConsistencyLevel consistency_level=1)
throws (1: InvalidRequestException ire, 2: NotFoundException nfe),
- map<string,list<ColumnOrSuperColumn>> multiget_slice(1:string keyspace, 2:list<string> keys, 3:ColumnParent column_parent, 4:SlicePredicate predicate, 5:ConsistencyLevel consistency_level=1)
- throws (1: InvalidRequestException ire),
-
- ColumnOrSuperColumn get(1:string keyspace, 2:string key, 3:ColumnPath column_path, 4:ConsistencyLevel consistency_level=1)
+ list<ColumnOrSuperColumn> get_slice(1:string keyspace, 2:string key, 3:ColumnParent column_parent, 4:SlicePredicate predicate, 5:ConsistencyLevel consistency_level=1)
throws (1: InvalidRequestException ire, 2: NotFoundException nfe),
map<string,ColumnOrSuperColumn> multiget(1:string keyspace, 2:list<string> keys, 3:ColumnPath column_path, 4:ConsistencyLevel consistency_level=1)
throws (1: InvalidRequestException ire),
+ map<string,list<ColumnOrSuperColumn>> multiget_slice(1:string keyspace, 2:list<string> keys, 3:ColumnParent column_parent, 4:SlicePredicate predicate, 5:ConsistencyLevel consistency_level=1)
+ throws (1: InvalidRequestException ire),
+
i32 get_count(1:string keyspace, 2:string key, 3:ColumnParent column_parent, 5:ConsistencyLevel consistency_level=1)
throws (1: InvalidRequestException ire),
- void insert(1:string keyspace, 2:string key, 3:ColumnPath column_path, 4:binary value, 5:i64 timestamp, 6:ConsistencyLevel consistency_level=0)
- throws (1: InvalidRequestException ire, 2: UnavailableException ue),
+ # range query: returns matching keys
+ list<string> get_key_range(1:string keyspace, 2:string column_family, 3:string start="", 4:string finish="", 5:i32 count=100, 6:ConsistencyLevel consistency_level=1)
+ throws (1: InvalidRequestException ire),
- void batch_insert(1:string keyspace, 2:BatchMutation batch_mutation, 3:ConsistencyLevel consistency_level=0)
+ # modification methods
+ void insert(1:string keyspace, 2:string key, 3:ColumnPath column_path, 4:binary value, 5:i64 timestamp, 6:ConsistencyLevel consistency_level=0)
throws (1: InvalidRequestException ire, 2: UnavailableException ue),
- void remove(1:string keyspace, 2:string key, 3:ColumnPath column_path, 4:i64 timestamp, 5:ConsistencyLevel consistency_level=0)
+ void batch_insert(1:string keyspace, 2:BatchMutation batch_mutation, 3:ConsistencyLevel consistency_level=0)
throws (1: InvalidRequestException ire, 2: UnavailableException ue),
- # range query: returns matching keys
- list<string> get_key_range(1:string keyspace, 2:string column_family, 3:string start="", 4:string finish="", 5:i32 count=100, 6:ConsistencyLevel consistency_level=1)
- throws (1: InvalidRequestException ire),
+ void remove(1:string keyspace, 2:string key, 3:ColumnPath column_path, 4:i64 timestamp, 5:ConsistencyLevel consistency_level=0)
+ throws (1: InvalidRequestException ire, 2: UnavailableException ue),
// Meta-APIs -- APIs to get information about the node or cluster,
// rather than user data. The nodeprobe program provides usage examples.
// get property whose value is of type "string"
- string get_string_property(1:string property),
+ string get_string_property(1:string property),
// get property whose value is list of "strings"
- list<string> get_string_list_property(1:string property),
+ list<string> get_string_list_property(1:string property),
// describe specified keyspace
- map<string, map<string, string>> describe_keyspace(1:string keyspace)
+ map<string, map<string, string>> describe_keyspace(1:string keyspace)
throws (1: NotFoundException nfe),
}
Modified: incubator/cassandra/trunk/src/java/org/apache/cassandra/service/CassandraDaemon.java
URL: http://svn.apache.org/viewvc/incubator/cassandra/trunk/src/java/org/apache/cassandra/service/CassandraDaemon.java?rev=809718&r1=809717&r2=809718&view=diff
==============================================================================
--- incubator/cassandra/trunk/src/java/org/apache/cassandra/service/CassandraDaemon.java (original)
+++ incubator/cassandra/trunk/src/java/org/apache/cassandra/service/CassandraDaemon.java Mon Aug 31 19:48:24 2009
@@ -24,6 +24,8 @@
import java.util.Set;
import org.apache.log4j.Logger;
+import org.apache.log4j.Level;
+
import org.apache.thrift.protocol.TBinaryProtocol;
import org.apache.thrift.protocol.TProtocolFactory;
import org.apache.thrift.server.TThreadPoolServer;