http://git-wip-us.apache.org/repos/asf/hive/blob/42216997/service/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/service/ThriftHive.java ---------------------------------------------------------------------- diff --git a/service/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/service/ThriftHive.java b/service/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/service/ThriftHive.java index 1c44789..e4ecd28 100644 --- a/service/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/service/ThriftHive.java +++ b/service/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/service/ThriftHive.java @@ -1,12 +1,11 @@ /** - * Autogenerated by Thrift Compiler (0.9.0) + * Autogenerated by Thrift Compiler (0.9.2) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package org.apache.hadoop.hive.service; -import org.apache.commons.lang.builder.HashCodeBuilder; import org.apache.thrift.scheme.IScheme; import org.apache.thrift.scheme.SchemeFactory; import org.apache.thrift.scheme.StandardScheme; @@ -16,6 +15,8 @@ import org.apache.thrift.protocol.TTupleProtocol; import org.apache.thrift.protocol.TProtocolException; import org.apache.thrift.EncodingUtils; import org.apache.thrift.TException; +import org.apache.thrift.async.AsyncMethodCallback; +import org.apache.thrift.server.AbstractNonblockingServer.*; import java.util.List; import java.util.ArrayList; import java.util.Map; @@ -28,9 +29,12 @@ import java.util.Collections; import java.util.BitSet; import java.nio.ByteBuffer; import java.util.Arrays; +import javax.annotation.Generated; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) +@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2015-7-14") public class ThriftHive { public interface Iface extends org.apache.hadoop.hive.metastore.api.ThriftHiveMetastore.Iface { @@ -57,23 +61,23 @@ public class ThriftHive { public interface AsyncIface extends org.apache.hadoop.hive.metastore.api.ThriftHiveMetastore .AsyncIface { - public void execute(String query, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.execute_call> resultHandler) throws org.apache.thrift.TException; + public void execute(String query, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; - public void fetchOne(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.fetchOne_call> resultHandler) throws org.apache.thrift.TException; + public void fetchOne(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; - public void fetchN(int numRows, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.fetchN_call> resultHandler) throws org.apache.thrift.TException; + public void fetchN(int numRows, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; - public void fetchAll(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.fetchAll_call> resultHandler) throws org.apache.thrift.TException; + public void fetchAll(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; - public void getSchema(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getSchema_call> resultHandler) throws org.apache.thrift.TException; + public void getSchema(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; - public void getThriftSchema(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getThriftSchema_call> resultHandler) throws org.apache.thrift.TException; + public void getThriftSchema(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; - public void getClusterStatus(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getClusterStatus_call> resultHandler) throws org.apache.thrift.TException; + public void getClusterStatus(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; - public void getQueryPlan(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getQueryPlan_call> resultHandler) throws org.apache.thrift.TException; + public void getQueryPlan(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; - public void clean(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.clean_call> resultHandler) throws org.apache.thrift.TException; + public void clean(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; } @@ -333,7 +337,7 @@ public class ThriftHive { super(protocolFactory, clientManager, transport); } - public void execute(String query, org.apache.thrift.async.AsyncMethodCallback<execute_call> resultHandler) throws org.apache.thrift.TException { + public void execute(String query, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); execute_call method_call = new execute_call(query, resultHandler, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; @@ -342,7 +346,7 @@ public class ThriftHive { public static class execute_call extends org.apache.thrift.async.TAsyncMethodCall { private String query; - public execute_call(String query, org.apache.thrift.async.AsyncMethodCallback<execute_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 execute_call(String query, 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.query = query; } @@ -365,7 +369,7 @@ public class ThriftHive { } } - public void fetchOne(org.apache.thrift.async.AsyncMethodCallback<fetchOne_call> resultHandler) throws org.apache.thrift.TException { + public void fetchOne(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); fetchOne_call method_call = new fetchOne_call(resultHandler, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; @@ -373,7 +377,7 @@ public class ThriftHive { } public static class fetchOne_call extends org.apache.thrift.async.TAsyncMethodCall { - public fetchOne_call(org.apache.thrift.async.AsyncMethodCallback<fetchOne_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 fetchOne_call(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); } @@ -394,7 +398,7 @@ public class ThriftHive { } } - public void fetchN(int numRows, org.apache.thrift.async.AsyncMethodCallback<fetchN_call> resultHandler) throws org.apache.thrift.TException { + public void fetchN(int numRows, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); fetchN_call method_call = new fetchN_call(numRows, resultHandler, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; @@ -403,7 +407,7 @@ public class ThriftHive { public static class fetchN_call extends org.apache.thrift.async.TAsyncMethodCall { private int numRows; - public fetchN_call(int numRows, org.apache.thrift.async.AsyncMethodCallback<fetchN_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 fetchN_call(int numRows, 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.numRows = numRows; } @@ -426,7 +430,7 @@ public class ThriftHive { } } - public void fetchAll(org.apache.thrift.async.AsyncMethodCallback<fetchAll_call> resultHandler) throws org.apache.thrift.TException { + public void fetchAll(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); fetchAll_call method_call = new fetchAll_call(resultHandler, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; @@ -434,7 +438,7 @@ public class ThriftHive { } public static class fetchAll_call extends org.apache.thrift.async.TAsyncMethodCall { - public fetchAll_call(org.apache.thrift.async.AsyncMethodCallback<fetchAll_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 fetchAll_call(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); } @@ -455,7 +459,7 @@ public class ThriftHive { } } - public void getSchema(org.apache.thrift.async.AsyncMethodCallback<getSchema_call> resultHandler) throws org.apache.thrift.TException { + public void getSchema(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); getSchema_call method_call = new getSchema_call(resultHandler, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; @@ -463,7 +467,7 @@ public class ThriftHive { } public static class getSchema_call extends org.apache.thrift.async.TAsyncMethodCall { - public getSchema_call(org.apache.thrift.async.AsyncMethodCallback<getSchema_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 getSchema_call(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); } @@ -484,7 +488,7 @@ public class ThriftHive { } } - public void getThriftSchema(org.apache.thrift.async.AsyncMethodCallback<getThriftSchema_call> resultHandler) throws org.apache.thrift.TException { + public void getThriftSchema(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); getThriftSchema_call method_call = new getThriftSchema_call(resultHandler, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; @@ -492,7 +496,7 @@ public class ThriftHive { } public static class getThriftSchema_call extends org.apache.thrift.async.TAsyncMethodCall { - public getThriftSchema_call(org.apache.thrift.async.AsyncMethodCallback<getThriftSchema_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 getThriftSchema_call(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); } @@ -513,7 +517,7 @@ public class ThriftHive { } } - public void getClusterStatus(org.apache.thrift.async.AsyncMethodCallback<getClusterStatus_call> resultHandler) throws org.apache.thrift.TException { + public void getClusterStatus(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); getClusterStatus_call method_call = new getClusterStatus_call(resultHandler, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; @@ -521,7 +525,7 @@ public class ThriftHive { } public static class getClusterStatus_call extends org.apache.thrift.async.TAsyncMethodCall { - public getClusterStatus_call(org.apache.thrift.async.AsyncMethodCallback<getClusterStatus_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 getClusterStatus_call(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); } @@ -542,7 +546,7 @@ public class ThriftHive { } } - public void getQueryPlan(org.apache.thrift.async.AsyncMethodCallback<getQueryPlan_call> resultHandler) throws org.apache.thrift.TException { + public void getQueryPlan(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); getQueryPlan_call method_call = new getQueryPlan_call(resultHandler, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; @@ -550,7 +554,7 @@ public class ThriftHive { } public static class getQueryPlan_call extends org.apache.thrift.async.TAsyncMethodCall { - public getQueryPlan_call(org.apache.thrift.async.AsyncMethodCallback<getQueryPlan_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 getQueryPlan_call(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); } @@ -571,7 +575,7 @@ public class ThriftHive { } } - public void clean(org.apache.thrift.async.AsyncMethodCallback<clean_call> resultHandler) throws org.apache.thrift.TException { + public void clean(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); clean_call method_call = new clean_call(resultHandler, this, ___protocolFactory, ___transport); this.___currentMethod = method_call; @@ -579,7 +583,7 @@ public class ThriftHive { } public static class clean_call extends org.apache.thrift.async.TAsyncMethodCall { - public clean_call(org.apache.thrift.async.AsyncMethodCallback<clean_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 clean_call(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); } @@ -839,7 +843,537 @@ public class ThriftHive { } - public static class execute_args implements org.apache.thrift.TBase<execute_args, execute_args._Fields>, java.io.Serializable, Cloneable { + public static class AsyncProcessor<I extends AsyncIface> extends org.apache.hadoop.hive.metastore.api.ThriftHiveMetastore.AsyncProcessor<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, ?>>())); + } + + protected AsyncProcessor(I iface, Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) { + super(iface, getProcessMap(processMap)); + } + + 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("execute", new execute()); + processMap.put("fetchOne", new fetchOne()); + processMap.put("fetchN", new fetchN()); + processMap.put("fetchAll", new fetchAll()); + processMap.put("getSchema", new getSchema()); + processMap.put("getThriftSchema", new getThriftSchema()); + processMap.put("getClusterStatus", new getClusterStatus()); + processMap.put("getQueryPlan", new getQueryPlan()); + processMap.put("clean", new clean()); + return processMap; + } + + public static class execute<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, execute_args, Void> { + public execute() { + super("execute"); + } + + public execute_args getEmptyArgsInstance() { + return new execute_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) { + execute_result result = new execute_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; + execute_result result = new execute_result(); + if (e instanceof HiveServerException) { + result.ex = (HiveServerException) e; + result.setExIsSet(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, execute_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException { + iface.execute(args.query,resultHandler); + } + } + + public static class fetchOne<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, fetchOne_args, String> { + public fetchOne() { + super("fetchOne"); + } + + public fetchOne_args getEmptyArgsInstance() { + return new fetchOne_args(); + } + + public AsyncMethodCallback<String> getResultHandler(final AsyncFrameBuffer fb, final int seqid) { + final org.apache.thrift.AsyncProcessFunction fcall = this; + return new AsyncMethodCallback<String>() { + public void onComplete(String o) { + fetchOne_result result = new fetchOne_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; + fetchOne_result result = new fetchOne_result(); + if (e instanceof HiveServerException) { + result.ex = (HiveServerException) e; + result.setExIsSet(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, fetchOne_args args, org.apache.thrift.async.AsyncMethodCallback<String> resultHandler) throws TException { + iface.fetchOne(resultHandler); + } + } + + public static class fetchN<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, fetchN_args, List<String>> { + public fetchN() { + super("fetchN"); + } + + public fetchN_args getEmptyArgsInstance() { + return new fetchN_args(); + } + + public AsyncMethodCallback<List<String>> getResultHandler(final AsyncFrameBuffer fb, final int seqid) { + final org.apache.thrift.AsyncProcessFunction fcall = this; + return new AsyncMethodCallback<List<String>>() { + public void onComplete(List<String> o) { + fetchN_result result = new fetchN_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; + fetchN_result result = new fetchN_result(); + if (e instanceof HiveServerException) { + result.ex = (HiveServerException) e; + result.setExIsSet(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, fetchN_args args, org.apache.thrift.async.AsyncMethodCallback<List<String>> resultHandler) throws TException { + iface.fetchN(args.numRows,resultHandler); + } + } + + public static class fetchAll<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, fetchAll_args, List<String>> { + public fetchAll() { + super("fetchAll"); + } + + public fetchAll_args getEmptyArgsInstance() { + return new fetchAll_args(); + } + + public AsyncMethodCallback<List<String>> getResultHandler(final AsyncFrameBuffer fb, final int seqid) { + final org.apache.thrift.AsyncProcessFunction fcall = this; + return new AsyncMethodCallback<List<String>>() { + public void onComplete(List<String> o) { + fetchAll_result result = new fetchAll_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; + fetchAll_result result = new fetchAll_result(); + if (e instanceof HiveServerException) { + result.ex = (HiveServerException) e; + result.setExIsSet(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, fetchAll_args args, org.apache.thrift.async.AsyncMethodCallback<List<String>> resultHandler) throws TException { + iface.fetchAll(resultHandler); + } + } + + public static class getSchema<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, getSchema_args, org.apache.hadoop.hive.metastore.api.Schema> { + public getSchema() { + super("getSchema"); + } + + public getSchema_args getEmptyArgsInstance() { + return new getSchema_args(); + } + + public AsyncMethodCallback<org.apache.hadoop.hive.metastore.api.Schema> getResultHandler(final AsyncFrameBuffer fb, final int seqid) { + final org.apache.thrift.AsyncProcessFunction fcall = this; + return new AsyncMethodCallback<org.apache.hadoop.hive.metastore.api.Schema>() { + public void onComplete(org.apache.hadoop.hive.metastore.api.Schema o) { + getSchema_result result = new getSchema_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; + getSchema_result result = new getSchema_result(); + if (e instanceof HiveServerException) { + result.ex = (HiveServerException) e; + result.setExIsSet(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, getSchema_args args, org.apache.thrift.async.AsyncMethodCallback<org.apache.hadoop.hive.metastore.api.Schema> resultHandler) throws TException { + iface.getSchema(resultHandler); + } + } + + public static class getThriftSchema<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, getThriftSchema_args, org.apache.hadoop.hive.metastore.api.Schema> { + public getThriftSchema() { + super("getThriftSchema"); + } + + public getThriftSchema_args getEmptyArgsInstance() { + return new getThriftSchema_args(); + } + + public AsyncMethodCallback<org.apache.hadoop.hive.metastore.api.Schema> getResultHandler(final AsyncFrameBuffer fb, final int seqid) { + final org.apache.thrift.AsyncProcessFunction fcall = this; + return new AsyncMethodCallback<org.apache.hadoop.hive.metastore.api.Schema>() { + public void onComplete(org.apache.hadoop.hive.metastore.api.Schema o) { + getThriftSchema_result result = new getThriftSchema_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; + getThriftSchema_result result = new getThriftSchema_result(); + if (e instanceof HiveServerException) { + result.ex = (HiveServerException) e; + result.setExIsSet(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, getThriftSchema_args args, org.apache.thrift.async.AsyncMethodCallback<org.apache.hadoop.hive.metastore.api.Schema> resultHandler) throws TException { + iface.getThriftSchema(resultHandler); + } + } + + public static class getClusterStatus<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, getClusterStatus_args, HiveClusterStatus> { + public getClusterStatus() { + super("getClusterStatus"); + } + + public getClusterStatus_args getEmptyArgsInstance() { + return new getClusterStatus_args(); + } + + public AsyncMethodCallback<HiveClusterStatus> getResultHandler(final AsyncFrameBuffer fb, final int seqid) { + final org.apache.thrift.AsyncProcessFunction fcall = this; + return new AsyncMethodCallback<HiveClusterStatus>() { + public void onComplete(HiveClusterStatus o) { + getClusterStatus_result result = new getClusterStatus_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; + getClusterStatus_result result = new getClusterStatus_result(); + if (e instanceof HiveServerException) { + result.ex = (HiveServerException) e; + result.setExIsSet(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, getClusterStatus_args args, org.apache.thrift.async.AsyncMethodCallback<HiveClusterStatus> resultHandler) throws TException { + iface.getClusterStatus(resultHandler); + } + } + + public static class getQueryPlan<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, getQueryPlan_args, org.apache.hadoop.hive.ql.plan.api.QueryPlan> { + public getQueryPlan() { + super("getQueryPlan"); + } + + public getQueryPlan_args getEmptyArgsInstance() { + return new getQueryPlan_args(); + } + + public AsyncMethodCallback<org.apache.hadoop.hive.ql.plan.api.QueryPlan> getResultHandler(final AsyncFrameBuffer fb, final int seqid) { + final org.apache.thrift.AsyncProcessFunction fcall = this; + return new AsyncMethodCallback<org.apache.hadoop.hive.ql.plan.api.QueryPlan>() { + public void onComplete(org.apache.hadoop.hive.ql.plan.api.QueryPlan o) { + getQueryPlan_result result = new getQueryPlan_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; + getQueryPlan_result result = new getQueryPlan_result(); + if (e instanceof HiveServerException) { + result.ex = (HiveServerException) e; + result.setExIsSet(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, getQueryPlan_args args, org.apache.thrift.async.AsyncMethodCallback<org.apache.hadoop.hive.ql.plan.api.QueryPlan> resultHandler) throws TException { + iface.getQueryPlan(resultHandler); + } + } + + public static class clean<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, clean_args, Void> { + public clean() { + super("clean"); + } + + public clean_args getEmptyArgsInstance() { + return new clean_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) { + clean_result result = new clean_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; + clean_result result = new clean_result(); + { + 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, clean_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException { + iface.clean(resultHandler); + } + } + + } + + public static class execute_args implements org.apache.thrift.TBase<execute_args, execute_args._Fields>, java.io.Serializable, Cloneable, Comparable<execute_args> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("execute_args"); private static final org.apache.thrift.protocol.TField QUERY_FIELD_DESC = new org.apache.thrift.protocol.TField("query", org.apache.thrift.protocol.TType.STRING, (short)1); @@ -1033,30 +1567,30 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_query = true && (isSetQuery()); - builder.append(present_query); + list.add(present_query); if (present_query) - builder.append(query); + list.add(query); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(execute_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - execute_args typedOther = (execute_args)other; - lastComparison = Boolean.valueOf(isSetQuery()).compareTo(typedOther.isSetQuery()); + lastComparison = Boolean.valueOf(isSetQuery()).compareTo(other.isSetQuery()); if (lastComparison != 0) { return lastComparison; } if (isSetQuery()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.query, typedOther.query); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.query, other.query); if (lastComparison != 0) { return lastComparison; } @@ -1197,7 +1731,7 @@ public class ThriftHive { } - public static class execute_result implements org.apache.thrift.TBase<execute_result, execute_result._Fields>, java.io.Serializable, Cloneable { + public static class execute_result implements org.apache.thrift.TBase<execute_result, execute_result._Fields>, java.io.Serializable, Cloneable, Comparable<execute_result> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("execute_result"); private static final org.apache.thrift.protocol.TField EX_FIELD_DESC = new org.apache.thrift.protocol.TField("ex", org.apache.thrift.protocol.TType.STRUCT, (short)1); @@ -1391,30 +1925,30 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_ex = true && (isSetEx()); - builder.append(present_ex); + list.add(present_ex); if (present_ex) - builder.append(ex); + list.add(ex); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(execute_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - execute_result typedOther = (execute_result)other; - lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx()); + lastComparison = Boolean.valueOf(isSetEx()).compareTo(other.isSetEx()); if (lastComparison != 0) { return lastComparison; } if (isSetEx()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, other.ex); if (lastComparison != 0) { return lastComparison; } @@ -1557,7 +2091,7 @@ public class ThriftHive { } - public static class fetchOne_args implements org.apache.thrift.TBase<fetchOne_args, fetchOne_args._Fields>, java.io.Serializable, Cloneable { + public static class fetchOne_args implements org.apache.thrift.TBase<fetchOne_args, fetchOne_args._Fields>, java.io.Serializable, Cloneable, Comparable<fetchOne_args> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("fetchOne_args"); @@ -1687,18 +2221,18 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(fetchOne_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - fetchOne_args typedOther = (fetchOne_args)other; return 0; } @@ -1803,7 +2337,7 @@ public class ThriftHive { } - public static class fetchOne_result implements org.apache.thrift.TBase<fetchOne_result, fetchOne_result._Fields>, java.io.Serializable, Cloneable { + public static class fetchOne_result implements org.apache.thrift.TBase<fetchOne_result, fetchOne_result._Fields>, java.io.Serializable, Cloneable, Comparable<fetchOne_result> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("fetchOne_result"); private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRING, (short)0); @@ -2055,45 +2589,45 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_success = true && (isSetSuccess()); - builder.append(present_success); + list.add(present_success); if (present_success) - builder.append(success); + list.add(success); boolean present_ex = true && (isSetEx()); - builder.append(present_ex); + list.add(present_ex); if (present_ex) - builder.append(ex); + list.add(ex); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(fetchOne_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - fetchOne_result typedOther = (fetchOne_result)other; - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); if (lastComparison != 0) { return lastComparison; } if (isSetSuccess()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success); if (lastComparison != 0) { return lastComparison; } } - lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx()); + lastComparison = Boolean.valueOf(isSetEx()).compareTo(other.isSetEx()); if (lastComparison != 0) { return lastComparison; } if (isSetEx()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, other.ex); if (lastComparison != 0) { return lastComparison; } @@ -2267,7 +2801,7 @@ public class ThriftHive { } - public static class fetchN_args implements org.apache.thrift.TBase<fetchN_args, fetchN_args._Fields>, java.io.Serializable, Cloneable { + public static class fetchN_args implements org.apache.thrift.TBase<fetchN_args, fetchN_args._Fields>, java.io.Serializable, Cloneable, Comparable<fetchN_args> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("fetchN_args"); private static final org.apache.thrift.protocol.TField NUM_ROWS_FIELD_DESC = new org.apache.thrift.protocol.TField("numRows", org.apache.thrift.protocol.TType.I32, (short)1); @@ -2463,30 +2997,30 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_numRows = true; - builder.append(present_numRows); + list.add(present_numRows); if (present_numRows) - builder.append(numRows); + list.add(numRows); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(fetchN_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - fetchN_args typedOther = (fetchN_args)other; - lastComparison = Boolean.valueOf(isSetNumRows()).compareTo(typedOther.isSetNumRows()); + lastComparison = Boolean.valueOf(isSetNumRows()).compareTo(other.isSetNumRows()); if (lastComparison != 0) { return lastComparison; } if (isSetNumRows()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.numRows, typedOther.numRows); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.numRows, other.numRows); if (lastComparison != 0) { return lastComparison; } @@ -2623,7 +3157,7 @@ public class ThriftHive { } - public static class fetchN_result implements org.apache.thrift.TBase<fetchN_result, fetchN_result._Fields>, java.io.Serializable, Cloneable { + public static class fetchN_result implements org.apache.thrift.TBase<fetchN_result, fetchN_result._Fields>, java.io.Serializable, Cloneable, Comparable<fetchN_result> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("fetchN_result"); private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0); @@ -2729,10 +3263,7 @@ public class ThriftHive { */ public fetchN_result(fetchN_result other) { if (other.isSetSuccess()) { - List<String> __this__success = new ArrayList<String>(); - for (String other_element : other.success) { - __this__success.add(other_element); - } + List<String> __this__success = new ArrayList<String>(other.success); this.success = __this__success; } if (other.isSetEx()) { @@ -2895,45 +3426,45 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_success = true && (isSetSuccess()); - builder.append(present_success); + list.add(present_success); if (present_success) - builder.append(success); + list.add(success); boolean present_ex = true && (isSetEx()); - builder.append(present_ex); + list.add(present_ex); if (present_ex) - builder.append(ex); + list.add(ex); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(fetchN_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - fetchN_result typedOther = (fetchN_result)other; - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); if (lastComparison != 0) { return lastComparison; } if (isSetSuccess()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success); if (lastComparison != 0) { return lastComparison; } } - lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx()); + lastComparison = Boolean.valueOf(isSetEx()).compareTo(other.isSetEx()); if (lastComparison != 0) { return lastComparison; } if (isSetEx()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, other.ex); if (lastComparison != 0) { return lastComparison; } @@ -3021,11 +3552,11 @@ public class ThriftHive { { org.apache.thrift.protocol.TList _list0 = iprot.readListBegin(); struct.success = new ArrayList<String>(_list0.size); - for (int _i1 = 0; _i1 < _list0.size; ++_i1) + String _elem1; + for (int _i2 = 0; _i2 < _list0.size; ++_i2) { - String _elem2; // optional - _elem2 = iprot.readString(); - struct.success.add(_elem2); + _elem1 = iprot.readString(); + struct.success.add(_elem1); } iprot.readListEnd(); } @@ -3120,11 +3651,11 @@ public class ThriftHive { { org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); struct.success = new ArrayList<String>(_list5.size); - for (int _i6 = 0; _i6 < _list5.size; ++_i6) + String _elem6; + for (int _i7 = 0; _i7 < _list5.size; ++_i7) { - String _elem7; // optional - _elem7 = iprot.readString(); - struct.success.add(_elem7); + _elem6 = iprot.readString(); + struct.success.add(_elem6); } } struct.setSuccessIsSet(true); @@ -3139,7 +3670,7 @@ public class ThriftHive { } - public static class fetchAll_args implements org.apache.thrift.TBase<fetchAll_args, fetchAll_args._Fields>, java.io.Serializable, Cloneable { + public static class fetchAll_args implements org.apache.thrift.TBase<fetchAll_args, fetchAll_args._Fields>, java.io.Serializable, Cloneable, Comparable<fetchAll_args> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("fetchAll_args"); @@ -3269,18 +3800,18 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(fetchAll_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - fetchAll_args typedOther = (fetchAll_args)other; return 0; } @@ -3385,7 +3916,7 @@ public class ThriftHive { } - public static class fetchAll_result implements org.apache.thrift.TBase<fetchAll_result, fetchAll_result._Fields>, java.io.Serializable, Cloneable { + public static class fetchAll_result implements org.apache.thrift.TBase<fetchAll_result, fetchAll_result._Fields>, java.io.Serializable, Cloneable, Comparable<fetchAll_result> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("fetchAll_result"); private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0); @@ -3491,10 +4022,7 @@ public class ThriftHive { */ public fetchAll_result(fetchAll_result other) { if (other.isSetSuccess()) { - List<String> __this__success = new ArrayList<String>(); - for (String other_element : other.success) { - __this__success.add(other_element); - } + List<String> __this__success = new ArrayList<String>(other.success); this.success = __this__success; } if (other.isSetEx()) { @@ -3657,45 +4185,45 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_success = true && (isSetSuccess()); - builder.append(present_success); + list.add(present_success); if (present_success) - builder.append(success); + list.add(success); boolean present_ex = true && (isSetEx()); - builder.append(present_ex); + list.add(present_ex); if (present_ex) - builder.append(ex); + list.add(ex); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(fetchAll_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - fetchAll_result typedOther = (fetchAll_result)other; - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); if (lastComparison != 0) { return lastComparison; } if (isSetSuccess()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success); if (lastComparison != 0) { return lastComparison; } } - lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx()); + lastComparison = Boolean.valueOf(isSetEx()).compareTo(other.isSetEx()); if (lastComparison != 0) { return lastComparison; } if (isSetEx()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, other.ex); if (lastComparison != 0) { return lastComparison; } @@ -3783,11 +4311,11 @@ public class ThriftHive { { org.apache.thrift.protocol.TList _list8 = iprot.readListBegin(); struct.success = new ArrayList<String>(_list8.size); - for (int _i9 = 0; _i9 < _list8.size; ++_i9) + String _elem9; + for (int _i10 = 0; _i10 < _list8.size; ++_i10) { - String _elem10; // optional - _elem10 = iprot.readString(); - struct.success.add(_elem10); + _elem9 = iprot.readString(); + struct.success.add(_elem9); } iprot.readListEnd(); } @@ -3882,11 +4410,11 @@ public class ThriftHive { { org.apache.thrift.protocol.TList _list13 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); struct.success = new ArrayList<String>(_list13.size); - for (int _i14 = 0; _i14 < _list13.size; ++_i14) + String _elem14; + for (int _i15 = 0; _i15 < _list13.size; ++_i15) { - String _elem15; // optional - _elem15 = iprot.readString(); - struct.success.add(_elem15); + _elem14 = iprot.readString(); + struct.success.add(_elem14); } } struct.setSuccessIsSet(true); @@ -3901,7 +4429,7 @@ public class ThriftHive { } - public static class getSchema_args implements org.apache.thrift.TBase<getSchema_args, getSchema_args._Fields>, java.io.Serializable, Cloneable { + public static class getSchema_args implements org.apache.thrift.TBase<getSchema_args, getSchema_args._Fields>, java.io.Serializable, Cloneable, Comparable<getSchema_args> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSchema_args"); @@ -4031,18 +4559,18 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(getSchema_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - getSchema_args typedOther = (getSchema_args)other; return 0; } @@ -4147,7 +4675,7 @@ public class ThriftHive { } - public static class getSchema_result implements org.apache.thrift.TBase<getSchema_result, getSchema_result._Fields>, java.io.Serializable, Cloneable { + public static class getSchema_result implements org.apache.thrift.TBase<getSchema_result, getSchema_result._Fields>, java.io.Serializable, Cloneable, Comparable<getSchema_result> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSchema_result"); private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0); @@ -4399,45 +4927,45 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_success = true && (isSetSuccess()); - builder.append(present_success); + list.add(present_success); if (present_success) - builder.append(success); + list.add(success); boolean present_ex = true && (isSetEx()); - builder.append(present_ex); + list.add(present_ex); if (present_ex) - builder.append(ex); + list.add(ex); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(getSchema_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - getSchema_result typedOther = (getSchema_result)other; - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); if (lastComparison != 0) { return lastComparison; } if (isSetSuccess()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success); if (lastComparison != 0) { return lastComparison; } } - lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx()); + lastComparison = Boolean.valueOf(isSetEx()).compareTo(other.isSetEx()); if (lastComparison != 0) { return lastComparison; } if (isSetEx()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, other.ex); if (lastComparison != 0) { return lastComparison; } @@ -4616,7 +5144,7 @@ public class ThriftHive { } - public static class getThriftSchema_args implements org.apache.thrift.TBase<getThriftSchema_args, getThriftSchema_args._Fields>, java.io.Serializable, Cloneable { + public static class getThriftSchema_args implements org.apache.thrift.TBase<getThriftSchema_args, getThriftSchema_args._Fields>, java.io.Serializable, Cloneable, Comparable<getThriftSchema_args> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getThriftSchema_args"); @@ -4746,18 +5274,18 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(getThriftSchema_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - getThriftSchema_args typedOther = (getThriftSchema_args)other; return 0; } @@ -4862,7 +5390,7 @@ public class ThriftHive { } - public static class getThriftSchema_result implements org.apache.thrift.TBase<getThriftSchema_result, getThriftSchema_result._Fields>, java.io.Serializable, Cloneable { + public static class getThriftSchema_result implements org.apache.thrift.TBase<getThriftSchema_result, getThriftSchema_result._Fields>, java.io.Serializable, Cloneable, Comparable<getThriftSchema_result> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getThriftSchema_result"); private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0); @@ -5114,45 +5642,45 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_success = true && (isSetSuccess()); - builder.append(present_success); + list.add(present_success); if (present_success) - builder.append(success); + list.add(success); boolean present_ex = true && (isSetEx()); - builder.append(present_ex); + list.add(present_ex); if (present_ex) - builder.append(ex); + list.add(ex); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(getThriftSchema_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - getThriftSchema_result typedOther = (getThriftSchema_result)other; - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); if (lastComparison != 0) { return lastComparison; } if (isSetSuccess()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success); if (lastComparison != 0) { return lastComparison; } } - lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx()); + lastComparison = Boolean.valueOf(isSetEx()).compareTo(other.isSetEx()); if (lastComparison != 0) { return lastComparison; } if (isSetEx()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, other.ex); if (lastComparison != 0) { return lastComparison; } @@ -5331,7 +5859,7 @@ public class ThriftHive { } - public static class getClusterStatus_args implements org.apache.thrift.TBase<getClusterStatus_args, getClusterStatus_args._Fields>, java.io.Serializable, Cloneable { + public static class getClusterStatus_args implements org.apache.thrift.TBase<getClusterStatus_args, getClusterStatus_args._Fields>, java.io.Serializable, Cloneable, Comparable<getClusterStatus_args> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getClusterStatus_args"); @@ -5461,18 +5989,18 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(getClusterStatus_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - getClusterStatus_args typedOther = (getClusterStatus_args)other; return 0; } @@ -5577,7 +6105,7 @@ public class ThriftHive { } - public static class getClusterStatus_result implements org.apache.thrift.TBase<getClusterStatus_result, getClusterStatus_result._Fields>, java.io.Serializable, Cloneable { + public static class getClusterStatus_result implements org.apache.thrift.TBase<getClusterStatus_result, getClusterStatus_result._Fields>, java.io.Serializable, Cloneable, Comparable<getClusterStatus_result> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getClusterStatus_result"); private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0); @@ -5829,45 +6357,45 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_success = true && (isSetSuccess()); - builder.append(present_success); + list.add(present_success); if (present_success) - builder.append(success); + list.add(success); boolean present_ex = true && (isSetEx()); - builder.append(present_ex); + list.add(present_ex); if (present_ex) - builder.append(ex); + list.add(ex); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(getClusterStatus_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - getClusterStatus_result typedOther = (getClusterStatus_result)other; - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); if (lastComparison != 0) { return lastComparison; } if (isSetSuccess()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success); if (lastComparison != 0) { return lastComparison; } } - lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx()); + lastComparison = Boolean.valueOf(isSetEx()).compareTo(other.isSetEx()); if (lastComparison != 0) { return lastComparison; } if (isSetEx()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, other.ex); if (lastComparison != 0) { return lastComparison; } @@ -6046,7 +6574,7 @@ public class ThriftHive { } - public static class getQueryPlan_args implements org.apache.thrift.TBase<getQueryPlan_args, getQueryPlan_args._Fields>, java.io.Serializable, Cloneable { + public static class getQueryPlan_args implements org.apache.thrift.TBase<getQueryPlan_args, getQueryPlan_args._Fields>, java.io.Serializable, Cloneable, Comparable<getQueryPlan_args> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getQueryPlan_args"); @@ -6176,18 +6704,18 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(getQueryPlan_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - getQueryPlan_args typedOther = (getQueryPlan_args)other; return 0; } @@ -6292,7 +6820,7 @@ public class ThriftHive { } - public static class getQueryPlan_result implements org.apache.thrift.TBase<getQueryPlan_result, getQueryPlan_result._Fields>, java.io.Serializable, Cloneable { + public static class getQueryPlan_result implements org.apache.thrift.TBase<getQueryPlan_result, getQueryPlan_result._Fields>, java.io.Serializable, Cloneable, Comparable<getQueryPlan_result> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getQueryPlan_result"); private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0); @@ -6544,45 +7072,45 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_success = true && (isSetSuccess()); - builder.append(present_success); + list.add(present_success); if (present_success) - builder.append(success); + list.add(success); boolean present_ex = true && (isSetEx()); - builder.append(present_ex); + list.add(present_ex); if (present_ex) - builder.append(ex); + list.add(ex); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(getQueryPlan_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - getQueryPlan_result typedOther = (getQueryPlan_result)other; - lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess()); if (lastComparison != 0) { return lastComparison; } if (isSetSuccess()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success); if (lastComparison != 0) { return lastComparison; } } - lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx()); + lastComparison = Boolean.valueOf(isSetEx()).compareTo(other.isSetEx()); if (lastComparison != 0) { return lastComparison; } if (isSetEx()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, other.ex); if (lastComparison != 0) { return lastComparison; } @@ -6761,7 +7289,7 @@ public class ThriftHive { } - public static class clean_args implements org.apache.thrift.TBase<clean_args, clean_args._Fields>, java.io.Serializable, Cloneable { + public static class clean_args implements org.apache.thrift.TBase<clean_args, clean_args._Fields>, java.io.Serializable, Cloneable, Comparable<clean_args> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clean_args"); @@ -6891,18 +7419,18 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(clean_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - clean_args typedOther = (clean_args)other; return 0; } @@ -7007,7 +7535,7 @@ public class ThriftHive { } - public static class clean_result implements org.apache.thrift.TBase<clean_result, clean_result._Fields>, java.io.Serializable, Cloneable { + public static class clean_result implements org.apache.thrift.TBase<clean_result, clean_result._Fields>, java.io.Serializable, Cloneable, Comparable<clean_result> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clean_result"); @@ -7137,18 +7665,18 @@ public class ThriftHive { @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(clean_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - clean_result typedOther = (clean_result)other; return 0; }
http://git-wip-us.apache.org/repos/asf/hive/blob/42216997/service/src/gen/thrift/gen-javabean/org/apache/hive/service/cli/thrift/TArrayTypeEntry.java ---------------------------------------------------------------------- diff --git a/service/src/gen/thrift/gen-javabean/org/apache/hive/service/cli/thrift/TArrayTypeEntry.java b/service/src/gen/thrift/gen-javabean/org/apache/hive/service/cli/thrift/TArrayTypeEntry.java index 6323d34..8d18125 100644 --- a/service/src/gen/thrift/gen-javabean/org/apache/hive/service/cli/thrift/TArrayTypeEntry.java +++ b/service/src/gen/thrift/gen-javabean/org/apache/hive/service/cli/thrift/TArrayTypeEntry.java @@ -1,12 +1,11 @@ /** - * Autogenerated by Thrift Compiler (0.9.0) + * Autogenerated by Thrift Compiler (0.9.2) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package org.apache.hive.service.cli.thrift; -import org.apache.commons.lang.builder.HashCodeBuilder; import org.apache.thrift.scheme.IScheme; import org.apache.thrift.scheme.SchemeFactory; import org.apache.thrift.scheme.StandardScheme; @@ -16,6 +15,8 @@ import org.apache.thrift.protocol.TTupleProtocol; import org.apache.thrift.protocol.TProtocolException; import org.apache.thrift.EncodingUtils; import org.apache.thrift.TException; +import org.apache.thrift.async.AsyncMethodCallback; +import org.apache.thrift.server.AbstractNonblockingServer.*; import java.util.List; import java.util.ArrayList; import java.util.Map; @@ -28,10 +29,13 @@ import java.util.Collections; import java.util.BitSet; import java.nio.ByteBuffer; import java.util.Arrays; +import javax.annotation.Generated; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -public class TArrayTypeEntry implements org.apache.thrift.TBase<TArrayTypeEntry, TArrayTypeEntry._Fields>, java.io.Serializable, Cloneable { +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) +@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2015-7-14") +public class TArrayTypeEntry implements org.apache.thrift.TBase<TArrayTypeEntry, TArrayTypeEntry._Fields>, java.io.Serializable, Cloneable, Comparable<TArrayTypeEntry> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TArrayTypeEntry"); private static final org.apache.thrift.protocol.TField OBJECT_TYPE_PTR_FIELD_DESC = new org.apache.thrift.protocol.TField("objectTypePtr", org.apache.thrift.protocol.TType.I32, (short)1); @@ -227,30 +231,30 @@ public class TArrayTypeEntry implements org.apache.thrift.TBase<TArrayTypeEntry, @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_objectTypePtr = true; - builder.append(present_objectTypePtr); + list.add(present_objectTypePtr); if (present_objectTypePtr) - builder.append(objectTypePtr); + list.add(objectTypePtr); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(TArrayTypeEntry other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - TArrayTypeEntry typedOther = (TArrayTypeEntry)other; - lastComparison = Boolean.valueOf(isSetObjectTypePtr()).compareTo(typedOther.isSetObjectTypePtr()); + lastComparison = Boolean.valueOf(isSetObjectTypePtr()).compareTo(other.isSetObjectTypePtr()); if (lastComparison != 0) { return lastComparison; } if (isSetObjectTypePtr()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.objectTypePtr, typedOther.objectTypePtr); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.objectTypePtr, other.objectTypePtr); if (lastComparison != 0) { return lastComparison; } http://git-wip-us.apache.org/repos/asf/hive/blob/42216997/service/src/gen/thrift/gen-javabean/org/apache/hive/service/cli/thrift/TBinaryColumn.java ---------------------------------------------------------------------- diff --git a/service/src/gen/thrift/gen-javabean/org/apache/hive/service/cli/thrift/TBinaryColumn.java b/service/src/gen/thrift/gen-javabean/org/apache/hive/service/cli/thrift/TBinaryColumn.java index 6b1b054..255726a 100644 --- a/service/src/gen/thrift/gen-javabean/org/apache/hive/service/cli/thrift/TBinaryColumn.java +++ b/service/src/gen/thrift/gen-javabean/org/apache/hive/service/cli/thrift/TBinaryColumn.java @@ -1,12 +1,11 @@ /** - * Autogenerated by Thrift Compiler (0.9.0) + * Autogenerated by Thrift Compiler (0.9.2) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package org.apache.hive.service.cli.thrift; -import org.apache.commons.lang.builder.HashCodeBuilder; import org.apache.thrift.scheme.IScheme; import org.apache.thrift.scheme.SchemeFactory; import org.apache.thrift.scheme.StandardScheme; @@ -16,6 +15,8 @@ import org.apache.thrift.protocol.TTupleProtocol; import org.apache.thrift.protocol.TProtocolException; import org.apache.thrift.EncodingUtils; import org.apache.thrift.TException; +import org.apache.thrift.async.AsyncMethodCallback; +import org.apache.thrift.server.AbstractNonblockingServer.*; import java.util.List; import java.util.ArrayList; import java.util.Map; @@ -28,10 +29,13 @@ import java.util.Collections; import java.util.BitSet; import java.nio.ByteBuffer; import java.util.Arrays; +import javax.annotation.Generated; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -public class TBinaryColumn implements org.apache.thrift.TBase<TBinaryColumn, TBinaryColumn._Fields>, java.io.Serializable, Cloneable { +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) +@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2015-7-14") +public class TBinaryColumn implements org.apache.thrift.TBase<TBinaryColumn, TBinaryColumn._Fields>, java.io.Serializable, Cloneable, Comparable<TBinaryColumn> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TBinaryColumn"); private static final org.apache.thrift.protocol.TField VALUES_FIELD_DESC = new org.apache.thrift.protocol.TField("values", org.apache.thrift.protocol.TType.LIST, (short)1); @@ -129,7 +133,7 @@ public class TBinaryColumn implements org.apache.thrift.TBase<TBinaryColumn, TBi { this(); this.values = values; - this.nulls = nulls; + this.nulls = org.apache.thrift.TBaseHelper.copyBinary(nulls); } /** @@ -137,17 +141,11 @@ public class TBinaryColumn implements org.apache.thrift.TBase<TBinaryColumn, TBi */ public TBinaryColumn(TBinaryColumn other) { if (other.isSetValues()) { - List<ByteBuffer> __this__values = new ArrayList<ByteBuffer>(); - for (ByteBuffer other_element : other.values) { - ByteBuffer temp_binary_element = org.apache.thrift.TBaseHelper.copyBinary(other_element); -; - __this__values.add(temp_binary_element); - } + List<ByteBuffer> __this__values = new ArrayList<ByteBuffer>(other.values); this.values = __this__values; } if (other.isSetNulls()) { this.nulls = org.apache.thrift.TBaseHelper.copyBinary(other.nulls); -; } } @@ -205,15 +203,15 @@ public class TBinaryColumn implements org.apache.thrift.TBase<TBinaryColumn, TBi } public ByteBuffer bufferForNulls() { - return nulls; + return org.apache.thrift.TBaseHelper.copyBinary(nulls); } public void setNulls(byte[] nulls) { - setNulls(nulls == null ? (ByteBuffer)null : ByteBuffer.wrap(nulls)); + this.nulls = nulls == null ? (ByteBuffer)null : ByteBuffer.wrap(Arrays.copyOf(nulls, nulls.length)); } public void setNulls(ByteBuffer nulls) { - this.nulls = nulls; + this.nulls = org.apache.thrift.TBaseHelper.copyBinary(nulls); } public void unsetNulls() { @@ -315,45 +313,45 @@ public class TBinaryColumn implements org.apache.thrift.TBase<TBinaryColumn, TBi @Override public int hashCode() { - HashCodeBuilder builder = new HashCodeBuilder(); + List<Object> list = new ArrayList<Object>(); boolean present_values = true && (isSetValues()); - builder.append(present_values); + list.add(present_values); if (present_values) - builder.append(values); + list.add(values); boolean present_nulls = true && (isSetNulls()); - builder.append(present_nulls); + list.add(present_nulls); if (present_nulls) - builder.append(nulls); + list.add(nulls); - return builder.toHashCode(); + return list.hashCode(); } + @Override public int compareTo(TBinaryColumn other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - TBinaryColumn typedOther = (TBinaryColumn)other; - lastComparison = Boolean.valueOf(isSetValues()).compareTo(typedOther.isSetValues()); + lastComparison = Boolean.valueOf(isSetValues()).compareTo(other.isSetValues()); if (lastComparison != 0) { return lastComparison; } if (isSetValues()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.values, typedOther.values); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.values, other.values); if (lastComparison != 0) { return lastComparison; } } - lastComparison = Boolean.valueOf(isSetNulls()).compareTo(typedOther.isSetNulls()); + lastComparison = Boolean.valueOf(isSetNulls()).compareTo(other.isSetNulls()); if (lastComparison != 0) { return lastComparison; } if (isSetNulls()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.nulls, typedOther.nulls); + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.nulls, other.nulls); if (lastComparison != 0) { return lastComparison; } @@ -449,11 +447,11 @@ public class TBinaryColumn implements org.apache.thrift.TBase<TBinaryColumn, TBi { org.apache.thrift.protocol.TList _list110 = iprot.readListBegin(); struct.values = new ArrayList<ByteBuffer>(_list110.size); - for (int _i111 = 0; _i111 < _list110.size; ++_i111) + ByteBuffer _elem111; + for (int _i112 = 0; _i112 < _list110.size; ++_i112) { - ByteBuffer _elem112; // optional - _elem112 = iprot.readBinary(); - struct.values.add(_elem112); + _elem111 = iprot.readBinary(); + struct.values.add(_elem111); } iprot.readListEnd(); } @@ -533,11 +531,11 @@ public class TBinaryColumn implements org.apache.thrift.TBase<TBinaryColumn, TBi { org.apache.thrift.protocol.TList _list115 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); struct.values = new ArrayList<ByteBuffer>(_list115.size); - for (int _i116 = 0; _i116 < _list115.size; ++_i116) + ByteBuffer _elem116; + for (int _i117 = 0; _i117 < _list115.size; ++_i117) { - ByteBuffer _elem117; // optional - _elem117 = iprot.readBinary(); - struct.values.add(_elem117); + _elem116 = iprot.readBinary(); + struct.values.add(_elem116); } } struct.setValuesIsSet(true);
