You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@zeppelin.apache.org by rk...@apache.org on 2019/06/12 12:30:49 UTC
[zeppelin] branch master updated: [ZEPPELIN-4185] Upgrade Thrift to
0.12.0 (#3376)
This is an automated email from the ASF dual-hosted git repository.
rkamath pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/zeppelin.git
The following commit(s) were added to refs/heads/master by this push:
new 4ee6a82 [ZEPPELIN-4185] Upgrade Thrift to 0.12.0 (#3376)
4ee6a82 is described below
commit 4ee6a82d11e1cd0d11f74a6dda0676a88fc4a6ed
Author: Renjith Kamath <r-...@users.noreply.github.com>
AuthorDate: Wed Jun 12 18:00:38 2019 +0530
[ZEPPELIN-4185] Upgrade Thrift to 0.12.0 (#3376)
Change-Id: I431f95ea5eed4b12df68f9d6b083cdf89e874216
---
pom.xml | 2 +-
zeppelin-distribution/src/bin_license/LICENSE | 2 +-
.../interpreter/thrift/AngularObjectId.java | 171 +-
.../interpreter/thrift/AppOutputAppendEvent.java | 208 +-
.../interpreter/thrift/AppOutputUpdateEvent.java | 228 +-
.../interpreter/thrift/AppStatusUpdateEvent.java | 191 +-
.../thrift/ClusterIntpProcParameters.java | 228 +-
.../interpreter/thrift/ClusterManagerService.java | 299 +-
.../interpreter/thrift/InterpreterCompletion.java | 171 +-
.../interpreter/thrift/OutputAppendEvent.java | 208 +-
.../interpreter/thrift/OutputUpdateAllEvent.java | 184 +-
.../interpreter/thrift/OutputUpdateEvent.java | 228 +-
.../zeppelin/interpreter/thrift/ParagraphInfo.java | 191 +-
.../zeppelin/interpreter/thrift/RegisterInfo.java | 168 +-
.../thrift/RemoteApplicationResult.java | 148 +-
.../thrift/RemoteInterpreterContext.java | 379 +-
.../interpreter/thrift/RemoteInterpreterEvent.java | 145 +-
.../thrift/RemoteInterpreterEventService.java | 4149 +++++++------
.../thrift/RemoteInterpreterEventType.java | 8 +-
.../thrift/RemoteInterpreterResult.java | 224 +-
.../thrift/RemoteInterpreterResultMessage.java | 151 +-
.../thrift/RemoteInterpreterService.java | 6163 +++++++++++---------
.../interpreter/thrift/RunParagraphsEvent.java | 223 +-
.../interpreter/thrift/ServiceException.java | 129 +-
.../zeppelin/dep/DependencyResolverTest.java | 4 +-
25 files changed, 7376 insertions(+), 6826 deletions(-)
diff --git a/pom.xml b/pom.xml
index c0767b2..a3aad15 100644
--- a/pom.xml
+++ b/pom.xml
@@ -108,7 +108,7 @@
<!-- common library versions -->
<slf4j.version>1.7.10</slf4j.version>
<log4j.version>1.2.17</log4j.version>
- <libthrift.version>0.9.3</libthrift.version>
+ <libthrift.version>0.12.0</libthrift.version>
<gson.version>2.2</gson.version>
<gson-extras.version>0.2.1</gson-extras.version>
<jetty.version>9.4.14.v20181114</jetty.version>
diff --git a/zeppelin-distribution/src/bin_license/LICENSE b/zeppelin-distribution/src/bin_license/LICENSE
index b1f7e48..59103f0 100644
--- a/zeppelin-distribution/src/bin_license/LICENSE
+++ b/zeppelin-distribution/src/bin_license/LICENSE
@@ -38,7 +38,7 @@ The following components are provided under Apache License.
(Apache 2.0) Apache Lens (http://lens.apache.org/)
(Apache 2.0) Apache Flink (http://flink.apache.org/)
(Apache 2.0) Apache Beam (http://beam.apache.org/)
- (Apache 2.0) Apache Thrift 0.9.3 (org.apache.thrift:libthrift:0.9.3 - http://thrift.apache.org/)
+ (Apache 2.0) Apache Thrift 0.12.0 (org.apache.thrift:libthrift:0.12.0 - http://thrift.apache.org/)
(Apache 2.0) Apache Lucene (https://lucene.apache.org/)
(Apache 2.0) Apache Zookeeper (org.apache.zookeeper:zookeeper:jar:3.4.5 - http://zookeeper.apache.org/)
(Apache 2.0) Chill (com.twitter:chill:0.8.0 - https://github.com/twitter/chill/)
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AngularObjectId.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AngularObjectId.java
index 24e9fd9..7aa2081 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AngularObjectId.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AngularObjectId.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId, AngularObjectId._Fields>, java.io.Serializable, Cloneable, Comparable<AngularObjectId> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("AngularObjectId");
@@ -59,15 +32,12 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
private static final org.apache.thrift.protocol.TField PARAGRAPH_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("paragraphId", org.apache.thrift.protocol.TType.STRING, (short)2);
private static final org.apache.thrift.protocol.TField NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("name", org.apache.thrift.protocol.TType.STRING, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new AngularObjectIdStandardSchemeFactory());
- schemes.put(TupleScheme.class, new AngularObjectIdTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new AngularObjectIdStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new AngularObjectIdTupleSchemeFactory();
- public String noteId; // required
- public String paragraphId; // required
- public String name; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String name; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -75,10 +45,10 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
PARAGRAPH_ID((short)2, "paragraphId"),
NAME((short)3, "name");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -86,6 +56,7 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // NOTE_ID
@@ -105,21 +76,22 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -128,22 +100,22 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NOTE_ID, new org.apache.thrift.meta_data.FieldMetaData("noteId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PARAGRAPH_ID, new org.apache.thrift.meta_data.FieldMetaData("paragraphId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(AngularObjectId.class, metaDataMap);
}
@@ -151,9 +123,9 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
}
public AngularObjectId(
- String noteId,
- String paragraphId,
- String name)
+ java.lang.String noteId,
+ java.lang.String paragraphId,
+ java.lang.String name)
{
this();
this.noteId = noteId;
@@ -187,11 +159,12 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
this.name = null;
}
- public String getNoteId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteId() {
return this.noteId;
}
- public AngularObjectId setNoteId(String noteId) {
+ public AngularObjectId setNoteId(@org.apache.thrift.annotation.Nullable java.lang.String noteId) {
this.noteId = noteId;
return this;
}
@@ -211,11 +184,12 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
}
}
- public String getParagraphId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphId() {
return this.paragraphId;
}
- public AngularObjectId setParagraphId(String paragraphId) {
+ public AngularObjectId setParagraphId(@org.apache.thrift.annotation.Nullable java.lang.String paragraphId) {
this.paragraphId = paragraphId;
return this;
}
@@ -235,11 +209,12 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
}
}
- public String getName() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getName() {
return this.name;
}
- public AngularObjectId setName(String name) {
+ public AngularObjectId setName(@org.apache.thrift.annotation.Nullable java.lang.String name) {
this.name = name;
return this;
}
@@ -259,13 +234,13 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case NOTE_ID:
if (value == null) {
unsetNoteId();
} else {
- setNoteId((String)value);
+ setNoteId((java.lang.String)value);
}
break;
@@ -273,7 +248,7 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
if (value == null) {
unsetParagraphId();
} else {
- setParagraphId((String)value);
+ setParagraphId((java.lang.String)value);
}
break;
@@ -281,14 +256,15 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NOTE_ID:
return getNoteId();
@@ -300,13 +276,13 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
return getName();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -317,11 +293,11 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
case NAME:
return isSetName();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof AngularObjectId)
@@ -332,6 +308,8 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
public boolean equals(AngularObjectId that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_noteId = true && this.isSetNoteId();
boolean that_present_noteId = true && that.isSetNoteId();
@@ -365,24 +343,21 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_noteId = true && (isSetNoteId());
- list.add(present_noteId);
- if (present_noteId)
- list.add(noteId);
+ hashCode = hashCode * 8191 + ((isSetNoteId()) ? 131071 : 524287);
+ if (isSetNoteId())
+ hashCode = hashCode * 8191 + noteId.hashCode();
- boolean present_paragraphId = true && (isSetParagraphId());
- list.add(present_paragraphId);
- if (present_paragraphId)
- list.add(paragraphId);
+ hashCode = hashCode * 8191 + ((isSetParagraphId()) ? 131071 : 524287);
+ if (isSetParagraphId())
+ hashCode = hashCode * 8191 + paragraphId.hashCode();
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -393,7 +368,7 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -403,7 +378,7 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -413,7 +388,7 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -426,21 +401,22 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("AngularObjectId(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("AngularObjectId(");
boolean first = true;
sb.append("noteId:");
@@ -483,7 +459,7 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -491,13 +467,13 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
}
}
- private static class AngularObjectIdStandardSchemeFactory implements SchemeFactory {
+ private static class AngularObjectIdStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AngularObjectIdStandardScheme getScheme() {
return new AngularObjectIdStandardScheme();
}
}
- private static class AngularObjectIdStandardScheme extends StandardScheme<AngularObjectId> {
+ private static class AngularObjectIdStandardScheme extends org.apache.thrift.scheme.StandardScheme<AngularObjectId> {
public void read(org.apache.thrift.protocol.TProtocol iprot, AngularObjectId struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -569,18 +545,18 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
}
- private static class AngularObjectIdTupleSchemeFactory implements SchemeFactory {
+ private static class AngularObjectIdTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AngularObjectIdTupleScheme getScheme() {
return new AngularObjectIdTupleScheme();
}
}
- private static class AngularObjectIdTupleScheme extends TupleScheme<AngularObjectId> {
+ private static class AngularObjectIdTupleScheme extends org.apache.thrift.scheme.TupleScheme<AngularObjectId> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, AngularObjectId struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetNoteId()) {
optionals.set(0);
}
@@ -604,8 +580,8 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, AngularObjectId struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(3);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.noteId = iprot.readString();
struct.setNoteIdIsSet(true);
@@ -621,5 +597,8 @@ public class AngularObjectId implements org.apache.thrift.TBase<AngularObjectId,
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppOutputAppendEvent.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppOutputAppendEvent.java
index bac58e9..38cff03 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppOutputAppendEvent.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppOutputAppendEvent.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAppendEvent, AppOutputAppendEvent._Fields>, java.io.Serializable, Cloneable, Comparable<AppOutputAppendEvent> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("AppOutputAppendEvent");
@@ -61,17 +34,14 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
private static final org.apache.thrift.protocol.TField INDEX_FIELD_DESC = new org.apache.thrift.protocol.TField("index", org.apache.thrift.protocol.TType.I32, (short)4);
private static final org.apache.thrift.protocol.TField DATA_FIELD_DESC = new org.apache.thrift.protocol.TField("data", org.apache.thrift.protocol.TType.STRING, (short)5);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new AppOutputAppendEventStandardSchemeFactory());
- schemes.put(TupleScheme.class, new AppOutputAppendEventTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new AppOutputAppendEventStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new AppOutputAppendEventTupleSchemeFactory();
- public String noteId; // required
- public String paragraphId; // required
- public String appId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String appId; // required
public int index; // required
- public String data; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String data; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -81,10 +51,10 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
INDEX((short)4, "index"),
DATA((short)5, "data");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -92,6 +62,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // NOTE_ID
@@ -115,21 +86,22 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -138,7 +110,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -146,9 +118,9 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
// isset id assignments
private static final int __INDEX_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NOTE_ID, new org.apache.thrift.meta_data.FieldMetaData("noteId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PARAGRAPH_ID, new org.apache.thrift.meta_data.FieldMetaData("paragraphId", org.apache.thrift.TFieldRequirementType.DEFAULT,
@@ -159,7 +131,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
tmpMap.put(_Fields.DATA, new org.apache.thrift.meta_data.FieldMetaData("data", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(AppOutputAppendEvent.class, metaDataMap);
}
@@ -167,11 +139,11 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
}
public AppOutputAppendEvent(
- String noteId,
- String paragraphId,
- String appId,
+ java.lang.String noteId,
+ java.lang.String paragraphId,
+ java.lang.String appId,
int index,
- String data)
+ java.lang.String data)
{
this();
this.noteId = noteId;
@@ -216,11 +188,12 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
this.data = null;
}
- public String getNoteId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteId() {
return this.noteId;
}
- public AppOutputAppendEvent setNoteId(String noteId) {
+ public AppOutputAppendEvent setNoteId(@org.apache.thrift.annotation.Nullable java.lang.String noteId) {
this.noteId = noteId;
return this;
}
@@ -240,11 +213,12 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
}
}
- public String getParagraphId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphId() {
return this.paragraphId;
}
- public AppOutputAppendEvent setParagraphId(String paragraphId) {
+ public AppOutputAppendEvent setParagraphId(@org.apache.thrift.annotation.Nullable java.lang.String paragraphId) {
this.paragraphId = paragraphId;
return this;
}
@@ -264,11 +238,12 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
}
}
- public String getAppId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getAppId() {
return this.appId;
}
- public AppOutputAppendEvent setAppId(String appId) {
+ public AppOutputAppendEvent setAppId(@org.apache.thrift.annotation.Nullable java.lang.String appId) {
this.appId = appId;
return this;
}
@@ -299,23 +274,24 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
}
public void unsetIndex() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __INDEX_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __INDEX_ISSET_ID);
}
/** Returns true if field index is set (has been assigned a value) and false otherwise */
public boolean isSetIndex() {
- return EncodingUtils.testBit(__isset_bitfield, __INDEX_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __INDEX_ISSET_ID);
}
public void setIndexIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __INDEX_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __INDEX_ISSET_ID, value);
}
- public String getData() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getData() {
return this.data;
}
- public AppOutputAppendEvent setData(String data) {
+ public AppOutputAppendEvent setData(@org.apache.thrift.annotation.Nullable java.lang.String data) {
this.data = data;
return this;
}
@@ -335,13 +311,13 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case NOTE_ID:
if (value == null) {
unsetNoteId();
} else {
- setNoteId((String)value);
+ setNoteId((java.lang.String)value);
}
break;
@@ -349,7 +325,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
if (value == null) {
unsetParagraphId();
} else {
- setParagraphId((String)value);
+ setParagraphId((java.lang.String)value);
}
break;
@@ -357,7 +333,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
if (value == null) {
unsetAppId();
} else {
- setAppId((String)value);
+ setAppId((java.lang.String)value);
}
break;
@@ -365,7 +341,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
if (value == null) {
unsetIndex();
} else {
- setIndex((Integer)value);
+ setIndex((java.lang.Integer)value);
}
break;
@@ -373,14 +349,15 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
if (value == null) {
unsetData();
} else {
- setData((String)value);
+ setData((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NOTE_ID:
return getNoteId();
@@ -392,19 +369,19 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
return getAppId();
case INDEX:
- return Integer.valueOf(getIndex());
+ return getIndex();
case DATA:
return getData();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -419,11 +396,11 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
case DATA:
return isSetData();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof AppOutputAppendEvent)
@@ -434,6 +411,8 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
public boolean equals(AppOutputAppendEvent that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_noteId = true && this.isSetNoteId();
boolean that_present_noteId = true && that.isSetNoteId();
@@ -485,34 +464,27 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_noteId = true && (isSetNoteId());
- list.add(present_noteId);
- if (present_noteId)
- list.add(noteId);
+ hashCode = hashCode * 8191 + ((isSetNoteId()) ? 131071 : 524287);
+ if (isSetNoteId())
+ hashCode = hashCode * 8191 + noteId.hashCode();
- boolean present_paragraphId = true && (isSetParagraphId());
- list.add(present_paragraphId);
- if (present_paragraphId)
- list.add(paragraphId);
+ hashCode = hashCode * 8191 + ((isSetParagraphId()) ? 131071 : 524287);
+ if (isSetParagraphId())
+ hashCode = hashCode * 8191 + paragraphId.hashCode();
- boolean present_appId = true && (isSetAppId());
- list.add(present_appId);
- if (present_appId)
- list.add(appId);
+ hashCode = hashCode * 8191 + ((isSetAppId()) ? 131071 : 524287);
+ if (isSetAppId())
+ hashCode = hashCode * 8191 + appId.hashCode();
- boolean present_index = true;
- list.add(present_index);
- if (present_index)
- list.add(index);
+ hashCode = hashCode * 8191 + index;
- boolean present_data = true && (isSetData());
- list.add(present_data);
- if (present_data)
- list.add(data);
+ hashCode = hashCode * 8191 + ((isSetData()) ? 131071 : 524287);
+ if (isSetData())
+ hashCode = hashCode * 8191 + data.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -523,7 +495,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -533,7 +505,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -543,7 +515,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAppId()).compareTo(other.isSetAppId());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppId()).compareTo(other.isSetAppId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -553,7 +525,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIndex()).compareTo(other.isSetIndex());
+ lastComparison = java.lang.Boolean.valueOf(isSetIndex()).compareTo(other.isSetIndex());
if (lastComparison != 0) {
return lastComparison;
}
@@ -563,7 +535,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetData()).compareTo(other.isSetData());
+ lastComparison = java.lang.Boolean.valueOf(isSetData()).compareTo(other.isSetData());
if (lastComparison != 0) {
return lastComparison;
}
@@ -576,21 +548,22 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("AppOutputAppendEvent(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("AppOutputAppendEvent(");
boolean first = true;
sb.append("noteId:");
@@ -645,7 +618,7 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
__isset_bitfield = 0;
@@ -655,13 +628,13 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
}
}
- private static class AppOutputAppendEventStandardSchemeFactory implements SchemeFactory {
+ private static class AppOutputAppendEventStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AppOutputAppendEventStandardScheme getScheme() {
return new AppOutputAppendEventStandardScheme();
}
}
- private static class AppOutputAppendEventStandardScheme extends StandardScheme<AppOutputAppendEvent> {
+ private static class AppOutputAppendEventStandardScheme extends org.apache.thrift.scheme.StandardScheme<AppOutputAppendEvent> {
public void read(org.apache.thrift.protocol.TProtocol iprot, AppOutputAppendEvent struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -757,18 +730,18 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
}
- private static class AppOutputAppendEventTupleSchemeFactory implements SchemeFactory {
+ private static class AppOutputAppendEventTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AppOutputAppendEventTupleScheme getScheme() {
return new AppOutputAppendEventTupleScheme();
}
}
- private static class AppOutputAppendEventTupleScheme extends TupleScheme<AppOutputAppendEvent> {
+ private static class AppOutputAppendEventTupleScheme extends org.apache.thrift.scheme.TupleScheme<AppOutputAppendEvent> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, AppOutputAppendEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetNoteId()) {
optionals.set(0);
}
@@ -804,8 +777,8 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, AppOutputAppendEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(5);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(5);
if (incoming.get(0)) {
struct.noteId = iprot.readString();
struct.setNoteIdIsSet(true);
@@ -829,5 +802,8 @@ public class AppOutputAppendEvent implements org.apache.thrift.TBase<AppOutputAp
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppOutputUpdateEvent.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppOutputUpdateEvent.java
index 03ff738..f14b701 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppOutputUpdateEvent.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppOutputUpdateEvent.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUpdateEvent, AppOutputUpdateEvent._Fields>, java.io.Serializable, Cloneable, Comparable<AppOutputUpdateEvent> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("AppOutputUpdateEvent");
@@ -62,18 +35,15 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.STRING, (short)5);
private static final org.apache.thrift.protocol.TField DATA_FIELD_DESC = new org.apache.thrift.protocol.TField("data", org.apache.thrift.protocol.TType.STRING, (short)6);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new AppOutputUpdateEventStandardSchemeFactory());
- schemes.put(TupleScheme.class, new AppOutputUpdateEventTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new AppOutputUpdateEventStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new AppOutputUpdateEventTupleSchemeFactory();
- public String noteId; // required
- public String paragraphId; // required
- public String appId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String appId; // required
public int index; // required
- public String type; // required
- public String data; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String type; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String data; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -84,10 +54,10 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
TYPE((short)5, "type"),
DATA((short)6, "data");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -95,6 +65,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // NOTE_ID
@@ -120,21 +91,22 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -143,7 +115,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -151,9 +123,9 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
// isset id assignments
private static final int __INDEX_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NOTE_ID, new org.apache.thrift.meta_data.FieldMetaData("noteId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PARAGRAPH_ID, new org.apache.thrift.meta_data.FieldMetaData("paragraphId", org.apache.thrift.TFieldRequirementType.DEFAULT,
@@ -166,7 +138,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.DATA, new org.apache.thrift.meta_data.FieldMetaData("data", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(AppOutputUpdateEvent.class, metaDataMap);
}
@@ -174,12 +146,12 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
}
public AppOutputUpdateEvent(
- String noteId,
- String paragraphId,
- String appId,
+ java.lang.String noteId,
+ java.lang.String paragraphId,
+ java.lang.String appId,
int index,
- String type,
- String data)
+ java.lang.String type,
+ java.lang.String data)
{
this();
this.noteId = noteId;
@@ -229,11 +201,12 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
this.data = null;
}
- public String getNoteId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteId() {
return this.noteId;
}
- public AppOutputUpdateEvent setNoteId(String noteId) {
+ public AppOutputUpdateEvent setNoteId(@org.apache.thrift.annotation.Nullable java.lang.String noteId) {
this.noteId = noteId;
return this;
}
@@ -253,11 +226,12 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
}
}
- public String getParagraphId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphId() {
return this.paragraphId;
}
- public AppOutputUpdateEvent setParagraphId(String paragraphId) {
+ public AppOutputUpdateEvent setParagraphId(@org.apache.thrift.annotation.Nullable java.lang.String paragraphId) {
this.paragraphId = paragraphId;
return this;
}
@@ -277,11 +251,12 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
}
}
- public String getAppId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getAppId() {
return this.appId;
}
- public AppOutputUpdateEvent setAppId(String appId) {
+ public AppOutputUpdateEvent setAppId(@org.apache.thrift.annotation.Nullable java.lang.String appId) {
this.appId = appId;
return this;
}
@@ -312,23 +287,24 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
}
public void unsetIndex() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __INDEX_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __INDEX_ISSET_ID);
}
/** Returns true if field index is set (has been assigned a value) and false otherwise */
public boolean isSetIndex() {
- return EncodingUtils.testBit(__isset_bitfield, __INDEX_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __INDEX_ISSET_ID);
}
public void setIndexIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __INDEX_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __INDEX_ISSET_ID, value);
}
- public String getType() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getType() {
return this.type;
}
- public AppOutputUpdateEvent setType(String type) {
+ public AppOutputUpdateEvent setType(@org.apache.thrift.annotation.Nullable java.lang.String type) {
this.type = type;
return this;
}
@@ -348,11 +324,12 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
}
}
- public String getData() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getData() {
return this.data;
}
- public AppOutputUpdateEvent setData(String data) {
+ public AppOutputUpdateEvent setData(@org.apache.thrift.annotation.Nullable java.lang.String data) {
this.data = data;
return this;
}
@@ -372,13 +349,13 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case NOTE_ID:
if (value == null) {
unsetNoteId();
} else {
- setNoteId((String)value);
+ setNoteId((java.lang.String)value);
}
break;
@@ -386,7 +363,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
if (value == null) {
unsetParagraphId();
} else {
- setParagraphId((String)value);
+ setParagraphId((java.lang.String)value);
}
break;
@@ -394,7 +371,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
if (value == null) {
unsetAppId();
} else {
- setAppId((String)value);
+ setAppId((java.lang.String)value);
}
break;
@@ -402,7 +379,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
if (value == null) {
unsetIndex();
} else {
- setIndex((Integer)value);
+ setIndex((java.lang.Integer)value);
}
break;
@@ -410,7 +387,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
if (value == null) {
unsetType();
} else {
- setType((String)value);
+ setType((java.lang.String)value);
}
break;
@@ -418,14 +395,15 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
if (value == null) {
unsetData();
} else {
- setData((String)value);
+ setData((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NOTE_ID:
return getNoteId();
@@ -437,7 +415,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
return getAppId();
case INDEX:
- return Integer.valueOf(getIndex());
+ return getIndex();
case TYPE:
return getType();
@@ -446,13 +424,13 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
return getData();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -469,11 +447,11 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
case DATA:
return isSetData();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof AppOutputUpdateEvent)
@@ -484,6 +462,8 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
public boolean equals(AppOutputUpdateEvent that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_noteId = true && this.isSetNoteId();
boolean that_present_noteId = true && that.isSetNoteId();
@@ -544,39 +524,31 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_noteId = true && (isSetNoteId());
- list.add(present_noteId);
- if (present_noteId)
- list.add(noteId);
+ hashCode = hashCode * 8191 + ((isSetNoteId()) ? 131071 : 524287);
+ if (isSetNoteId())
+ hashCode = hashCode * 8191 + noteId.hashCode();
- boolean present_paragraphId = true && (isSetParagraphId());
- list.add(present_paragraphId);
- if (present_paragraphId)
- list.add(paragraphId);
+ hashCode = hashCode * 8191 + ((isSetParagraphId()) ? 131071 : 524287);
+ if (isSetParagraphId())
+ hashCode = hashCode * 8191 + paragraphId.hashCode();
- boolean present_appId = true && (isSetAppId());
- list.add(present_appId);
- if (present_appId)
- list.add(appId);
+ hashCode = hashCode * 8191 + ((isSetAppId()) ? 131071 : 524287);
+ if (isSetAppId())
+ hashCode = hashCode * 8191 + appId.hashCode();
- boolean present_index = true;
- list.add(present_index);
- if (present_index)
- list.add(index);
+ hashCode = hashCode * 8191 + index;
- boolean present_type = true && (isSetType());
- list.add(present_type);
- if (present_type)
- list.add(type);
+ hashCode = hashCode * 8191 + ((isSetType()) ? 131071 : 524287);
+ if (isSetType())
+ hashCode = hashCode * 8191 + type.hashCode();
- boolean present_data = true && (isSetData());
- list.add(present_data);
- if (present_data)
- list.add(data);
+ hashCode = hashCode * 8191 + ((isSetData()) ? 131071 : 524287);
+ if (isSetData())
+ hashCode = hashCode * 8191 + data.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -587,7 +559,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -597,7 +569,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -607,7 +579,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAppId()).compareTo(other.isSetAppId());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppId()).compareTo(other.isSetAppId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -617,7 +589,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIndex()).compareTo(other.isSetIndex());
+ lastComparison = java.lang.Boolean.valueOf(isSetIndex()).compareTo(other.isSetIndex());
if (lastComparison != 0) {
return lastComparison;
}
@@ -627,7 +599,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetType()).compareTo(other.isSetType());
+ lastComparison = java.lang.Boolean.valueOf(isSetType()).compareTo(other.isSetType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -637,7 +609,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetData()).compareTo(other.isSetData());
+ lastComparison = java.lang.Boolean.valueOf(isSetData()).compareTo(other.isSetData());
if (lastComparison != 0) {
return lastComparison;
}
@@ -650,21 +622,22 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("AppOutputUpdateEvent(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("AppOutputUpdateEvent(");
boolean first = true;
sb.append("noteId:");
@@ -727,7 +700,7 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
__isset_bitfield = 0;
@@ -737,13 +710,13 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
}
}
- private static class AppOutputUpdateEventStandardSchemeFactory implements SchemeFactory {
+ private static class AppOutputUpdateEventStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AppOutputUpdateEventStandardScheme getScheme() {
return new AppOutputUpdateEventStandardScheme();
}
}
- private static class AppOutputUpdateEventStandardScheme extends StandardScheme<AppOutputUpdateEvent> {
+ private static class AppOutputUpdateEventStandardScheme extends org.apache.thrift.scheme.StandardScheme<AppOutputUpdateEvent> {
public void read(org.apache.thrift.protocol.TProtocol iprot, AppOutputUpdateEvent struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -852,18 +825,18 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
}
- private static class AppOutputUpdateEventTupleSchemeFactory implements SchemeFactory {
+ private static class AppOutputUpdateEventTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AppOutputUpdateEventTupleScheme getScheme() {
return new AppOutputUpdateEventTupleScheme();
}
}
- private static class AppOutputUpdateEventTupleScheme extends TupleScheme<AppOutputUpdateEvent> {
+ private static class AppOutputUpdateEventTupleScheme extends org.apache.thrift.scheme.TupleScheme<AppOutputUpdateEvent> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, AppOutputUpdateEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetNoteId()) {
optionals.set(0);
}
@@ -905,8 +878,8 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, AppOutputUpdateEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(6);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(6);
if (incoming.get(0)) {
struct.noteId = iprot.readString();
struct.setNoteIdIsSet(true);
@@ -934,5 +907,8 @@ public class AppOutputUpdateEvent implements org.apache.thrift.TBase<AppOutputUp
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppStatusUpdateEvent.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppStatusUpdateEvent.java
index ad09d5d..90e6b0d 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppStatusUpdateEvent.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/AppStatusUpdateEvent.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUpdateEvent, AppStatusUpdateEvent._Fields>, java.io.Serializable, Cloneable, Comparable<AppStatusUpdateEvent> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("AppStatusUpdateEvent");
@@ -60,16 +33,13 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
private static final org.apache.thrift.protocol.TField APP_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("appId", org.apache.thrift.protocol.TType.STRING, (short)3);
private static final org.apache.thrift.protocol.TField STATUS_FIELD_DESC = new org.apache.thrift.protocol.TField("status", org.apache.thrift.protocol.TType.STRING, (short)4);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new AppStatusUpdateEventStandardSchemeFactory());
- schemes.put(TupleScheme.class, new AppStatusUpdateEventTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new AppStatusUpdateEventStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new AppStatusUpdateEventTupleSchemeFactory();
- public String noteId; // required
- public String paragraphId; // required
- public String appId; // required
- public String status; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String appId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String status; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -78,10 +48,10 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
APP_ID((short)3, "appId"),
STATUS((short)4, "status");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -89,6 +59,7 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // NOTE_ID
@@ -110,21 +81,22 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -133,15 +105,15 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NOTE_ID, new org.apache.thrift.meta_data.FieldMetaData("noteId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PARAGRAPH_ID, new org.apache.thrift.meta_data.FieldMetaData("paragraphId", org.apache.thrift.TFieldRequirementType.DEFAULT,
@@ -150,7 +122,7 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.STATUS, new org.apache.thrift.meta_data.FieldMetaData("status", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(AppStatusUpdateEvent.class, metaDataMap);
}
@@ -158,10 +130,10 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
}
public AppStatusUpdateEvent(
- String noteId,
- String paragraphId,
- String appId,
- String status)
+ java.lang.String noteId,
+ java.lang.String paragraphId,
+ java.lang.String appId,
+ java.lang.String status)
{
this();
this.noteId = noteId;
@@ -200,11 +172,12 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
this.status = null;
}
- public String getNoteId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteId() {
return this.noteId;
}
- public AppStatusUpdateEvent setNoteId(String noteId) {
+ public AppStatusUpdateEvent setNoteId(@org.apache.thrift.annotation.Nullable java.lang.String noteId) {
this.noteId = noteId;
return this;
}
@@ -224,11 +197,12 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
}
}
- public String getParagraphId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphId() {
return this.paragraphId;
}
- public AppStatusUpdateEvent setParagraphId(String paragraphId) {
+ public AppStatusUpdateEvent setParagraphId(@org.apache.thrift.annotation.Nullable java.lang.String paragraphId) {
this.paragraphId = paragraphId;
return this;
}
@@ -248,11 +222,12 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
}
}
- public String getAppId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getAppId() {
return this.appId;
}
- public AppStatusUpdateEvent setAppId(String appId) {
+ public AppStatusUpdateEvent setAppId(@org.apache.thrift.annotation.Nullable java.lang.String appId) {
this.appId = appId;
return this;
}
@@ -272,11 +247,12 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
}
}
- public String getStatus() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getStatus() {
return this.status;
}
- public AppStatusUpdateEvent setStatus(String status) {
+ public AppStatusUpdateEvent setStatus(@org.apache.thrift.annotation.Nullable java.lang.String status) {
this.status = status;
return this;
}
@@ -296,13 +272,13 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case NOTE_ID:
if (value == null) {
unsetNoteId();
} else {
- setNoteId((String)value);
+ setNoteId((java.lang.String)value);
}
break;
@@ -310,7 +286,7 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
if (value == null) {
unsetParagraphId();
} else {
- setParagraphId((String)value);
+ setParagraphId((java.lang.String)value);
}
break;
@@ -318,7 +294,7 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
if (value == null) {
unsetAppId();
} else {
- setAppId((String)value);
+ setAppId((java.lang.String)value);
}
break;
@@ -326,14 +302,15 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
if (value == null) {
unsetStatus();
} else {
- setStatus((String)value);
+ setStatus((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NOTE_ID:
return getNoteId();
@@ -348,13 +325,13 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
return getStatus();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -367,11 +344,11 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
case STATUS:
return isSetStatus();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof AppStatusUpdateEvent)
@@ -382,6 +359,8 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
public boolean equals(AppStatusUpdateEvent that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_noteId = true && this.isSetNoteId();
boolean that_present_noteId = true && that.isSetNoteId();
@@ -424,29 +403,25 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_noteId = true && (isSetNoteId());
- list.add(present_noteId);
- if (present_noteId)
- list.add(noteId);
+ hashCode = hashCode * 8191 + ((isSetNoteId()) ? 131071 : 524287);
+ if (isSetNoteId())
+ hashCode = hashCode * 8191 + noteId.hashCode();
- boolean present_paragraphId = true && (isSetParagraphId());
- list.add(present_paragraphId);
- if (present_paragraphId)
- list.add(paragraphId);
+ hashCode = hashCode * 8191 + ((isSetParagraphId()) ? 131071 : 524287);
+ if (isSetParagraphId())
+ hashCode = hashCode * 8191 + paragraphId.hashCode();
- boolean present_appId = true && (isSetAppId());
- list.add(present_appId);
- if (present_appId)
- list.add(appId);
+ hashCode = hashCode * 8191 + ((isSetAppId()) ? 131071 : 524287);
+ if (isSetAppId())
+ hashCode = hashCode * 8191 + appId.hashCode();
- boolean present_status = true && (isSetStatus());
- list.add(present_status);
- if (present_status)
- list.add(status);
+ hashCode = hashCode * 8191 + ((isSetStatus()) ? 131071 : 524287);
+ if (isSetStatus())
+ hashCode = hashCode * 8191 + status.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -457,7 +432,7 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -467,7 +442,7 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -477,7 +452,7 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAppId()).compareTo(other.isSetAppId());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppId()).compareTo(other.isSetAppId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -487,7 +462,7 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus());
+ lastComparison = java.lang.Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus());
if (lastComparison != 0) {
return lastComparison;
}
@@ -500,21 +475,22 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("AppStatusUpdateEvent(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("AppStatusUpdateEvent(");
boolean first = true;
sb.append("noteId:");
@@ -565,7 +541,7 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -573,13 +549,13 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
}
}
- private static class AppStatusUpdateEventStandardSchemeFactory implements SchemeFactory {
+ private static class AppStatusUpdateEventStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AppStatusUpdateEventStandardScheme getScheme() {
return new AppStatusUpdateEventStandardScheme();
}
}
- private static class AppStatusUpdateEventStandardScheme extends StandardScheme<AppStatusUpdateEvent> {
+ private static class AppStatusUpdateEventStandardScheme extends org.apache.thrift.scheme.StandardScheme<AppStatusUpdateEvent> {
public void read(org.apache.thrift.protocol.TProtocol iprot, AppStatusUpdateEvent struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -664,18 +640,18 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
}
- private static class AppStatusUpdateEventTupleSchemeFactory implements SchemeFactory {
+ private static class AppStatusUpdateEventTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AppStatusUpdateEventTupleScheme getScheme() {
return new AppStatusUpdateEventTupleScheme();
}
}
- private static class AppStatusUpdateEventTupleScheme extends TupleScheme<AppStatusUpdateEvent> {
+ private static class AppStatusUpdateEventTupleScheme extends org.apache.thrift.scheme.TupleScheme<AppStatusUpdateEvent> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, AppStatusUpdateEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetNoteId()) {
optionals.set(0);
}
@@ -705,8 +681,8 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, AppStatusUpdateEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(4);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(4);
if (incoming.get(0)) {
struct.noteId = iprot.readString();
struct.setNoteIdIsSet(true);
@@ -726,5 +702,8 @@ public class AppStatusUpdateEvent implements org.apache.thrift.TBase<AppStatusUp
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ClusterIntpProcParameters.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ClusterIntpProcParameters.java
index 546d235..4cd82f0 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ClusterIntpProcParameters.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ClusterIntpProcParameters.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2018-9-28")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class ClusterIntpProcParameters implements org.apache.thrift.TBase<ClusterIntpProcParameters, ClusterIntpProcParameters._Fields>, java.io.Serializable, Cloneable, Comparable<ClusterIntpProcParameters> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ClusterIntpProcParameters");
@@ -62,18 +35,15 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
private static final org.apache.thrift.protocol.TField REPL_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("replName", org.apache.thrift.protocol.TType.STRING, (short)5);
private static final org.apache.thrift.protocol.TField DEFAULT_INTERPRETER_SETTING_FIELD_DESC = new org.apache.thrift.protocol.TField("defaultInterpreterSetting", org.apache.thrift.protocol.TType.STRING, (short)6);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ClusterIntpProcParametersStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ClusterIntpProcParametersTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ClusterIntpProcParametersStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ClusterIntpProcParametersTupleSchemeFactory();
- public String host; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String host; // required
public int port; // required
- public String userName; // required
- public String noteId; // required
- public String replName; // required
- public String defaultInterpreterSetting; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String userName; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String replName; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String defaultInterpreterSetting; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -84,10 +54,10 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
REPL_NAME((short)5, "replName"),
DEFAULT_INTERPRETER_SETTING((short)6, "defaultInterpreterSetting");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -95,6 +65,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // HOST
@@ -120,21 +91,22 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -143,7 +115,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -151,9 +123,9 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
// isset id assignments
private static final int __PORT_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.HOST, new org.apache.thrift.meta_data.FieldMetaData("host", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PORT, new org.apache.thrift.meta_data.FieldMetaData("port", org.apache.thrift.TFieldRequirementType.DEFAULT,
@@ -166,7 +138,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.DEFAULT_INTERPRETER_SETTING, new org.apache.thrift.meta_data.FieldMetaData("defaultInterpreterSetting", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ClusterIntpProcParameters.class, metaDataMap);
}
@@ -174,12 +146,12 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
}
public ClusterIntpProcParameters(
- String host,
+ java.lang.String host,
int port,
- String userName,
- String noteId,
- String replName,
- String defaultInterpreterSetting)
+ java.lang.String userName,
+ java.lang.String noteId,
+ java.lang.String replName,
+ java.lang.String defaultInterpreterSetting)
{
this();
this.host = host;
@@ -229,11 +201,12 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
this.defaultInterpreterSetting = null;
}
- public String getHost() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getHost() {
return this.host;
}
- public ClusterIntpProcParameters setHost(String host) {
+ public ClusterIntpProcParameters setHost(@org.apache.thrift.annotation.Nullable java.lang.String host) {
this.host = host;
return this;
}
@@ -264,23 +237,24 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
}
public void unsetPort() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PORT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __PORT_ISSET_ID);
}
/** Returns true if field port is set (has been assigned a value) and false otherwise */
public boolean isSetPort() {
- return EncodingUtils.testBit(__isset_bitfield, __PORT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PORT_ISSET_ID);
}
public void setPortIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PORT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PORT_ISSET_ID, value);
}
- public String getUserName() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getUserName() {
return this.userName;
}
- public ClusterIntpProcParameters setUserName(String userName) {
+ public ClusterIntpProcParameters setUserName(@org.apache.thrift.annotation.Nullable java.lang.String userName) {
this.userName = userName;
return this;
}
@@ -300,11 +274,12 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
}
}
- public String getNoteId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteId() {
return this.noteId;
}
- public ClusterIntpProcParameters setNoteId(String noteId) {
+ public ClusterIntpProcParameters setNoteId(@org.apache.thrift.annotation.Nullable java.lang.String noteId) {
this.noteId = noteId;
return this;
}
@@ -324,11 +299,12 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
}
}
- public String getReplName() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getReplName() {
return this.replName;
}
- public ClusterIntpProcParameters setReplName(String replName) {
+ public ClusterIntpProcParameters setReplName(@org.apache.thrift.annotation.Nullable java.lang.String replName) {
this.replName = replName;
return this;
}
@@ -348,11 +324,12 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
}
}
- public String getDefaultInterpreterSetting() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getDefaultInterpreterSetting() {
return this.defaultInterpreterSetting;
}
- public ClusterIntpProcParameters setDefaultInterpreterSetting(String defaultInterpreterSetting) {
+ public ClusterIntpProcParameters setDefaultInterpreterSetting(@org.apache.thrift.annotation.Nullable java.lang.String defaultInterpreterSetting) {
this.defaultInterpreterSetting = defaultInterpreterSetting;
return this;
}
@@ -372,13 +349,13 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case HOST:
if (value == null) {
unsetHost();
} else {
- setHost((String)value);
+ setHost((java.lang.String)value);
}
break;
@@ -386,7 +363,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
if (value == null) {
unsetPort();
} else {
- setPort((Integer)value);
+ setPort((java.lang.Integer)value);
}
break;
@@ -394,7 +371,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
if (value == null) {
unsetUserName();
} else {
- setUserName((String)value);
+ setUserName((java.lang.String)value);
}
break;
@@ -402,7 +379,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
if (value == null) {
unsetNoteId();
} else {
- setNoteId((String)value);
+ setNoteId((java.lang.String)value);
}
break;
@@ -410,7 +387,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
if (value == null) {
unsetReplName();
} else {
- setReplName((String)value);
+ setReplName((java.lang.String)value);
}
break;
@@ -418,20 +395,21 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
if (value == null) {
unsetDefaultInterpreterSetting();
} else {
- setDefaultInterpreterSetting((String)value);
+ setDefaultInterpreterSetting((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case HOST:
return getHost();
case PORT:
- return Integer.valueOf(getPort());
+ return getPort();
case USER_NAME:
return getUserName();
@@ -446,13 +424,13 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
return getDefaultInterpreterSetting();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -469,11 +447,11 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
case DEFAULT_INTERPRETER_SETTING:
return isSetDefaultInterpreterSetting();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ClusterIntpProcParameters)
@@ -484,6 +462,8 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
public boolean equals(ClusterIntpProcParameters that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_host = true && this.isSetHost();
boolean that_present_host = true && that.isSetHost();
@@ -544,39 +524,31 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_host = true && (isSetHost());
- list.add(present_host);
- if (present_host)
- list.add(host);
+ hashCode = hashCode * 8191 + ((isSetHost()) ? 131071 : 524287);
+ if (isSetHost())
+ hashCode = hashCode * 8191 + host.hashCode();
- boolean present_port = true;
- list.add(present_port);
- if (present_port)
- list.add(port);
+ hashCode = hashCode * 8191 + port;
- boolean present_userName = true && (isSetUserName());
- list.add(present_userName);
- if (present_userName)
- list.add(userName);
+ hashCode = hashCode * 8191 + ((isSetUserName()) ? 131071 : 524287);
+ if (isSetUserName())
+ hashCode = hashCode * 8191 + userName.hashCode();
- boolean present_noteId = true && (isSetNoteId());
- list.add(present_noteId);
- if (present_noteId)
- list.add(noteId);
+ hashCode = hashCode * 8191 + ((isSetNoteId()) ? 131071 : 524287);
+ if (isSetNoteId())
+ hashCode = hashCode * 8191 + noteId.hashCode();
- boolean present_replName = true && (isSetReplName());
- list.add(present_replName);
- if (present_replName)
- list.add(replName);
+ hashCode = hashCode * 8191 + ((isSetReplName()) ? 131071 : 524287);
+ if (isSetReplName())
+ hashCode = hashCode * 8191 + replName.hashCode();
- boolean present_defaultInterpreterSetting = true && (isSetDefaultInterpreterSetting());
- list.add(present_defaultInterpreterSetting);
- if (present_defaultInterpreterSetting)
- list.add(defaultInterpreterSetting);
+ hashCode = hashCode * 8191 + ((isSetDefaultInterpreterSetting()) ? 131071 : 524287);
+ if (isSetDefaultInterpreterSetting())
+ hashCode = hashCode * 8191 + defaultInterpreterSetting.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -587,7 +559,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetHost()).compareTo(other.isSetHost());
+ lastComparison = java.lang.Boolean.valueOf(isSetHost()).compareTo(other.isSetHost());
if (lastComparison != 0) {
return lastComparison;
}
@@ -597,7 +569,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPort()).compareTo(other.isSetPort());
+ lastComparison = java.lang.Boolean.valueOf(isSetPort()).compareTo(other.isSetPort());
if (lastComparison != 0) {
return lastComparison;
}
@@ -607,7 +579,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserName()).compareTo(other.isSetUserName());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserName()).compareTo(other.isSetUserName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -617,7 +589,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -627,7 +599,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReplName()).compareTo(other.isSetReplName());
+ lastComparison = java.lang.Boolean.valueOf(isSetReplName()).compareTo(other.isSetReplName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -637,7 +609,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultInterpreterSetting()).compareTo(other.isSetDefaultInterpreterSetting());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultInterpreterSetting()).compareTo(other.isSetDefaultInterpreterSetting());
if (lastComparison != 0) {
return lastComparison;
}
@@ -650,21 +622,22 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ClusterIntpProcParameters(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ClusterIntpProcParameters(");
boolean first = true;
sb.append("host:");
@@ -727,7 +700,7 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
__isset_bitfield = 0;
@@ -737,13 +710,13 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
}
}
- private static class ClusterIntpProcParametersStandardSchemeFactory implements SchemeFactory {
+ private static class ClusterIntpProcParametersStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ClusterIntpProcParametersStandardScheme getScheme() {
return new ClusterIntpProcParametersStandardScheme();
}
}
- private static class ClusterIntpProcParametersStandardScheme extends StandardScheme<ClusterIntpProcParameters> {
+ private static class ClusterIntpProcParametersStandardScheme extends org.apache.thrift.scheme.StandardScheme<ClusterIntpProcParameters> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ClusterIntpProcParameters struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -852,18 +825,18 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
}
- private static class ClusterIntpProcParametersTupleSchemeFactory implements SchemeFactory {
+ private static class ClusterIntpProcParametersTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ClusterIntpProcParametersTupleScheme getScheme() {
return new ClusterIntpProcParametersTupleScheme();
}
}
- private static class ClusterIntpProcParametersTupleScheme extends TupleScheme<ClusterIntpProcParameters> {
+ private static class ClusterIntpProcParametersTupleScheme extends org.apache.thrift.scheme.TupleScheme<ClusterIntpProcParameters> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ClusterIntpProcParameters struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetHost()) {
optionals.set(0);
}
@@ -905,8 +878,8 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ClusterIntpProcParameters struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(6);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(6);
if (incoming.get(0)) {
struct.host = iprot.readString();
struct.setHostIsSet(true);
@@ -934,5 +907,8 @@ public class ClusterIntpProcParameters implements org.apache.thrift.TBase<Cluste
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ClusterManagerService.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ClusterManagerService.java
index 1e508dd..5c46b0e 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ClusterManagerService.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ClusterManagerService.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2018-9-28")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class ClusterManagerService {
public interface Iface {
@@ -62,7 +35,7 @@ public class ClusterManagerService {
public interface AsyncIface {
- public void createClusterInterpreterProcess(ClusterIntpProcParameters intpProcParameters, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void createClusterInterpreterProcess(ClusterIntpProcParameters intpProcParameters, org.apache.thrift.async.AsyncMethodCallback<java.lang.Boolean> resultHandler) throws org.apache.thrift.TException;
}
@@ -127,16 +100,16 @@ public class ClusterManagerService {
super(protocolFactory, clientManager, transport);
}
- public void createClusterInterpreterProcess(ClusterIntpProcParameters intpProcParameters, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void createClusterInterpreterProcess(ClusterIntpProcParameters intpProcParameters, org.apache.thrift.async.AsyncMethodCallback<java.lang.Boolean> resultHandler) throws org.apache.thrift.TException {
checkReady();
createClusterInterpreterProcess_call method_call = new createClusterInterpreterProcess_call(intpProcParameters, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class createClusterInterpreterProcess_call extends org.apache.thrift.async.TAsyncMethodCall {
+ public static class createClusterInterpreterProcess_call extends org.apache.thrift.async.TAsyncMethodCall<java.lang.Boolean> {
private ClusterIntpProcParameters intpProcParameters;
- public createClusterInterpreterProcess_call(ClusterIntpProcParameters intpProcParameters, 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 {
+ public createClusterInterpreterProcess_call(ClusterIntpProcParameters intpProcParameters, org.apache.thrift.async.AsyncMethodCallback<java.lang.Boolean> 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.intpProcParameters = intpProcParameters;
}
@@ -149,9 +122,9 @@ public class ClusterManagerService {
prot.writeMessageEnd();
}
- public boolean getResult() throws org.apache.thrift.TException {
+ public java.lang.Boolean getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
@@ -162,16 +135,16 @@ public class ClusterManagerService {
}
public static class Processor<I extends Iface> extends org.apache.thrift.TBaseProcessor<I> implements org.apache.thrift.TProcessor {
- private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
+ private static final org.slf4j.Logger _LOGGER = org.slf4j.LoggerFactory.getLogger(Processor.class.getName());
public Processor(I iface) {
- super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
+ super(iface, getProcessMap(new java.util.HashMap<java.lang.String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
}
- protected Processor(I iface, Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
+ protected Processor(I iface, java.util.Map<java.lang.String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
super(iface, getProcessMap(processMap));
}
- private static <I extends Iface> Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> getProcessMap(Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
+ private static <I extends Iface> java.util.Map<java.lang.String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> getProcessMap(java.util.Map<java.lang.String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
processMap.put("createClusterInterpreterProcess", new createClusterInterpreterProcess());
return processMap;
}
@@ -189,6 +162,11 @@ public class ClusterManagerService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public createClusterInterpreterProcess_result getResult(I iface, createClusterInterpreterProcess_args args) throws org.apache.thrift.TException {
createClusterInterpreterProcess_result result = new createClusterInterpreterProcess_result();
result.success = iface.createClusterInterpreterProcess(args.intpProcParameters);
@@ -200,21 +178,21 @@ public class ClusterManagerService {
}
public static class AsyncProcessor<I extends AsyncIface> extends org.apache.thrift.TBaseAsyncProcessor<I> {
- private static final Logger LOGGER = LoggerFactory.getLogger(AsyncProcessor.class.getName());
+ private static final org.slf4j.Logger _LOGGER = org.slf4j.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, ?>>()));
+ super(iface, getProcessMap(new java.util.HashMap<java.lang.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) {
+ protected AsyncProcessor(I iface, java.util.Map<java.lang.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) {
+ private static <I extends AsyncIface> java.util.Map<java.lang.String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase,?>> getProcessMap(java.util.Map<java.lang.String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) {
processMap.put("createClusterInterpreterProcess", new createClusterInterpreterProcess());
return processMap;
}
- public static class createClusterInterpreterProcess<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, createClusterInterpreterProcess_args, Boolean> {
+ public static class createClusterInterpreterProcess<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, createClusterInterpreterProcess_args, java.lang.Boolean> {
public createClusterInterpreterProcess() {
super("createClusterInterpreterProcess");
}
@@ -223,36 +201,46 @@ public class ClusterManagerService {
return new createClusterInterpreterProcess_args();
}
- public AsyncMethodCallback<Boolean> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<java.lang.Boolean> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Boolean>() {
- public void onComplete(Boolean o) {
+ return new org.apache.thrift.async.AsyncMethodCallback<java.lang.Boolean>() {
+ public void onComplete(java.lang.Boolean o) {
createClusterInterpreterProcess_result result = new createClusterInterpreterProcess_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
createClusterInterpreterProcess_result result = new createClusterInterpreterProcess_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
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());
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -261,7 +249,7 @@ public class ClusterManagerService {
return false;
}
- public void start(I iface, createClusterInterpreterProcess_args args, org.apache.thrift.async.AsyncMethodCallback<Boolean> resultHandler) throws TException {
+ public void start(I iface, createClusterInterpreterProcess_args args, org.apache.thrift.async.AsyncMethodCallback<java.lang.Boolean> resultHandler) throws org.apache.thrift.TException {
iface.createClusterInterpreterProcess(args.intpProcParameters,resultHandler);
}
}
@@ -273,22 +261,19 @@ public class ClusterManagerService {
private static final org.apache.thrift.protocol.TField INTP_PROC_PARAMETERS_FIELD_DESC = new org.apache.thrift.protocol.TField("intpProcParameters", org.apache.thrift.protocol.TType.STRUCT, (short)1);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new createClusterInterpreterProcess_argsStandardSchemeFactory());
- schemes.put(TupleScheme.class, new createClusterInterpreterProcess_argsTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new createClusterInterpreterProcess_argsStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new createClusterInterpreterProcess_argsTupleSchemeFactory();
- public ClusterIntpProcParameters intpProcParameters; // required
+ public @org.apache.thrift.annotation.Nullable ClusterIntpProcParameters intpProcParameters; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
INTP_PROC_PARAMETERS((short)1, "intpProcParameters");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -296,6 +281,7 @@ public class ClusterManagerService {
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // INTP_PROC_PARAMETERS
@@ -311,21 +297,22 @@ public class ClusterManagerService {
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -334,18 +321,18 @@ public class ClusterManagerService {
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.INTP_PROC_PARAMETERS, new org.apache.thrift.meta_data.FieldMetaData("intpProcParameters", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ClusterIntpProcParameters.class)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createClusterInterpreterProcess_args.class, metaDataMap);
}
@@ -377,11 +364,12 @@ public class ClusterManagerService {
this.intpProcParameters = null;
}
+ @org.apache.thrift.annotation.Nullable
public ClusterIntpProcParameters getIntpProcParameters() {
return this.intpProcParameters;
}
- public createClusterInterpreterProcess_args setIntpProcParameters(ClusterIntpProcParameters intpProcParameters) {
+ public createClusterInterpreterProcess_args setIntpProcParameters(@org.apache.thrift.annotation.Nullable ClusterIntpProcParameters intpProcParameters) {
this.intpProcParameters = intpProcParameters;
return this;
}
@@ -401,7 +389,7 @@ public class ClusterManagerService {
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case INTP_PROC_PARAMETERS:
if (value == null) {
@@ -414,30 +402,31 @@ public class ClusterManagerService {
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case INTP_PROC_PARAMETERS:
return getIntpProcParameters();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case INTP_PROC_PARAMETERS:
return isSetIntpProcParameters();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof createClusterInterpreterProcess_args)
@@ -448,6 +437,8 @@ public class ClusterManagerService {
public boolean equals(createClusterInterpreterProcess_args that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_intpProcParameters = true && this.isSetIntpProcParameters();
boolean that_present_intpProcParameters = true && that.isSetIntpProcParameters();
@@ -463,14 +454,13 @@ public class ClusterManagerService {
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_intpProcParameters = true && (isSetIntpProcParameters());
- list.add(present_intpProcParameters);
- if (present_intpProcParameters)
- list.add(intpProcParameters);
+ hashCode = hashCode * 8191 + ((isSetIntpProcParameters()) ? 131071 : 524287);
+ if (isSetIntpProcParameters())
+ hashCode = hashCode * 8191 + intpProcParameters.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -481,7 +471,7 @@ public class ClusterManagerService {
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetIntpProcParameters()).compareTo(other.isSetIntpProcParameters());
+ lastComparison = java.lang.Boolean.valueOf(isSetIntpProcParameters()).compareTo(other.isSetIntpProcParameters());
if (lastComparison != 0) {
return lastComparison;
}
@@ -494,21 +484,22 @@ public class ClusterManagerService {
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("createClusterInterpreterProcess_args(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("createClusterInterpreterProcess_args(");
boolean first = true;
sb.append("intpProcParameters:");
@@ -538,7 +529,7 @@ public class ClusterManagerService {
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -546,13 +537,13 @@ public class ClusterManagerService {
}
}
- private static class createClusterInterpreterProcess_argsStandardSchemeFactory implements SchemeFactory {
+ private static class createClusterInterpreterProcess_argsStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public createClusterInterpreterProcess_argsStandardScheme getScheme() {
return new createClusterInterpreterProcess_argsStandardScheme();
}
}
- private static class createClusterInterpreterProcess_argsStandardScheme extends StandardScheme<createClusterInterpreterProcess_args> {
+ private static class createClusterInterpreterProcess_argsStandardScheme extends org.apache.thrift.scheme.StandardScheme<createClusterInterpreterProcess_args> {
public void read(org.apache.thrift.protocol.TProtocol iprot, createClusterInterpreterProcess_args struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -599,18 +590,18 @@ public class ClusterManagerService {
}
- private static class createClusterInterpreterProcess_argsTupleSchemeFactory implements SchemeFactory {
+ private static class createClusterInterpreterProcess_argsTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public createClusterInterpreterProcess_argsTupleScheme getScheme() {
return new createClusterInterpreterProcess_argsTupleScheme();
}
}
- private static class createClusterInterpreterProcess_argsTupleScheme extends TupleScheme<createClusterInterpreterProcess_args> {
+ private static class createClusterInterpreterProcess_argsTupleScheme extends org.apache.thrift.scheme.TupleScheme<createClusterInterpreterProcess_args> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, createClusterInterpreterProcess_args struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetIntpProcParameters()) {
optionals.set(0);
}
@@ -622,8 +613,8 @@ public class ClusterManagerService {
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, createClusterInterpreterProcess_args struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(1);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
struct.intpProcParameters = new ClusterIntpProcParameters();
struct.intpProcParameters.read(iprot);
@@ -632,6 +623,9 @@ public class ClusterManagerService {
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
public static class createClusterInterpreterProcess_result implements org.apache.thrift.TBase<createClusterInterpreterProcess_result, createClusterInterpreterProcess_result._Fields>, java.io.Serializable, Cloneable, Comparable<createClusterInterpreterProcess_result> {
@@ -639,11 +633,8 @@ public class ClusterManagerService {
private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)0);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new createClusterInterpreterProcess_resultStandardSchemeFactory());
- schemes.put(TupleScheme.class, new createClusterInterpreterProcess_resultTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new createClusterInterpreterProcess_resultStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new createClusterInterpreterProcess_resultTupleSchemeFactory();
public boolean success; // required
@@ -651,10 +642,10 @@ public class ClusterManagerService {
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
SUCCESS((short)0, "success");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -662,6 +653,7 @@ public class ClusterManagerService {
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 0: // SUCCESS
@@ -677,21 +669,22 @@ public class ClusterManagerService {
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -700,7 +693,7 @@ public class ClusterManagerService {
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -708,12 +701,12 @@ public class ClusterManagerService {
// isset id assignments
private static final int __SUCCESS_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createClusterInterpreterProcess_result.class, metaDataMap);
}
@@ -757,55 +750,56 @@ public class ClusterManagerService {
}
public void unsetSuccess() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SUCCESS_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __SUCCESS_ISSET_ID);
}
/** Returns true if field success is set (has been assigned a value) and false otherwise */
public boolean isSetSuccess() {
- return EncodingUtils.testBit(__isset_bitfield, __SUCCESS_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __SUCCESS_ISSET_ID);
}
public void setSuccessIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
unsetSuccess();
} else {
- setSuccess((Boolean)value);
+ setSuccess((java.lang.Boolean)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Boolean.valueOf(isSuccess());
+ return isSuccess();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case SUCCESS:
return isSetSuccess();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof createClusterInterpreterProcess_result)
@@ -816,6 +810,8 @@ public class ClusterManagerService {
public boolean equals(createClusterInterpreterProcess_result that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_success = true;
boolean that_present_success = true;
@@ -831,14 +827,11 @@ public class ClusterManagerService {
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_success = true;
- list.add(present_success);
- if (present_success)
- list.add(success);
+ hashCode = hashCode * 8191 + ((success) ? 131071 : 524287);
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -849,7 +842,7 @@ public class ClusterManagerService {
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess());
+ lastComparison = java.lang.Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess());
if (lastComparison != 0) {
return lastComparison;
}
@@ -862,21 +855,22 @@ public class ClusterManagerService {
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("createClusterInterpreterProcess_result(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("createClusterInterpreterProcess_result(");
boolean first = true;
sb.append("success:");
@@ -899,7 +893,7 @@ public class ClusterManagerService {
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
__isset_bitfield = 0;
@@ -909,13 +903,13 @@ public class ClusterManagerService {
}
}
- private static class createClusterInterpreterProcess_resultStandardSchemeFactory implements SchemeFactory {
+ private static class createClusterInterpreterProcess_resultStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public createClusterInterpreterProcess_resultStandardScheme getScheme() {
return new createClusterInterpreterProcess_resultStandardScheme();
}
}
- private static class createClusterInterpreterProcess_resultStandardScheme extends StandardScheme<createClusterInterpreterProcess_result> {
+ private static class createClusterInterpreterProcess_resultStandardScheme extends org.apache.thrift.scheme.StandardScheme<createClusterInterpreterProcess_result> {
public void read(org.apache.thrift.protocol.TProtocol iprot, createClusterInterpreterProcess_result struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -961,18 +955,18 @@ public class ClusterManagerService {
}
- private static class createClusterInterpreterProcess_resultTupleSchemeFactory implements SchemeFactory {
+ private static class createClusterInterpreterProcess_resultTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public createClusterInterpreterProcess_resultTupleScheme getScheme() {
return new createClusterInterpreterProcess_resultTupleScheme();
}
}
- private static class createClusterInterpreterProcess_resultTupleScheme extends TupleScheme<createClusterInterpreterProcess_result> {
+ private static class createClusterInterpreterProcess_resultTupleScheme extends org.apache.thrift.scheme.TupleScheme<createClusterInterpreterProcess_result> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, createClusterInterpreterProcess_result struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetSuccess()) {
optionals.set(0);
}
@@ -984,8 +978,8 @@ public class ClusterManagerService {
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, createClusterInterpreterProcess_result struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(1);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
struct.success = iprot.readBool();
struct.setSuccessIsSet(true);
@@ -993,6 +987,9 @@ public class ClusterManagerService {
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/InterpreterCompletion.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/InterpreterCompletion.java
index d19d1ac..688daad 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/InterpreterCompletion.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/InterpreterCompletion.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class InterpreterCompletion implements org.apache.thrift.TBase<InterpreterCompletion, InterpreterCompletion._Fields>, java.io.Serializable, Cloneable, Comparable<InterpreterCompletion> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("InterpreterCompletion");
@@ -59,15 +32,12 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
private static final org.apache.thrift.protocol.TField VALUE_FIELD_DESC = new org.apache.thrift.protocol.TField("value", org.apache.thrift.protocol.TType.STRING, (short)2);
private static final org.apache.thrift.protocol.TField META_FIELD_DESC = new org.apache.thrift.protocol.TField("meta", org.apache.thrift.protocol.TType.STRING, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new InterpreterCompletionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new InterpreterCompletionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new InterpreterCompletionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new InterpreterCompletionTupleSchemeFactory();
- public String name; // required
- public String value; // required
- public String meta; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String name; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String value; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String meta; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -75,10 +45,10 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
VALUE((short)2, "value"),
META((short)3, "meta");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -86,6 +56,7 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // NAME
@@ -105,21 +76,22 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -128,22 +100,22 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.VALUE, new org.apache.thrift.meta_data.FieldMetaData("value", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.META, new org.apache.thrift.meta_data.FieldMetaData("meta", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(InterpreterCompletion.class, metaDataMap);
}
@@ -151,9 +123,9 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
}
public InterpreterCompletion(
- String name,
- String value,
- String meta)
+ java.lang.String name,
+ java.lang.String value,
+ java.lang.String meta)
{
this();
this.name = name;
@@ -187,11 +159,12 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
this.meta = null;
}
- public String getName() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getName() {
return this.name;
}
- public InterpreterCompletion setName(String name) {
+ public InterpreterCompletion setName(@org.apache.thrift.annotation.Nullable java.lang.String name) {
this.name = name;
return this;
}
@@ -211,11 +184,12 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
}
}
- public String getValue() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getValue() {
return this.value;
}
- public InterpreterCompletion setValue(String value) {
+ public InterpreterCompletion setValue(@org.apache.thrift.annotation.Nullable java.lang.String value) {
this.value = value;
return this;
}
@@ -235,11 +209,12 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
}
}
- public String getMeta() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getMeta() {
return this.meta;
}
- public InterpreterCompletion setMeta(String meta) {
+ public InterpreterCompletion setMeta(@org.apache.thrift.annotation.Nullable java.lang.String meta) {
this.meta = meta;
return this;
}
@@ -259,13 +234,13 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case NAME:
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
@@ -273,7 +248,7 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
if (value == null) {
unsetValue();
} else {
- setValue((String)value);
+ setValue((java.lang.String)value);
}
break;
@@ -281,14 +256,15 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
if (value == null) {
unsetMeta();
} else {
- setMeta((String)value);
+ setMeta((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NAME:
return getName();
@@ -300,13 +276,13 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
return getMeta();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -317,11 +293,11 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
case META:
return isSetMeta();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof InterpreterCompletion)
@@ -332,6 +308,8 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
public boolean equals(InterpreterCompletion that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_name = true && this.isSetName();
boolean that_present_name = true && that.isSetName();
@@ -365,24 +343,21 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
- boolean present_value = true && (isSetValue());
- list.add(present_value);
- if (present_value)
- list.add(value);
+ hashCode = hashCode * 8191 + ((isSetValue()) ? 131071 : 524287);
+ if (isSetValue())
+ hashCode = hashCode * 8191 + value.hashCode();
- boolean present_meta = true && (isSetMeta());
- list.add(present_meta);
- if (present_meta)
- list.add(meta);
+ hashCode = hashCode * 8191 + ((isSetMeta()) ? 131071 : 524287);
+ if (isSetMeta())
+ hashCode = hashCode * 8191 + meta.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -393,7 +368,7 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -403,7 +378,7 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetValue()).compareTo(other.isSetValue());
+ lastComparison = java.lang.Boolean.valueOf(isSetValue()).compareTo(other.isSetValue());
if (lastComparison != 0) {
return lastComparison;
}
@@ -413,7 +388,7 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMeta()).compareTo(other.isSetMeta());
+ lastComparison = java.lang.Boolean.valueOf(isSetMeta()).compareTo(other.isSetMeta());
if (lastComparison != 0) {
return lastComparison;
}
@@ -426,21 +401,22 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("InterpreterCompletion(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("InterpreterCompletion(");
boolean first = true;
sb.append("name:");
@@ -483,7 +459,7 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -491,13 +467,13 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
}
}
- private static class InterpreterCompletionStandardSchemeFactory implements SchemeFactory {
+ private static class InterpreterCompletionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public InterpreterCompletionStandardScheme getScheme() {
return new InterpreterCompletionStandardScheme();
}
}
- private static class InterpreterCompletionStandardScheme extends StandardScheme<InterpreterCompletion> {
+ private static class InterpreterCompletionStandardScheme extends org.apache.thrift.scheme.StandardScheme<InterpreterCompletion> {
public void read(org.apache.thrift.protocol.TProtocol iprot, InterpreterCompletion struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -569,18 +545,18 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
}
- private static class InterpreterCompletionTupleSchemeFactory implements SchemeFactory {
+ private static class InterpreterCompletionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public InterpreterCompletionTupleScheme getScheme() {
return new InterpreterCompletionTupleScheme();
}
}
- private static class InterpreterCompletionTupleScheme extends TupleScheme<InterpreterCompletion> {
+ private static class InterpreterCompletionTupleScheme extends org.apache.thrift.scheme.TupleScheme<InterpreterCompletion> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, InterpreterCompletion struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetName()) {
optionals.set(0);
}
@@ -604,8 +580,8 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, InterpreterCompletion struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(3);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.name = iprot.readString();
struct.setNameIsSet(true);
@@ -621,5 +597,8 @@ public class InterpreterCompletion implements org.apache.thrift.TBase<Interprete
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputAppendEvent.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputAppendEvent.java
index 69abc08..49e5d74 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputAppendEvent.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputAppendEvent.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEvent, OutputAppendEvent._Fields>, java.io.Serializable, Cloneable, Comparable<OutputAppendEvent> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("OutputAppendEvent");
@@ -61,17 +34,14 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
private static final org.apache.thrift.protocol.TField DATA_FIELD_DESC = new org.apache.thrift.protocol.TField("data", org.apache.thrift.protocol.TType.STRING, (short)4);
private static final org.apache.thrift.protocol.TField APP_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("appId", org.apache.thrift.protocol.TType.STRING, (short)5);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new OutputAppendEventStandardSchemeFactory());
- schemes.put(TupleScheme.class, new OutputAppendEventTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new OutputAppendEventStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new OutputAppendEventTupleSchemeFactory();
- public String noteId; // required
- public String paragraphId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphId; // required
public int index; // required
- public String data; // required
- public String appId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String data; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String appId; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -81,10 +51,10 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
DATA((short)4, "data"),
APP_ID((short)5, "appId");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -92,6 +62,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // NOTE_ID
@@ -115,21 +86,22 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -138,7 +110,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -146,9 +118,9 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
// isset id assignments
private static final int __INDEX_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NOTE_ID, new org.apache.thrift.meta_data.FieldMetaData("noteId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PARAGRAPH_ID, new org.apache.thrift.meta_data.FieldMetaData("paragraphId", org.apache.thrift.TFieldRequirementType.DEFAULT,
@@ -159,7 +131,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.APP_ID, new org.apache.thrift.meta_data.FieldMetaData("appId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(OutputAppendEvent.class, metaDataMap);
}
@@ -167,11 +139,11 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
}
public OutputAppendEvent(
- String noteId,
- String paragraphId,
+ java.lang.String noteId,
+ java.lang.String paragraphId,
int index,
- String data,
- String appId)
+ java.lang.String data,
+ java.lang.String appId)
{
this();
this.noteId = noteId;
@@ -216,11 +188,12 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
this.appId = null;
}
- public String getNoteId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteId() {
return this.noteId;
}
- public OutputAppendEvent setNoteId(String noteId) {
+ public OutputAppendEvent setNoteId(@org.apache.thrift.annotation.Nullable java.lang.String noteId) {
this.noteId = noteId;
return this;
}
@@ -240,11 +213,12 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
}
}
- public String getParagraphId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphId() {
return this.paragraphId;
}
- public OutputAppendEvent setParagraphId(String paragraphId) {
+ public OutputAppendEvent setParagraphId(@org.apache.thrift.annotation.Nullable java.lang.String paragraphId) {
this.paragraphId = paragraphId;
return this;
}
@@ -275,23 +249,24 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
}
public void unsetIndex() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __INDEX_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __INDEX_ISSET_ID);
}
/** Returns true if field index is set (has been assigned a value) and false otherwise */
public boolean isSetIndex() {
- return EncodingUtils.testBit(__isset_bitfield, __INDEX_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __INDEX_ISSET_ID);
}
public void setIndexIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __INDEX_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __INDEX_ISSET_ID, value);
}
- public String getData() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getData() {
return this.data;
}
- public OutputAppendEvent setData(String data) {
+ public OutputAppendEvent setData(@org.apache.thrift.annotation.Nullable java.lang.String data) {
this.data = data;
return this;
}
@@ -311,11 +286,12 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
}
}
- public String getAppId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getAppId() {
return this.appId;
}
- public OutputAppendEvent setAppId(String appId) {
+ public OutputAppendEvent setAppId(@org.apache.thrift.annotation.Nullable java.lang.String appId) {
this.appId = appId;
return this;
}
@@ -335,13 +311,13 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case NOTE_ID:
if (value == null) {
unsetNoteId();
} else {
- setNoteId((String)value);
+ setNoteId((java.lang.String)value);
}
break;
@@ -349,7 +325,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
if (value == null) {
unsetParagraphId();
} else {
- setParagraphId((String)value);
+ setParagraphId((java.lang.String)value);
}
break;
@@ -357,7 +333,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
if (value == null) {
unsetIndex();
} else {
- setIndex((Integer)value);
+ setIndex((java.lang.Integer)value);
}
break;
@@ -365,7 +341,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
if (value == null) {
unsetData();
} else {
- setData((String)value);
+ setData((java.lang.String)value);
}
break;
@@ -373,14 +349,15 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
if (value == null) {
unsetAppId();
} else {
- setAppId((String)value);
+ setAppId((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NOTE_ID:
return getNoteId();
@@ -389,7 +366,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
return getParagraphId();
case INDEX:
- return Integer.valueOf(getIndex());
+ return getIndex();
case DATA:
return getData();
@@ -398,13 +375,13 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
return getAppId();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -419,11 +396,11 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
case APP_ID:
return isSetAppId();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof OutputAppendEvent)
@@ -434,6 +411,8 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
public boolean equals(OutputAppendEvent that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_noteId = true && this.isSetNoteId();
boolean that_present_noteId = true && that.isSetNoteId();
@@ -485,34 +464,27 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_noteId = true && (isSetNoteId());
- list.add(present_noteId);
- if (present_noteId)
- list.add(noteId);
+ hashCode = hashCode * 8191 + ((isSetNoteId()) ? 131071 : 524287);
+ if (isSetNoteId())
+ hashCode = hashCode * 8191 + noteId.hashCode();
- boolean present_paragraphId = true && (isSetParagraphId());
- list.add(present_paragraphId);
- if (present_paragraphId)
- list.add(paragraphId);
+ hashCode = hashCode * 8191 + ((isSetParagraphId()) ? 131071 : 524287);
+ if (isSetParagraphId())
+ hashCode = hashCode * 8191 + paragraphId.hashCode();
- boolean present_index = true;
- list.add(present_index);
- if (present_index)
- list.add(index);
+ hashCode = hashCode * 8191 + index;
- boolean present_data = true && (isSetData());
- list.add(present_data);
- if (present_data)
- list.add(data);
+ hashCode = hashCode * 8191 + ((isSetData()) ? 131071 : 524287);
+ if (isSetData())
+ hashCode = hashCode * 8191 + data.hashCode();
- boolean present_appId = true && (isSetAppId());
- list.add(present_appId);
- if (present_appId)
- list.add(appId);
+ hashCode = hashCode * 8191 + ((isSetAppId()) ? 131071 : 524287);
+ if (isSetAppId())
+ hashCode = hashCode * 8191 + appId.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -523,7 +495,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -533,7 +505,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -543,7 +515,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIndex()).compareTo(other.isSetIndex());
+ lastComparison = java.lang.Boolean.valueOf(isSetIndex()).compareTo(other.isSetIndex());
if (lastComparison != 0) {
return lastComparison;
}
@@ -553,7 +525,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetData()).compareTo(other.isSetData());
+ lastComparison = java.lang.Boolean.valueOf(isSetData()).compareTo(other.isSetData());
if (lastComparison != 0) {
return lastComparison;
}
@@ -563,7 +535,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAppId()).compareTo(other.isSetAppId());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppId()).compareTo(other.isSetAppId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -576,21 +548,22 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("OutputAppendEvent(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("OutputAppendEvent(");
boolean first = true;
sb.append("noteId:");
@@ -645,7 +618,7 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
__isset_bitfield = 0;
@@ -655,13 +628,13 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
}
}
- private static class OutputAppendEventStandardSchemeFactory implements SchemeFactory {
+ private static class OutputAppendEventStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public OutputAppendEventStandardScheme getScheme() {
return new OutputAppendEventStandardScheme();
}
}
- private static class OutputAppendEventStandardScheme extends StandardScheme<OutputAppendEvent> {
+ private static class OutputAppendEventStandardScheme extends org.apache.thrift.scheme.StandardScheme<OutputAppendEvent> {
public void read(org.apache.thrift.protocol.TProtocol iprot, OutputAppendEvent struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -757,18 +730,18 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
}
- private static class OutputAppendEventTupleSchemeFactory implements SchemeFactory {
+ private static class OutputAppendEventTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public OutputAppendEventTupleScheme getScheme() {
return new OutputAppendEventTupleScheme();
}
}
- private static class OutputAppendEventTupleScheme extends TupleScheme<OutputAppendEvent> {
+ private static class OutputAppendEventTupleScheme extends org.apache.thrift.scheme.TupleScheme<OutputAppendEvent> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, OutputAppendEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetNoteId()) {
optionals.set(0);
}
@@ -804,8 +777,8 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, OutputAppendEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(5);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(5);
if (incoming.get(0)) {
struct.noteId = iprot.readString();
struct.setNoteIdIsSet(true);
@@ -829,5 +802,8 @@ public class OutputAppendEvent implements org.apache.thrift.TBase<OutputAppendEv
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputUpdateAllEvent.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputUpdateAllEvent.java
index ac32e6e..6b9c81c 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputUpdateAllEvent.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputUpdateAllEvent.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdateAllEvent, OutputUpdateAllEvent._Fields>, java.io.Serializable, Cloneable, Comparable<OutputUpdateAllEvent> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("OutputUpdateAllEvent");
@@ -59,15 +32,12 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
private static final org.apache.thrift.protocol.TField PARAGRAPH_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("paragraphId", org.apache.thrift.protocol.TType.STRING, (short)2);
private static final org.apache.thrift.protocol.TField MSG_FIELD_DESC = new org.apache.thrift.protocol.TField("msg", org.apache.thrift.protocol.TType.LIST, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new OutputUpdateAllEventStandardSchemeFactory());
- schemes.put(TupleScheme.class, new OutputUpdateAllEventTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new OutputUpdateAllEventStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new OutputUpdateAllEventTupleSchemeFactory();
- public String noteId; // required
- public String paragraphId; // required
- public List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> msg; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphId; // required
+ public @org.apache.thrift.annotation.Nullable java.util.List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> msg; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -75,10 +45,10 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
PARAGRAPH_ID((short)2, "paragraphId"),
MSG((short)3, "msg");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -86,6 +56,7 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // NOTE_ID
@@ -105,21 +76,22 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -128,15 +100,15 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NOTE_ID, new org.apache.thrift.meta_data.FieldMetaData("noteId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PARAGRAPH_ID, new org.apache.thrift.meta_data.FieldMetaData("paragraphId", org.apache.thrift.TFieldRequirementType.DEFAULT,
@@ -144,7 +116,7 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
tmpMap.put(_Fields.MSG, new org.apache.thrift.meta_data.FieldMetaData("msg", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage.class))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(OutputUpdateAllEvent.class, metaDataMap);
}
@@ -152,9 +124,9 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
}
public OutputUpdateAllEvent(
- String noteId,
- String paragraphId,
- List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> msg)
+ java.lang.String noteId,
+ java.lang.String paragraphId,
+ java.util.List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> msg)
{
this();
this.noteId = noteId;
@@ -173,7 +145,7 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
this.paragraphId = other.paragraphId;
}
if (other.isSetMsg()) {
- List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> __this__msg = new ArrayList<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage>(other.msg.size());
+ java.util.List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> __this__msg = new java.util.ArrayList<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage>(other.msg.size());
for (org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage other_element : other.msg) {
__this__msg.add(new org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage(other_element));
}
@@ -192,11 +164,12 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
this.msg = null;
}
- public String getNoteId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteId() {
return this.noteId;
}
- public OutputUpdateAllEvent setNoteId(String noteId) {
+ public OutputUpdateAllEvent setNoteId(@org.apache.thrift.annotation.Nullable java.lang.String noteId) {
this.noteId = noteId;
return this;
}
@@ -216,11 +189,12 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
}
}
- public String getParagraphId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphId() {
return this.paragraphId;
}
- public OutputUpdateAllEvent setParagraphId(String paragraphId) {
+ public OutputUpdateAllEvent setParagraphId(@org.apache.thrift.annotation.Nullable java.lang.String paragraphId) {
this.paragraphId = paragraphId;
return this;
}
@@ -244,22 +218,24 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
return (this.msg == null) ? 0 : this.msg.size();
}
+ @org.apache.thrift.annotation.Nullable
public java.util.Iterator<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> getMsgIterator() {
return (this.msg == null) ? null : this.msg.iterator();
}
public void addToMsg(org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage elem) {
if (this.msg == null) {
- this.msg = new ArrayList<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage>();
+ this.msg = new java.util.ArrayList<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage>();
}
this.msg.add(elem);
}
- public List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> getMsg() {
+ @org.apache.thrift.annotation.Nullable
+ public java.util.List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> getMsg() {
return this.msg;
}
- public OutputUpdateAllEvent setMsg(List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> msg) {
+ public OutputUpdateAllEvent setMsg(@org.apache.thrift.annotation.Nullable java.util.List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage> msg) {
this.msg = msg;
return this;
}
@@ -279,13 +255,13 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case NOTE_ID:
if (value == null) {
unsetNoteId();
} else {
- setNoteId((String)value);
+ setNoteId((java.lang.String)value);
}
break;
@@ -293,7 +269,7 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
if (value == null) {
unsetParagraphId();
} else {
- setParagraphId((String)value);
+ setParagraphId((java.lang.String)value);
}
break;
@@ -301,14 +277,15 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
if (value == null) {
unsetMsg();
} else {
- setMsg((List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage>)value);
+ setMsg((java.util.List<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NOTE_ID:
return getNoteId();
@@ -320,13 +297,13 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
return getMsg();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -337,11 +314,11 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
case MSG:
return isSetMsg();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof OutputUpdateAllEvent)
@@ -352,6 +329,8 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
public boolean equals(OutputUpdateAllEvent that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_noteId = true && this.isSetNoteId();
boolean that_present_noteId = true && that.isSetNoteId();
@@ -385,24 +364,21 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_noteId = true && (isSetNoteId());
- list.add(present_noteId);
- if (present_noteId)
- list.add(noteId);
+ hashCode = hashCode * 8191 + ((isSetNoteId()) ? 131071 : 524287);
+ if (isSetNoteId())
+ hashCode = hashCode * 8191 + noteId.hashCode();
- boolean present_paragraphId = true && (isSetParagraphId());
- list.add(present_paragraphId);
- if (present_paragraphId)
- list.add(paragraphId);
+ hashCode = hashCode * 8191 + ((isSetParagraphId()) ? 131071 : 524287);
+ if (isSetParagraphId())
+ hashCode = hashCode * 8191 + paragraphId.hashCode();
- boolean present_msg = true && (isSetMsg());
- list.add(present_msg);
- if (present_msg)
- list.add(msg);
+ hashCode = hashCode * 8191 + ((isSetMsg()) ? 131071 : 524287);
+ if (isSetMsg())
+ hashCode = hashCode * 8191 + msg.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -413,7 +389,7 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -423,7 +399,7 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -433,7 +409,7 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMsg()).compareTo(other.isSetMsg());
+ lastComparison = java.lang.Boolean.valueOf(isSetMsg()).compareTo(other.isSetMsg());
if (lastComparison != 0) {
return lastComparison;
}
@@ -446,21 +422,22 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("OutputUpdateAllEvent(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("OutputUpdateAllEvent(");
boolean first = true;
sb.append("noteId:");
@@ -503,7 +480,7 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -511,13 +488,13 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
}
}
- private static class OutputUpdateAllEventStandardSchemeFactory implements SchemeFactory {
+ private static class OutputUpdateAllEventStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public OutputUpdateAllEventStandardScheme getScheme() {
return new OutputUpdateAllEventStandardScheme();
}
}
- private static class OutputUpdateAllEventStandardScheme extends StandardScheme<OutputUpdateAllEvent> {
+ private static class OutputUpdateAllEventStandardScheme extends org.apache.thrift.scheme.StandardScheme<OutputUpdateAllEvent> {
public void read(org.apache.thrift.protocol.TProtocol iprot, OutputUpdateAllEvent struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -549,8 +526,8 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.msg = new ArrayList<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage>(_list0.size);
- org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage _elem1;
+ struct.msg = new java.util.ArrayList<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage>(_list0.size);
+ @org.apache.thrift.annotation.Nullable org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
_elem1 = new org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage();
@@ -607,18 +584,18 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
}
- private static class OutputUpdateAllEventTupleSchemeFactory implements SchemeFactory {
+ private static class OutputUpdateAllEventTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public OutputUpdateAllEventTupleScheme getScheme() {
return new OutputUpdateAllEventTupleScheme();
}
}
- private static class OutputUpdateAllEventTupleScheme extends TupleScheme<OutputUpdateAllEvent> {
+ private static class OutputUpdateAllEventTupleScheme extends org.apache.thrift.scheme.TupleScheme<OutputUpdateAllEvent> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, OutputUpdateAllEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetNoteId()) {
optionals.set(0);
}
@@ -648,8 +625,8 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, OutputUpdateAllEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(3);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.noteId = iprot.readString();
struct.setNoteIdIsSet(true);
@@ -661,8 +638,8 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.msg = new ArrayList<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage>(_list5.size);
- org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage _elem6;
+ struct.msg = new java.util.ArrayList<org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage>(_list5.size);
+ @org.apache.thrift.annotation.Nullable org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage _elem6;
for (int _i7 = 0; _i7 < _list5.size; ++_i7)
{
_elem6 = new org.apache.zeppelin.interpreter.thrift.RemoteInterpreterResultMessage();
@@ -675,5 +652,8 @@ public class OutputUpdateAllEvent implements org.apache.thrift.TBase<OutputUpdat
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputUpdateEvent.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputUpdateEvent.java
index 0e226ba..df163d6 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputUpdateEvent.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/OutputUpdateEvent.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEvent, OutputUpdateEvent._Fields>, java.io.Serializable, Cloneable, Comparable<OutputUpdateEvent> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("OutputUpdateEvent");
@@ -62,18 +35,15 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
private static final org.apache.thrift.protocol.TField DATA_FIELD_DESC = new org.apache.thrift.protocol.TField("data", org.apache.thrift.protocol.TType.STRING, (short)5);
private static final org.apache.thrift.protocol.TField APP_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("appId", org.apache.thrift.protocol.TType.STRING, (short)6);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new OutputUpdateEventStandardSchemeFactory());
- schemes.put(TupleScheme.class, new OutputUpdateEventTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new OutputUpdateEventStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new OutputUpdateEventTupleSchemeFactory();
- public String noteId; // required
- public String paragraphId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphId; // required
public int index; // required
- public String type; // required
- public String data; // required
- public String appId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String type; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String data; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String appId; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -84,10 +54,10 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
DATA((short)5, "data"),
APP_ID((short)6, "appId");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -95,6 +65,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // NOTE_ID
@@ -120,21 +91,22 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -143,7 +115,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -151,9 +123,9 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
// isset id assignments
private static final int __INDEX_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NOTE_ID, new org.apache.thrift.meta_data.FieldMetaData("noteId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PARAGRAPH_ID, new org.apache.thrift.meta_data.FieldMetaData("paragraphId", org.apache.thrift.TFieldRequirementType.DEFAULT,
@@ -166,7 +138,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.APP_ID, new org.apache.thrift.meta_data.FieldMetaData("appId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(OutputUpdateEvent.class, metaDataMap);
}
@@ -174,12 +146,12 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
}
public OutputUpdateEvent(
- String noteId,
- String paragraphId,
+ java.lang.String noteId,
+ java.lang.String paragraphId,
int index,
- String type,
- String data,
- String appId)
+ java.lang.String type,
+ java.lang.String data,
+ java.lang.String appId)
{
this();
this.noteId = noteId;
@@ -229,11 +201,12 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
this.appId = null;
}
- public String getNoteId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteId() {
return this.noteId;
}
- public OutputUpdateEvent setNoteId(String noteId) {
+ public OutputUpdateEvent setNoteId(@org.apache.thrift.annotation.Nullable java.lang.String noteId) {
this.noteId = noteId;
return this;
}
@@ -253,11 +226,12 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
}
}
- public String getParagraphId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphId() {
return this.paragraphId;
}
- public OutputUpdateEvent setParagraphId(String paragraphId) {
+ public OutputUpdateEvent setParagraphId(@org.apache.thrift.annotation.Nullable java.lang.String paragraphId) {
this.paragraphId = paragraphId;
return this;
}
@@ -288,23 +262,24 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
}
public void unsetIndex() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __INDEX_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __INDEX_ISSET_ID);
}
/** Returns true if field index is set (has been assigned a value) and false otherwise */
public boolean isSetIndex() {
- return EncodingUtils.testBit(__isset_bitfield, __INDEX_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __INDEX_ISSET_ID);
}
public void setIndexIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __INDEX_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __INDEX_ISSET_ID, value);
}
- public String getType() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getType() {
return this.type;
}
- public OutputUpdateEvent setType(String type) {
+ public OutputUpdateEvent setType(@org.apache.thrift.annotation.Nullable java.lang.String type) {
this.type = type;
return this;
}
@@ -324,11 +299,12 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
}
}
- public String getData() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getData() {
return this.data;
}
- public OutputUpdateEvent setData(String data) {
+ public OutputUpdateEvent setData(@org.apache.thrift.annotation.Nullable java.lang.String data) {
this.data = data;
return this;
}
@@ -348,11 +324,12 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
}
}
- public String getAppId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getAppId() {
return this.appId;
}
- public OutputUpdateEvent setAppId(String appId) {
+ public OutputUpdateEvent setAppId(@org.apache.thrift.annotation.Nullable java.lang.String appId) {
this.appId = appId;
return this;
}
@@ -372,13 +349,13 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case NOTE_ID:
if (value == null) {
unsetNoteId();
} else {
- setNoteId((String)value);
+ setNoteId((java.lang.String)value);
}
break;
@@ -386,7 +363,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
if (value == null) {
unsetParagraphId();
} else {
- setParagraphId((String)value);
+ setParagraphId((java.lang.String)value);
}
break;
@@ -394,7 +371,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
if (value == null) {
unsetIndex();
} else {
- setIndex((Integer)value);
+ setIndex((java.lang.Integer)value);
}
break;
@@ -402,7 +379,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
if (value == null) {
unsetType();
} else {
- setType((String)value);
+ setType((java.lang.String)value);
}
break;
@@ -410,7 +387,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
if (value == null) {
unsetData();
} else {
- setData((String)value);
+ setData((java.lang.String)value);
}
break;
@@ -418,14 +395,15 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
if (value == null) {
unsetAppId();
} else {
- setAppId((String)value);
+ setAppId((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NOTE_ID:
return getNoteId();
@@ -434,7 +412,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
return getParagraphId();
case INDEX:
- return Integer.valueOf(getIndex());
+ return getIndex();
case TYPE:
return getType();
@@ -446,13 +424,13 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
return getAppId();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -469,11 +447,11 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
case APP_ID:
return isSetAppId();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof OutputUpdateEvent)
@@ -484,6 +462,8 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
public boolean equals(OutputUpdateEvent that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_noteId = true && this.isSetNoteId();
boolean that_present_noteId = true && that.isSetNoteId();
@@ -544,39 +524,31 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_noteId = true && (isSetNoteId());
- list.add(present_noteId);
- if (present_noteId)
- list.add(noteId);
+ hashCode = hashCode * 8191 + ((isSetNoteId()) ? 131071 : 524287);
+ if (isSetNoteId())
+ hashCode = hashCode * 8191 + noteId.hashCode();
- boolean present_paragraphId = true && (isSetParagraphId());
- list.add(present_paragraphId);
- if (present_paragraphId)
- list.add(paragraphId);
+ hashCode = hashCode * 8191 + ((isSetParagraphId()) ? 131071 : 524287);
+ if (isSetParagraphId())
+ hashCode = hashCode * 8191 + paragraphId.hashCode();
- boolean present_index = true;
- list.add(present_index);
- if (present_index)
- list.add(index);
+ hashCode = hashCode * 8191 + index;
- boolean present_type = true && (isSetType());
- list.add(present_type);
- if (present_type)
- list.add(type);
+ hashCode = hashCode * 8191 + ((isSetType()) ? 131071 : 524287);
+ if (isSetType())
+ hashCode = hashCode * 8191 + type.hashCode();
- boolean present_data = true && (isSetData());
- list.add(present_data);
- if (present_data)
- list.add(data);
+ hashCode = hashCode * 8191 + ((isSetData()) ? 131071 : 524287);
+ if (isSetData())
+ hashCode = hashCode * 8191 + data.hashCode();
- boolean present_appId = true && (isSetAppId());
- list.add(present_appId);
- if (present_appId)
- list.add(appId);
+ hashCode = hashCode * 8191 + ((isSetAppId()) ? 131071 : 524287);
+ if (isSetAppId())
+ hashCode = hashCode * 8191 + appId.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -587,7 +559,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -597,7 +569,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -607,7 +579,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIndex()).compareTo(other.isSetIndex());
+ lastComparison = java.lang.Boolean.valueOf(isSetIndex()).compareTo(other.isSetIndex());
if (lastComparison != 0) {
return lastComparison;
}
@@ -617,7 +589,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetType()).compareTo(other.isSetType());
+ lastComparison = java.lang.Boolean.valueOf(isSetType()).compareTo(other.isSetType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -627,7 +599,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetData()).compareTo(other.isSetData());
+ lastComparison = java.lang.Boolean.valueOf(isSetData()).compareTo(other.isSetData());
if (lastComparison != 0) {
return lastComparison;
}
@@ -637,7 +609,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAppId()).compareTo(other.isSetAppId());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppId()).compareTo(other.isSetAppId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -650,21 +622,22 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("OutputUpdateEvent(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("OutputUpdateEvent(");
boolean first = true;
sb.append("noteId:");
@@ -727,7 +700,7 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
__isset_bitfield = 0;
@@ -737,13 +710,13 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
}
}
- private static class OutputUpdateEventStandardSchemeFactory implements SchemeFactory {
+ private static class OutputUpdateEventStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public OutputUpdateEventStandardScheme getScheme() {
return new OutputUpdateEventStandardScheme();
}
}
- private static class OutputUpdateEventStandardScheme extends StandardScheme<OutputUpdateEvent> {
+ private static class OutputUpdateEventStandardScheme extends org.apache.thrift.scheme.StandardScheme<OutputUpdateEvent> {
public void read(org.apache.thrift.protocol.TProtocol iprot, OutputUpdateEvent struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -852,18 +825,18 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
}
- private static class OutputUpdateEventTupleSchemeFactory implements SchemeFactory {
+ private static class OutputUpdateEventTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public OutputUpdateEventTupleScheme getScheme() {
return new OutputUpdateEventTupleScheme();
}
}
- private static class OutputUpdateEventTupleScheme extends TupleScheme<OutputUpdateEvent> {
+ private static class OutputUpdateEventTupleScheme extends org.apache.thrift.scheme.TupleScheme<OutputUpdateEvent> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, OutputUpdateEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetNoteId()) {
optionals.set(0);
}
@@ -905,8 +878,8 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, OutputUpdateEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(6);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(6);
if (incoming.get(0)) {
struct.noteId = iprot.readString();
struct.setNoteIdIsSet(true);
@@ -934,5 +907,8 @@ public class OutputUpdateEvent implements org.apache.thrift.TBase<OutputUpdateEv
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ParagraphInfo.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ParagraphInfo.java
index bd50d99..59e7340 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ParagraphInfo.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/ParagraphInfo.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, ParagraphInfo._Fields>, java.io.Serializable, Cloneable, Comparable<ParagraphInfo> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ParagraphInfo");
@@ -60,16 +33,13 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
private static final org.apache.thrift.protocol.TField PARAGRAPH_TITLE_FIELD_DESC = new org.apache.thrift.protocol.TField("paragraphTitle", org.apache.thrift.protocol.TType.STRING, (short)3);
private static final org.apache.thrift.protocol.TField PARAGRAPH_TEXT_FIELD_DESC = new org.apache.thrift.protocol.TField("paragraphText", org.apache.thrift.protocol.TType.STRING, (short)4);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ParagraphInfoStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ParagraphInfoTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ParagraphInfoStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ParagraphInfoTupleSchemeFactory();
- public String noteId; // required
- public String paragraphId; // required
- public String paragraphTitle; // required
- public String paragraphText; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphTitle; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphText; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -78,10 +48,10 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
PARAGRAPH_TITLE((short)3, "paragraphTitle"),
PARAGRAPH_TEXT((short)4, "paragraphText");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -89,6 +59,7 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // NOTE_ID
@@ -110,21 +81,22 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -133,15 +105,15 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NOTE_ID, new org.apache.thrift.meta_data.FieldMetaData("noteId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PARAGRAPH_ID, new org.apache.thrift.meta_data.FieldMetaData("paragraphId", org.apache.thrift.TFieldRequirementType.DEFAULT,
@@ -150,7 +122,7 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PARAGRAPH_TEXT, new org.apache.thrift.meta_data.FieldMetaData("paragraphText", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ParagraphInfo.class, metaDataMap);
}
@@ -158,10 +130,10 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
}
public ParagraphInfo(
- String noteId,
- String paragraphId,
- String paragraphTitle,
- String paragraphText)
+ java.lang.String noteId,
+ java.lang.String paragraphId,
+ java.lang.String paragraphTitle,
+ java.lang.String paragraphText)
{
this();
this.noteId = noteId;
@@ -200,11 +172,12 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
this.paragraphText = null;
}
- public String getNoteId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteId() {
return this.noteId;
}
- public ParagraphInfo setNoteId(String noteId) {
+ public ParagraphInfo setNoteId(@org.apache.thrift.annotation.Nullable java.lang.String noteId) {
this.noteId = noteId;
return this;
}
@@ -224,11 +197,12 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
}
}
- public String getParagraphId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphId() {
return this.paragraphId;
}
- public ParagraphInfo setParagraphId(String paragraphId) {
+ public ParagraphInfo setParagraphId(@org.apache.thrift.annotation.Nullable java.lang.String paragraphId) {
this.paragraphId = paragraphId;
return this;
}
@@ -248,11 +222,12 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
}
}
- public String getParagraphTitle() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphTitle() {
return this.paragraphTitle;
}
- public ParagraphInfo setParagraphTitle(String paragraphTitle) {
+ public ParagraphInfo setParagraphTitle(@org.apache.thrift.annotation.Nullable java.lang.String paragraphTitle) {
this.paragraphTitle = paragraphTitle;
return this;
}
@@ -272,11 +247,12 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
}
}
- public String getParagraphText() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphText() {
return this.paragraphText;
}
- public ParagraphInfo setParagraphText(String paragraphText) {
+ public ParagraphInfo setParagraphText(@org.apache.thrift.annotation.Nullable java.lang.String paragraphText) {
this.paragraphText = paragraphText;
return this;
}
@@ -296,13 +272,13 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case NOTE_ID:
if (value == null) {
unsetNoteId();
} else {
- setNoteId((String)value);
+ setNoteId((java.lang.String)value);
}
break;
@@ -310,7 +286,7 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
if (value == null) {
unsetParagraphId();
} else {
- setParagraphId((String)value);
+ setParagraphId((java.lang.String)value);
}
break;
@@ -318,7 +294,7 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
if (value == null) {
unsetParagraphTitle();
} else {
- setParagraphTitle((String)value);
+ setParagraphTitle((java.lang.String)value);
}
break;
@@ -326,14 +302,15 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
if (value == null) {
unsetParagraphText();
} else {
- setParagraphText((String)value);
+ setParagraphText((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NOTE_ID:
return getNoteId();
@@ -348,13 +325,13 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
return getParagraphText();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -367,11 +344,11 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
case PARAGRAPH_TEXT:
return isSetParagraphText();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ParagraphInfo)
@@ -382,6 +359,8 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
public boolean equals(ParagraphInfo that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_noteId = true && this.isSetNoteId();
boolean that_present_noteId = true && that.isSetNoteId();
@@ -424,29 +403,25 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_noteId = true && (isSetNoteId());
- list.add(present_noteId);
- if (present_noteId)
- list.add(noteId);
+ hashCode = hashCode * 8191 + ((isSetNoteId()) ? 131071 : 524287);
+ if (isSetNoteId())
+ hashCode = hashCode * 8191 + noteId.hashCode();
- boolean present_paragraphId = true && (isSetParagraphId());
- list.add(present_paragraphId);
- if (present_paragraphId)
- list.add(paragraphId);
+ hashCode = hashCode * 8191 + ((isSetParagraphId()) ? 131071 : 524287);
+ if (isSetParagraphId())
+ hashCode = hashCode * 8191 + paragraphId.hashCode();
- boolean present_paragraphTitle = true && (isSetParagraphTitle());
- list.add(present_paragraphTitle);
- if (present_paragraphTitle)
- list.add(paragraphTitle);
+ hashCode = hashCode * 8191 + ((isSetParagraphTitle()) ? 131071 : 524287);
+ if (isSetParagraphTitle())
+ hashCode = hashCode * 8191 + paragraphTitle.hashCode();
- boolean present_paragraphText = true && (isSetParagraphText());
- list.add(present_paragraphText);
- if (present_paragraphText)
- list.add(paragraphText);
+ hashCode = hashCode * 8191 + ((isSetParagraphText()) ? 131071 : 524287);
+ if (isSetParagraphText())
+ hashCode = hashCode * 8191 + paragraphText.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -457,7 +432,7 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -467,7 +442,7 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -477,7 +452,7 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphTitle()).compareTo(other.isSetParagraphTitle());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphTitle()).compareTo(other.isSetParagraphTitle());
if (lastComparison != 0) {
return lastComparison;
}
@@ -487,7 +462,7 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphText()).compareTo(other.isSetParagraphText());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphText()).compareTo(other.isSetParagraphText());
if (lastComparison != 0) {
return lastComparison;
}
@@ -500,21 +475,22 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ParagraphInfo(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ParagraphInfo(");
boolean first = true;
sb.append("noteId:");
@@ -565,7 +541,7 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -573,13 +549,13 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
}
}
- private static class ParagraphInfoStandardSchemeFactory implements SchemeFactory {
+ private static class ParagraphInfoStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ParagraphInfoStandardScheme getScheme() {
return new ParagraphInfoStandardScheme();
}
}
- private static class ParagraphInfoStandardScheme extends StandardScheme<ParagraphInfo> {
+ private static class ParagraphInfoStandardScheme extends org.apache.thrift.scheme.StandardScheme<ParagraphInfo> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ParagraphInfo struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -664,18 +640,18 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
}
- private static class ParagraphInfoTupleSchemeFactory implements SchemeFactory {
+ private static class ParagraphInfoTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ParagraphInfoTupleScheme getScheme() {
return new ParagraphInfoTupleScheme();
}
}
- private static class ParagraphInfoTupleScheme extends TupleScheme<ParagraphInfo> {
+ private static class ParagraphInfoTupleScheme extends org.apache.thrift.scheme.TupleScheme<ParagraphInfo> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ParagraphInfo struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetNoteId()) {
optionals.set(0);
}
@@ -705,8 +681,8 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ParagraphInfo struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(4);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(4);
if (incoming.get(0)) {
struct.noteId = iprot.readString();
struct.setNoteIdIsSet(true);
@@ -726,5 +702,8 @@ public class ParagraphInfo implements org.apache.thrift.TBase<ParagraphInfo, Par
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RegisterInfo.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RegisterInfo.java
index 46fb9b0..8cd7b2e 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RegisterInfo.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RegisterInfo.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, RegisterInfo._Fields>, java.io.Serializable, Cloneable, Comparable<RegisterInfo> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("RegisterInfo");
@@ -59,15 +32,12 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
private static final org.apache.thrift.protocol.TField PORT_FIELD_DESC = new org.apache.thrift.protocol.TField("port", org.apache.thrift.protocol.TType.I32, (short)2);
private static final org.apache.thrift.protocol.TField INTERPRETER_GROUP_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("interpreterGroupId", org.apache.thrift.protocol.TType.STRING, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new RegisterInfoStandardSchemeFactory());
- schemes.put(TupleScheme.class, new RegisterInfoTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new RegisterInfoStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new RegisterInfoTupleSchemeFactory();
- public String host; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String host; // required
public int port; // required
- public String interpreterGroupId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String interpreterGroupId; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -75,10 +45,10 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
PORT((short)2, "port"),
INTERPRETER_GROUP_ID((short)3, "interpreterGroupId");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -86,6 +56,7 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // HOST
@@ -105,21 +76,22 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -128,7 +100,7 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -136,16 +108,16 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
// isset id assignments
private static final int __PORT_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.HOST, new org.apache.thrift.meta_data.FieldMetaData("host", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PORT, new org.apache.thrift.meta_data.FieldMetaData("port", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
tmpMap.put(_Fields.INTERPRETER_GROUP_ID, new org.apache.thrift.meta_data.FieldMetaData("interpreterGroupId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(RegisterInfo.class, metaDataMap);
}
@@ -153,9 +125,9 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
}
public RegisterInfo(
- String host,
+ java.lang.String host,
int port,
- String interpreterGroupId)
+ java.lang.String interpreterGroupId)
{
this();
this.host = host;
@@ -190,11 +162,12 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
this.interpreterGroupId = null;
}
- public String getHost() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getHost() {
return this.host;
}
- public RegisterInfo setHost(String host) {
+ public RegisterInfo setHost(@org.apache.thrift.annotation.Nullable java.lang.String host) {
this.host = host;
return this;
}
@@ -225,23 +198,24 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
}
public void unsetPort() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PORT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __PORT_ISSET_ID);
}
/** Returns true if field port is set (has been assigned a value) and false otherwise */
public boolean isSetPort() {
- return EncodingUtils.testBit(__isset_bitfield, __PORT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PORT_ISSET_ID);
}
public void setPortIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PORT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PORT_ISSET_ID, value);
}
- public String getInterpreterGroupId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getInterpreterGroupId() {
return this.interpreterGroupId;
}
- public RegisterInfo setInterpreterGroupId(String interpreterGroupId) {
+ public RegisterInfo setInterpreterGroupId(@org.apache.thrift.annotation.Nullable java.lang.String interpreterGroupId) {
this.interpreterGroupId = interpreterGroupId;
return this;
}
@@ -261,13 +235,13 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case HOST:
if (value == null) {
unsetHost();
} else {
- setHost((String)value);
+ setHost((java.lang.String)value);
}
break;
@@ -275,7 +249,7 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
if (value == null) {
unsetPort();
} else {
- setPort((Integer)value);
+ setPort((java.lang.Integer)value);
}
break;
@@ -283,32 +257,33 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
if (value == null) {
unsetInterpreterGroupId();
} else {
- setInterpreterGroupId((String)value);
+ setInterpreterGroupId((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case HOST:
return getHost();
case PORT:
- return Integer.valueOf(getPort());
+ return getPort();
case INTERPRETER_GROUP_ID:
return getInterpreterGroupId();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -319,11 +294,11 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
case INTERPRETER_GROUP_ID:
return isSetInterpreterGroupId();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof RegisterInfo)
@@ -334,6 +309,8 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
public boolean equals(RegisterInfo that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_host = true && this.isSetHost();
boolean that_present_host = true && that.isSetHost();
@@ -367,24 +344,19 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_host = true && (isSetHost());
- list.add(present_host);
- if (present_host)
- list.add(host);
+ hashCode = hashCode * 8191 + ((isSetHost()) ? 131071 : 524287);
+ if (isSetHost())
+ hashCode = hashCode * 8191 + host.hashCode();
- boolean present_port = true;
- list.add(present_port);
- if (present_port)
- list.add(port);
+ hashCode = hashCode * 8191 + port;
- boolean present_interpreterGroupId = true && (isSetInterpreterGroupId());
- list.add(present_interpreterGroupId);
- if (present_interpreterGroupId)
- list.add(interpreterGroupId);
+ hashCode = hashCode * 8191 + ((isSetInterpreterGroupId()) ? 131071 : 524287);
+ if (isSetInterpreterGroupId())
+ hashCode = hashCode * 8191 + interpreterGroupId.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -395,7 +367,7 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetHost()).compareTo(other.isSetHost());
+ lastComparison = java.lang.Boolean.valueOf(isSetHost()).compareTo(other.isSetHost());
if (lastComparison != 0) {
return lastComparison;
}
@@ -405,7 +377,7 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPort()).compareTo(other.isSetPort());
+ lastComparison = java.lang.Boolean.valueOf(isSetPort()).compareTo(other.isSetPort());
if (lastComparison != 0) {
return lastComparison;
}
@@ -415,7 +387,7 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetInterpreterGroupId()).compareTo(other.isSetInterpreterGroupId());
+ lastComparison = java.lang.Boolean.valueOf(isSetInterpreterGroupId()).compareTo(other.isSetInterpreterGroupId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -428,21 +400,22 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("RegisterInfo(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("RegisterInfo(");
boolean first = true;
sb.append("host:");
@@ -481,7 +454,7 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
__isset_bitfield = 0;
@@ -491,13 +464,13 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
}
}
- private static class RegisterInfoStandardSchemeFactory implements SchemeFactory {
+ private static class RegisterInfoStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public RegisterInfoStandardScheme getScheme() {
return new RegisterInfoStandardScheme();
}
}
- private static class RegisterInfoStandardScheme extends StandardScheme<RegisterInfo> {
+ private static class RegisterInfoStandardScheme extends org.apache.thrift.scheme.StandardScheme<RegisterInfo> {
public void read(org.apache.thrift.protocol.TProtocol iprot, RegisterInfo struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -567,18 +540,18 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
}
- private static class RegisterInfoTupleSchemeFactory implements SchemeFactory {
+ private static class RegisterInfoTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public RegisterInfoTupleScheme getScheme() {
return new RegisterInfoTupleScheme();
}
}
- private static class RegisterInfoTupleScheme extends TupleScheme<RegisterInfo> {
+ private static class RegisterInfoTupleScheme extends org.apache.thrift.scheme.TupleScheme<RegisterInfo> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, RegisterInfo struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetHost()) {
optionals.set(0);
}
@@ -602,8 +575,8 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, RegisterInfo struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(3);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.host = iprot.readString();
struct.setHostIsSet(true);
@@ -619,5 +592,8 @@ public class RegisterInfo implements org.apache.thrift.TBase<RegisterInfo, Regis
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteApplicationResult.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteApplicationResult.java
index 3cbbb3d..b38b2c4 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteApplicationResult.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteApplicationResult.java
@@ -16,66 +16,36 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteApplicationResult, RemoteApplicationResult._Fields>, java.io.Serializable, Cloneable, Comparable<RemoteApplicationResult> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("RemoteApplicationResult");
private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)1);
private static final org.apache.thrift.protocol.TField MSG_FIELD_DESC = new org.apache.thrift.protocol.TField("msg", org.apache.thrift.protocol.TType.STRING, (short)2);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new RemoteApplicationResultStandardSchemeFactory());
- schemes.put(TupleScheme.class, new RemoteApplicationResultTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new RemoteApplicationResultStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new RemoteApplicationResultTupleSchemeFactory();
public boolean success; // required
- public String msg; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String msg; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
SUCCESS((short)1, "success"),
MSG((short)2, "msg");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -83,6 +53,7 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // SUCCESS
@@ -100,21 +71,22 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -123,7 +95,7 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -131,14 +103,14 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
// isset id assignments
private static final int __SUCCESS_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
tmpMap.put(_Fields.MSG, new org.apache.thrift.meta_data.FieldMetaData("msg", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(RemoteApplicationResult.class, metaDataMap);
}
@@ -147,7 +119,7 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
public RemoteApplicationResult(
boolean success,
- String msg)
+ java.lang.String msg)
{
this();
this.success = success;
@@ -188,23 +160,24 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
}
public void unsetSuccess() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SUCCESS_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __SUCCESS_ISSET_ID);
}
/** Returns true if field success is set (has been assigned a value) and false otherwise */
public boolean isSetSuccess() {
- return EncodingUtils.testBit(__isset_bitfield, __SUCCESS_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __SUCCESS_ISSET_ID);
}
public void setSuccessIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value);
}
- public String getMsg() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getMsg() {
return this.msg;
}
- public RemoteApplicationResult setMsg(String msg) {
+ public RemoteApplicationResult setMsg(@org.apache.thrift.annotation.Nullable java.lang.String msg) {
this.msg = msg;
return this;
}
@@ -224,13 +197,13 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case SUCCESS:
if (value == null) {
unsetSuccess();
} else {
- setSuccess((Boolean)value);
+ setSuccess((java.lang.Boolean)value);
}
break;
@@ -238,29 +211,30 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
if (value == null) {
unsetMsg();
} else {
- setMsg((String)value);
+ setMsg((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case SUCCESS:
- return Boolean.valueOf(isSuccess());
+ return isSuccess();
case MSG:
return getMsg();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -269,11 +243,11 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
case MSG:
return isSetMsg();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof RemoteApplicationResult)
@@ -284,6 +258,8 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
public boolean equals(RemoteApplicationResult that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_success = true;
boolean that_present_success = true;
@@ -308,19 +284,15 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_success = true;
- list.add(present_success);
- if (present_success)
- list.add(success);
+ hashCode = hashCode * 8191 + ((success) ? 131071 : 524287);
- boolean present_msg = true && (isSetMsg());
- list.add(present_msg);
- if (present_msg)
- list.add(msg);
+ hashCode = hashCode * 8191 + ((isSetMsg()) ? 131071 : 524287);
+ if (isSetMsg())
+ hashCode = hashCode * 8191 + msg.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -331,7 +303,7 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess());
+ lastComparison = java.lang.Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess());
if (lastComparison != 0) {
return lastComparison;
}
@@ -341,7 +313,7 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMsg()).compareTo(other.isSetMsg());
+ lastComparison = java.lang.Boolean.valueOf(isSetMsg()).compareTo(other.isSetMsg());
if (lastComparison != 0) {
return lastComparison;
}
@@ -354,21 +326,22 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("RemoteApplicationResult(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("RemoteApplicationResult(");
boolean first = true;
sb.append("success:");
@@ -399,7 +372,7 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
__isset_bitfield = 0;
@@ -409,13 +382,13 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
}
}
- private static class RemoteApplicationResultStandardSchemeFactory implements SchemeFactory {
+ private static class RemoteApplicationResultStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public RemoteApplicationResultStandardScheme getScheme() {
return new RemoteApplicationResultStandardScheme();
}
}
- private static class RemoteApplicationResultStandardScheme extends StandardScheme<RemoteApplicationResult> {
+ private static class RemoteApplicationResultStandardScheme extends org.apache.thrift.scheme.StandardScheme<RemoteApplicationResult> {
public void read(org.apache.thrift.protocol.TProtocol iprot, RemoteApplicationResult struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -472,18 +445,18 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
}
- private static class RemoteApplicationResultTupleSchemeFactory implements SchemeFactory {
+ private static class RemoteApplicationResultTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public RemoteApplicationResultTupleScheme getScheme() {
return new RemoteApplicationResultTupleScheme();
}
}
- private static class RemoteApplicationResultTupleScheme extends TupleScheme<RemoteApplicationResult> {
+ private static class RemoteApplicationResultTupleScheme extends org.apache.thrift.scheme.TupleScheme<RemoteApplicationResult> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, RemoteApplicationResult struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetSuccess()) {
optionals.set(0);
}
@@ -501,8 +474,8 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, RemoteApplicationResult struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(2);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(2);
if (incoming.get(0)) {
struct.success = iprot.readBool();
struct.setSuccessIsSet(true);
@@ -514,5 +487,8 @@ public class RemoteApplicationResult implements org.apache.thrift.TBase<RemoteAp
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterContext.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterContext.java
index 4ff4896..ddc1d3c 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterContext.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterContext.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteInterpreterContext, RemoteInterpreterContext._Fields>, java.io.Serializable, Cloneable, Comparable<RemoteInterpreterContext> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("RemoteInterpreterContext");
@@ -67,23 +40,20 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
private static final org.apache.thrift.protocol.TField NOTE_GUI_FIELD_DESC = new org.apache.thrift.protocol.TField("noteGui", org.apache.thrift.protocol.TType.STRING, (short)10);
private static final org.apache.thrift.protocol.TField LOCAL_PROPERTIES_FIELD_DESC = new org.apache.thrift.protocol.TField("localProperties", org.apache.thrift.protocol.TType.MAP, (short)11);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new RemoteInterpreterContextStandardSchemeFactory());
- schemes.put(TupleScheme.class, new RemoteInterpreterContextTupleSchemeFactory());
- }
-
- public String noteId; // required
- public String noteName; // required
- public String paragraphId; // required
- public String replName; // required
- public String paragraphTitle; // required
- public String paragraphText; // required
- public String authenticationInfo; // required
- public String config; // required
- public String gui; // required
- public String noteGui; // required
- public Map<String,String> localProperties; // required
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new RemoteInterpreterContextStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new RemoteInterpreterContextTupleSchemeFactory();
+
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteName; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String replName; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphTitle; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String paragraphText; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String authenticationInfo; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String config; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String gui; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String noteGui; // required
+ public @org.apache.thrift.annotation.Nullable java.util.Map<java.lang.String,java.lang.String> localProperties; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -99,10 +69,10 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
NOTE_GUI((short)10, "noteGui"),
LOCAL_PROPERTIES((short)11, "localProperties");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -110,6 +80,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // NOTE_ID
@@ -145,21 +116,22 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -168,15 +140,15 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NOTE_ID, new org.apache.thrift.meta_data.FieldMetaData("noteId", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.NOTE_NAME, new org.apache.thrift.meta_data.FieldMetaData("noteName", org.apache.thrift.TFieldRequirementType.DEFAULT,
@@ -201,7 +173,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING),
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(RemoteInterpreterContext.class, metaDataMap);
}
@@ -209,17 +181,17 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
public RemoteInterpreterContext(
- String noteId,
- String noteName,
- String paragraphId,
- String replName,
- String paragraphTitle,
- String paragraphText,
- String authenticationInfo,
- String config,
- String gui,
- String noteGui,
- Map<String,String> localProperties)
+ java.lang.String noteId,
+ java.lang.String noteName,
+ java.lang.String paragraphId,
+ java.lang.String replName,
+ java.lang.String paragraphTitle,
+ java.lang.String paragraphText,
+ java.lang.String authenticationInfo,
+ java.lang.String config,
+ java.lang.String gui,
+ java.lang.String noteGui,
+ java.util.Map<java.lang.String,java.lang.String> localProperties)
{
this();
this.noteId = noteId;
@@ -270,7 +242,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
this.noteGui = other.noteGui;
}
if (other.isSetLocalProperties()) {
- Map<String,String> __this__localProperties = new HashMap<String,String>(other.localProperties);
+ java.util.Map<java.lang.String,java.lang.String> __this__localProperties = new java.util.HashMap<java.lang.String,java.lang.String>(other.localProperties);
this.localProperties = __this__localProperties;
}
}
@@ -294,11 +266,12 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
this.localProperties = null;
}
- public String getNoteId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteId() {
return this.noteId;
}
- public RemoteInterpreterContext setNoteId(String noteId) {
+ public RemoteInterpreterContext setNoteId(@org.apache.thrift.annotation.Nullable java.lang.String noteId) {
this.noteId = noteId;
return this;
}
@@ -318,11 +291,12 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- public String getNoteName() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteName() {
return this.noteName;
}
- public RemoteInterpreterContext setNoteName(String noteName) {
+ public RemoteInterpreterContext setNoteName(@org.apache.thrift.annotation.Nullable java.lang.String noteName) {
this.noteName = noteName;
return this;
}
@@ -342,11 +316,12 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- public String getParagraphId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphId() {
return this.paragraphId;
}
- public RemoteInterpreterContext setParagraphId(String paragraphId) {
+ public RemoteInterpreterContext setParagraphId(@org.apache.thrift.annotation.Nullable java.lang.String paragraphId) {
this.paragraphId = paragraphId;
return this;
}
@@ -366,11 +341,12 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- public String getReplName() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getReplName() {
return this.replName;
}
- public RemoteInterpreterContext setReplName(String replName) {
+ public RemoteInterpreterContext setReplName(@org.apache.thrift.annotation.Nullable java.lang.String replName) {
this.replName = replName;
return this;
}
@@ -390,11 +366,12 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- public String getParagraphTitle() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphTitle() {
return this.paragraphTitle;
}
- public RemoteInterpreterContext setParagraphTitle(String paragraphTitle) {
+ public RemoteInterpreterContext setParagraphTitle(@org.apache.thrift.annotation.Nullable java.lang.String paragraphTitle) {
this.paragraphTitle = paragraphTitle;
return this;
}
@@ -414,11 +391,12 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- public String getParagraphText() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getParagraphText() {
return this.paragraphText;
}
- public RemoteInterpreterContext setParagraphText(String paragraphText) {
+ public RemoteInterpreterContext setParagraphText(@org.apache.thrift.annotation.Nullable java.lang.String paragraphText) {
this.paragraphText = paragraphText;
return this;
}
@@ -438,11 +416,12 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- public String getAuthenticationInfo() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getAuthenticationInfo() {
return this.authenticationInfo;
}
- public RemoteInterpreterContext setAuthenticationInfo(String authenticationInfo) {
+ public RemoteInterpreterContext setAuthenticationInfo(@org.apache.thrift.annotation.Nullable java.lang.String authenticationInfo) {
this.authenticationInfo = authenticationInfo;
return this;
}
@@ -462,11 +441,12 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- public String getConfig() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getConfig() {
return this.config;
}
- public RemoteInterpreterContext setConfig(String config) {
+ public RemoteInterpreterContext setConfig(@org.apache.thrift.annotation.Nullable java.lang.String config) {
this.config = config;
return this;
}
@@ -486,11 +466,12 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- public String getGui() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getGui() {
return this.gui;
}
- public RemoteInterpreterContext setGui(String gui) {
+ public RemoteInterpreterContext setGui(@org.apache.thrift.annotation.Nullable java.lang.String gui) {
this.gui = gui;
return this;
}
@@ -510,11 +491,12 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- public String getNoteGui() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getNoteGui() {
return this.noteGui;
}
- public RemoteInterpreterContext setNoteGui(String noteGui) {
+ public RemoteInterpreterContext setNoteGui(@org.apache.thrift.annotation.Nullable java.lang.String noteGui) {
this.noteGui = noteGui;
return this;
}
@@ -538,18 +520,19 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return (this.localProperties == null) ? 0 : this.localProperties.size();
}
- public void putToLocalProperties(String key, String val) {
+ public void putToLocalProperties(java.lang.String key, java.lang.String val) {
if (this.localProperties == null) {
- this.localProperties = new HashMap<String,String>();
+ this.localProperties = new java.util.HashMap<java.lang.String,java.lang.String>();
}
this.localProperties.put(key, val);
}
- public Map<String,String> getLocalProperties() {
+ @org.apache.thrift.annotation.Nullable
+ public java.util.Map<java.lang.String,java.lang.String> getLocalProperties() {
return this.localProperties;
}
- public RemoteInterpreterContext setLocalProperties(Map<String,String> localProperties) {
+ public RemoteInterpreterContext setLocalProperties(@org.apache.thrift.annotation.Nullable java.util.Map<java.lang.String,java.lang.String> localProperties) {
this.localProperties = localProperties;
return this;
}
@@ -569,13 +552,13 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case NOTE_ID:
if (value == null) {
unsetNoteId();
} else {
- setNoteId((String)value);
+ setNoteId((java.lang.String)value);
}
break;
@@ -583,7 +566,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (value == null) {
unsetNoteName();
} else {
- setNoteName((String)value);
+ setNoteName((java.lang.String)value);
}
break;
@@ -591,7 +574,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (value == null) {
unsetParagraphId();
} else {
- setParagraphId((String)value);
+ setParagraphId((java.lang.String)value);
}
break;
@@ -599,7 +582,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (value == null) {
unsetReplName();
} else {
- setReplName((String)value);
+ setReplName((java.lang.String)value);
}
break;
@@ -607,7 +590,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (value == null) {
unsetParagraphTitle();
} else {
- setParagraphTitle((String)value);
+ setParagraphTitle((java.lang.String)value);
}
break;
@@ -615,7 +598,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (value == null) {
unsetParagraphText();
} else {
- setParagraphText((String)value);
+ setParagraphText((java.lang.String)value);
}
break;
@@ -623,7 +606,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (value == null) {
unsetAuthenticationInfo();
} else {
- setAuthenticationInfo((String)value);
+ setAuthenticationInfo((java.lang.String)value);
}
break;
@@ -631,7 +614,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (value == null) {
unsetConfig();
} else {
- setConfig((String)value);
+ setConfig((java.lang.String)value);
}
break;
@@ -639,7 +622,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (value == null) {
unsetGui();
} else {
- setGui((String)value);
+ setGui((java.lang.String)value);
}
break;
@@ -647,7 +630,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (value == null) {
unsetNoteGui();
} else {
- setNoteGui((String)value);
+ setNoteGui((java.lang.String)value);
}
break;
@@ -655,14 +638,15 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (value == null) {
unsetLocalProperties();
} else {
- setLocalProperties((Map<String,String>)value);
+ setLocalProperties((java.util.Map<java.lang.String,java.lang.String>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NOTE_ID:
return getNoteId();
@@ -698,13 +682,13 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return getLocalProperties();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -731,11 +715,11 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
case LOCAL_PROPERTIES:
return isSetLocalProperties();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof RemoteInterpreterContext)
@@ -746,6 +730,8 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
public boolean equals(RemoteInterpreterContext that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_noteId = true && this.isSetNoteId();
boolean that_present_noteId = true && that.isSetNoteId();
@@ -851,64 +837,53 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_noteId = true && (isSetNoteId());
- list.add(present_noteId);
- if (present_noteId)
- list.add(noteId);
-
- boolean present_noteName = true && (isSetNoteName());
- list.add(present_noteName);
- if (present_noteName)
- list.add(noteName);
-
- boolean present_paragraphId = true && (isSetParagraphId());
- list.add(present_paragraphId);
- if (present_paragraphId)
- list.add(paragraphId);
-
- boolean present_replName = true && (isSetReplName());
- list.add(present_replName);
- if (present_replName)
- list.add(replName);
-
- boolean present_paragraphTitle = true && (isSetParagraphTitle());
- list.add(present_paragraphTitle);
- if (present_paragraphTitle)
- list.add(paragraphTitle);
-
- boolean present_paragraphText = true && (isSetParagraphText());
- list.add(present_paragraphText);
- if (present_paragraphText)
- list.add(paragraphText);
-
- boolean present_authenticationInfo = true && (isSetAuthenticationInfo());
- list.add(present_authenticationInfo);
- if (present_authenticationInfo)
- list.add(authenticationInfo);
-
- boolean present_config = true && (isSetConfig());
- list.add(present_config);
- if (present_config)
- list.add(config);
-
- boolean present_gui = true && (isSetGui());
- list.add(present_gui);
- if (present_gui)
- list.add(gui);
-
- boolean present_noteGui = true && (isSetNoteGui());
- list.add(present_noteGui);
- if (present_noteGui)
- list.add(noteGui);
-
- boolean present_localProperties = true && (isSetLocalProperties());
- list.add(present_localProperties);
- if (present_localProperties)
- list.add(localProperties);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetNoteId()) ? 131071 : 524287);
+ if (isSetNoteId())
+ hashCode = hashCode * 8191 + noteId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetNoteName()) ? 131071 : 524287);
+ if (isSetNoteName())
+ hashCode = hashCode * 8191 + noteName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetParagraphId()) ? 131071 : 524287);
+ if (isSetParagraphId())
+ hashCode = hashCode * 8191 + paragraphId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetReplName()) ? 131071 : 524287);
+ if (isSetReplName())
+ hashCode = hashCode * 8191 + replName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetParagraphTitle()) ? 131071 : 524287);
+ if (isSetParagraphTitle())
+ hashCode = hashCode * 8191 + paragraphTitle.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetParagraphText()) ? 131071 : 524287);
+ if (isSetParagraphText())
+ hashCode = hashCode * 8191 + paragraphText.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetAuthenticationInfo()) ? 131071 : 524287);
+ if (isSetAuthenticationInfo())
+ hashCode = hashCode * 8191 + authenticationInfo.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetConfig()) ? 131071 : 524287);
+ if (isSetConfig())
+ hashCode = hashCode * 8191 + config.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetGui()) ? 131071 : 524287);
+ if (isSetGui())
+ hashCode = hashCode * 8191 + gui.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetNoteGui()) ? 131071 : 524287);
+ if (isSetNoteGui())
+ hashCode = hashCode * 8191 + noteGui.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetLocalProperties()) ? 131071 : 524287);
+ if (isSetLocalProperties())
+ hashCode = hashCode * 8191 + localProperties.hashCode();
+
+ return hashCode;
}
@Override
@@ -919,7 +894,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteId()).compareTo(other.isSetNoteId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -929,7 +904,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetNoteName()).compareTo(other.isSetNoteName());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteName()).compareTo(other.isSetNoteName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -939,7 +914,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphId()).compareTo(other.isSetParagraphId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -949,7 +924,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReplName()).compareTo(other.isSetReplName());
+ lastComparison = java.lang.Boolean.valueOf(isSetReplName()).compareTo(other.isSetReplName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -959,7 +934,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphTitle()).compareTo(other.isSetParagraphTitle());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphTitle()).compareTo(other.isSetParagraphTitle());
if (lastComparison != 0) {
return lastComparison;
}
@@ -969,7 +944,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParagraphText()).compareTo(other.isSetParagraphText());
+ lastComparison = java.lang.Boolean.valueOf(isSetParagraphText()).compareTo(other.isSetParagraphText());
if (lastComparison != 0) {
return lastComparison;
}
@@ -979,7 +954,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAuthenticationInfo()).compareTo(other.isSetAuthenticationInfo());
+ lastComparison = java.lang.Boolean.valueOf(isSetAuthenticationInfo()).compareTo(other.isSetAuthenticationInfo());
if (lastComparison != 0) {
return lastComparison;
}
@@ -989,7 +964,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetConfig()).compareTo(other.isSetConfig());
+ lastComparison = java.lang.Boolean.valueOf(isSetConfig()).compareTo(other.isSetConfig());
if (lastComparison != 0) {
return lastComparison;
}
@@ -999,7 +974,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGui()).compareTo(other.isSetGui());
+ lastComparison = java.lang.Boolean.valueOf(isSetGui()).compareTo(other.isSetGui());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1009,7 +984,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetNoteGui()).compareTo(other.isSetNoteGui());
+ lastComparison = java.lang.Boolean.valueOf(isSetNoteGui()).compareTo(other.isSetNoteGui());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1019,7 +994,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLocalProperties()).compareTo(other.isSetLocalProperties());
+ lastComparison = java.lang.Boolean.valueOf(isSetLocalProperties()).compareTo(other.isSetLocalProperties());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1032,21 +1007,22 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("RemoteInterpreterContext(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("RemoteInterpreterContext(");
boolean first = true;
sb.append("noteId:");
@@ -1153,7 +1129,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -1161,13 +1137,13 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
- private static class RemoteInterpreterContextStandardSchemeFactory implements SchemeFactory {
+ private static class RemoteInterpreterContextStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public RemoteInterpreterContextStandardScheme getScheme() {
return new RemoteInterpreterContextStandardScheme();
}
}
- private static class RemoteInterpreterContextStandardScheme extends StandardScheme<RemoteInterpreterContext> {
+ private static class RemoteInterpreterContextStandardScheme extends org.apache.thrift.scheme.StandardScheme<RemoteInterpreterContext> {
public void read(org.apache.thrift.protocol.TProtocol iprot, RemoteInterpreterContext struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1263,9 +1239,9 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (schemeField.type == org.apache.thrift.protocol.TType.MAP) {
{
org.apache.thrift.protocol.TMap _map0 = iprot.readMapBegin();
- struct.localProperties = new HashMap<String,String>(2*_map0.size);
- String _key1;
- String _val2;
+ struct.localProperties = new java.util.HashMap<java.lang.String,java.lang.String>(2*_map0.size);
+ @org.apache.thrift.annotation.Nullable java.lang.String _key1;
+ @org.apache.thrift.annotation.Nullable java.lang.String _val2;
for (int _i3 = 0; _i3 < _map0.size; ++_i3)
{
_key1 = iprot.readString();
@@ -1348,7 +1324,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
oprot.writeFieldBegin(LOCAL_PROPERTIES_FIELD_DESC);
{
oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.localProperties.size()));
- for (Map.Entry<String, String> _iter4 : struct.localProperties.entrySet())
+ for (java.util.Map.Entry<java.lang.String, java.lang.String> _iter4 : struct.localProperties.entrySet())
{
oprot.writeString(_iter4.getKey());
oprot.writeString(_iter4.getValue());
@@ -1363,18 +1339,18 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
- private static class RemoteInterpreterContextTupleSchemeFactory implements SchemeFactory {
+ private static class RemoteInterpreterContextTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public RemoteInterpreterContextTupleScheme getScheme() {
return new RemoteInterpreterContextTupleScheme();
}
}
- private static class RemoteInterpreterContextTupleScheme extends TupleScheme<RemoteInterpreterContext> {
+ private static class RemoteInterpreterContextTupleScheme extends org.apache.thrift.scheme.TupleScheme<RemoteInterpreterContext> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, RemoteInterpreterContext struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetNoteId()) {
optionals.set(0);
}
@@ -1442,7 +1418,7 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (struct.isSetLocalProperties()) {
{
oprot.writeI32(struct.localProperties.size());
- for (Map.Entry<String, String> _iter5 : struct.localProperties.entrySet())
+ for (java.util.Map.Entry<java.lang.String, java.lang.String> _iter5 : struct.localProperties.entrySet())
{
oprot.writeString(_iter5.getKey());
oprot.writeString(_iter5.getValue());
@@ -1453,8 +1429,8 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, RemoteInterpreterContext struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(11);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(11);
if (incoming.get(0)) {
struct.noteId = iprot.readString();
struct.setNoteIdIsSet(true);
@@ -1498,9 +1474,9 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
if (incoming.get(10)) {
{
org.apache.thrift.protocol.TMap _map6 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.localProperties = new HashMap<String,String>(2*_map6.size);
- String _key7;
- String _val8;
+ struct.localProperties = new java.util.HashMap<java.lang.String,java.lang.String>(2*_map6.size);
+ @org.apache.thrift.annotation.Nullable java.lang.String _key7;
+ @org.apache.thrift.annotation.Nullable java.lang.String _val8;
for (int _i9 = 0; _i9 < _map6.size; ++_i9)
{
_key7 = iprot.readString();
@@ -1513,5 +1489,8 @@ public class RemoteInterpreterContext implements org.apache.thrift.TBase<RemoteI
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterEvent.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterEvent.java
index 0fa6465..6fd85d5 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterEvent.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterEvent.java
@@ -16,60 +16,30 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInterpreterEvent, RemoteInterpreterEvent._Fields>, java.io.Serializable, Cloneable, Comparable<RemoteInterpreterEvent> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("RemoteInterpreterEvent");
private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.I32, (short)1);
private static final org.apache.thrift.protocol.TField DATA_FIELD_DESC = new org.apache.thrift.protocol.TField("data", org.apache.thrift.protocol.TType.STRING, (short)2);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new RemoteInterpreterEventStandardSchemeFactory());
- schemes.put(TupleScheme.class, new RemoteInterpreterEventTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new RemoteInterpreterEventStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new RemoteInterpreterEventTupleSchemeFactory();
/**
*
* @see RemoteInterpreterEventType
*/
- public RemoteInterpreterEventType type; // required
- public String data; // required
+ public @org.apache.thrift.annotation.Nullable RemoteInterpreterEventType type; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String data; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -80,10 +50,10 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
TYPE((short)1, "type"),
DATA((short)2, "data");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -91,6 +61,7 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // TYPE
@@ -108,21 +79,22 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -131,20 +103,20 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, RemoteInterpreterEventType.class)));
tmpMap.put(_Fields.DATA, new org.apache.thrift.meta_data.FieldMetaData("data", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(RemoteInterpreterEvent.class, metaDataMap);
}
@@ -153,7 +125,7 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
public RemoteInterpreterEvent(
RemoteInterpreterEventType type,
- String data)
+ java.lang.String data)
{
this();
this.type = type;
@@ -186,6 +158,7 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
*
* @see RemoteInterpreterEventType
*/
+ @org.apache.thrift.annotation.Nullable
public RemoteInterpreterEventType getType() {
return this.type;
}
@@ -194,7 +167,7 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
*
* @see RemoteInterpreterEventType
*/
- public RemoteInterpreterEvent setType(RemoteInterpreterEventType type) {
+ public RemoteInterpreterEvent setType(@org.apache.thrift.annotation.Nullable RemoteInterpreterEventType type) {
this.type = type;
return this;
}
@@ -214,11 +187,12 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
}
}
- public String getData() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getData() {
return this.data;
}
- public RemoteInterpreterEvent setData(String data) {
+ public RemoteInterpreterEvent setData(@org.apache.thrift.annotation.Nullable java.lang.String data) {
this.data = data;
return this;
}
@@ -238,7 +212,7 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case TYPE:
if (value == null) {
@@ -252,14 +226,15 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
if (value == null) {
unsetData();
} else {
- setData((String)value);
+ setData((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case TYPE:
return getType();
@@ -268,13 +243,13 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
return getData();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -283,11 +258,11 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
case DATA:
return isSetData();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof RemoteInterpreterEvent)
@@ -298,6 +273,8 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
public boolean equals(RemoteInterpreterEvent that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_type = true && this.isSetType();
boolean that_present_type = true && that.isSetType();
@@ -322,19 +299,17 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_type = true && (isSetType());
- list.add(present_type);
- if (present_type)
- list.add(type.getValue());
+ hashCode = hashCode * 8191 + ((isSetType()) ? 131071 : 524287);
+ if (isSetType())
+ hashCode = hashCode * 8191 + type.getValue();
- boolean present_data = true && (isSetData());
- list.add(present_data);
- if (present_data)
- list.add(data);
+ hashCode = hashCode * 8191 + ((isSetData()) ? 131071 : 524287);
+ if (isSetData())
+ hashCode = hashCode * 8191 + data.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -345,7 +320,7 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetType()).compareTo(other.isSetType());
+ lastComparison = java.lang.Boolean.valueOf(isSetType()).compareTo(other.isSetType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -355,7 +330,7 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetData()).compareTo(other.isSetData());
+ lastComparison = java.lang.Boolean.valueOf(isSetData()).compareTo(other.isSetData());
if (lastComparison != 0) {
return lastComparison;
}
@@ -368,21 +343,22 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("RemoteInterpreterEvent(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("RemoteInterpreterEvent(");
boolean first = true;
sb.append("type:");
@@ -417,7 +393,7 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -425,13 +401,13 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
}
}
- private static class RemoteInterpreterEventStandardSchemeFactory implements SchemeFactory {
+ private static class RemoteInterpreterEventStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public RemoteInterpreterEventStandardScheme getScheme() {
return new RemoteInterpreterEventStandardScheme();
}
}
- private static class RemoteInterpreterEventStandardScheme extends StandardScheme<RemoteInterpreterEvent> {
+ private static class RemoteInterpreterEventStandardScheme extends org.apache.thrift.scheme.StandardScheme<RemoteInterpreterEvent> {
public void read(org.apache.thrift.protocol.TProtocol iprot, RemoteInterpreterEvent struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -490,18 +466,18 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
}
- private static class RemoteInterpreterEventTupleSchemeFactory implements SchemeFactory {
+ private static class RemoteInterpreterEventTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public RemoteInterpreterEventTupleScheme getScheme() {
return new RemoteInterpreterEventTupleScheme();
}
}
- private static class RemoteInterpreterEventTupleScheme extends TupleScheme<RemoteInterpreterEvent> {
+ private static class RemoteInterpreterEventTupleScheme extends org.apache.thrift.scheme.TupleScheme<RemoteInterpreterEvent> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, RemoteInterpreterEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetType()) {
optionals.set(0);
}
@@ -519,8 +495,8 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, RemoteInterpreterEvent struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(2);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(2);
if (incoming.get(0)) {
struct.type = org.apache.zeppelin.interpreter.thrift.RemoteInterpreterEventType.findByValue(iprot.readI32());
struct.setTypeIsSet(true);
@@ -532,5 +508,8 @@ public class RemoteInterpreterEvent implements org.apache.thrift.TBase<RemoteInt
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterEventService.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterEventService.java
index 4bbc8f7..8ef1033 100644
--- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterEventService.java
+++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/thrift/RemoteInterpreterEventService.java
@@ -16,42 +16,15 @@
* limitations under the License.
*/
/**
- * Autogenerated by Thrift Compiler (0.9.2)
+ * Autogenerated by Thrift Compiler (0.12.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.zeppelin.interpreter.thrift;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-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;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-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 = "2019-3-4")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.12.0)", date = "2019-06-10")
public class RemoteInterpreterEventService {
public interface Iface {
@@ -72,57 +45,57 @@ public class RemoteInterpreterEventService {
public void runParagraphs(RunParagraphsEvent event) throws org.apache.thrift.TException;
- public void addAngularObject(String intpGroupId, String json) throws org.apache.thrift.TException;
+ public void addAngularObject(java.lang.String intpGroupId, java.lang.String json) throws org.apache.thrift.TException;
- public void updateAngularObject(String intpGroupId, String json) throws org.apache.thrift.TException;
+ public void updateAngularObject(java.lang.String intpGroupId, java.lang.String json) throws org.apache.thrift.TException;
- public void removeAngularObject(String intpGroupId, String noteId, String paragraphId, String name) throws org.apache.thrift.TException;
+ public void removeAngularObject(java.lang.String intpGroupId, java.lang.String noteId, java.lang.String paragraphId, java.lang.String name) throws org.apache.thrift.TException;
- public void sendParagraphInfo(String intpGroupId, String json) throws org.apache.thrift.TException;
+ public void sendParagraphInfo(java.lang.String intpGroupId, java.lang.String json) throws org.apache.thrift.TException;
- public List<String> getAllResources(String intpGroupId) throws org.apache.thrift.TException;
+ public java.util.List<java.lang.String> getAllResources(java.lang.String intpGroupId) throws org.apache.thrift.TException;
- public ByteBuffer getResource(String resourceIdJson) throws org.apache.thrift.TException;
+ public java.nio.ByteBuffer getResource(java.lang.String resourceIdJson) throws org.apache.thrift.TException;
- public ByteBuffer invokeMethod(String intpGroupId, String invokeMethodJson) throws org.apache.thrift.TException;
+ public java.nio.ByteBuffer invokeMethod(java.lang.String intpGroupId, java.lang.String invokeMethodJson) throws org.apache.thrift.TException;
- public List<ParagraphInfo> getParagraphList(String user, String noteId) throws ServiceException, org.apache.thrift.TException;
+ public java.util.List<ParagraphInfo> getParagraphList(java.lang.String user, java.lang.String noteId) throws ServiceException, org.apache.thrift.TException;
}
public interface AsyncIface {
- public void registerInterpreterProcess(RegisterInfo registerInfo, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void registerInterpreterProcess(RegisterInfo registerInfo, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void appendOutput(OutputAppendEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void appendOutput(OutputAppendEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void updateOutput(OutputUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void updateOutput(OutputUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void updateAllOutput(OutputUpdateAllEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void updateAllOutput(OutputUpdateAllEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void appendAppOutput(AppOutputAppendEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void appendAppOutput(AppOutputAppendEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void updateAppOutput(AppOutputUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void updateAppOutput(AppOutputUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void updateAppStatus(AppStatusUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void updateAppStatus(AppStatusUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void runParagraphs(RunParagraphsEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void runParagraphs(RunParagraphsEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void addAngularObject(String intpGroupId, String json, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void addAngularObject(java.lang.String intpGroupId, java.lang.String json, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void updateAngularObject(String intpGroupId, String json, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void updateAngularObject(java.lang.String intpGroupId, java.lang.String json, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void removeAngularObject(String intpGroupId, String noteId, String paragraphId, String name, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void removeAngularObject(java.lang.String intpGroupId, java.lang.String noteId, java.lang.String paragraphId, java.lang.String name, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void sendParagraphInfo(String intpGroupId, String json, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void sendParagraphInfo(java.lang.String intpGroupId, java.lang.String json, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException;
- public void getAllResources(String intpGroupId, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void getAllResources(java.lang.String intpGroupId, org.apache.thrift.async.AsyncMethodCallback<java.util.List<java.lang.String>> resultHandler) throws org.apache.thrift.TException;
- public void getResource(String resourceIdJson, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void getResource(java.lang.String resourceIdJson, org.apache.thrift.async.AsyncMethodCallback<java.nio.ByteBuffer> resultHandler) throws org.apache.thrift.TException;
- public void invokeMethod(String intpGroupId, String invokeMethodJson, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void invokeMethod(java.lang.String intpGroupId, java.lang.String invokeMethodJson, org.apache.thrift.async.AsyncMethodCallback<java.nio.ByteBuffer> resultHandler) throws org.apache.thrift.TException;
- public void getParagraphList(String user, String noteId, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
+ public void getParagraphList(java.lang.String user, java.lang.String noteId, org.apache.thrift.async.AsyncMethodCallback<java.util.List<ParagraphInfo>> resultHandler) throws org.apache.thrift.TException;
}
@@ -306,13 +279,13 @@ public class RemoteInterpreterEventService {
return;
}
- public void addAngularObject(String intpGroupId, String json) throws org.apache.thrift.TException
+ public void addAngularObject(java.lang.String intpGroupId, java.lang.String json) throws org.apache.thrift.TException
{
send_addAngularObject(intpGroupId, json);
recv_addAngularObject();
}
- public void send_addAngularObject(String intpGroupId, String json) throws org.apache.thrift.TException
+ public void send_addAngularObject(java.lang.String intpGroupId, java.lang.String json) throws org.apache.thrift.TException
{
addAngularObject_args args = new addAngularObject_args();
args.setIntpGroupId(intpGroupId);
@@ -327,13 +300,13 @@ public class RemoteInterpreterEventService {
return;
}
- public void updateAngularObject(String intpGroupId, String json) throws org.apache.thrift.TException
+ public void updateAngularObject(java.lang.String intpGroupId, java.lang.String json) throws org.apache.thrift.TException
{
send_updateAngularObject(intpGroupId, json);
recv_updateAngularObject();
}
- public void send_updateAngularObject(String intpGroupId, String json) throws org.apache.thrift.TException
+ public void send_updateAngularObject(java.lang.String intpGroupId, java.lang.String json) throws org.apache.thrift.TException
{
updateAngularObject_args args = new updateAngularObject_args();
args.setIntpGroupId(intpGroupId);
@@ -348,13 +321,13 @@ public class RemoteInterpreterEventService {
return;
}
- public void removeAngularObject(String intpGroupId, String noteId, String paragraphId, String name) throws org.apache.thrift.TException
+ public void removeAngularObject(java.lang.String intpGroupId, java.lang.String noteId, java.lang.String paragraphId, java.lang.String name) throws org.apache.thrift.TException
{
send_removeAngularObject(intpGroupId, noteId, paragraphId, name);
recv_removeAngularObject();
}
- public void send_removeAngularObject(String intpGroupId, String noteId, String paragraphId, String name) throws org.apache.thrift.TException
+ public void send_removeAngularObject(java.lang.String intpGroupId, java.lang.String noteId, java.lang.String paragraphId, java.lang.String name) throws org.apache.thrift.TException
{
removeAngularObject_args args = new removeAngularObject_args();
args.setIntpGroupId(intpGroupId);
@@ -371,13 +344,13 @@ public class RemoteInterpreterEventService {
return;
}
- public void sendParagraphInfo(String intpGroupId, String json) throws org.apache.thrift.TException
+ public void sendParagraphInfo(java.lang.String intpGroupId, java.lang.String json) throws org.apache.thrift.TException
{
send_sendParagraphInfo(intpGroupId, json);
recv_sendParagraphInfo();
}
- public void send_sendParagraphInfo(String intpGroupId, String json) throws org.apache.thrift.TException
+ public void send_sendParagraphInfo(java.lang.String intpGroupId, java.lang.String json) throws org.apache.thrift.TException
{
sendParagraphInfo_args args = new sendParagraphInfo_args();
args.setIntpGroupId(intpGroupId);
@@ -392,20 +365,20 @@ public class RemoteInterpreterEventService {
return;
}
- public List<String> getAllResources(String intpGroupId) throws org.apache.thrift.TException
+ public java.util.List<java.lang.String> getAllResources(java.lang.String intpGroupId) throws org.apache.thrift.TException
{
send_getAllResources(intpGroupId);
return recv_getAllResources();
}
- public void send_getAllResources(String intpGroupId) throws org.apache.thrift.TException
+ public void send_getAllResources(java.lang.String intpGroupId) throws org.apache.thrift.TException
{
getAllResources_args args = new getAllResources_args();
args.setIntpGroupId(intpGroupId);
sendBase("getAllResources", args);
}
- public List<String> recv_getAllResources() throws org.apache.thrift.TException
+ public java.util.List<java.lang.String> recv_getAllResources() throws org.apache.thrift.TException
{
getAllResources_result result = new getAllResources_result();
receiveBase(result, "getAllResources");
@@ -415,20 +388,20 @@ public class RemoteInterpreterEventService {
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllResources failed: unknown result");
}
- public ByteBuffer getResource(String resourceIdJson) throws org.apache.thrift.TException
+ public java.nio.ByteBuffer getResource(java.lang.String resourceIdJson) throws org.apache.thrift.TException
{
send_getResource(resourceIdJson);
return recv_getResource();
}
- public void send_getResource(String resourceIdJson) throws org.apache.thrift.TException
+ public void send_getResource(java.lang.String resourceIdJson) throws org.apache.thrift.TException
{
getResource_args args = new getResource_args();
args.setResourceIdJson(resourceIdJson);
sendBase("getResource", args);
}
- public ByteBuffer recv_getResource() throws org.apache.thrift.TException
+ public java.nio.ByteBuffer recv_getResource() throws org.apache.thrift.TException
{
getResource_result result = new getResource_result();
receiveBase(result, "getResource");
@@ -438,13 +411,13 @@ public class RemoteInterpreterEventService {
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getResource failed: unknown result");
}
- public ByteBuffer invokeMethod(String intpGroupId, String invokeMethodJson) throws org.apache.thrift.TException
+ public java.nio.ByteBuffer invokeMethod(java.lang.String intpGroupId, java.lang.String invokeMethodJson) throws org.apache.thrift.TException
{
send_invokeMethod(intpGroupId, invokeMethodJson);
return recv_invokeMethod();
}
- public void send_invokeMethod(String intpGroupId, String invokeMethodJson) throws org.apache.thrift.TException
+ public void send_invokeMethod(java.lang.String intpGroupId, java.lang.String invokeMethodJson) throws org.apache.thrift.TException
{
invokeMethod_args args = new invokeMethod_args();
args.setIntpGroupId(intpGroupId);
@@ -452,7 +425,7 @@ public class RemoteInterpreterEventService {
sendBase("invokeMethod", args);
}
- public ByteBuffer recv_invokeMethod() throws org.apache.thrift.TException
+ public java.nio.ByteBuffer recv_invokeMethod() throws org.apache.thrift.TException
{
invokeMethod_result result = new invokeMethod_result();
receiveBase(result, "invokeMethod");
@@ -462,13 +435,13 @@ public class RemoteInterpreterEventService {
throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "invokeMethod failed: unknown result");
}
- public List<ParagraphInfo> getParagraphList(String user, String noteId) throws ServiceException, org.apache.thrift.TException
+ public java.util.List<ParagraphInfo> getParagraphList(java.lang.String user, java.lang.String noteId) throws ServiceException, org.apache.thrift.TException
{
send_getParagraphList(user, noteId);
return recv_getParagraphList();
}
- public void send_getParagraphList(String user, String noteId) throws org.apache.thrift.TException
+ public void send_getParagraphList(java.lang.String user, java.lang.String noteId) throws org.apache.thrift.TException
{
getParagraphList_args args = new getParagraphList_args();
args.setUser(user);
@@ -476,7 +449,7 @@ public class RemoteInterpreterEventService {
sendBase("getParagraphList", args);
}
- public List<ParagraphInfo> recv_getParagraphList() throws ServiceException, org.apache.thrift.TException
+ public java.util.List<ParagraphInfo> recv_getParagraphList() throws ServiceException, org.apache.thrift.TException
{
getParagraphList_result result = new getParagraphList_result();
receiveBase(result, "getParagraphList");
@@ -507,16 +480,16 @@ public class RemoteInterpreterEventService {
super(protocolFactory, clientManager, transport);
}
- public void registerInterpreterProcess(RegisterInfo registerInfo, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void registerInterpreterProcess(RegisterInfo registerInfo, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
registerInterpreterProcess_call method_call = new registerInterpreterProcess_call(registerInfo, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class registerInterpreterProcess_call extends org.apache.thrift.async.TAsyncMethodCall {
+ public static class registerInterpreterProcess_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
private RegisterInfo registerInfo;
- public registerInterpreterProcess_call(RegisterInfo registerInfo, 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 {
+ public registerInterpreterProcess_call(RegisterInfo registerInfo, org.apache.thrift.async.AsyncMethodCallback<Void> 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.registerInfo = registerInfo;
}
@@ -529,26 +502,26 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_registerInterpreterProcess();
+ return null;
}
}
- public void appendOutput(OutputAppendEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void appendOutput(OutputAppendEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
appendOutput_call method_call = new appendOutput_call(event, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class appendOutput_call extends org.apache.thrift.async.TAsyncMethodCall {
+ public static class appendOutput_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
private OutputAppendEvent event;
- public appendOutput_call(OutputAppendEvent event, 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 {
+ public appendOutput_call(OutputAppendEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> 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.event = event;
}
@@ -561,26 +534,26 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_appendOutput();
+ return null;
}
}
- public void updateOutput(OutputUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void updateOutput(OutputUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
updateOutput_call method_call = new updateOutput_call(event, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class updateOutput_call extends org.apache.thrift.async.TAsyncMethodCall {
+ public static class updateOutput_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
private OutputUpdateEvent event;
- public updateOutput_call(OutputUpdateEvent event, 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 {
+ public updateOutput_call(OutputUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> 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.event = event;
}
@@ -593,26 +566,26 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_updateOutput();
+ return null;
}
}
- public void updateAllOutput(OutputUpdateAllEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void updateAllOutput(OutputUpdateAllEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
updateAllOutput_call method_call = new updateAllOutput_call(event, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class updateAllOutput_call extends org.apache.thrift.async.TAsyncMethodCall {
+ public static class updateAllOutput_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
private OutputUpdateAllEvent event;
- public updateAllOutput_call(OutputUpdateAllEvent event, 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 {
+ public updateAllOutput_call(OutputUpdateAllEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> 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.event = event;
}
@@ -625,26 +598,26 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_updateAllOutput();
+ return null;
}
}
- public void appendAppOutput(AppOutputAppendEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void appendAppOutput(AppOutputAppendEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
appendAppOutput_call method_call = new appendAppOutput_call(event, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class appendAppOutput_call extends org.apache.thrift.async.TAsyncMethodCall {
+ public static class appendAppOutput_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
private AppOutputAppendEvent event;
- public appendAppOutput_call(AppOutputAppendEvent event, 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 {
+ public appendAppOutput_call(AppOutputAppendEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> 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.event = event;
}
@@ -657,26 +630,26 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_appendAppOutput();
+ return null;
}
}
- public void updateAppOutput(AppOutputUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void updateAppOutput(AppOutputUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
updateAppOutput_call method_call = new updateAppOutput_call(event, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class updateAppOutput_call extends org.apache.thrift.async.TAsyncMethodCall {
+ public static class updateAppOutput_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
private AppOutputUpdateEvent event;
- public updateAppOutput_call(AppOutputUpdateEvent event, 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 {
+ public updateAppOutput_call(AppOutputUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> 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.event = event;
}
@@ -689,26 +662,26 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_updateAppOutput();
+ return null;
}
}
- public void updateAppStatus(AppStatusUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void updateAppStatus(AppStatusUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
updateAppStatus_call method_call = new updateAppStatus_call(event, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class updateAppStatus_call extends org.apache.thrift.async.TAsyncMethodCall {
+ public static class updateAppStatus_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
private AppStatusUpdateEvent event;
- public updateAppStatus_call(AppStatusUpdateEvent event, 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 {
+ public updateAppStatus_call(AppStatusUpdateEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> 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.event = event;
}
@@ -721,26 +694,26 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_updateAppStatus();
+ return null;
}
}
- public void runParagraphs(RunParagraphsEvent event, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void runParagraphs(RunParagraphsEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
runParagraphs_call method_call = new runParagraphs_call(event, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class runParagraphs_call extends org.apache.thrift.async.TAsyncMethodCall {
+ public static class runParagraphs_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
private RunParagraphsEvent event;
- public runParagraphs_call(RunParagraphsEvent event, 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 {
+ public runParagraphs_call(RunParagraphsEvent event, org.apache.thrift.async.AsyncMethodCallback<Void> 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.event = event;
}
@@ -753,27 +726,27 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_runParagraphs();
+ return null;
}
}
- public void addAngularObject(String intpGroupId, String json, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void addAngularObject(java.lang.String intpGroupId, java.lang.String json, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
addAngularObject_call method_call = new addAngularObject_call(intpGroupId, json, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class addAngularObject_call extends org.apache.thrift.async.TAsyncMethodCall {
- private String intpGroupId;
- private String json;
- public addAngularObject_call(String intpGroupId, String json, 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 {
+ public static class addAngularObject_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
+ private java.lang.String intpGroupId;
+ private java.lang.String json;
+ public addAngularObject_call(java.lang.String intpGroupId, java.lang.String json, org.apache.thrift.async.AsyncMethodCallback<Void> 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.intpGroupId = intpGroupId;
this.json = json;
@@ -788,27 +761,27 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_addAngularObject();
+ return null;
}
}
- public void updateAngularObject(String intpGroupId, String json, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void updateAngularObject(java.lang.String intpGroupId, java.lang.String json, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
updateAngularObject_call method_call = new updateAngularObject_call(intpGroupId, json, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class updateAngularObject_call extends org.apache.thrift.async.TAsyncMethodCall {
- private String intpGroupId;
- private String json;
- public updateAngularObject_call(String intpGroupId, String json, 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 {
+ public static class updateAngularObject_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
+ private java.lang.String intpGroupId;
+ private java.lang.String json;
+ public updateAngularObject_call(java.lang.String intpGroupId, java.lang.String json, org.apache.thrift.async.AsyncMethodCallback<Void> 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.intpGroupId = intpGroupId;
this.json = json;
@@ -823,29 +796,29 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_updateAngularObject();
+ return null;
}
}
- public void removeAngularObject(String intpGroupId, String noteId, String paragraphId, String name, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void removeAngularObject(java.lang.String intpGroupId, java.lang.String noteId, java.lang.String paragraphId, java.lang.String name, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
removeAngularObject_call method_call = new removeAngularObject_call(intpGroupId, noteId, paragraphId, name, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class removeAngularObject_call extends org.apache.thrift.async.TAsyncMethodCall {
- private String intpGroupId;
- private String noteId;
- private String paragraphId;
- private String name;
- public removeAngularObject_call(String intpGroupId, String noteId, String paragraphId, String name, 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 {
+ public static class removeAngularObject_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
+ private java.lang.String intpGroupId;
+ private java.lang.String noteId;
+ private java.lang.String paragraphId;
+ private java.lang.String name;
+ public removeAngularObject_call(java.lang.String intpGroupId, java.lang.String noteId, java.lang.String paragraphId, java.lang.String name, org.apache.thrift.async.AsyncMethodCallback<Void> 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.intpGroupId = intpGroupId;
this.noteId = noteId;
@@ -864,27 +837,27 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_removeAngularObject();
+ return null;
}
}
- public void sendParagraphInfo(String intpGroupId, String json, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void sendParagraphInfo(java.lang.String intpGroupId, java.lang.String json, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
checkReady();
sendParagraphInfo_call method_call = new sendParagraphInfo_call(intpGroupId, json, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class sendParagraphInfo_call extends org.apache.thrift.async.TAsyncMethodCall {
- private String intpGroupId;
- private String json;
- public sendParagraphInfo_call(String intpGroupId, String json, 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 {
+ public static class sendParagraphInfo_call extends org.apache.thrift.async.TAsyncMethodCall<Void> {
+ private java.lang.String intpGroupId;
+ private java.lang.String json;
+ public sendParagraphInfo_call(java.lang.String intpGroupId, java.lang.String json, org.apache.thrift.async.AsyncMethodCallback<Void> 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.intpGroupId = intpGroupId;
this.json = json;
@@ -899,26 +872,26 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public void getResult() throws org.apache.thrift.TException {
+ public Void getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
- (new Client(prot)).recv_sendParagraphInfo();
+ return null;
}
}
- public void getAllResources(String intpGroupId, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void getAllResources(java.lang.String intpGroupId, org.apache.thrift.async.AsyncMethodCallback<java.util.List<java.lang.String>> resultHandler) throws org.apache.thrift.TException {
checkReady();
getAllResources_call method_call = new getAllResources_call(intpGroupId, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class getAllResources_call extends org.apache.thrift.async.TAsyncMethodCall {
- private String intpGroupId;
- public getAllResources_call(String intpGroupId, 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 {
+ public static class getAllResources_call extends org.apache.thrift.async.TAsyncMethodCall<java.util.List<java.lang.String>> {
+ private java.lang.String intpGroupId;
+ public getAllResources_call(java.lang.String intpGroupId, org.apache.thrift.async.AsyncMethodCallback<java.util.List<java.lang.String>> 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.intpGroupId = intpGroupId;
}
@@ -931,9 +904,9 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public List<String> getResult() throws org.apache.thrift.TException {
+ public java.util.List<java.lang.String> getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
@@ -941,16 +914,16 @@ public class RemoteInterpreterEventService {
}
}
- public void getResource(String resourceIdJson, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void getResource(java.lang.String resourceIdJson, org.apache.thrift.async.AsyncMethodCallback<java.nio.ByteBuffer> resultHandler) throws org.apache.thrift.TException {
checkReady();
getResource_call method_call = new getResource_call(resourceIdJson, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class getResource_call extends org.apache.thrift.async.TAsyncMethodCall {
- private String resourceIdJson;
- public getResource_call(String resourceIdJson, 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 {
+ public static class getResource_call extends org.apache.thrift.async.TAsyncMethodCall<java.nio.ByteBuffer> {
+ private java.lang.String resourceIdJson;
+ public getResource_call(java.lang.String resourceIdJson, org.apache.thrift.async.AsyncMethodCallback<java.nio.ByteBuffer> 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.resourceIdJson = resourceIdJson;
}
@@ -963,9 +936,9 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public ByteBuffer getResult() throws org.apache.thrift.TException {
+ public java.nio.ByteBuffer getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
@@ -973,17 +946,17 @@ public class RemoteInterpreterEventService {
}
}
- public void invokeMethod(String intpGroupId, String invokeMethodJson, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void invokeMethod(java.lang.String intpGroupId, java.lang.String invokeMethodJson, org.apache.thrift.async.AsyncMethodCallback<java.nio.ByteBuffer> resultHandler) throws org.apache.thrift.TException {
checkReady();
invokeMethod_call method_call = new invokeMethod_call(intpGroupId, invokeMethodJson, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class invokeMethod_call extends org.apache.thrift.async.TAsyncMethodCall {
- private String intpGroupId;
- private String invokeMethodJson;
- public invokeMethod_call(String intpGroupId, String invokeMethodJson, 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 {
+ public static class invokeMethod_call extends org.apache.thrift.async.TAsyncMethodCall<java.nio.ByteBuffer> {
+ private java.lang.String intpGroupId;
+ private java.lang.String invokeMethodJson;
+ public invokeMethod_call(java.lang.String intpGroupId, java.lang.String invokeMethodJson, org.apache.thrift.async.AsyncMethodCallback<java.nio.ByteBuffer> 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.intpGroupId = intpGroupId;
this.invokeMethodJson = invokeMethodJson;
@@ -998,9 +971,9 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public ByteBuffer getResult() throws org.apache.thrift.TException {
+ public java.nio.ByteBuffer getResult() throws org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
@@ -1008,17 +981,17 @@ public class RemoteInterpreterEventService {
}
}
- public void getParagraphList(String user, String noteId, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
+ public void getParagraphList(java.lang.String user, java.lang.String noteId, org.apache.thrift.async.AsyncMethodCallback<java.util.List<ParagraphInfo>> resultHandler) throws org.apache.thrift.TException {
checkReady();
getParagraphList_call method_call = new getParagraphList_call(user, noteId, resultHandler, this, ___protocolFactory, ___transport);
this.___currentMethod = method_call;
___manager.call(method_call);
}
- public static class getParagraphList_call extends org.apache.thrift.async.TAsyncMethodCall {
- private String user;
- private String noteId;
- public getParagraphList_call(String user, String noteId, 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 {
+ public static class getParagraphList_call extends org.apache.thrift.async.TAsyncMethodCall<java.util.List<ParagraphInfo>> {
+ private java.lang.String user;
+ private java.lang.String noteId;
+ public getParagraphList_call(java.lang.String user, java.lang.String noteId, org.apache.thrift.async.AsyncMethodCallback<java.util.List<ParagraphInfo>> 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.user = user;
this.noteId = noteId;
@@ -1033,9 +1006,9 @@ public class RemoteInterpreterEventService {
prot.writeMessageEnd();
}
- public List<ParagraphInfo> getResult() throws ServiceException, org.apache.thrift.TException {
+ public java.util.List<ParagraphInfo> getResult() throws ServiceException, org.apache.thrift.TException {
if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
- throw new IllegalStateException("Method call not finished!");
+ throw new java.lang.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);
@@ -1046,16 +1019,16 @@ public class RemoteInterpreterEventService {
}
public static class Processor<I extends Iface> extends org.apache.thrift.TBaseProcessor<I> implements org.apache.thrift.TProcessor {
- private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
+ private static final org.slf4j.Logger _LOGGER = org.slf4j.LoggerFactory.getLogger(Processor.class.getName());
public Processor(I iface) {
- super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
+ super(iface, getProcessMap(new java.util.HashMap<java.lang.String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
}
- protected Processor(I iface, Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
+ protected Processor(I iface, java.util.Map<java.lang.String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
super(iface, getProcessMap(processMap));
}
- private static <I extends Iface> Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> getProcessMap(Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
+ private static <I extends Iface> java.util.Map<java.lang.String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> getProcessMap(java.util.Map<java.lang.String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
processMap.put("registerInterpreterProcess", new registerInterpreterProcess());
processMap.put("appendOutput", new appendOutput());
processMap.put("updateOutput", new updateOutput());
@@ -1088,6 +1061,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public registerInterpreterProcess_result getResult(I iface, registerInterpreterProcess_args args) throws org.apache.thrift.TException {
registerInterpreterProcess_result result = new registerInterpreterProcess_result();
iface.registerInterpreterProcess(args.registerInfo);
@@ -1108,6 +1086,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public appendOutput_result getResult(I iface, appendOutput_args args) throws org.apache.thrift.TException {
appendOutput_result result = new appendOutput_result();
iface.appendOutput(args.event);
@@ -1128,6 +1111,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public updateOutput_result getResult(I iface, updateOutput_args args) throws org.apache.thrift.TException {
updateOutput_result result = new updateOutput_result();
iface.updateOutput(args.event);
@@ -1148,6 +1136,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public updateAllOutput_result getResult(I iface, updateAllOutput_args args) throws org.apache.thrift.TException {
updateAllOutput_result result = new updateAllOutput_result();
iface.updateAllOutput(args.event);
@@ -1168,6 +1161,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public appendAppOutput_result getResult(I iface, appendAppOutput_args args) throws org.apache.thrift.TException {
appendAppOutput_result result = new appendAppOutput_result();
iface.appendAppOutput(args.event);
@@ -1188,6 +1186,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public updateAppOutput_result getResult(I iface, updateAppOutput_args args) throws org.apache.thrift.TException {
updateAppOutput_result result = new updateAppOutput_result();
iface.updateAppOutput(args.event);
@@ -1208,6 +1211,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public updateAppStatus_result getResult(I iface, updateAppStatus_args args) throws org.apache.thrift.TException {
updateAppStatus_result result = new updateAppStatus_result();
iface.updateAppStatus(args.event);
@@ -1228,6 +1236,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public runParagraphs_result getResult(I iface, runParagraphs_args args) throws org.apache.thrift.TException {
runParagraphs_result result = new runParagraphs_result();
iface.runParagraphs(args.event);
@@ -1248,6 +1261,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public addAngularObject_result getResult(I iface, addAngularObject_args args) throws org.apache.thrift.TException {
addAngularObject_result result = new addAngularObject_result();
iface.addAngularObject(args.intpGroupId, args.json);
@@ -1268,6 +1286,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public updateAngularObject_result getResult(I iface, updateAngularObject_args args) throws org.apache.thrift.TException {
updateAngularObject_result result = new updateAngularObject_result();
iface.updateAngularObject(args.intpGroupId, args.json);
@@ -1288,6 +1311,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public removeAngularObject_result getResult(I iface, removeAngularObject_args args) throws org.apache.thrift.TException {
removeAngularObject_result result = new removeAngularObject_result();
iface.removeAngularObject(args.intpGroupId, args.noteId, args.paragraphId, args.name);
@@ -1308,6 +1336,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public sendParagraphInfo_result getResult(I iface, sendParagraphInfo_args args) throws org.apache.thrift.TException {
sendParagraphInfo_result result = new sendParagraphInfo_result();
iface.sendParagraphInfo(args.intpGroupId, args.json);
@@ -1328,6 +1361,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public getAllResources_result getResult(I iface, getAllResources_args args) throws org.apache.thrift.TException {
getAllResources_result result = new getAllResources_result();
result.success = iface.getAllResources(args.intpGroupId);
@@ -1348,6 +1386,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public getResource_result getResult(I iface, getResource_args args) throws org.apache.thrift.TException {
getResource_result result = new getResource_result();
result.success = iface.getResource(args.resourceIdJson);
@@ -1368,6 +1411,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public invokeMethod_result getResult(I iface, invokeMethod_args args) throws org.apache.thrift.TException {
invokeMethod_result result = new invokeMethod_result();
result.success = iface.invokeMethod(args.intpGroupId, args.invokeMethodJson);
@@ -1388,6 +1436,11 @@ public class RemoteInterpreterEventService {
return false;
}
+ @Override
+ protected boolean rethrowUnhandledExceptions() {
+ return false;
+ }
+
public getParagraphList_result getResult(I iface, getParagraphList_args args) throws org.apache.thrift.TException {
getParagraphList_result result = new getParagraphList_result();
try {
@@ -1402,16 +1455,16 @@ public class RemoteInterpreterEventService {
}
public static class AsyncProcessor<I extends AsyncIface> extends org.apache.thrift.TBaseAsyncProcessor<I> {
- private static final Logger LOGGER = LoggerFactory.getLogger(AsyncProcessor.class.getName());
+ private static final org.slf4j.Logger _LOGGER = org.slf4j.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, ?>>()));
+ super(iface, getProcessMap(new java.util.HashMap<java.lang.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) {
+ protected AsyncProcessor(I iface, java.util.Map<java.lang.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) {
+ private static <I extends AsyncIface> java.util.Map<java.lang.String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase,?>> getProcessMap(java.util.Map<java.lang.String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) {
processMap.put("registerInterpreterProcess", new registerInterpreterProcess());
processMap.put("appendOutput", new appendOutput());
processMap.put("updateOutput", new updateOutput());
@@ -1440,34 +1493,44 @@ public class RemoteInterpreterEventService {
return new registerInterpreterProcess_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
registerInterpreterProcess_result result = new registerInterpreterProcess_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
registerInterpreterProcess_result result = new registerInterpreterProcess_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
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());
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1476,7 +1539,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, registerInterpreterProcess_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, registerInterpreterProcess_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.registerInterpreterProcess(args.registerInfo,resultHandler);
}
}
@@ -1490,34 +1553,44 @@ public class RemoteInterpreterEventService {
return new appendOutput_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
appendOutput_result result = new appendOutput_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
appendOutput_result result = new appendOutput_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
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());
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1526,7 +1599,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, appendOutput_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, appendOutput_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.appendOutput(args.event,resultHandler);
}
}
@@ -1540,34 +1613,44 @@ public class RemoteInterpreterEventService {
return new updateOutput_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
updateOutput_result result = new updateOutput_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
updateOutput_result result = new updateOutput_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
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());
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1576,7 +1659,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, updateOutput_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, updateOutput_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.updateOutput(args.event,resultHandler);
}
}
@@ -1590,34 +1673,44 @@ public class RemoteInterpreterEventService {
return new updateAllOutput_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
updateAllOutput_result result = new updateAllOutput_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
updateAllOutput_result result = new updateAllOutput_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
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());
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1626,7 +1719,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, updateAllOutput_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, updateAllOutput_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.updateAllOutput(args.event,resultHandler);
}
}
@@ -1640,34 +1733,44 @@ public class RemoteInterpreterEventService {
return new appendAppOutput_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
appendAppOutput_result result = new appendAppOutput_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
appendAppOutput_result result = new appendAppOutput_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
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());
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1676,7 +1779,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, appendAppOutput_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, appendAppOutput_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.appendAppOutput(args.event,resultHandler);
}
}
@@ -1690,34 +1793,44 @@ public class RemoteInterpreterEventService {
return new updateAppOutput_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
updateAppOutput_result result = new updateAppOutput_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
updateAppOutput_result result = new updateAppOutput_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
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());
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1726,7 +1839,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, updateAppOutput_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, updateAppOutput_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.updateAppOutput(args.event,resultHandler);
}
}
@@ -1740,34 +1853,44 @@ public class RemoteInterpreterEventService {
return new updateAppStatus_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
updateAppStatus_result result = new updateAppStatus_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
updateAppStatus_result result = new updateAppStatus_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
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());
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1776,7 +1899,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, updateAppStatus_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, updateAppStatus_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.updateAppStatus(args.event,resultHandler);
}
}
@@ -1790,34 +1913,44 @@ public class RemoteInterpreterEventService {
return new runParagraphs_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
runParagraphs_result result = new runParagraphs_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
runParagraphs_result result = new runParagraphs_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
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());
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1826,7 +1959,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, runParagraphs_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, runParagraphs_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.runParagraphs(args.event,resultHandler);
}
}
@@ -1840,34 +1973,44 @@ public class RemoteInterpreterEventService {
return new addAngularObject_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
addAngularObject_result result = new addAngularObject_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
addAngularObject_result result = new addAngularObject_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
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());
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1876,7 +2019,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, addAngularObject_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, addAngularObject_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.addAngularObject(args.intpGroupId, args.json,resultHandler);
}
}
@@ -1890,34 +2033,44 @@ public class RemoteInterpreterEventService {
return new updateAngularObject_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
updateAngularObject_result result = new updateAngularObject_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
updateAngularObject_result result = new updateAngularObject_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
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());
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1926,7 +2079,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, updateAngularObject_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, updateAngularObject_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.updateAngularObject(args.intpGroupId, args.json,resultHandler);
}
}
@@ -1940,34 +2093,44 @@ public class RemoteInterpreterEventService {
return new removeAngularObject_args();
}
- public AsyncMethodCallback<Void> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
+ public org.apache.thrift.async.AsyncMethodCallback<Void> getResultHandler(final org.apache.thrift.server.AbstractNonblockingServer.AsyncFrameBuffer fb, final int seqid) {
final org.apache.thrift.AsyncProcessFunction fcall = this;
- return new AsyncMethodCallback<Void>() {
+ return new org.apache.thrift.async.AsyncMethodCallback<Void>() {
public void onComplete(Void o) {
removeAngularObject_result result = new removeAngularObject_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);
+ fcall.sendResponse(fb, result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
+ } catch (org.apache.thrift.transport.TTransportException e) {
+ _LOGGER.error("TTransportException writing to internal frame buffer", e);
+ fb.close();
+ } catch (java.lang.Exception e) {
+ _LOGGER.error("Exception writing to internal frame buffer", e);
+ onError(e);
}
- fb.close();
}
- public void onError(Exception e) {
+ public void onError(java.lang.Exception e) {
byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
- org.apache.thrift.TBase msg;
+ org.apache.thrift.TSerializable msg;
removeAngularObject_result result = new removeAngularObject_result();
- {
+ if (e instanceof org.apache.thrift.transport.TTransportException) {
+ _LOGGER.error("TTransportException inside handler", e);
+ fb.close();
+ return;
+ } else if (e instanceof org.apache.thrift.TApplicationException) {
+ _LOGGER.error("TApplicationException inside handler", e);
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());
+ msg = (org.apache.thrift.TApplicationException)e;
+ } else {
+ _LOGGER.error("Exception inside handler", e);
+ msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
+ msg = 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);
+ } catch (java.lang.Exception ex) {
+ _LOGGER.error("Exception writing to internal frame buffer", ex);
+ fb.close();
}
- fb.close();
}
};
}
@@ -1976,7 +2139,7 @@ public class RemoteInterpreterEventService {
return false;
}
- public void start(I iface, removeAngularObject_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws TException {
+ public void start(I iface, removeAngularObject_args args, org.apache.thrift.async.AsyncMethodCallback<Void> resultHandler) throws org.apache.thrift.TException {
iface.removeAngularObject(args.intpGroupId, args.noteId, args.paragraphId, args.name,resultHandler);
... 27958 lines suppressed ...