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 2013/12/06 16:52:31 UTC
[14/16] Merge branch 'cassandra-1.2' into cassandra-2.0
http://git-wip-us.apache.org/repos/asf/cassandra/blob/f2a82ee7/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java
----------------------------------------------------------------------
diff --cc interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java
index 837acfc,5c8d286..15b99fa
--- a/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java
+++ b/interface/thrift/gen-java/org/apache/cassandra/thrift/Cassandra.java
@@@ -437,91 -387,91 +444,93 @@@ public class Cassandra
public interface AsyncIface {
- public void login(AuthenticationRequest auth_request, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.login_call> resultHandler) throws org.apache.thrift.TException;
+ public void login(AuthenticationRequest auth_request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void set_keyspace(String keyspace, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.set_keyspace_call> resultHandler) throws org.apache.thrift.TException;
+ public void set_keyspace(String keyspace, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void get(ByteBuffer key, ColumnPath column_path, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.get_call> resultHandler) throws org.apache.thrift.TException;
+ public void get(ByteBuffer key, ColumnPath column_path, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void get_slice(ByteBuffer key, ColumnParent column_parent, SlicePredicate predicate, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.get_slice_call> resultHandler) throws org.apache.thrift.TException;
+ public void get_slice(ByteBuffer key, ColumnParent column_parent, SlicePredicate predicate, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void get_count(ByteBuffer key, ColumnParent column_parent, SlicePredicate predicate, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.get_count_call> resultHandler) throws org.apache.thrift.TException;
+ public void get_count(ByteBuffer key, ColumnParent column_parent, SlicePredicate predicate, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void multiget_slice(List<ByteBuffer> keys, ColumnParent column_parent, SlicePredicate predicate, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.multiget_slice_call> resultHandler) throws org.apache.thrift.TException;
+ public void multiget_slice(List<ByteBuffer> keys, ColumnParent column_parent, SlicePredicate predicate, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void multiget_count(List<ByteBuffer> keys, ColumnParent column_parent, SlicePredicate predicate, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.multiget_count_call> resultHandler) throws org.apache.thrift.TException;
+ public void multiget_count(List<ByteBuffer> keys, ColumnParent column_parent, SlicePredicate predicate, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void get_range_slices(ColumnParent column_parent, SlicePredicate predicate, KeyRange range, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.get_range_slices_call> resultHandler) throws org.apache.thrift.TException;
+ public void get_range_slices(ColumnParent column_parent, SlicePredicate predicate, KeyRange range, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void get_paged_slice(String column_family, KeyRange range, ByteBuffer start_column, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.get_paged_slice_call> resultHandler) throws org.apache.thrift.TException;
+ public void get_paged_slice(String column_family, KeyRange range, ByteBuffer start_column, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void get_indexed_slices(ColumnParent column_parent, IndexClause index_clause, SlicePredicate column_predicate, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.get_indexed_slices_call> resultHandler) throws org.apache.thrift.TException;
+ public void get_indexed_slices(ColumnParent column_parent, IndexClause index_clause, SlicePredicate column_predicate, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void insert(ByteBuffer key, ColumnParent column_parent, Column column, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.insert_call> resultHandler) throws org.apache.thrift.TException;
+ public void insert(ByteBuffer key, ColumnParent column_parent, Column column, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void add(ByteBuffer key, ColumnParent column_parent, CounterColumn column, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.add_call> resultHandler) throws org.apache.thrift.TException;
+ public void add(ByteBuffer key, ColumnParent column_parent, CounterColumn column, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void remove(ByteBuffer key, ColumnPath column_path, long timestamp, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.remove_call> resultHandler) throws org.apache.thrift.TException;
+ public void cas(ByteBuffer key, String column_family, List<Column> expected, List<Column> updates, ConsistencyLevel serial_consistency_level, ConsistencyLevel commit_consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void remove_counter(ByteBuffer key, ColumnPath path, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.remove_counter_call> resultHandler) throws org.apache.thrift.TException;
+ public void remove(ByteBuffer key, ColumnPath column_path, long timestamp, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void batch_mutate(Map<ByteBuffer,Map<String,List<Mutation>>> mutation_map, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.batch_mutate_call> resultHandler) throws org.apache.thrift.TException;
+ public void remove_counter(ByteBuffer key, ColumnPath path, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void atomic_batch_mutate(Map<ByteBuffer,Map<String,List<Mutation>>> mutation_map, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.atomic_batch_mutate_call> resultHandler) throws org.apache.thrift.TException;
+ public void batch_mutate(Map<ByteBuffer,Map<String,List<Mutation>>> mutation_map, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void truncate(String cfname, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.truncate_call> resultHandler) throws org.apache.thrift.TException;
+ public void atomic_batch_mutate(Map<ByteBuffer,Map<String,List<Mutation>>> mutation_map, ConsistencyLevel consistency_level, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_schema_versions(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_schema_versions_call> resultHandler) throws org.apache.thrift.TException;
+ public void truncate(String cfname, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_keyspaces(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_keyspaces_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_schema_versions(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_cluster_name(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_cluster_name_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_keyspaces(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_version(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_version_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_cluster_name(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_ring(String keyspace, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_ring_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_version(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_local_ring(String keyspace, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_local_ring_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_ring(String keyspace, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_token_map(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_token_map_call> resultHandler) throws org.apache.thrift.TException;
++ public void describe_local_ring(String keyspace, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+
- public void describe_partitioner(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_partitioner_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_token_map(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_snitch(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_snitch_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_partitioner(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_keyspace(String keyspace, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_keyspace_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_snitch(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_splits(String cfName, String start_token, String end_token, int keys_per_split, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_splits_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_keyspace(String keyspace, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void trace_next_query(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.trace_next_query_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_splits(String cfName, String start_token, String end_token, int keys_per_split, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void describe_splits_ex(String cfName, String start_token, String end_token, int keys_per_split, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.describe_splits_ex_call> resultHandler) throws org.apache.thrift.TException;
+ public void trace_next_query(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void system_add_column_family(CfDef cf_def, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.system_add_column_family_call> resultHandler) throws org.apache.thrift.TException;
+ public void describe_splits_ex(String cfName, String start_token, String end_token, int keys_per_split, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void system_drop_column_family(String column_family, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.system_drop_column_family_call> resultHandler) throws org.apache.thrift.TException;
+ public void system_add_column_family(CfDef cf_def, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void system_add_keyspace(KsDef ks_def, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.system_add_keyspace_call> resultHandler) throws org.apache.thrift.TException;
+ public void system_drop_column_family(String column_family, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void system_drop_keyspace(String keyspace, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.system_drop_keyspace_call> resultHandler) throws org.apache.thrift.TException;
+ public void system_add_keyspace(KsDef ks_def, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void system_update_keyspace(KsDef ks_def, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.system_update_keyspace_call> resultHandler) throws org.apache.thrift.TException;
+ public void system_drop_keyspace(String keyspace, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void system_update_column_family(CfDef cf_def, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.system_update_column_family_call> resultHandler) throws org.apache.thrift.TException;
+ public void system_update_keyspace(KsDef ks_def, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void execute_cql_query(ByteBuffer query, Compression compression, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.execute_cql_query_call> resultHandler) throws org.apache.thrift.TException;
+ public void system_update_column_family(CfDef cf_def, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void execute_cql3_query(ByteBuffer query, Compression compression, ConsistencyLevel consistency, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.execute_cql3_query_call> resultHandler) throws org.apache.thrift.TException;
+ public void execute_cql_query(ByteBuffer query, Compression compression, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void prepare_cql_query(ByteBuffer query, Compression compression, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.prepare_cql_query_call> resultHandler) throws org.apache.thrift.TException;
+ public void execute_cql3_query(ByteBuffer query, Compression compression, ConsistencyLevel consistency, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void prepare_cql3_query(ByteBuffer query, Compression compression, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.prepare_cql3_query_call> resultHandler) throws org.apache.thrift.TException;
+ public void prepare_cql_query(ByteBuffer query, Compression compression, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void execute_prepared_cql_query(int itemId, List<ByteBuffer> values, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.execute_prepared_cql_query_call> resultHandler) throws org.apache.thrift.TException;
+ public void prepare_cql3_query(ByteBuffer query, Compression compression, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void execute_prepared_cql3_query(int itemId, List<ByteBuffer> values, ConsistencyLevel consistency, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.execute_prepared_cql3_query_call> resultHandler) throws org.apache.thrift.TException;
+ public void execute_prepared_cql_query(int itemId, List<ByteBuffer> values, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
- public void set_cql_version(String version, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.set_cql_version_call> resultHandler) throws org.apache.thrift.TException;
+ public void execute_prepared_cql3_query(int itemId, List<ByteBuffer> values, ConsistencyLevel consistency, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+
+ public void set_cql_version(String version, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
}
@@@ -2689,7 -2581,39 +2724,39 @@@
}
}
- public void describe_local_ring(String keyspace, org.apache.thrift.async.AsyncMethodCallback<describe_local_ring_call> resultHandler) throws org.apache.thrift.TException {
++ public void describe_local_ring(String keyspace, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ checkReady();
+ describe_local_ring_call method_call = new describe_local_ring_call(keyspace, resultHandler, this, ___protocolFactory, ___transport);
+ this.___currentMethod = method_call;
+ ___manager.call(method_call);
+ }
+
+ public static class describe_local_ring_call extends org.apache.thrift.async.TAsyncMethodCall {
+ private String keyspace;
- public describe_local_ring_call(String keyspace, org.apache.thrift.async.AsyncMethodCallback<describe_local_ring_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
++ public describe_local_ring_call(String keyspace, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
+ super(client, protocolFactory, transport, resultHandler, false);
+ this.keyspace = keyspace;
+ }
+
+ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
+ prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("describe_local_ring", org.apache.thrift.protocol.TMessageType.CALL, 0));
+ describe_local_ring_args args = new describe_local_ring_args();
+ args.setKeyspace(keyspace);
+ args.write(prot);
+ prot.writeMessageEnd();
+ }
+
+ public List<TokenRange> getResult() throws InvalidRequestException, org.apache.thrift.TException {
+ if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
+ throw new IllegalStateException("Method call not finished!");
+ }
+ org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
+ org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
+ return (new Client(prot)).recv_describe_local_ring();
+ }
+ }
+
- public void describe_token_map(org.apache.thrift.async.AsyncMethodCallback<describe_token_map_call> resultHandler) throws org.apache.thrift.TException {
+ public void describe_token_map(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
checkReady();
describe_token_map_call method_call = new describe_token_map_call(resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
@@@ -4031,7 -3839,27 +4099,31 @@@
}
}
- private static class describe_local_ring<I extends Iface> extends org.apache.thrift.ProcessFunction<I, describe_local_ring_args> {
++ public static class describe_local_ring<I extends Iface> extends org.apache.thrift.ProcessFunction<I, describe_local_ring_args> {
+ public describe_local_ring() {
+ super("describe_local_ring");
+ }
+
- protected describe_local_ring_args getEmptyArgsInstance() {
++ public describe_local_ring_args getEmptyArgsInstance() {
+ return new describe_local_ring_args();
+ }
+
- protected describe_local_ring_result getResult(I iface, describe_local_ring_args args) throws org.apache.thrift.TException {
++ protected boolean isOneway() {
++ return false;
++ }
++
++ public describe_local_ring_result getResult(I iface, describe_local_ring_args args) throws org.apache.thrift.TException {
+ describe_local_ring_result result = new describe_local_ring_result();
+ try {
+ result.success = iface.describe_local_ring(args.keyspace);
+ } catch (InvalidRequestException ire) {
+ result.ire = ire;
+ }
+ return result;
+ }
+ }
+
- private static class describe_token_map<I extends Iface> extends org.apache.thrift.ProcessFunction<I, describe_token_map_args> {
+ public static class describe_token_map<I extends Iface> extends org.apache.thrift.ProcessFunction<I, describe_token_map_args> {
public describe_token_map() {
super("describe_token_map");
}
@@@ -4539,2942 -4287,201 +4631,3000 @@@
}
- public static class login_args implements org.apache.thrift.TBase<login_args, login_args._Fields>, java.io.Serializable, Cloneable {
- private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("login_args");
+ public static class AsyncProcessor<I extends AsyncIface> extends org.apache.thrift.TBaseAsyncProcessor<I> {
+ private static final Logger LOGGER = LoggerFactory.getLogger(AsyncProcessor.class.getName());
+ public AsyncProcessor(I iface) {
+ super(iface, getProcessMap(new HashMap<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>>()));
+ }
- private static final org.apache.thrift.protocol.TField AUTH_REQUEST_FIELD_DESC = new org.apache.thrift.protocol.TField("auth_request", org.apache.thrift.protocol.TType.STRUCT, (short)1);
+ protected AsyncProcessor(I iface, Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) {
+ super(iface, getProcessMap(processMap));
+ }
- public AuthenticationRequest auth_request; // required
+ private static <I extends AsyncIface> Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase,?>> getProcessMap(Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) {
+ processMap.put("login", new login());
+ processMap.put("set_keyspace", new set_keyspace());
+ processMap.put("get", new get());
+ processMap.put("get_slice", new get_slice());
+ processMap.put("get_count", new get_count());
+ processMap.put("multiget_slice", new multiget_slice());
+ processMap.put("multiget_count", new multiget_count());
+ processMap.put("get_range_slices", new get_range_slices());
+ processMap.put("get_paged_slice", new get_paged_slice());
+ processMap.put("get_indexed_slices", new get_indexed_slices());
+ processMap.put("insert", new insert());
+ processMap.put("add", new add());
+ processMap.put("cas", new cas());
+ processMap.put("remove", new remove());
+ processMap.put("remove_counter", new remove_counter());
+ processMap.put("batch_mutate", new batch_mutate());
+ processMap.put("atomic_batch_mutate", new atomic_batch_mutate());
+ processMap.put("truncate", new truncate());
+ processMap.put("describe_schema_versions", new describe_schema_versions());
+ processMap.put("describe_keyspaces", new describe_keyspaces());
+ processMap.put("describe_cluster_name", new describe_cluster_name());
+ processMap.put("describe_version", new describe_version());
+ processMap.put("describe_ring", new describe_ring());
++ processMap.put("describe_local_ring", new describe_local_ring());
+ processMap.put("describe_token_map", new describe_token_map());
+ processMap.put("describe_partitioner", new describe_partitioner());
+ processMap.put("describe_snitch", new describe_snitch());
+ processMap.put("describe_keyspace", new describe_keyspace());
+ processMap.put("describe_splits", new describe_splits());
+ processMap.put("trace_next_query", new trace_next_query());
+ processMap.put("describe_splits_ex", new describe_splits_ex());
+ processMap.put("system_add_column_family", new system_add_column_family());
+ processMap.put("system_drop_column_family", new system_drop_column_family());
+ processMap.put("system_add_keyspace", new system_add_keyspace());
+ processMap.put("system_drop_keyspace", new system_drop_keyspace());
+ processMap.put("system_update_keyspace", new system_update_keyspace());
+ processMap.put("system_update_column_family", new system_update_column_family());
+ processMap.put("execute_cql_query", new execute_cql_query());
+ processMap.put("execute_cql3_query", new execute_cql3_query());
+ processMap.put("prepare_cql_query", new prepare_cql_query());
+ processMap.put("prepare_cql3_query", new prepare_cql3_query());
+ processMap.put("execute_prepared_cql_query", new execute_prepared_cql_query());
+ processMap.put("execute_prepared_cql3_query", new execute_prepared_cql3_query());
+ processMap.put("set_cql_version", new set_cql_version());
+ return processMap;
+ }
- /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
- public enum _Fields implements org.apache.thrift.TFieldIdEnum {
- AUTH_REQUEST((short)1, "auth_request");
+ public static class login<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, login_args, Void> {
+ public login() {
+ super("login");
+ }
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ public login_args getEmptyArgsInstance() {
+ return new login_args();
+ }
- static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
- byName.put(field.getFieldName(), field);
- }
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Void>() {
+ public void onComplete(Void o) {
+ login_result result = new login_result();
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ login_result result = new login_result();
+ if (e instanceof AuthenticationException) {
+ result.authnx = (AuthenticationException) e;
+ result.setAuthnxIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof AuthorizationException) {
+ result.authzx = (AuthorizationException) e;
+ result.setAuthzxIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
}
- /**
- * Find the _Fields constant that matches fieldId, or null if its not found.
- */
- public static _Fields findByThriftId(int fieldId) {
- switch(fieldId) {
- case 1: // AUTH_REQUEST
- return AUTH_REQUEST;
- default:
- return null;
- }
+ protected boolean isOneway() {
+ return false;
}
- /**
- * Find the _Fields constant that matches fieldId, throwing an exception
- * if it is not found.
- */
- public static _Fields findByThriftIdOrThrow(int fieldId) {
- _Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
- return fields;
+ public void start(I iface, login_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ iface.login(args.auth_request,resultHandler);
}
+ }
- /**
- * Find the _Fields constant that matches name, or null if its not found.
- */
- public static _Fields findByName(String name) {
- return byName.get(name);
+ public static class set_keyspace<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, set_keyspace_args, Void> {
+ public set_keyspace() {
+ super("set_keyspace");
}
- private final short _thriftId;
- private final String _fieldName;
+ public set_keyspace_args getEmptyArgsInstance() {
+ return new set_keyspace_args();
+ }
- _Fields(short thriftId, String fieldName) {
- _thriftId = thriftId;
- _fieldName = fieldName;
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Void>() {
+ public void onComplete(Void o) {
+ set_keyspace_result result = new set_keyspace_result();
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ set_keyspace_result result = new set_keyspace_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
}
- public short getThriftFieldId() {
- return _thriftId;
+ protected boolean isOneway() {
+ return false;
}
- public String getFieldName() {
- return _fieldName;
+ public void start(I iface, set_keyspace_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ iface.set_keyspace(args.keyspace,resultHandler);
}
}
- // isset id assignments
-
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
- static {
- Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
- tmpMap.put(_Fields.AUTH_REQUEST, new org.apache.thrift.meta_data.FieldMetaData("auth_request", org.apache.thrift.TFieldRequirementType.REQUIRED,
- new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, AuthenticationRequest.class)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
- org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(login_args.class, metaDataMap);
- }
+ public static class get<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, get_args, ColumnOrSuperColumn> {
+ public get() {
+ super("get");
+ }
- public login_args() {
- }
+ public get_args getEmptyArgsInstance() {
+ return new get_args();
+ }
- public login_args(
- AuthenticationRequest auth_request)
- {
- this();
- this.auth_request = auth_request;
- }
+ public AsyncMethodCallback<ColumnOrSuperColumn> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<ColumnOrSuperColumn>() {
+ public void onComplete(ColumnOrSuperColumn o) {
+ get_result result = new get_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ get_result result = new get_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof NotFoundException) {
+ result.nfe = (NotFoundException) e;
+ result.setNfeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
- /**
- * Performs a deep copy on <i>other</i>.
- */
- public login_args(login_args other) {
- if (other.isSetAuth_request()) {
- this.auth_request = new AuthenticationRequest(other.auth_request);
+ protected boolean isOneway() {
+ return false;
}
- }
- public login_args deepCopy() {
- return new login_args(this);
+ public void start(I iface, get_args args, org.apache.thrift.async.AsyncMethodCallback<ColumnOrSuperColumn> resultHandler) throws TException {
+ iface.get(args.key, args.column_path, args.consistency_level,resultHandler);
+ }
}
- @Override
- public void clear() {
- this.auth_request = null;
- }
+ public static class get_slice<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, get_slice_args, List<ColumnOrSuperColumn>> {
+ public get_slice() {
+ super("get_slice");
+ }
- public AuthenticationRequest getAuth_request() {
- return this.auth_request;
- }
+ public get_slice_args getEmptyArgsInstance() {
+ return new get_slice_args();
+ }
- public login_args setAuth_request(AuthenticationRequest auth_request) {
- this.auth_request = auth_request;
- return this;
- }
+ public AsyncMethodCallback<List<ColumnOrSuperColumn>> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<List<ColumnOrSuperColumn>>() {
+ public void onComplete(List<ColumnOrSuperColumn> o) {
+ get_slice_result result = new get_slice_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ get_slice_result result = new get_slice_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
- public void unsetAuth_request() {
- this.auth_request = null;
- }
+ protected boolean isOneway() {
+ return false;
+ }
- /** Returns true if field auth_request is set (has been assigned a value) and false otherwise */
- public boolean isSetAuth_request() {
- return this.auth_request != null;
+ public void start(I iface, get_slice_args args, org.apache.thrift.async.AsyncMethodCallback<List<ColumnOrSuperColumn>> resultHandler) throws TException {
+ iface.get_slice(args.key, args.column_parent, args.predicate, args.consistency_level,resultHandler);
+ }
}
- public void setAuth_requestIsSet(boolean value) {
- if (!value) {
- this.auth_request = null;
+ public static class get_count<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, get_count_args, Integer> {
+ public get_count() {
+ super("get_count");
}
- }
- public void setFieldValue(_Fields field, Object value) {
- switch (field) {
- case AUTH_REQUEST:
- if (value == null) {
- unsetAuth_request();
- } else {
- setAuth_request((AuthenticationRequest)value);
- }
- break;
+ public get_count_args getEmptyArgsInstance() {
+ return new get_count_args();
+ }
+ public AsyncMethodCallback<Integer> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Integer>() {
+ public void onComplete(Integer o) {
+ get_count_result result = new get_count_result();
+ result.success = o;
+ result.setSuccessIsSet(true);
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ get_count_result result = new get_count_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
}
- }
- public Object getFieldValue(_Fields field) {
- switch (field) {
- case AUTH_REQUEST:
- return getAuth_request();
+ protected boolean isOneway() {
+ return false;
+ }
+ public void start(I iface, get_count_args args, org.apache.thrift.async.AsyncMethodCallback<Integer> resultHandler) throws TException {
+ iface.get_count(args.key, args.column_parent, args.predicate, args.consistency_level,resultHandler);
}
- throw new IllegalStateException();
}
- /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
- public boolean isSet(_Fields field) {
- if (field == null) {
- throw new IllegalArgumentException();
+ public static class multiget_slice<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, multiget_slice_args, Map<ByteBuffer,List<ColumnOrSuperColumn>>> {
+ public multiget_slice() {
+ super("multiget_slice");
}
- switch (field) {
- case AUTH_REQUEST:
- return isSetAuth_request();
+ public multiget_slice_args getEmptyArgsInstance() {
+ return new multiget_slice_args();
}
- throw new IllegalStateException();
- }
- @Override
- public boolean equals(Object that) {
- if (that == null)
- return false;
- if (that instanceof login_args)
- return this.equals((login_args)that);
- return false;
- }
+ public AsyncMethodCallback<Map<ByteBuffer,List<ColumnOrSuperColumn>>> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Map<ByteBuffer,List<ColumnOrSuperColumn>>>() {
+ public void onComplete(Map<ByteBuffer,List<ColumnOrSuperColumn>> o) {
+ multiget_slice_result result = new multiget_slice_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ multiget_slice_result result = new multiget_slice_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
- public boolean equals(login_args that) {
- if (that == null)
+ protected boolean isOneway() {
return false;
-
- boolean this_present_auth_request = true && this.isSetAuth_request();
- boolean that_present_auth_request = true && that.isSetAuth_request();
- if (this_present_auth_request || that_present_auth_request) {
- if (!(this_present_auth_request && that_present_auth_request))
- return false;
- if (!this.auth_request.equals(that.auth_request))
- return false;
}
- return true;
+ public void start(I iface, multiget_slice_args args, org.apache.thrift.async.AsyncMethodCallback<Map<ByteBuffer,List<ColumnOrSuperColumn>>> resultHandler) throws TException {
+ iface.multiget_slice(args.keys, args.column_parent, args.predicate, args.consistency_level,resultHandler);
+ }
}
- @Override
- public int hashCode() {
- HashCodeBuilder builder = new HashCodeBuilder();
+ public static class multiget_count<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, multiget_count_args, Map<ByteBuffer,Integer>> {
+ public multiget_count() {
+ super("multiget_count");
+ }
- boolean present_auth_request = true && (isSetAuth_request());
- builder.append(present_auth_request);
- if (present_auth_request)
+ public multiget_count_args getEmptyArgsInstance() {
+ return new multiget_count_args();
+ }
+
+ public AsyncMethodCallback<Map<ByteBuffer,Integer>> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Map<ByteBuffer,Integer>>() {
+ public void onComplete(Map<ByteBuffer,Integer> o) {
+ multiget_count_result result = new multiget_count_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ multiget_count_result result = new multiget_count_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, multiget_count_args args, org.apache.thrift.async.AsyncMethodCallback<Map<ByteBuffer,Integer>> resultHandler) throws TException {
+ iface.multiget_count(args.keys, args.column_parent, args.predicate, args.consistency_level,resultHandler);
+ }
+ }
+
+ public static class get_range_slices<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, get_range_slices_args, List<KeySlice>> {
+ public get_range_slices() {
+ super("get_range_slices");
+ }
+
+ public get_range_slices_args getEmptyArgsInstance() {
+ return new get_range_slices_args();
+ }
+
+ public AsyncMethodCallback<List<KeySlice>> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<List<KeySlice>>() {
+ public void onComplete(List<KeySlice> o) {
+ get_range_slices_result result = new get_range_slices_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ get_range_slices_result result = new get_range_slices_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, get_range_slices_args args, org.apache.thrift.async.AsyncMethodCallback<List<KeySlice>> resultHandler) throws TException {
+ iface.get_range_slices(args.column_parent, args.predicate, args.range, args.consistency_level,resultHandler);
+ }
+ }
+
+ public static class get_paged_slice<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, get_paged_slice_args, List<KeySlice>> {
+ public get_paged_slice() {
+ super("get_paged_slice");
+ }
+
+ public get_paged_slice_args getEmptyArgsInstance() {
+ return new get_paged_slice_args();
+ }
+
+ public AsyncMethodCallback<List<KeySlice>> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<List<KeySlice>>() {
+ public void onComplete(List<KeySlice> o) {
+ get_paged_slice_result result = new get_paged_slice_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ get_paged_slice_result result = new get_paged_slice_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, get_paged_slice_args args, org.apache.thrift.async.AsyncMethodCallback<List<KeySlice>> resultHandler) throws TException {
+ iface.get_paged_slice(args.column_family, args.range, args.start_column, args.consistency_level,resultHandler);
+ }
+ }
+
+ public static class get_indexed_slices<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, get_indexed_slices_args, List<KeySlice>> {
+ public get_indexed_slices() {
+ super("get_indexed_slices");
+ }
+
+ public get_indexed_slices_args getEmptyArgsInstance() {
+ return new get_indexed_slices_args();
+ }
+
+ public AsyncMethodCallback<List<KeySlice>> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<List<KeySlice>>() {
+ public void onComplete(List<KeySlice> o) {
+ get_indexed_slices_result result = new get_indexed_slices_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ get_indexed_slices_result result = new get_indexed_slices_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, get_indexed_slices_args args, org.apache.thrift.async.AsyncMethodCallback<List<KeySlice>> resultHandler) throws TException {
+ iface.get_indexed_slices(args.column_parent, args.index_clause, args.column_predicate, args.consistency_level,resultHandler);
+ }
+ }
+
+ public static class insert<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, insert_args, Void> {
+ public insert() {
+ super("insert");
+ }
+
+ public insert_args getEmptyArgsInstance() {
+ return new insert_args();
+ }
+
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Void>() {
+ public void onComplete(Void o) {
+ insert_result result = new insert_result();
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ insert_result result = new insert_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, insert_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ iface.insert(args.key, args.column_parent, args.column, args.consistency_level,resultHandler);
+ }
+ }
+
+ public static class add<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, add_args, Void> {
+ public add() {
+ super("add");
+ }
+
+ public add_args getEmptyArgsInstance() {
+ return new add_args();
+ }
+
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Void>() {
+ public void onComplete(Void o) {
+ add_result result = new add_result();
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ add_result result = new add_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, add_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ iface.add(args.key, args.column_parent, args.column, args.consistency_level,resultHandler);
+ }
+ }
+
+ public static class cas<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, cas_args, CASResult> {
+ public cas() {
+ super("cas");
+ }
+
+ public cas_args getEmptyArgsInstance() {
+ return new cas_args();
+ }
+
+ public AsyncMethodCallback<CASResult> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<CASResult>() {
+ public void onComplete(CASResult o) {
+ cas_result result = new cas_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ cas_result result = new cas_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, cas_args args, org.apache.thrift.async.AsyncMethodCallback<CASResult> resultHandler) throws TException {
+ iface.cas(args.key, args.column_family, args.expected, args.updates, args.serial_consistency_level, args.commit_consistency_level,resultHandler);
+ }
+ }
+
+ public static class remove<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, remove_args, Void> {
+ public remove() {
+ super("remove");
+ }
+
+ public remove_args getEmptyArgsInstance() {
+ return new remove_args();
+ }
+
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Void>() {
+ public void onComplete(Void o) {
+ remove_result result = new remove_result();
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ remove_result result = new remove_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, remove_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ iface.remove(args.key, args.column_path, args.timestamp, args.consistency_level,resultHandler);
+ }
+ }
+
+ public static class remove_counter<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, remove_counter_args, Void> {
+ public remove_counter() {
+ super("remove_counter");
+ }
+
+ public remove_counter_args getEmptyArgsInstance() {
+ return new remove_counter_args();
+ }
+
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Void>() {
+ public void onComplete(Void o) {
+ remove_counter_result result = new remove_counter_result();
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ remove_counter_result result = new remove_counter_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, remove_counter_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ iface.remove_counter(args.key, args.path, args.consistency_level,resultHandler);
+ }
+ }
+
+ public static class batch_mutate<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, batch_mutate_args, Void> {
+ public batch_mutate() {
+ super("batch_mutate");
+ }
+
+ public batch_mutate_args getEmptyArgsInstance() {
+ return new batch_mutate_args();
+ }
+
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Void>() {
+ public void onComplete(Void o) {
+ batch_mutate_result result = new batch_mutate_result();
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ batch_mutate_result result = new batch_mutate_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, batch_mutate_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ iface.batch_mutate(args.mutation_map, args.consistency_level,resultHandler);
+ }
+ }
+
+ public static class atomic_batch_mutate<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, atomic_batch_mutate_args, Void> {
+ public atomic_batch_mutate() {
+ super("atomic_batch_mutate");
+ }
+
+ public atomic_batch_mutate_args getEmptyArgsInstance() {
+ return new atomic_batch_mutate_args();
+ }
+
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Void>() {
+ public void onComplete(Void o) {
+ atomic_batch_mutate_result result = new atomic_batch_mutate_result();
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ atomic_batch_mutate_result result = new atomic_batch_mutate_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, atomic_batch_mutate_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ iface.atomic_batch_mutate(args.mutation_map, args.consistency_level,resultHandler);
+ }
+ }
+
+ public static class truncate<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, truncate_args, Void> {
+ public truncate() {
+ super("truncate");
+ }
+
+ public truncate_args getEmptyArgsInstance() {
+ return new truncate_args();
+ }
+
+ public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Void>() {
+ public void onComplete(Void o) {
+ truncate_result result = new truncate_result();
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ truncate_result result = new truncate_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof UnavailableException) {
+ result.ue = (UnavailableException) e;
+ result.setUeIsSet(true);
+ msg = result;
+ }
+ else if (e instanceof TimedOutException) {
+ result.te = (TimedOutException) e;
+ result.setTeIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, truncate_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ iface.truncate(args.cfname,resultHandler);
+ }
+ }
+
+ public static class describe_schema_versions<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, describe_schema_versions_args, Map<String,List<String>>> {
+ public describe_schema_versions() {
+ super("describe_schema_versions");
+ }
+
+ public describe_schema_versions_args getEmptyArgsInstance() {
+ return new describe_schema_versions_args();
+ }
+
+ public AsyncMethodCallback<Map<String,List<String>>> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<Map<String,List<String>>>() {
+ public void onComplete(Map<String,List<String>> o) {
+ describe_schema_versions_result result = new describe_schema_versions_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ describe_schema_versions_result result = new describe_schema_versions_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ public void start(I iface, describe_schema_versions_args args, org.apache.thrift.async.AsyncMethodCallback<Map<String,List<String>>> resultHandler) throws TException {
+ iface.describe_schema_versions(resultHandler);
+ }
+ }
+
+ public static class describe_keyspaces<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, describe_keyspaces_args, List<KsDef>> {
+ public describe_keyspaces() {
+ super("describe_keyspaces");
+ }
+
+ public describe_keyspaces_args getEmptyArgsInstance() {
+ return new describe_keyspaces_args();
+ }
+
+ public AsyncMethodCallback<List<KsDef>> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ final org.apache.thrift.AsyncProcessFunction fcall = this;
+ return new AsyncMethodCallback<List<KsDef>>() {
+ public void onComplete(List<KsDef> o) {
+ describe_keyspaces_result result = new describe_keyspaces_result();
+ result.success = o;
+ try {
+ fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ return;
+ } catch (Exception e) {
+ LOGGER.error("Exception writing to internal frame buffer", e);
+ }
+ fb.close();
+ }
+ public void onError(Exception e) {
+ byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
+ org.apache.thrift.TBase msg;
+ describe_keyspaces_result result = new describe_keyspaces_result();
+ if (e instanceof InvalidRequestException) {
+ result.ire = (InvalidRequestException) e;
+ result.setIreIsSet(true);
+ msg = result;
+ }
+ else
+ {
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
+ }
+ try {
+ fcall.sendResponse(fb,msg,msgType,seqid);
+ return;
+ } catch (Exception ex) {
+ LOGGER.error("Exception writing to internal frame buffer", ex);
+ }
+ fb.close();
+ }
+ };
+ }
+
+ protected boolean isOneway() {
+ return false;
+ }
+
+ publi
<TRUNCATED>