Return-Path: Delivered-To: apmail-cassandra-commits-archive@www.apache.org Received: (qmail 54865 invoked from network); 22 Apr 2010 06:19:59 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 22 Apr 2010 06:19:59 -0000 Received: (qmail 41978 invoked by uid 500); 22 Apr 2010 06:19:59 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 41875 invoked by uid 500); 22 Apr 2010 06:19:59 -0000 Mailing-List: contact commits-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cassandra.apache.org Delivered-To: mailing list commits@cassandra.apache.org Received: (qmail 41867 invoked by uid 500); 22 Apr 2010 06:19:59 -0000 Delivered-To: apmail-incubator-cassandra-commits@incubator.apache.org Received: (qmail 41864 invoked by uid 99); 22 Apr 2010 06:19:58 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 Apr 2010 06:19:58 +0000 X-ASF-Spam-Status: No, hits=-1388.8 required=10.0 tests=ALL_TRUSTED,AWL X-Spam-Check-By: apache.org Received: from [140.211.11.130] (HELO eos.apache.org) (140.211.11.130) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 Apr 2010 06:19:57 +0000 Received: from eos.apache.org (localhost [127.0.0.1]) by eos.apache.org (Postfix) with ESMTP id 4AE8417D15; Thu, 22 Apr 2010 06:19:37 +0000 (GMT) MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable From: Apache Wiki To: Apache Wiki Date: Thu, 22 Apr 2010 06:19:37 -0000 Message-ID: <20100422061937.15392.73426@eos.apache.org> Subject: =?utf-8?q?=5BCassandra_Wiki=5D_Update_of_=22API07=22_by_ToddBlose?= Dear Wiki user, You have subscribed to a wiki page or wiki category on "Cassandra Wiki" for= change notification. The "API07" page has been changed by ToddBlose. http://wiki.apache.org/cassandra/API07?action=3Ddiff&rev1=3D1&rev2=3D2 -------------------------------------------------- Authenticates with the cluster for operations on the specified keyspace u= sing the specified `AuthenticationRequest` credentials. Throws `Authenticat= ionException` if the credentials are invalid or `AuthorizationException` if= the credentials are valid, but not for the specified keyspace. = =3D=3D=3D get =3D=3D=3D - . `ColumnOrSuperColumn get(keyspace, key, column_path, consistency_level= )` + . `ColumnOrSuperColumn get(key, column_path, consistency_level)` = Get the `Column` or `SuperColumn` at the given `column_path`. If no valu= e is present, `NotFoundException` is thrown. (This is the only method that= can throw an exception under non-failure conditions.) = =3D=3D=3D get_slice =3D=3D=3D - . `list get_slice(keyspace, key, column_parent, pre= dicate, consistency_level)` + . `list get_slice(key, column_parent, predicate, co= nsistency_level)` = Get the group of columns contained by `column_parent` (either a `ColumnFa= mily` name or a `ColumnFamily/SuperColumn` name pair) specified by the give= n `SlicePredicate` struct. = =3D=3D=3D multiget_slice =3D=3D=3D - . `map> multiget_slice(keyspace, keys, = column_parent, predicate, consistency_level)` + . `map> multiget_slice(keys, column_par= ent, predicate, consistency_level)` = Retrieves slices for `column_parent` and `predicate` on each of the given= keys in parallel. Keys are a `list of the keys to get slices for. = This is similar to `get_range_slice` (Cassandra 0.5) except operating on = a set of non-contiguous keys instead of a range of keys. = =3D=3D=3D get_count =3D=3D=3D - . `i32 get_count(keyspace, key, column_parent, consistency_level)` + . `i32 get_count(key, column_parent, consistency_level)` = Counts the columns present in `column_parent`. = The method is not O(1). It takes all the columns from disk to calculate t= he answer. The only benefit of the method is that you do not need to pull a= ll the columns over Thrift interface to count them. = =3D=3D=3D get_range_slices =3D=3D=3D - . `list get_range_slices(keyspace, column_parent, predicate, r= ange, consistency_level)` + . `list get_range_slices(column_parent, predicate, range, cons= istency_level)` = Replaces `get_range_slice`. Returns a list of slices for the keys within = the specified `KeyRange`. Unlike get_key_range, this applies the given pred= icate to all keys in the range, not just those with undeleted matching data= . This method is only allowed when using an order-preserving partitioner. = =3D=3D=3D insert =3D=3D=3D - . `insert(keyspace, key, column_path, value, timestamp, consistency_leve= l)` + . `insert(key, column_path, value, timestamp, consistency_level)` = Insert a `Column` consisting of (`column_path.column`, `value`, `timestam= p`) at the given `column_path.column_family` and optional `column_path.supe= r_column`. Note that `column_path.column` is here required, since a !Super= Column cannot directly contain binary values -- it can only contain sub-Col= umns. = =3D=3D=3D batch_mutate =3D=3D=3D - . `batch_mutate(keyspace, mutation_map, consistency_level)` + . `batch_mutate(mutation_map, consistency_level)` = Executes the specified mutations on the keyspace. `mutation_map` is a `ma= p>>`; the outer map maps the key to the = inner map, which maps the column family to the `Mutation`; can be read as: = `map>>`. To be mo= re specific, the outer map key is a row key, the inner map key is the colum= n family name. = A `Mutation` specifies either columns to insert or columns to delete. See= `Mutation` and `Deletion` above for more details. = =3D=3D=3D remove =3D=3D=3D - . `remove(keyspace, key, column_path, timestamp, consistency_level)` + . `remove(key, column_path, timestamp, consistency_level)` = Remove data from the row specified by `key` at the granularity specified = by `column_path`, and the given `timestamp`. Note that all the values in `= column_path` besides `column_path.column_family` are truly optional: you ca= n remove the entire row by just specifying the !ColumnFamily, or you can re= move a !SuperColumn or a single Column by specifying those levels too. Note= that the `timestamp` is needed, so that if the commands are replayed in a = different order on different nodes, the same result is produced. =20