diff --git a/pom.xml b/pom.xml index 60b35ab60..de5d9b3e8 100644 --- a/pom.xml +++ b/pom.xml @@ -659,7 +659,7 @@ org.apache.thrift libthrift - 0.9.2 + 0.10.0 org.apache.httpcomponents diff --git a/profiler/src/main/java/com/navercorp/pinpoint/profiler/monitor/collector/AgentStatMetricCollector.java b/profiler/src/main/java/com/navercorp/pinpoint/profiler/monitor/collector/AgentStatMetricCollector.java index 9bacbcf1c..9b585b372 100644 --- a/profiler/src/main/java/com/navercorp/pinpoint/profiler/monitor/collector/AgentStatMetricCollector.java +++ b/profiler/src/main/java/com/navercorp/pinpoint/profiler/monitor/collector/AgentStatMetricCollector.java @@ -22,8 +22,8 @@ import org.apache.thrift.TFieldIdEnum; /** * @author HyunGil Jeong */ -public interface AgentStatMetricCollector> { - +public interface AgentStatMetricCollector> { + T collect(); } diff --git a/thrift/build-thrift-linux.sh b/thrift/build-thrift-linux.sh index 768f39754..01af096c2 100755 --- a/thrift/build-thrift-linux.sh +++ b/thrift/build-thrift-linux.sh @@ -1,4 +1,4 @@ -mvn generate-sources -P with-thrift -Dmaven.test.skip -Dthrift.executable.path=./src/compiler/linux/thrift-0.9.2 +mvn generate-sources -P with-thrift -Dmaven.test.skip -Dthrift.executable.path=./src/compiler/linux/thrift-0.10.0 rc=$? if [[ $rc != 0 ]] ; then diff --git a/thrift/build-thrift-windows.bat b/thrift/build-thrift-windows.bat index 23f86879b..72cd2b720 100755 --- a/thrift/build-thrift-windows.bat +++ b/thrift/build-thrift-windows.bat @@ -1,4 +1,4 @@ -mvn generate-sources -P with-thrift -Dmaven.test.skip -Dthrift.executable.path=./src/compiler/windows/thrift-0.9.2 +mvn generate-sources -P with-thrift -Dmaven.test.skip -Dthrift.executable.path=./src/compiler/windows/thrift-0.10.0 rc=$? if [[ $rc != 0 ]] ; then diff --git a/thrift/src/compiler/linux/thrift-0.10.0-not-exist.txt b/thrift/src/compiler/linux/thrift-0.10.0-not-exist.txt new file mode 100644 index 000000000..d855b8ad4 --- /dev/null +++ b/thrift/src/compiler/linux/thrift-0.10.0-not-exist.txt @@ -0,0 +1 @@ +copy thrift 0.10.0 binary \ No newline at end of file diff --git a/thrift/src/compiler/linux/thrift-0.9.2 b/thrift/src/compiler/linux/thrift-0.9.2 deleted file mode 100755 index 8284ed1c5..000000000 Binary files a/thrift/src/compiler/linux/thrift-0.9.2 and /dev/null differ diff --git a/thrift/src/compiler/windows/thrift-0.10.0.exe b/thrift/src/compiler/windows/thrift-0.10.0.exe new file mode 100644 index 000000000..480cf9a9a Binary files /dev/null and b/thrift/src/compiler/windows/thrift-0.10.0.exe differ diff --git a/thrift/src/compiler/windows/thrift-0.9.2.exe b/thrift/src/compiler/windows/thrift-0.9.2.exe deleted file mode 100644 index 318119979..000000000 Binary files a/thrift/src/compiler/windows/thrift-0.9.2.exe and /dev/null differ diff --git a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TActiveTrace.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TActiveTrace.java index a4be0bd65..1077622d4 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TActiveTrace.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TActiveTrace.java @@ -1,50 +1,20 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2016-1-29") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TActiveTrace implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TActiveTrace"); private static final org.apache.thrift.protocol.TField HISTOGRAM_FIELD_DESC = new org.apache.thrift.protocol.TField("histogram", org.apache.thrift.protocol.TType.STRUCT, (short)1); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TActiveTraceStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TActiveTraceTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TActiveTraceStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TActiveTraceTupleSchemeFactory(); private TActiveTraceHistogram histogram; // optional @@ -52,10 +22,10 @@ public class TActiveTrace implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -78,21 +48,21 @@ public class TActiveTrace implements org.apache.thrift.TBase 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.HISTOGRAM, new org.apache.thrift.meta_data.FieldMetaData("histogram", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TActiveTraceHistogram.class))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TActiveTrace.class, metaDataMap); } @@ -161,7 +131,7 @@ public class TActiveTrace implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_histogram = true && (isSetHistogram()); - list.add(present_histogram); - if (present_histogram) - list.add(histogram); + hashCode = hashCode * 8191 + ((isSetHistogram()) ? 131071 : 524287); + if (isSetHistogram()) + hashCode = hashCode * 8191 + histogram.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -241,7 +212,7 @@ public class TActiveTrace implements org.apache.thrift.TBase { + private static class TActiveTraceStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TActiveTrace struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -361,18 +332,18 @@ public class TActiveTrace implements org.apache.thrift.TBase { + private static class TActiveTraceTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TActiveTrace 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.isSetHistogram()) { optionals.set(0); } @@ -384,8 +355,8 @@ public class TActiveTrace implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TActiveTraceHistogram.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TActiveTraceHistogram.java index e6646f2f2..aa9bf8465 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TActiveTraceHistogram.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TActiveTraceHistogram.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2016-2-2") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TActiveTraceHistogram implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TActiveTraceHistogram"); @@ -42,15 +15,12 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TActiveTraceHistogramStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TActiveTraceHistogramTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TActiveTraceHistogramStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TActiveTraceHistogramTupleSchemeFactory(); private short version; // required private int histogramSchemaType; // optional - private List activeTraceCount; // optional + private java.util.List activeTraceCount; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { @@ -58,10 +28,10 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -88,21 +58,21 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase 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.VERSION, new org.apache.thrift.meta_data.FieldMetaData("version", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I16))); tmpMap.put(_Fields.HISTOGRAM_SCHEMA_TYPE, new org.apache.thrift.meta_data.FieldMetaData("histogramSchemaType", org.apache.thrift.TFieldRequirementType.OPTIONAL, @@ -131,7 +101,7 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase __this__activeTraceCount = new ArrayList(other.activeTraceCount); + java.util.List __this__activeTraceCount = new java.util.ArrayList(other.activeTraceCount); this.activeTraceCount = __this__activeTraceCount; } } @@ -184,16 +154,16 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase getActiveTraceCountIterator() { + public java.util.Iterator getActiveTraceCountIterator() { return (this.activeTraceCount == null) ? null : this.activeTraceCount.iterator(); } public void addToActiveTraceCount(int elem) { if (this.activeTraceCount == null) { - this.activeTraceCount = new ArrayList(); + this.activeTraceCount = new java.util.ArrayList(); } this.activeTraceCount.add(elem); } - public List getActiveTraceCount() { + public java.util.List getActiveTraceCount() { return this.activeTraceCount; } - public void setActiveTraceCount(List activeTraceCount) { + public void setActiveTraceCount(java.util.List activeTraceCount) { this.activeTraceCount = activeTraceCount; } @@ -256,13 +226,13 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase)value); + setActiveTraceCount((java.util.List)value); } break; } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case VERSION: - return Short.valueOf(getVersion()); + return getVersion(); case HISTOGRAM_SCHEMA_TYPE: - return Integer.valueOf(getHistogramSchemaType()); + return getHistogramSchemaType(); case ACTIVE_TRACE_COUNT: return getActiveTraceCount(); } - 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) { @@ -314,11 +284,11 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_version = true; - list.add(present_version); - if (present_version) - list.add(version); + hashCode = hashCode * 8191 + version; - boolean present_histogramSchemaType = true && (isSetHistogramSchemaType()); - list.add(present_histogramSchemaType); - if (present_histogramSchemaType) - list.add(histogramSchemaType); + hashCode = hashCode * 8191 + ((isSetHistogramSchemaType()) ? 131071 : 524287); + if (isSetHistogramSchemaType()) + hashCode = hashCode * 8191 + histogramSchemaType; - boolean present_activeTraceCount = true && (isSetActiveTraceCount()); - list.add(present_activeTraceCount); - if (present_activeTraceCount) - list.add(activeTraceCount); + hashCode = hashCode * 8191 + ((isSetActiveTraceCount()) ? 131071 : 524287); + if (isSetActiveTraceCount()) + hashCode = hashCode * 8191 + activeTraceCount.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -390,7 +357,7 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase { + private static class TActiveTraceHistogramStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TActiveTraceHistogram struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -524,7 +491,7 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase(_list24.size); + struct.activeTraceCount = new java.util.ArrayList(_list24.size); int _elem25; for (int _i26 = 0; _i26 < _list24.size; ++_i26) { @@ -579,18 +546,18 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase { + private static class TActiveTraceHistogramTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TActiveTraceHistogram 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.isSetVersion()) { optionals.set(0); } @@ -620,8 +587,8 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase(_list29.size); + struct.activeTraceCount = new java.util.ArrayList(_list29.size); int _elem30; for (int _i31 = 0; _i31 < _list29.size; ++_i31) { @@ -646,5 +613,8 @@ public class TActiveTraceHistogram implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentInfo.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentInfo.java index 5123b3d48..7e5af07ce 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentInfo.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentInfo.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2016-2-15") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TAgentInfo implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TAgentInfo"); @@ -53,21 +26,18 @@ public class TAgentInfo implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TAgentInfoStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TAgentInfoTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TAgentInfoStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TAgentInfoTupleSchemeFactory(); - private String hostname; // required - private String ip; // required - private String ports; // required - private String agentId; // required - private String applicationName; // required + private java.lang.String hostname; // required + private java.lang.String ip; // required + private java.lang.String ports; // required + private java.lang.String agentId; // required + private java.lang.String applicationName; // required private short serviceType; // required private int pid; // required - private String agentVersion; // required - private String vmVersion; // required + private java.lang.String agentVersion; // required + private java.lang.String vmVersion; // required private long startTimestamp; // required private long endTimestamp; // optional private int endStatus; // optional @@ -91,10 +61,10 @@ public class TAgentInfo implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -143,21 +113,21 @@ public class TAgentInfo implements org.apache.thrift.TBase 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.HOSTNAME, new org.apache.thrift.meta_data.FieldMetaData("hostname", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.IP, new org.apache.thrift.meta_data.FieldMetaData("ip", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -210,7 +180,7 @@ public class TAgentInfo implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_hostname = true && (isSetHostname()); - list.add(present_hostname); - if (present_hostname) - list.add(hostname); + hashCode = hashCode * 8191 + ((isSetHostname()) ? 131071 : 524287); + if (isSetHostname()) + hashCode = hashCode * 8191 + hostname.hashCode(); - boolean present_ip = true && (isSetIp()); - list.add(present_ip); - if (present_ip) - list.add(ip); + hashCode = hashCode * 8191 + ((isSetIp()) ? 131071 : 524287); + if (isSetIp()) + hashCode = hashCode * 8191 + ip.hashCode(); - boolean present_ports = true && (isSetPorts()); - list.add(present_ports); - if (present_ports) - list.add(ports); + hashCode = hashCode * 8191 + ((isSetPorts()) ? 131071 : 524287); + if (isSetPorts()) + hashCode = hashCode * 8191 + ports.hashCode(); - boolean present_agentId = true && (isSetAgentId()); - list.add(present_agentId); - if (present_agentId) - list.add(agentId); + hashCode = hashCode * 8191 + ((isSetAgentId()) ? 131071 : 524287); + if (isSetAgentId()) + hashCode = hashCode * 8191 + agentId.hashCode(); - boolean present_applicationName = true && (isSetApplicationName()); - list.add(present_applicationName); - if (present_applicationName) - list.add(applicationName); + hashCode = hashCode * 8191 + ((isSetApplicationName()) ? 131071 : 524287); + if (isSetApplicationName()) + hashCode = hashCode * 8191 + applicationName.hashCode(); - boolean present_serviceType = true; - list.add(present_serviceType); - if (present_serviceType) - list.add(serviceType); + hashCode = hashCode * 8191 + serviceType; - boolean present_pid = true; - list.add(present_pid); - if (present_pid) - list.add(pid); + hashCode = hashCode * 8191 + pid; - boolean present_agentVersion = true && (isSetAgentVersion()); - list.add(present_agentVersion); - if (present_agentVersion) - list.add(agentVersion); + hashCode = hashCode * 8191 + ((isSetAgentVersion()) ? 131071 : 524287); + if (isSetAgentVersion()) + hashCode = hashCode * 8191 + agentVersion.hashCode(); - boolean present_vmVersion = true && (isSetVmVersion()); - list.add(present_vmVersion); - if (present_vmVersion) - list.add(vmVersion); + hashCode = hashCode * 8191 + ((isSetVmVersion()) ? 131071 : 524287); + if (isSetVmVersion()) + hashCode = hashCode * 8191 + vmVersion.hashCode(); - boolean present_startTimestamp = true; - list.add(present_startTimestamp); - if (present_startTimestamp) - list.add(startTimestamp); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(startTimestamp); - boolean present_endTimestamp = true && (isSetEndTimestamp()); - list.add(present_endTimestamp); - if (present_endTimestamp) - list.add(endTimestamp); + hashCode = hashCode * 8191 + ((isSetEndTimestamp()) ? 131071 : 524287); + if (isSetEndTimestamp()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(endTimestamp); - boolean present_endStatus = true && (isSetEndStatus()); - list.add(present_endStatus); - if (present_endStatus) - list.add(endStatus); + hashCode = hashCode * 8191 + ((isSetEndStatus()) ? 131071 : 524287); + if (isSetEndStatus()) + hashCode = hashCode * 8191 + endStatus; - boolean present_serverMetaData = true && (isSetServerMetaData()); - list.add(present_serverMetaData); - if (present_serverMetaData) - list.add(serverMetaData); + hashCode = hashCode * 8191 + ((isSetServerMetaData()) ? 131071 : 524287); + if (isSetServerMetaData()) + hashCode = hashCode * 8191 + serverMetaData.hashCode(); - boolean present_jvmInfo = true && (isSetJvmInfo()); - list.add(present_jvmInfo); - if (present_jvmInfo) - list.add(jvmInfo); + hashCode = hashCode * 8191 + ((isSetJvmInfo()) ? 131071 : 524287); + if (isSetJvmInfo()) + hashCode = hashCode * 8191 + jvmInfo.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -1059,7 +1011,7 @@ public class TAgentInfo implements org.apache.thrift.TBase { + private static class TAgentInfoStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TAgentInfo struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -1570,18 +1522,18 @@ public class TAgentInfo implements org.apache.thrift.TBase { + private static class TAgentInfoTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TAgentInfo 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.isSetHostname()) { optionals.set(0); } @@ -1671,8 +1623,8 @@ public class TAgentInfo implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentStat.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentStat.java index 919996f13..d1c5b2874 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentStat.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentStat.java @@ -1,30 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -import org.apache.thrift.EncodingUtils; -import org.apache.thrift.protocol.TTupleProtocol; -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 javax.annotation.Generated; -import java.util.ArrayList; -import java.util.BitSet; -import java.util.Collections; -import java.util.EnumMap; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) -@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2017-1-24") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TAgentStat implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TAgentStat"); @@ -39,13 +22,10 @@ public class TAgentStat implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TAgentStatStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TAgentStatTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TAgentStatStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TAgentStatTupleSchemeFactory(); - private String agentId; // optional + private java.lang.String agentId; // optional private long startTimestamp; // optional private long timestamp; // optional private long collectInterval; // optional @@ -54,7 +34,7 @@ public class TAgentStat implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -113,21 +93,21 @@ public class TAgentStat implements org.apache.thrift.TBase 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.AGENT_ID, new org.apache.thrift.meta_data.FieldMetaData("agentId", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.START_TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("startTimestamp", org.apache.thrift.TFieldRequirementType.OPTIONAL, @@ -170,7 +150,7 @@ public class TAgentStat implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_agentId = true && (isSetAgentId()); - list.add(present_agentId); - if (present_agentId) - list.add(agentId); + hashCode = hashCode * 8191 + ((isSetAgentId()) ? 131071 : 524287); + if (isSetAgentId()) + hashCode = hashCode * 8191 + agentId.hashCode(); - boolean present_startTimestamp = true && (isSetStartTimestamp()); - list.add(present_startTimestamp); - if (present_startTimestamp) - list.add(startTimestamp); + hashCode = hashCode * 8191 + ((isSetStartTimestamp()) ? 131071 : 524287); + if (isSetStartTimestamp()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(startTimestamp); - boolean present_timestamp = true && (isSetTimestamp()); - list.add(present_timestamp); - if (present_timestamp) - list.add(timestamp); + hashCode = hashCode * 8191 + ((isSetTimestamp()) ? 131071 : 524287); + if (isSetTimestamp()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(timestamp); - boolean present_collectInterval = true && (isSetCollectInterval()); - list.add(present_collectInterval); - if (present_collectInterval) - list.add(collectInterval); + hashCode = hashCode * 8191 + ((isSetCollectInterval()) ? 131071 : 524287); + if (isSetCollectInterval()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(collectInterval); - boolean present_gc = true && (isSetGc()); - list.add(present_gc); - if (present_gc) - list.add(gc); + hashCode = hashCode * 8191 + ((isSetGc()) ? 131071 : 524287); + if (isSetGc()) + hashCode = hashCode * 8191 + gc.hashCode(); - boolean present_cpuLoad = true && (isSetCpuLoad()); - list.add(present_cpuLoad); - if (present_cpuLoad) - list.add(cpuLoad); + hashCode = hashCode * 8191 + ((isSetCpuLoad()) ? 131071 : 524287); + if (isSetCpuLoad()) + hashCode = hashCode * 8191 + cpuLoad.hashCode(); - boolean present_transaction = true && (isSetTransaction()); - list.add(present_transaction); - if (present_transaction) - list.add(transaction); + hashCode = hashCode * 8191 + ((isSetTransaction()) ? 131071 : 524287); + if (isSetTransaction()) + hashCode = hashCode * 8191 + transaction.hashCode(); - boolean present_activeTrace = true && (isSetActiveTrace()); - list.add(present_activeTrace); - if (present_activeTrace) - list.add(activeTrace); + hashCode = hashCode * 8191 + ((isSetActiveTrace()) ? 131071 : 524287); + if (isSetActiveTrace()) + hashCode = hashCode * 8191 + activeTrace.hashCode(); - boolean present_dataSourceList = true && (isSetDataSourceList()); - list.add(present_dataSourceList); - if (present_dataSourceList) - list.add(dataSourceList); + hashCode = hashCode * 8191 + ((isSetDataSourceList()) ? 131071 : 524287); + if (isSetDataSourceList()) + hashCode = hashCode * 8191 + dataSourceList.hashCode(); - boolean present_metadata = true && (isSetMetadata()); - list.add(present_metadata); - if (present_metadata) - list.add(metadata); + hashCode = hashCode * 8191 + ((isSetMetadata()) ? 131071 : 524287); + if (isSetMetadata()) + hashCode = hashCode * 8191 + metadata.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -779,7 +751,7 @@ public class TAgentStat implements org.apache.thrift.TBase { + private static class TAgentStatStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TAgentStat struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -1211,18 +1183,18 @@ public class TAgentStat implements org.apache.thrift.TBase { + private static class TAgentStatTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TAgentStat 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.isSetAgentId()) { optionals.set(0); } @@ -1288,8 +1260,8 @@ public class TAgentStat implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentStatBatch.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentStatBatch.java index 3ff9786a2..3abc28c5f 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentStatBatch.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAgentStatBatch.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TAgentStatBatch implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TAgentStatBatch"); @@ -42,15 +15,12 @@ public class TAgentStatBatch implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TAgentStatBatchStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TAgentStatBatchTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TAgentStatBatchStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TAgentStatBatchTupleSchemeFactory(); - private String agentId; // required + private java.lang.String agentId; // required private long startTimestamp; // required - private List agentStats; // required + private java.util.List agentStats; // 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 { @@ -58,10 +28,10 @@ public class TAgentStatBatch implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -88,21 +58,21 @@ public class TAgentStatBatch implements org.apache.thrift.TBase 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.AGENT_ID, new org.apache.thrift.meta_data.FieldMetaData("agentId", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.START_TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("startTimestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -129,7 +99,7 @@ public class TAgentStatBatch implements org.apache.thrift.TBase agentStats) + java.util.List agentStats) { this(); this.agentId = agentId; @@ -158,7 +128,7 @@ public class TAgentStatBatch implements org.apache.thrift.TBase __this__agentStats = new ArrayList(other.agentStats.size()); + java.util.List __this__agentStats = new java.util.ArrayList(other.agentStats.size()); for (TAgentStat other_element : other.agentStats) { __this__agentStats.add(new TAgentStat(other_element)); } @@ -178,11 +148,11 @@ public class TAgentStatBatch implements org.apache.thrift.TBase(); + this.agentStats = new java.util.ArrayList(); } this.agentStats.add(elem); } - public List getAgentStats() { + public java.util.List getAgentStats() { return this.agentStats; } - public void setAgentStats(List agentStats) { + public void setAgentStats(java.util.List agentStats) { this.agentStats = agentStats; } @@ -261,13 +231,13 @@ public class TAgentStatBatch implements org.apache.thrift.TBase)value); + setAgentStats((java.util.List)value); } break; } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case AGENT_ID: return getAgentId(); case START_TIMESTAMP: - return Long.valueOf(getStartTimestamp()); + return getStartTimestamp(); case AGENT_STATS: return getAgentStats(); } - 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 +289,11 @@ public class TAgentStatBatch implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_agentId = true && (isSetAgentId()); - list.add(present_agentId); - if (present_agentId) - list.add(agentId); + hashCode = hashCode * 8191 + ((isSetAgentId()) ? 131071 : 524287); + if (isSetAgentId()) + hashCode = hashCode * 8191 + agentId.hashCode(); - boolean present_startTimestamp = true; - list.add(present_startTimestamp); - if (present_startTimestamp) - list.add(startTimestamp); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(startTimestamp); - boolean present_agentStats = true && (isSetAgentStats()); - list.add(present_agentStats); - if (present_agentStats) - list.add(agentStats); + hashCode = hashCode * 8191 + ((isSetAgentStats()) ? 131071 : 524287); + if (isSetAgentStats()) + hashCode = hashCode * 8191 + agentStats.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -395,7 +362,7 @@ public class TAgentStatBatch implements org.apache.thrift.TBase { + private static class TAgentStatBatchStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TAgentStatBatch struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -528,14 +495,14 @@ public class TAgentStatBatch implements org.apache.thrift.TBase(_list24.size); - TAgentStat _elem25; - for (int _i26 = 0; _i26 < _list24.size; ++_i26) + org.apache.thrift.protocol.TList _list32 = iprot.readListBegin(); + struct.agentStats = new java.util.ArrayList(_list32.size); + TAgentStat _elem33; + for (int _i34 = 0; _i34 < _list32.size; ++_i34) { - _elem25 = new TAgentStat(); - _elem25.read(iprot); - struct.agentStats.add(_elem25); + _elem33 = new TAgentStat(); + _elem33.read(iprot); + struct.agentStats.add(_elem33); } iprot.readListEnd(); } @@ -569,9 +536,9 @@ public class TAgentStatBatch implements org.apache.thrift.TBase { + private static class TAgentStatBatchTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TAgentStatBatch 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.isSetAgentId()) { optionals.set(0); } @@ -614,9 +581,9 @@ public class TAgentStatBatch implements org.apache.thrift.TBase(_list29.size); - TAgentStat _elem30; - for (int _i31 = 0; _i31 < _list29.size; ++_i31) + org.apache.thrift.protocol.TList _list37 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.agentStats = new java.util.ArrayList(_list37.size); + TAgentStat _elem38; + for (int _i39 = 0; _i39 < _list37.size; ++_i39) { - _elem30 = new TAgentStat(); - _elem30.read(iprot); - struct.agentStats.add(_elem30); + _elem38 = new TAgentStat(); + _elem38.read(iprot); + struct.agentStats.add(_elem38); } } struct.setAgentStatsIsSet(true); @@ -651,5 +618,8 @@ public class TAgentStatBatch implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAnnotation.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAnnotation.java index a4368147f..b1d28542a 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAnnotation.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAnnotation.java @@ -1,51 +1,21 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TAnnotation implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TAnnotation"); private static final org.apache.thrift.protocol.TField KEY_FIELD_DESC = new org.apache.thrift.protocol.TField("key", org.apache.thrift.protocol.TType.I32, (short)1); private static final org.apache.thrift.protocol.TField VALUE_FIELD_DESC = new org.apache.thrift.protocol.TField("value", org.apache.thrift.protocol.TType.STRUCT, (short)2); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TAnnotationStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TAnnotationTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TAnnotationStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TAnnotationTupleSchemeFactory(); private int key; // required private TAnnotationValue value; // optional @@ -55,10 +25,10 @@ public class TAnnotation implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -83,21 +53,21 @@ public class TAnnotation implements org.apache.thrift.TBase 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.KEY, new org.apache.thrift.meta_data.FieldMetaData("key", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); tmpMap.put(_Fields.VALUE, new org.apache.thrift.meta_data.FieldMetaData("value", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TAnnotationValue.class))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TAnnotation.class, metaDataMap); } @@ -169,16 +139,16 @@ public class TAnnotation implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_key = true; - list.add(present_key); - if (present_key) - list.add(key); + hashCode = hashCode * 8191 + key; - 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(); - return list.hashCode(); + return hashCode; } @Override @@ -311,7 +279,7 @@ public class TAnnotation implements org.apache.thrift.TBase { + private static class TAnnotationStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TAnnotation struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -455,18 +423,18 @@ public class TAnnotation implements org.apache.thrift.TBase { + private static class TAnnotationTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TAnnotation 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.isSetKey()) { optionals.set(0); } @@ -484,8 +452,8 @@ public class TAnnotation implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAnnotationValue.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAnnotationValue.java index 188ec01c5..cb8399d83 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAnnotationValue.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TAnnotationValue.java @@ -1,39 +1,12 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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"}) +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) public class TAnnotationValue extends org.apache.thrift.TUnion { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TAnnotationValue"); private static final org.apache.thrift.protocol.TField STRING_VALUE_FIELD_DESC = new org.apache.thrift.protocol.TField("stringValue", org.apache.thrift.protocol.TType.STRING, (short)1); @@ -60,10 +33,10 @@ public class TAnnotationValue extends org.apache.thrift.TUnion byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -104,21 +77,21 @@ public class TAnnotationValue extends org.apache.thrift.TUnion 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); - tmpMap.put(_Fields.STRING_VALUE, new org.apache.thrift.meta_data.FieldMetaData("stringValue", org.apache.thrift.TFieldRequirementType.DEFAULT, + 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.STRING_VALUE, new org.apache.thrift.meta_data.FieldMetaData("stringValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); - tmpMap.put(_Fields.BOOL_VALUE, new org.apache.thrift.meta_data.FieldMetaData("boolValue", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.BOOL_VALUE, new org.apache.thrift.meta_data.FieldMetaData("boolValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL))); - tmpMap.put(_Fields.INT_VALUE, new org.apache.thrift.meta_data.FieldMetaData("intValue", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.INT_VALUE, new org.apache.thrift.meta_data.FieldMetaData("intValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); - tmpMap.put(_Fields.LONG_VALUE, new org.apache.thrift.meta_data.FieldMetaData("longValue", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.LONG_VALUE, new org.apache.thrift.meta_data.FieldMetaData("longValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))); - tmpMap.put(_Fields.SHORT_VALUE, new org.apache.thrift.meta_data.FieldMetaData("shortValue", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.SHORT_VALUE, new org.apache.thrift.meta_data.FieldMetaData("shortValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I16))); - tmpMap.put(_Fields.DOUBLE_VALUE, new org.apache.thrift.meta_data.FieldMetaData("doubleValue", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.DOUBLE_VALUE, new org.apache.thrift.meta_data.FieldMetaData("doubleValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE))); - tmpMap.put(_Fields.BINARY_VALUE, new org.apache.thrift.meta_data.FieldMetaData("binaryValue", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.BINARY_VALUE, new org.apache.thrift.meta_data.FieldMetaData("binaryValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING , true))); - tmpMap.put(_Fields.BYTE_VALUE, new org.apache.thrift.meta_data.FieldMetaData("byteValue", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.BYTE_VALUE, new org.apache.thrift.meta_data.FieldMetaData("byteValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BYTE))); - tmpMap.put(_Fields.INT_STRING_VALUE, new org.apache.thrift.meta_data.FieldMetaData("intStringValue", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.INT_STRING_VALUE, new org.apache.thrift.meta_data.FieldMetaData("intStringValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TIntStringValue.class))); - tmpMap.put(_Fields.INT_STRING_STRING_VALUE, new org.apache.thrift.meta_data.FieldMetaData("intStringStringValue", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.INT_STRING_STRING_VALUE, new org.apache.thrift.meta_data.FieldMetaData("intStringStringValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TIntStringStringValue.class))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TAnnotationValue.class, metaDataMap); } @@ -163,7 +136,7 @@ public class TAnnotationValue extends org.apache.thrift.TUnion list = new ArrayList(); + java.util.List list = new java.util.ArrayList(); list.add(this.getClass().getName()); org.apache.thrift.TFieldIdEnum setField = getSetField(); if (setField != null) { list.add(setField.getThriftFieldId()); - Object value = getFieldValue(); + java.lang.Object value = getFieldValue(); if (value instanceof org.apache.thrift.TEnum) { list.add(((org.apache.thrift.TEnum)getFieldValue()).getValue()); } else { @@ -840,7 +813,7 @@ public class TAnnotationValue extends org.apache.thrift.TUnion, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TApiMetaData"); @@ -45,16 +18,13 @@ public class TApiMetaData implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TApiMetaDataStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TApiMetaDataTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TApiMetaDataStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TApiMetaDataTupleSchemeFactory(); - private String agentId; // required + private java.lang.String agentId; // required private long agentStartTime; // required private int apiId; // required - private String apiInfo; // required + private java.lang.String apiInfo; // required private int line; // optional private int type; // optional @@ -67,10 +37,10 @@ public class TApiMetaData implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -103,21 +73,21 @@ public class TApiMetaData implements org.apache.thrift.TBase 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.AGENT_ID, new org.apache.thrift.meta_data.FieldMetaData("agentId", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.AGENT_START_TIME, new org.apache.thrift.meta_data.FieldMetaData("agentStartTime", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -153,7 +123,7 @@ public class TApiMetaData implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_agentId = true && (isSetAgentId()); - list.add(present_agentId); - if (present_agentId) - list.add(agentId); + hashCode = hashCode * 8191 + ((isSetAgentId()) ? 131071 : 524287); + if (isSetAgentId()) + hashCode = hashCode * 8191 + agentId.hashCode(); - boolean present_agentStartTime = true; - list.add(present_agentStartTime); - if (present_agentStartTime) - list.add(agentStartTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(agentStartTime); - boolean present_apiId = true; - list.add(present_apiId); - if (present_apiId) - list.add(apiId); + hashCode = hashCode * 8191 + apiId; - boolean present_apiInfo = true && (isSetApiInfo()); - list.add(present_apiInfo); - if (present_apiInfo) - list.add(apiInfo); + hashCode = hashCode * 8191 + ((isSetApiInfo()) ? 131071 : 524287); + if (isSetApiInfo()) + hashCode = hashCode * 8191 + apiInfo.hashCode(); - boolean present_line = true && (isSetLine()); - list.add(present_line); - if (present_line) - list.add(line); + hashCode = hashCode * 8191 + ((isSetLine()) ? 131071 : 524287); + if (isSetLine()) + hashCode = hashCode * 8191 + line; - 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; - return list.hashCode(); + return hashCode; } @Override @@ -559,7 +521,7 @@ public class TApiMetaData implements org.apache.thrift.TBase { + private static class TApiMetaDataStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TApiMetaData struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -812,18 +774,18 @@ public class TApiMetaData implements org.apache.thrift.TBase { + private static class TApiMetaDataTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TApiMetaData 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.isSetAgentId()) { optionals.set(0); } @@ -865,8 +827,8 @@ public class TApiMetaData implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TCpuLoad.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TCpuLoad.java index da99ed6a8..f4d2b9a0c 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TCpuLoad.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TCpuLoad.java @@ -1,51 +1,21 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCpuLoad implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCpuLoad"); private static final org.apache.thrift.protocol.TField JVM_CPU_LOAD_FIELD_DESC = new org.apache.thrift.protocol.TField("jvmCpuLoad", org.apache.thrift.protocol.TType.DOUBLE, (short)1); private static final org.apache.thrift.protocol.TField SYSTEM_CPU_LOAD_FIELD_DESC = new org.apache.thrift.protocol.TField("systemCpuLoad", org.apache.thrift.protocol.TType.DOUBLE, (short)2); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCpuLoadStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCpuLoadTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCpuLoadStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCpuLoadTupleSchemeFactory(); private double jvmCpuLoad; // optional private double systemCpuLoad; // optional @@ -55,10 +25,10 @@ public class TCpuLoad implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -83,21 +53,21 @@ public class TCpuLoad implements org.apache.thrift.TBase 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.JVM_CPU_LOAD, new org.apache.thrift.meta_data.FieldMetaData("jvmCpuLoad", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE))); tmpMap.put(_Fields.SYSTEM_CPU_LOAD, new org.apache.thrift.meta_data.FieldMetaData("systemCpuLoad", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TCpuLoad.class, metaDataMap); } @@ -161,16 +131,16 @@ public class TCpuLoad implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_jvmCpuLoad = true && (isSetJvmCpuLoad()); - list.add(present_jvmCpuLoad); - if (present_jvmCpuLoad) - list.add(jvmCpuLoad); + hashCode = hashCode * 8191 + ((isSetJvmCpuLoad()) ? 131071 : 524287); + if (isSetJvmCpuLoad()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmCpuLoad); - boolean present_systemCpuLoad = true && (isSetSystemCpuLoad()); - list.add(present_systemCpuLoad); - if (present_systemCpuLoad) - list.add(systemCpuLoad); + hashCode = hashCode * 8191 + ((isSetSystemCpuLoad()) ? 131071 : 524287); + if (isSetSystemCpuLoad()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(systemCpuLoad); - return list.hashCode(); + return hashCode; } @Override @@ -302,7 +272,7 @@ public class TCpuLoad implements org.apache.thrift.TBase { + private static class TCpuLoadStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCpuLoad struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -443,18 +413,18 @@ public class TCpuLoad implements org.apache.thrift.TBase { + private static class TCpuLoadTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCpuLoad 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.isSetJvmCpuLoad()) { optionals.set(0); } @@ -472,8 +442,8 @@ public class TCpuLoad implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TDataSource.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TDataSource.java index a38b1271d..397586880 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TDataSource.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TDataSource.java @@ -1,30 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -import org.apache.thrift.EncodingUtils; -import org.apache.thrift.protocol.TTupleProtocol; -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 javax.annotation.Generated; -import java.util.ArrayList; -import java.util.BitSet; -import java.util.Collections; -import java.util.EnumMap; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) -@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2017-2-22") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TDataSource implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TDataSource"); @@ -35,16 +18,13 @@ public class TDataSource implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TDataSourceStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TDataSourceTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TDataSourceStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TDataSourceTupleSchemeFactory(); private int id; // required private short serviceTypeCode; // optional - private String databaseName; // optional - private String url; // optional + private java.lang.String databaseName; // optional + private java.lang.String url; // optional private int activeConnectionSize; // optional private int maxConnectionSize; // optional @@ -57,10 +37,10 @@ public class TDataSource implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -93,21 +73,21 @@ public class TDataSource implements org.apache.thrift.TBase 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.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); tmpMap.put(_Fields.SERVICE_TYPE_CODE, new org.apache.thrift.meta_data.FieldMetaData("serviceTypeCode", org.apache.thrift.TFieldRequirementType.OPTIONAL, @@ -143,7 +123,7 @@ public class TDataSource implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_id = true; - list.add(present_id); - if (present_id) - list.add(id); + hashCode = hashCode * 8191 + id; - boolean present_serviceTypeCode = true && (isSetServiceTypeCode()); - list.add(present_serviceTypeCode); - if (present_serviceTypeCode) - list.add(serviceTypeCode); + hashCode = hashCode * 8191 + ((isSetServiceTypeCode()) ? 131071 : 524287); + if (isSetServiceTypeCode()) + hashCode = hashCode * 8191 + serviceTypeCode; - boolean present_databaseName = true && (isSetDatabaseName()); - list.add(present_databaseName); - if (present_databaseName) - list.add(databaseName); + hashCode = hashCode * 8191 + ((isSetDatabaseName()) ? 131071 : 524287); + if (isSetDatabaseName()) + hashCode = hashCode * 8191 + databaseName.hashCode(); - boolean present_url = true && (isSetUrl()); - list.add(present_url); - if (present_url) - list.add(url); + hashCode = hashCode * 8191 + ((isSetUrl()) ? 131071 : 524287); + if (isSetUrl()) + hashCode = hashCode * 8191 + url.hashCode(); - boolean present_activeConnectionSize = true && (isSetActiveConnectionSize()); - list.add(present_activeConnectionSize); - if (present_activeConnectionSize) - list.add(activeConnectionSize); + hashCode = hashCode * 8191 + ((isSetActiveConnectionSize()) ? 131071 : 524287); + if (isSetActiveConnectionSize()) + hashCode = hashCode * 8191 + activeConnectionSize; - boolean present_maxConnectionSize = true && (isSetMaxConnectionSize()); - list.add(present_maxConnectionSize); - if (present_maxConnectionSize) - list.add(maxConnectionSize); + hashCode = hashCode * 8191 + ((isSetMaxConnectionSize()) ? 131071 : 524287); + if (isSetMaxConnectionSize()) + hashCode = hashCode * 8191 + maxConnectionSize; - return list.hashCode(); + return hashCode; } @Override @@ -544,7 +518,7 @@ public class TDataSource implements org.apache.thrift.TBase { + private static class TDataSourceStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TDataSource struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -809,18 +783,18 @@ public class TDataSource implements org.apache.thrift.TBase { + private static class TDataSourceTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TDataSource 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.isSetId()) { optionals.set(0); } @@ -862,8 +836,8 @@ public class TDataSource implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TDataSourceList.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TDataSourceList.java index d756a744e..b40b20795 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TDataSourceList.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TDataSourceList.java @@ -1,50 +1,31 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -import org.apache.thrift.protocol.TTupleProtocol; -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 javax.annotation.Generated; -import java.util.ArrayList; -import java.util.BitSet; -import java.util.Collections; -import java.util.EnumMap; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) -@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2017-1-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TDataSourceList implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TDataSourceList"); private static final org.apache.thrift.protocol.TField DATA_SOURCE_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("dataSourceList", org.apache.thrift.protocol.TType.LIST, (short)1); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TDataSourceListStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TDataSourceListTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TDataSourceListStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TDataSourceListTupleSchemeFactory(); - private List dataSourceList; // required + private java.util.List dataSourceList; // 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 { DATA_SOURCE_LIST((short)1, "dataSourceList"); - private static final Map byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -67,21 +48,21 @@ public class TDataSourceList implements org.apache.thrift.TBase 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.DATA_SOURCE_LIST, new org.apache.thrift.meta_data.FieldMetaData("dataSourceList", 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, TDataSource.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TDataSourceList.class, metaDataMap); } @@ -110,7 +91,7 @@ public class TDataSourceList implements org.apache.thrift.TBase dataSourceList) + java.util.List dataSourceList) { this(); this.dataSourceList = dataSourceList; @@ -121,7 +102,7 @@ public class TDataSourceList implements org.apache.thrift.TBase __this__dataSourceList = new ArrayList(other.dataSourceList.size()); + java.util.List __this__dataSourceList = new java.util.ArrayList(other.dataSourceList.size()); for (TDataSource other_element : other.dataSourceList) { __this__dataSourceList.add(new TDataSource(other_element)); } @@ -148,16 +129,16 @@ public class TDataSourceList implements org.apache.thrift.TBase(); + this.dataSourceList = new java.util.ArrayList(); } this.dataSourceList.add(elem); } - public List getDataSourceList() { + public java.util.List getDataSourceList() { return this.dataSourceList; } - public void setDataSourceList(List dataSourceList) { + public void setDataSourceList(java.util.List dataSourceList) { this.dataSourceList = dataSourceList; } @@ -176,43 +157,43 @@ public class TDataSourceList implements org.apache.thrift.TBase)value); + setDataSourceList((java.util.List)value); } break; } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case DATA_SOURCE_LIST: return getDataSourceList(); } - 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 DATA_SOURCE_LIST: return isSetDataSourceList(); } - 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 TDataSourceList) @@ -223,6 +204,8 @@ public class TDataSourceList implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_dataSourceList = true && (isSetDataSourceList()); - list.add(present_dataSourceList); - if (present_dataSourceList) - list.add(dataSourceList); + hashCode = hashCode * 8191 + ((isSetDataSourceList()) ? 131071 : 524287); + if (isSetDataSourceList()) + hashCode = hashCode * 8191 + dataSourceList.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -256,7 +238,7 @@ public class TDataSourceList implements org.apache.thrift.TBase { + private static class TDataSourceListStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TDataSourceList struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -340,7 +322,7 @@ public class TDataSourceList implements org.apache.thrift.TBase(_list40.size); + struct.dataSourceList = new java.util.ArrayList(_list40.size); TDataSource _elem41; for (int _i42 = 0; _i42 < _list40.size; ++_i42) { @@ -386,18 +368,18 @@ public class TDataSourceList implements org.apache.thrift.TBase { + private static class TDataSourceListTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TDataSourceList 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.isSetDataSourceList()) { optionals.set(0); } @@ -415,12 +397,12 @@ public class TDataSourceList implements org.apache.thrift.TBase(_list45.size); + struct.dataSourceList = new java.util.ArrayList(_list45.size); TDataSource _elem46; for (int _i47 = 0; _i47 < _list45.size; ++_i47) { @@ -434,5 +416,8 @@ public class TDataSourceList implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TIntStringStringValue.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TIntStringStringValue.java index 7dad228b9..d4d57062a 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TIntStringStringValue.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TIntStringStringValue.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TIntStringStringValue implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TIntStringStringValue"); @@ -42,15 +15,12 @@ public class TIntStringStringValue implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TIntStringStringValueStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TIntStringStringValueTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TIntStringStringValueStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TIntStringStringValueTupleSchemeFactory(); private int intValue; // required - private String stringValue1; // optional - private String stringValue2; // optional + private java.lang.String stringValue1; // optional + private java.lang.String stringValue2; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { @@ -58,10 +28,10 @@ public class TIntStringStringValue implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -88,21 +58,21 @@ public class TIntStringStringValue implements org.apache.thrift.TBase 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.INT_VALUE, new org.apache.thrift.meta_data.FieldMetaData("intValue", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); tmpMap.put(_Fields.STRING_VALUE1, new org.apache.thrift.meta_data.FieldMetaData("stringValue1", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.STRING_VALUE2, new org.apache.thrift.meta_data.FieldMetaData("stringValue2", org.apache.thrift.TFieldRequirementType.OPTIONAL, 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(TIntStringStringValue.class, metaDataMap); } @@ -180,23 +150,23 @@ public class TIntStringStringValue implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_intValue = true; - list.add(present_intValue); - if (present_intValue) - list.add(intValue); + hashCode = hashCode * 8191 + intValue; - boolean present_stringValue1 = true && (isSetStringValue1()); - list.add(present_stringValue1); - if (present_stringValue1) - list.add(stringValue1); + hashCode = hashCode * 8191 + ((isSetStringValue1()) ? 131071 : 524287); + if (isSetStringValue1()) + hashCode = hashCode * 8191 + stringValue1.hashCode(); - boolean present_stringValue2 = true && (isSetStringValue2()); - list.add(present_stringValue2); - if (present_stringValue2) - list.add(stringValue2); + hashCode = hashCode * 8191 + ((isSetStringValue2()) ? 131071 : 524287); + if (isSetStringValue2()) + hashCode = hashCode * 8191 + stringValue2.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -372,7 +339,7 @@ public class TIntStringStringValue implements org.apache.thrift.TBase { + private static class TIntStringStringValueStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TIntStringStringValue struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -550,18 +517,18 @@ public class TIntStringStringValue implements org.apache.thrift.TBase { + private static class TIntStringStringValueTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TIntStringStringValue 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.isSetIntValue()) { optionals.set(0); } @@ -585,8 +552,8 @@ public class TIntStringStringValue implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TIntStringValue.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TIntStringValue.java index dbd17535b..f82e63e89 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TIntStringValue.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TIntStringValue.java @@ -1,64 +1,34 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TIntStringValue implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TIntStringValue"); private static final org.apache.thrift.protocol.TField INT_VALUE_FIELD_DESC = new org.apache.thrift.protocol.TField("intValue", org.apache.thrift.protocol.TType.I32, (short)1); private static final org.apache.thrift.protocol.TField STRING_VALUE_FIELD_DESC = new org.apache.thrift.protocol.TField("stringValue", org.apache.thrift.protocol.TType.STRING, (short)2); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TIntStringValueStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TIntStringValueTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TIntStringValueStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TIntStringValueTupleSchemeFactory(); private int intValue; // required - private String stringValue; // optional + private java.lang.String stringValue; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { INT_VALUE((short)1, "intValue"), STRING_VALUE((short)2, "stringValue"); - private static final Map byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -83,21 +53,21 @@ public class TIntStringValue implements org.apache.thrift.TBase 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.INT_VALUE, new org.apache.thrift.meta_data.FieldMetaData("intValue", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); tmpMap.put(_Fields.STRING_VALUE, new org.apache.thrift.meta_data.FieldMetaData("stringValue", org.apache.thrift.TFieldRequirementType.OPTIONAL, 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(TIntStringValue.class, metaDataMap); } @@ -169,23 +139,23 @@ public class TIntStringValue implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_intValue = true; - list.add(present_intValue); - if (present_intValue) - list.add(intValue); + hashCode = hashCode * 8191 + intValue; - boolean present_stringValue = true && (isSetStringValue()); - list.add(present_stringValue); - if (present_stringValue) - list.add(stringValue); + hashCode = hashCode * 8191 + ((isSetStringValue()) ? 131071 : 524287); + if (isSetStringValue()) + hashCode = hashCode * 8191 + stringValue.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -311,7 +279,7 @@ public class TIntStringValue implements org.apache.thrift.TBase { + private static class TIntStringValueStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TIntStringValue struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -454,18 +422,18 @@ public class TIntStringValue implements org.apache.thrift.TBase { + private static class TIntStringValueTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TIntStringValue 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.isSetIntValue()) { optionals.set(0); } @@ -483,8 +451,8 @@ public class TIntStringValue implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGc.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGc.java index 782e45fe3..9cd537260 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGc.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGc.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-12-18") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TJvmGc implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TJvmGc"); @@ -47,11 +20,8 @@ public class TJvmGc implements org.apache.thrift.TBase, private static final org.apache.thrift.protocol.TField JVM_GC_OLD_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("jvmGcOldTime", org.apache.thrift.protocol.TType.I64, (short)7); private static final org.apache.thrift.protocol.TField JVM_GC_DETAILED_FIELD_DESC = new org.apache.thrift.protocol.TField("jvmGcDetailed", org.apache.thrift.protocol.TType.STRUCT, (short)8); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TJvmGcStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TJvmGcTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TJvmGcStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TJvmGcTupleSchemeFactory(); private TJvmGcType type; // required private long jvmMemoryHeapUsed; // required @@ -77,10 +47,10 @@ public class TJvmGc implements org.apache.thrift.TBase, JVM_GC_OLD_TIME((short)7, "jvmGcOldTime"), JVM_GC_DETAILED((short)8, "jvmGcDetailed"); - private static final Map byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -117,21 +87,21 @@ public class TJvmGc implements org.apache.thrift.TBase, */ 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) { + 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; } @@ -140,7 +110,7 @@ public class TJvmGc implements org.apache.thrift.TBase, return _thriftId; } - public String getFieldName() { + public java.lang.String getFieldName() { return _fieldName; } } @@ -154,9 +124,9 @@ public class TJvmGc implements org.apache.thrift.TBase, private static final int __JVMGCOLDTIME_ISSET_ID = 5; private byte __isset_bitfield = 0; private static final _Fields optionals[] = {_Fields.JVM_GC_DETAILED}; - 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, TJvmGcType.class))); tmpMap.put(_Fields.JVM_MEMORY_HEAP_USED, new org.apache.thrift.meta_data.FieldMetaData("jvmMemoryHeapUsed", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -173,7 +143,7 @@ public class TJvmGc implements org.apache.thrift.TBase, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))); tmpMap.put(_Fields.JVM_GC_DETAILED, new org.apache.thrift.meta_data.FieldMetaData("jvmGcDetailed", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT , "TJvmGcDetailed"))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TJvmGc.class, metaDataMap); } @@ -222,7 +192,7 @@ public class TJvmGc implements org.apache.thrift.TBase, this.jvmGcOldCount = other.jvmGcOldCount; this.jvmGcOldTime = other.jvmGcOldTime; if (other.isSetJvmGcDetailed()) { - this.jvmGcDetailed = other.jvmGcDetailed; + this.jvmGcDetailed = new TJvmGcDetailed(other.jvmGcDetailed); } } @@ -290,16 +260,16 @@ public class TJvmGc implements org.apache.thrift.TBase, } public void unsetJvmMemoryHeapUsed() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __JVMMEMORYHEAPUSED_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __JVMMEMORYHEAPUSED_ISSET_ID); } /** Returns true if field jvmMemoryHeapUsed is set (has been assigned a value) and false otherwise */ public boolean isSetJvmMemoryHeapUsed() { - return EncodingUtils.testBit(__isset_bitfield, __JVMMEMORYHEAPUSED_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __JVMMEMORYHEAPUSED_ISSET_ID); } public void setJvmMemoryHeapUsedIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __JVMMEMORYHEAPUSED_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __JVMMEMORYHEAPUSED_ISSET_ID, value); } public long getJvmMemoryHeapMax() { @@ -312,16 +282,16 @@ public class TJvmGc implements org.apache.thrift.TBase, } public void unsetJvmMemoryHeapMax() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __JVMMEMORYHEAPMAX_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __JVMMEMORYHEAPMAX_ISSET_ID); } /** Returns true if field jvmMemoryHeapMax is set (has been assigned a value) and false otherwise */ public boolean isSetJvmMemoryHeapMax() { - return EncodingUtils.testBit(__isset_bitfield, __JVMMEMORYHEAPMAX_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __JVMMEMORYHEAPMAX_ISSET_ID); } public void setJvmMemoryHeapMaxIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __JVMMEMORYHEAPMAX_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __JVMMEMORYHEAPMAX_ISSET_ID, value); } public long getJvmMemoryNonHeapUsed() { @@ -334,16 +304,16 @@ public class TJvmGc implements org.apache.thrift.TBase, } public void unsetJvmMemoryNonHeapUsed() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __JVMMEMORYNONHEAPUSED_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __JVMMEMORYNONHEAPUSED_ISSET_ID); } /** Returns true if field jvmMemoryNonHeapUsed is set (has been assigned a value) and false otherwise */ public boolean isSetJvmMemoryNonHeapUsed() { - return EncodingUtils.testBit(__isset_bitfield, __JVMMEMORYNONHEAPUSED_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __JVMMEMORYNONHEAPUSED_ISSET_ID); } public void setJvmMemoryNonHeapUsedIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __JVMMEMORYNONHEAPUSED_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __JVMMEMORYNONHEAPUSED_ISSET_ID, value); } public long getJvmMemoryNonHeapMax() { @@ -356,16 +326,16 @@ public class TJvmGc implements org.apache.thrift.TBase, } public void unsetJvmMemoryNonHeapMax() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __JVMMEMORYNONHEAPMAX_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __JVMMEMORYNONHEAPMAX_ISSET_ID); } /** Returns true if field jvmMemoryNonHeapMax is set (has been assigned a value) and false otherwise */ public boolean isSetJvmMemoryNonHeapMax() { - return EncodingUtils.testBit(__isset_bitfield, __JVMMEMORYNONHEAPMAX_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __JVMMEMORYNONHEAPMAX_ISSET_ID); } public void setJvmMemoryNonHeapMaxIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __JVMMEMORYNONHEAPMAX_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __JVMMEMORYNONHEAPMAX_ISSET_ID, value); } public long getJvmGcOldCount() { @@ -378,16 +348,16 @@ public class TJvmGc implements org.apache.thrift.TBase, } public void unsetJvmGcOldCount() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __JVMGCOLDCOUNT_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __JVMGCOLDCOUNT_ISSET_ID); } /** Returns true if field jvmGcOldCount is set (has been assigned a value) and false otherwise */ public boolean isSetJvmGcOldCount() { - return EncodingUtils.testBit(__isset_bitfield, __JVMGCOLDCOUNT_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __JVMGCOLDCOUNT_ISSET_ID); } public void setJvmGcOldCountIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __JVMGCOLDCOUNT_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __JVMGCOLDCOUNT_ISSET_ID, value); } public long getJvmGcOldTime() { @@ -400,16 +370,16 @@ public class TJvmGc implements org.apache.thrift.TBase, } public void unsetJvmGcOldTime() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __JVMGCOLDTIME_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __JVMGCOLDTIME_ISSET_ID); } /** Returns true if field jvmGcOldTime is set (has been assigned a value) and false otherwise */ public boolean isSetJvmGcOldTime() { - return EncodingUtils.testBit(__isset_bitfield, __JVMGCOLDTIME_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __JVMGCOLDTIME_ISSET_ID); } public void setJvmGcOldTimeIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __JVMGCOLDTIME_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __JVMGCOLDTIME_ISSET_ID, value); } public TJvmGcDetailed getJvmGcDetailed() { @@ -435,7 +405,7 @@ public class TJvmGc implements org.apache.thrift.TBase, } } - public void setFieldValue(_Fields field, Object value) { + public void setFieldValue(_Fields field, java.lang.Object value) { switch (field) { case TYPE: if (value == null) { @@ -449,7 +419,7 @@ public class TJvmGc implements org.apache.thrift.TBase, if (value == null) { unsetJvmMemoryHeapUsed(); } else { - setJvmMemoryHeapUsed((Long)value); + setJvmMemoryHeapUsed((java.lang.Long)value); } break; @@ -457,7 +427,7 @@ public class TJvmGc implements org.apache.thrift.TBase, if (value == null) { unsetJvmMemoryHeapMax(); } else { - setJvmMemoryHeapMax((Long)value); + setJvmMemoryHeapMax((java.lang.Long)value); } break; @@ -465,7 +435,7 @@ public class TJvmGc implements org.apache.thrift.TBase, if (value == null) { unsetJvmMemoryNonHeapUsed(); } else { - setJvmMemoryNonHeapUsed((Long)value); + setJvmMemoryNonHeapUsed((java.lang.Long)value); } break; @@ -473,7 +443,7 @@ public class TJvmGc implements org.apache.thrift.TBase, if (value == null) { unsetJvmMemoryNonHeapMax(); } else { - setJvmMemoryNonHeapMax((Long)value); + setJvmMemoryNonHeapMax((java.lang.Long)value); } break; @@ -481,7 +451,7 @@ public class TJvmGc implements org.apache.thrift.TBase, if (value == null) { unsetJvmGcOldCount(); } else { - setJvmGcOldCount((Long)value); + setJvmGcOldCount((java.lang.Long)value); } break; @@ -489,7 +459,7 @@ public class TJvmGc implements org.apache.thrift.TBase, if (value == null) { unsetJvmGcOldTime(); } else { - setJvmGcOldTime((Long)value); + setJvmGcOldTime((java.lang.Long)value); } break; @@ -504,40 +474,40 @@ public class TJvmGc implements org.apache.thrift.TBase, } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case TYPE: return getType(); case JVM_MEMORY_HEAP_USED: - return Long.valueOf(getJvmMemoryHeapUsed()); + return getJvmMemoryHeapUsed(); case JVM_MEMORY_HEAP_MAX: - return Long.valueOf(getJvmMemoryHeapMax()); + return getJvmMemoryHeapMax(); case JVM_MEMORY_NON_HEAP_USED: - return Long.valueOf(getJvmMemoryNonHeapUsed()); + return getJvmMemoryNonHeapUsed(); case JVM_MEMORY_NON_HEAP_MAX: - return Long.valueOf(getJvmMemoryNonHeapMax()); + return getJvmMemoryNonHeapMax(); case JVM_GC_OLD_COUNT: - return Long.valueOf(getJvmGcOldCount()); + return getJvmGcOldCount(); case JVM_GC_OLD_TIME: - return Long.valueOf(getJvmGcOldTime()); + return getJvmGcOldTime(); case JVM_GC_DETAILED: return getJvmGcDetailed(); } - 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) { @@ -558,11 +528,11 @@ public class TJvmGc implements org.apache.thrift.TBase, case JVM_GC_DETAILED: return isSetJvmGcDetailed(); } - 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 TJvmGc) @@ -573,6 +543,8 @@ public class TJvmGc implements org.apache.thrift.TBase, public boolean equals(TJvmGc 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(); @@ -651,49 +623,29 @@ public class TJvmGc implements org.apache.thrift.TBase, @Override public int hashCode() { - List list = new ArrayList(); + 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_jvmMemoryHeapUsed = true; - list.add(present_jvmMemoryHeapUsed); - if (present_jvmMemoryHeapUsed) - list.add(jvmMemoryHeapUsed); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmMemoryHeapUsed); - boolean present_jvmMemoryHeapMax = true; - list.add(present_jvmMemoryHeapMax); - if (present_jvmMemoryHeapMax) - list.add(jvmMemoryHeapMax); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmMemoryHeapMax); - boolean present_jvmMemoryNonHeapUsed = true; - list.add(present_jvmMemoryNonHeapUsed); - if (present_jvmMemoryNonHeapUsed) - list.add(jvmMemoryNonHeapUsed); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmMemoryNonHeapUsed); - boolean present_jvmMemoryNonHeapMax = true; - list.add(present_jvmMemoryNonHeapMax); - if (present_jvmMemoryNonHeapMax) - list.add(jvmMemoryNonHeapMax); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmMemoryNonHeapMax); - boolean present_jvmGcOldCount = true; - list.add(present_jvmGcOldCount); - if (present_jvmGcOldCount) - list.add(jvmGcOldCount); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmGcOldCount); - boolean present_jvmGcOldTime = true; - list.add(present_jvmGcOldTime); - if (present_jvmGcOldTime) - list.add(jvmGcOldTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmGcOldTime); - boolean present_jvmGcDetailed = true && (isSetJvmGcDetailed()); - list.add(present_jvmGcDetailed); - if (present_jvmGcDetailed) - list.add(jvmGcDetailed); + hashCode = hashCode * 8191 + ((isSetJvmGcDetailed()) ? 131071 : 524287); + if (isSetJvmGcDetailed()) + hashCode = hashCode * 8191 + jvmGcDetailed.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -704,7 +656,7 @@ public class TJvmGc implements org.apache.thrift.TBase, int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetType()).compareTo(other.isSetType()); + lastComparison = java.lang.Boolean.valueOf(isSetType()).compareTo(other.isSetType()); if (lastComparison != 0) { return lastComparison; } @@ -714,7 +666,7 @@ public class TJvmGc implements org.apache.thrift.TBase, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetJvmMemoryHeapUsed()).compareTo(other.isSetJvmMemoryHeapUsed()); + lastComparison = java.lang.Boolean.valueOf(isSetJvmMemoryHeapUsed()).compareTo(other.isSetJvmMemoryHeapUsed()); if (lastComparison != 0) { return lastComparison; } @@ -724,7 +676,7 @@ public class TJvmGc implements org.apache.thrift.TBase, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetJvmMemoryHeapMax()).compareTo(other.isSetJvmMemoryHeapMax()); + lastComparison = java.lang.Boolean.valueOf(isSetJvmMemoryHeapMax()).compareTo(other.isSetJvmMemoryHeapMax()); if (lastComparison != 0) { return lastComparison; } @@ -734,7 +686,7 @@ public class TJvmGc implements org.apache.thrift.TBase, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetJvmMemoryNonHeapUsed()).compareTo(other.isSetJvmMemoryNonHeapUsed()); + lastComparison = java.lang.Boolean.valueOf(isSetJvmMemoryNonHeapUsed()).compareTo(other.isSetJvmMemoryNonHeapUsed()); if (lastComparison != 0) { return lastComparison; } @@ -744,7 +696,7 @@ public class TJvmGc implements org.apache.thrift.TBase, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetJvmMemoryNonHeapMax()).compareTo(other.isSetJvmMemoryNonHeapMax()); + lastComparison = java.lang.Boolean.valueOf(isSetJvmMemoryNonHeapMax()).compareTo(other.isSetJvmMemoryNonHeapMax()); if (lastComparison != 0) { return lastComparison; } @@ -754,7 +706,7 @@ public class TJvmGc implements org.apache.thrift.TBase, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetJvmGcOldCount()).compareTo(other.isSetJvmGcOldCount()); + lastComparison = java.lang.Boolean.valueOf(isSetJvmGcOldCount()).compareTo(other.isSetJvmGcOldCount()); if (lastComparison != 0) { return lastComparison; } @@ -764,7 +716,7 @@ public class TJvmGc implements org.apache.thrift.TBase, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetJvmGcOldTime()).compareTo(other.isSetJvmGcOldTime()); + lastComparison = java.lang.Boolean.valueOf(isSetJvmGcOldTime()).compareTo(other.isSetJvmGcOldTime()); if (lastComparison != 0) { return lastComparison; } @@ -774,7 +726,7 @@ public class TJvmGc implements org.apache.thrift.TBase, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetJvmGcDetailed()).compareTo(other.isSetJvmGcDetailed()); + lastComparison = java.lang.Boolean.valueOf(isSetJvmGcDetailed()).compareTo(other.isSetJvmGcDetailed()); if (lastComparison != 0) { return lastComparison; } @@ -792,16 +744,16 @@ public class TJvmGc implements org.apache.thrift.TBase, } 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("TJvmGc("); + public java.lang.String toString() { + java.lang.StringBuilder sb = new java.lang.StringBuilder("TJvmGc("); boolean first = true; sb.append("type:"); @@ -862,7 +814,7 @@ public class TJvmGc implements org.apache.thrift.TBase, } } - 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; @@ -872,13 +824,13 @@ public class TJvmGc implements org.apache.thrift.TBase, } } - private static class TJvmGcStandardSchemeFactory implements SchemeFactory { + private static class TJvmGcStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory { public TJvmGcStandardScheme getScheme() { return new TJvmGcStandardScheme(); } } - private static class TJvmGcStandardScheme extends StandardScheme { + private static class TJvmGcStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TJvmGc struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -1004,18 +956,18 @@ public class TJvmGc implements org.apache.thrift.TBase, } - private static class TJvmGcTupleSchemeFactory implements SchemeFactory { + private static class TJvmGcTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory { public TJvmGcTupleScheme getScheme() { return new TJvmGcTupleScheme(); } } - private static class TJvmGcTupleScheme extends TupleScheme { + private static class TJvmGcTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TJvmGc 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); } @@ -1069,8 +1021,8 @@ public class TJvmGc implements org.apache.thrift.TBase, @Override public void read(org.apache.thrift.protocol.TProtocol prot, TJvmGc struct) throws org.apache.thrift.TException { - TTupleProtocol iprot = (TTupleProtocol) prot; - BitSet incoming = iprot.readBitSet(8); + org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot; + java.util.BitSet incoming = iprot.readBitSet(8); if (incoming.get(0)) { struct.type = com.navercorp.pinpoint.thrift.dto.TJvmGcType.findByValue(iprot.readI32()); struct.setTypeIsSet(true); @@ -1107,5 +1059,8 @@ public class TJvmGc implements org.apache.thrift.TBase, } } + private static 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGcDetailed.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGcDetailed.java index c8b6ff2f1..32b083420 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGcDetailed.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGcDetailed.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-12-18") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TJvmGcDetailed implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TJvmGcDetailed"); @@ -47,11 +20,8 @@ public class TJvmGcDetailed implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TJvmGcDetailedStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TJvmGcDetailedTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TJvmGcDetailedStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TJvmGcDetailedTupleSchemeFactory(); private long jvmGcNewCount; // optional private long jvmGcNewTime; // optional @@ -73,10 +43,10 @@ public class TJvmGcDetailed implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -113,21 +83,21 @@ public class TJvmGcDetailed implements org.apache.thrift.TBase 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.JVM_GC_NEW_COUNT, new org.apache.thrift.meta_data.FieldMetaData("jvmGcNewCount", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))); tmpMap.put(_Fields.JVM_GC_NEW_TIME, new org.apache.thrift.meta_data.FieldMetaData("jvmGcNewTime", org.apache.thrift.TFieldRequirementType.OPTIONAL, @@ -171,7 +141,7 @@ public class TJvmGcDetailed implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_jvmGcNewCount = true && (isSetJvmGcNewCount()); - list.add(present_jvmGcNewCount); - if (present_jvmGcNewCount) - list.add(jvmGcNewCount); + hashCode = hashCode * 8191 + ((isSetJvmGcNewCount()) ? 131071 : 524287); + if (isSetJvmGcNewCount()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmGcNewCount); - boolean present_jvmGcNewTime = true && (isSetJvmGcNewTime()); - list.add(present_jvmGcNewTime); - if (present_jvmGcNewTime) - list.add(jvmGcNewTime); + hashCode = hashCode * 8191 + ((isSetJvmGcNewTime()) ? 131071 : 524287); + if (isSetJvmGcNewTime()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmGcNewTime); - boolean present_jvmPoolCodeCacheUsed = true && (isSetJvmPoolCodeCacheUsed()); - list.add(present_jvmPoolCodeCacheUsed); - if (present_jvmPoolCodeCacheUsed) - list.add(jvmPoolCodeCacheUsed); + hashCode = hashCode * 8191 + ((isSetJvmPoolCodeCacheUsed()) ? 131071 : 524287); + if (isSetJvmPoolCodeCacheUsed()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmPoolCodeCacheUsed); - boolean present_jvmPoolNewGenUsed = true && (isSetJvmPoolNewGenUsed()); - list.add(present_jvmPoolNewGenUsed); - if (present_jvmPoolNewGenUsed) - list.add(jvmPoolNewGenUsed); + hashCode = hashCode * 8191 + ((isSetJvmPoolNewGenUsed()) ? 131071 : 524287); + if (isSetJvmPoolNewGenUsed()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmPoolNewGenUsed); - boolean present_jvmPoolOldGenUsed = true && (isSetJvmPoolOldGenUsed()); - list.add(present_jvmPoolOldGenUsed); - if (present_jvmPoolOldGenUsed) - list.add(jvmPoolOldGenUsed); + hashCode = hashCode * 8191 + ((isSetJvmPoolOldGenUsed()) ? 131071 : 524287); + if (isSetJvmPoolOldGenUsed()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmPoolOldGenUsed); - boolean present_jvmPoolSurvivorSpaceUsed = true && (isSetJvmPoolSurvivorSpaceUsed()); - list.add(present_jvmPoolSurvivorSpaceUsed); - if (present_jvmPoolSurvivorSpaceUsed) - list.add(jvmPoolSurvivorSpaceUsed); + hashCode = hashCode * 8191 + ((isSetJvmPoolSurvivorSpaceUsed()) ? 131071 : 524287); + if (isSetJvmPoolSurvivorSpaceUsed()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmPoolSurvivorSpaceUsed); - boolean present_jvmPoolPermGenUsed = true && (isSetJvmPoolPermGenUsed()); - list.add(present_jvmPoolPermGenUsed); - if (present_jvmPoolPermGenUsed) - list.add(jvmPoolPermGenUsed); + hashCode = hashCode * 8191 + ((isSetJvmPoolPermGenUsed()) ? 131071 : 524287); + if (isSetJvmPoolPermGenUsed()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmPoolPermGenUsed); - boolean present_jvmPoolMetaspaceUsed = true && (isSetJvmPoolMetaspaceUsed()); - list.add(present_jvmPoolMetaspaceUsed); - if (present_jvmPoolMetaspaceUsed) - list.add(jvmPoolMetaspaceUsed); + hashCode = hashCode * 8191 + ((isSetJvmPoolMetaspaceUsed()) ? 131071 : 524287); + if (isSetJvmPoolMetaspaceUsed()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(jvmPoolMetaspaceUsed); - return list.hashCode(); + return hashCode; } @Override @@ -662,7 +626,7 @@ public class TJvmGcDetailed implements org.apache.thrift.TBase { + private static class TJvmGcDetailedStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TJvmGcDetailed struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -977,18 +941,18 @@ public class TJvmGcDetailed implements org.apache.thrift.TBase { + private static class TJvmGcDetailedTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TJvmGcDetailed 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.isSetJvmGcNewCount()) { optionals.set(0); } @@ -1042,8 +1006,8 @@ public class TJvmGcDetailed implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGcType.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGcType.java index dbac0fa4e..9fb054c0e 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGcType.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmGcType.java @@ -1,5 +1,5 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated diff --git a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmInfo.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmInfo.java index 2cef868a1..e43f35a97 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmInfo.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TJvmInfo.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2016-2-15") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TJvmInfo implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TJvmInfo"); @@ -42,14 +15,11 @@ public class TJvmInfo implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TJvmInfoStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TJvmInfoTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TJvmInfoStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TJvmInfoTupleSchemeFactory(); private short version; // required - private String vmVersion; // optional + private java.lang.String vmVersion; // optional private TJvmGcType gcType; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ @@ -62,10 +32,10 @@ public class TJvmInfo implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -92,21 +62,21 @@ public class TJvmInfo implements org.apache.thrift.TBase 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.VERSION, new org.apache.thrift.meta_data.FieldMetaData("version", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I16))); tmpMap.put(_Fields.VM_VERSION, new org.apache.thrift.meta_data.FieldMetaData("vmVersion", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.GC_TYPE, new org.apache.thrift.meta_data.FieldMetaData("gcType", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, TJvmGcType.class))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TJvmInfo.class, metaDataMap); } @@ -189,23 +159,23 @@ public class TJvmInfo implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_version = true; - list.add(present_version); - if (present_version) - list.add(version); + hashCode = hashCode * 8191 + version; - boolean present_vmVersion = true && (isSetVmVersion()); - list.add(present_vmVersion); - if (present_vmVersion) - list.add(vmVersion); + hashCode = hashCode * 8191 + ((isSetVmVersion()) ? 131071 : 524287); + if (isSetVmVersion()) + hashCode = hashCode * 8191 + vmVersion.hashCode(); - boolean present_gcType = true && (isSetGcType()); - list.add(present_gcType); - if (present_gcType) - list.add(gcType.getValue()); + hashCode = hashCode * 8191 + ((isSetGcType()) ? 131071 : 524287); + if (isSetGcType()) + hashCode = hashCode * 8191 + gcType.getValue(); - return list.hashCode(); + return hashCode; } @Override @@ -389,7 +356,7 @@ public class TJvmInfo implements org.apache.thrift.TBase { + private static class TJvmInfoStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TJvmInfo struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -567,18 +534,18 @@ public class TJvmInfo implements org.apache.thrift.TBase { + private static class TJvmInfoTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TJvmInfo 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.isSetVersion()) { optionals.set(0); } @@ -602,8 +569,8 @@ public class TJvmInfo implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TResult.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TResult.java index ac2822179..32897e438 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TResult.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TResult.java @@ -1,64 +1,34 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TResult implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TResult"); 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 MESSAGE_FIELD_DESC = new org.apache.thrift.protocol.TField("message", org.apache.thrift.protocol.TType.STRING, (short)2); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TResultStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TResultTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TResultStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TResultTupleSchemeFactory(); private boolean success; // required - private String message; // optional + private java.lang.String message; // optional /** 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"), MESSAGE((short)2, "message"); - private static final Map byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -83,21 +53,21 @@ public class TResult implements org.apache.thrift.TBase 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.MESSAGE, new org.apache.thrift.meta_data.FieldMetaData("message", org.apache.thrift.TFieldRequirementType.OPTIONAL, 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(TResult.class, metaDataMap); } @@ -169,23 +139,23 @@ public class TResult implements org.apache.thrift.TBase list = new ArrayList(); + 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_message = true && (isSetMessage()); - list.add(present_message); - if (present_message) - list.add(message); + hashCode = hashCode * 8191 + ((isSetMessage()) ? 131071 : 524287); + if (isSetMessage()) + hashCode = hashCode * 8191 + message.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -311,7 +279,7 @@ public class TResult implements org.apache.thrift.TBase { + private static class TResultStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TResult struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -454,18 +422,18 @@ public class TResult implements org.apache.thrift.TBase { + private static class TResultTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TResult 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); } @@ -483,8 +451,8 @@ public class TResult implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TServerMetaData.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TServerMetaData.java index 964d7c3e1..a846b1eef 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TServerMetaData.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TServerMetaData.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TServerMetaData implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TServerMetaData"); @@ -42,15 +15,12 @@ public class TServerMetaData implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TServerMetaDataStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TServerMetaDataTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TServerMetaDataStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TServerMetaDataTupleSchemeFactory(); - private String serverInfo; // optional - private List vmArgs; // optional - private List serviceInfos; // optional + private java.lang.String serverInfo; // optional + private java.util.List vmArgs; // optional + private java.util.List serviceInfos; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { @@ -58,10 +28,10 @@ public class TServerMetaData implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -88,21 +58,21 @@ public class TServerMetaData implements org.apache.thrift.TBase 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.SERVER_INFO, new org.apache.thrift.meta_data.FieldMetaData("serverInfo", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.VM_ARGS, new org.apache.thrift.meta_data.FieldMetaData("vmArgs", org.apache.thrift.TFieldRequirementType.OPTIONAL, @@ -129,7 +99,7 @@ public class TServerMetaData implements org.apache.thrift.TBase __this__vmArgs = new ArrayList(other.vmArgs); + java.util.List __this__vmArgs = new java.util.ArrayList(other.vmArgs); this.vmArgs = __this__vmArgs; } if (other.isSetServiceInfos()) { - List __this__serviceInfos = new ArrayList(other.serviceInfos.size()); + java.util.List __this__serviceInfos = new java.util.ArrayList(other.serviceInfos.size()); for (TServiceInfo other_element : other.serviceInfos) { __this__serviceInfos.add(new TServiceInfo(other_element)); } @@ -167,11 +137,11 @@ public class TServerMetaData implements org.apache.thrift.TBase getVmArgsIterator() { + public java.util.Iterator getVmArgsIterator() { return (this.vmArgs == null) ? null : this.vmArgs.iterator(); } - public void addToVmArgs(String elem) { + public void addToVmArgs(java.lang.String elem) { if (this.vmArgs == null) { - this.vmArgs = new ArrayList(); + this.vmArgs = new java.util.ArrayList(); } this.vmArgs.add(elem); } - public List getVmArgs() { + public java.util.List getVmArgs() { return this.vmArgs; } - public void setVmArgs(List vmArgs) { + public void setVmArgs(java.util.List vmArgs) { this.vmArgs = vmArgs; } @@ -238,16 +208,16 @@ public class TServerMetaData implements org.apache.thrift.TBase(); + this.serviceInfos = new java.util.ArrayList(); } this.serviceInfos.add(elem); } - public List getServiceInfos() { + public java.util.List getServiceInfos() { return this.serviceInfos; } - public void setServiceInfos(List serviceInfos) { + public void setServiceInfos(java.util.List serviceInfos) { this.serviceInfos = serviceInfos; } @@ -266,13 +236,13 @@ public class TServerMetaData implements org.apache.thrift.TBase)value); + setVmArgs((java.util.List)value); } break; @@ -288,14 +258,14 @@ public class TServerMetaData implements org.apache.thrift.TBase)value); + setServiceInfos((java.util.List)value); } break; } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case SERVER_INFO: return getServerInfo(); @@ -307,13 +277,13 @@ public class TServerMetaData implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_serverInfo = true && (isSetServerInfo()); - list.add(present_serverInfo); - if (present_serverInfo) - list.add(serverInfo); + hashCode = hashCode * 8191 + ((isSetServerInfo()) ? 131071 : 524287); + if (isSetServerInfo()) + hashCode = hashCode * 8191 + serverInfo.hashCode(); - boolean present_vmArgs = true && (isSetVmArgs()); - list.add(present_vmArgs); - if (present_vmArgs) - list.add(vmArgs); + hashCode = hashCode * 8191 + ((isSetVmArgs()) ? 131071 : 524287); + if (isSetVmArgs()) + hashCode = hashCode * 8191 + vmArgs.hashCode(); - boolean present_serviceInfos = true && (isSetServiceInfos()); - list.add(present_serviceInfos); - if (present_serviceInfos) - list.add(serviceInfos); + hashCode = hashCode * 8191 + ((isSetServiceInfos()) ? 131071 : 524287); + if (isSetServiceInfos()) + hashCode = hashCode * 8191 + serviceInfos.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -400,7 +369,7 @@ public class TServerMetaData implements org.apache.thrift.TBase { + private static class TServerMetaDataStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TServerMetaData struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -534,8 +503,8 @@ public class TServerMetaData implements org.apache.thrift.TBase(_list8.size); - String _elem9; + struct.vmArgs = new java.util.ArrayList(_list8.size); + java.lang.String _elem9; for (int _i10 = 0; _i10 < _list8.size; ++_i10) { _elem9 = iprot.readString(); @@ -552,7 +521,7 @@ public class TServerMetaData implements org.apache.thrift.TBase(_list11.size); + struct.serviceInfos = new java.util.ArrayList(_list11.size); TServiceInfo _elem12; for (int _i13 = 0; _i13 < _list11.size; ++_i13) { @@ -592,7 +561,7 @@ public class TServerMetaData implements org.apache.thrift.TBase { + private static class TServerMetaDataTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TServerMetaData 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.isSetServerInfo()) { optionals.set(0); } @@ -649,7 +618,7 @@ public class TServerMetaData implements org.apache.thrift.TBase(_list18.size); - String _elem19; + struct.vmArgs = new java.util.ArrayList(_list18.size); + java.lang.String _elem19; for (int _i20 = 0; _i20 < _list18.size; ++_i20) { _elem19 = iprot.readString(); @@ -690,7 +659,7 @@ public class TServerMetaData implements org.apache.thrift.TBase(_list21.size); + struct.serviceInfos = new java.util.ArrayList(_list21.size); TServiceInfo _elem22; for (int _i23 = 0; _i23 < _list21.size; ++_i23) { @@ -704,5 +673,8 @@ public class TServerMetaData implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TServiceInfo.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TServiceInfo.java index 7055a2196..f7f35c291 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TServiceInfo.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TServiceInfo.java @@ -1,64 +1,34 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TServiceInfo implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TServiceInfo"); private static final org.apache.thrift.protocol.TField SERVICE_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("serviceName", org.apache.thrift.protocol.TType.STRING, (short)1); private static final org.apache.thrift.protocol.TField SERVICE_LIBS_FIELD_DESC = new org.apache.thrift.protocol.TField("serviceLibs", org.apache.thrift.protocol.TType.LIST, (short)2); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TServiceInfoStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TServiceInfoTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TServiceInfoStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TServiceInfoTupleSchemeFactory(); - private String serviceName; // optional - private List serviceLibs; // optional + private java.lang.String serviceName; // optional + private java.util.List serviceLibs; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { SERVICE_NAME((short)1, "serviceName"), SERVICE_LIBS((short)2, "serviceLibs"); - private static final Map byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -83,21 +53,21 @@ public class TServiceInfo implements org.apache.thrift.TBase 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.SERVICE_NAME, new org.apache.thrift.meta_data.FieldMetaData("serviceName", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.SERVICE_LIBS, new org.apache.thrift.meta_data.FieldMetaData("serviceLibs", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 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(TServiceInfo.class, metaDataMap); } @@ -136,7 +106,7 @@ public class TServiceInfo implements org.apache.thrift.TBase __this__serviceLibs = new ArrayList(other.serviceLibs); + java.util.List __this__serviceLibs = new java.util.ArrayList(other.serviceLibs); this.serviceLibs = __this__serviceLibs; } } @@ -151,11 +121,11 @@ public class TServiceInfo implements org.apache.thrift.TBase getServiceLibsIterator() { + public java.util.Iterator getServiceLibsIterator() { return (this.serviceLibs == null) ? null : this.serviceLibs.iterator(); } - public void addToServiceLibs(String elem) { + public void addToServiceLibs(java.lang.String elem) { if (this.serviceLibs == null) { - this.serviceLibs = new ArrayList(); + this.serviceLibs = new java.util.ArrayList(); } this.serviceLibs.add(elem); } - public List getServiceLibs() { + public java.util.List getServiceLibs() { return this.serviceLibs; } - public void setServiceLibs(List serviceLibs) { + public void setServiceLibs(java.util.List serviceLibs) { this.serviceLibs = serviceLibs; } @@ -212,13 +182,13 @@ public class TServiceInfo implements org.apache.thrift.TBase)value); + setServiceLibs((java.util.List)value); } break; } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case SERVICE_NAME: return getServiceName(); @@ -242,13 +212,13 @@ public class TServiceInfo implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_serviceName = true && (isSetServiceName()); - list.add(present_serviceName); - if (present_serviceName) - list.add(serviceName); + hashCode = hashCode * 8191 + ((isSetServiceName()) ? 131071 : 524287); + if (isSetServiceName()) + hashCode = hashCode * 8191 + serviceName.hashCode(); - boolean present_serviceLibs = true && (isSetServiceLibs()); - list.add(present_serviceLibs); - if (present_serviceLibs) - list.add(serviceLibs); + hashCode = hashCode * 8191 + ((isSetServiceLibs()) ? 131071 : 524287); + if (isSetServiceLibs()) + hashCode = hashCode * 8191 + serviceLibs.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -319,7 +289,7 @@ public class TServiceInfo implements org.apache.thrift.TBase { + private static class TServiceInfoStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TServiceInfo struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -433,8 +403,8 @@ public class TServiceInfo implements org.apache.thrift.TBase(_list0.size); - String _elem1; + struct.serviceLibs = new java.util.ArrayList(_list0.size); + java.lang.String _elem1; for (int _i2 = 0; _i2 < _list0.size; ++_i2) { _elem1 = iprot.readString(); @@ -472,7 +442,7 @@ public class TServiceInfo implements org.apache.thrift.TBase { + private static class TServiceInfoTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TServiceInfo 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.isSetServiceName()) { optionals.set(0); } @@ -512,7 +482,7 @@ public class TServiceInfo implements org.apache.thrift.TBase(_list5.size); - String _elem6; + struct.serviceLibs = new java.util.ArrayList(_list5.size); + java.lang.String _elem6; for (int _i7 = 0; _i7 < _list5.size; ++_i7) { _elem6 = iprot.readString(); @@ -544,5 +514,8 @@ public class TServiceInfo implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpan.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpan.java index 8b4e7eddc..e6601abe3 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpan.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpan.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2016-12-9") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TSpan implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TSpan"); @@ -62,31 +35,28 @@ public class TSpan implements org.apache.thrift.TBase, jav private static final org.apache.thrift.protocol.TField APPLICATION_SERVICE_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("applicationServiceType", org.apache.thrift.protocol.TType.I16, (short)30); private static final org.apache.thrift.protocol.TField LOGGING_TRANSACTION_INFO_FIELD_DESC = new org.apache.thrift.protocol.TField("loggingTransactionInfo", org.apache.thrift.protocol.TType.BYTE, (short)31); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TSpanStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TSpanTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TSpanStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TSpanTupleSchemeFactory(); - private String agentId; // required - private String applicationName; // required + private java.lang.String agentId; // required + private java.lang.String applicationName; // required private long agentStartTime; // required - private ByteBuffer transactionId; // required + private java.nio.ByteBuffer transactionId; // required private long spanId; // required private long parentSpanId; // optional private long startTime; // required private int elapsed; // optional - private String rpc; // optional + private java.lang.String rpc; // optional private short serviceType; // required - private String endPoint; // optional - private String remoteAddr; // optional - private List annotations; // optional + private java.lang.String endPoint; // optional + private java.lang.String remoteAddr; // optional + private java.util.List annotations; // optional private short flag; // optional private int err; // optional - private List spanEventList; // optional - private String parentApplicationName; // optional + private java.util.List spanEventList; // optional + private java.lang.String parentApplicationName; // optional private short parentApplicationType; // optional - private String acceptorHost; // optional + private java.lang.String acceptorHost; // optional private int apiId; // optional private TIntStringValue exceptionInfo; // optional private short applicationServiceType; // optional @@ -118,10 +88,10 @@ public class TSpan implements org.apache.thrift.TBase, jav APPLICATION_SERVICE_TYPE((short)30, "applicationServiceType"), LOGGING_TRANSACTION_INFO((short)31, "loggingTransactionInfo"); - private static final Map byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -188,21 +158,21 @@ public class TSpan implements org.apache.thrift.TBase, jav */ 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) { + 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; } @@ -211,7 +181,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return _thriftId; } - public String getFieldName() { + public java.lang.String getFieldName() { return _fieldName; } } @@ -231,9 +201,9 @@ public class TSpan implements org.apache.thrift.TBase, jav private static final int __LOGGINGTRANSACTIONINFO_ISSET_ID = 11; private short __isset_bitfield = 0; private static final _Fields optionals[] = {_Fields.PARENT_SPAN_ID,_Fields.ELAPSED,_Fields.RPC,_Fields.END_POINT,_Fields.REMOTE_ADDR,_Fields.ANNOTATIONS,_Fields.FLAG,_Fields.ERR,_Fields.SPAN_EVENT_LIST,_Fields.PARENT_APPLICATION_NAME,_Fields.PARENT_APPLICATION_TYPE,_Fields.ACCEPTOR_HOST,_Fields.API_ID,_Fields.EXCEPTION_INFO,_Fields.APPLICATION_SERVICE_TYPE,_Fields.LOGGING_TRANSACTION_INFO}; - 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.AGENT_ID, new org.apache.thrift.meta_data.FieldMetaData("agentId", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.APPLICATION_NAME, new org.apache.thrift.meta_data.FieldMetaData("applicationName", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -282,7 +252,7 @@ public class TSpan implements org.apache.thrift.TBase, jav new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I16))); tmpMap.put(_Fields.LOGGING_TRANSACTION_INFO, new org.apache.thrift.meta_data.FieldMetaData("loggingTransactionInfo", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BYTE))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TSpan.class, metaDataMap); } @@ -296,10 +266,10 @@ public class TSpan implements org.apache.thrift.TBase, jav } public TSpan( - String agentId, - String applicationName, + java.lang.String agentId, + java.lang.String applicationName, long agentStartTime, - ByteBuffer transactionId, + java.nio.ByteBuffer transactionId, long spanId, long startTime, short serviceType) @@ -348,7 +318,7 @@ public class TSpan implements org.apache.thrift.TBase, jav this.remoteAddr = other.remoteAddr; } if (other.isSetAnnotations()) { - List __this__annotations = new ArrayList(other.annotations.size()); + java.util.List __this__annotations = new java.util.ArrayList(other.annotations.size()); for (TAnnotation other_element : other.annotations) { __this__annotations.add(new TAnnotation(other_element)); } @@ -357,7 +327,7 @@ public class TSpan implements org.apache.thrift.TBase, jav this.flag = other.flag; this.err = other.err; if (other.isSetSpanEventList()) { - List __this__spanEventList = new ArrayList(other.spanEventList.size()); + java.util.List __this__spanEventList = new java.util.ArrayList(other.spanEventList.size()); for (TSpanEvent other_element : other.spanEventList) { __this__spanEventList.add(new TSpanEvent(other_element)); } @@ -421,11 +391,11 @@ public class TSpan implements org.apache.thrift.TBase, jav this.loggingTransactionInfo = 0; } - public String getAgentId() { + public java.lang.String getAgentId() { return this.agentId; } - public void setAgentId(String agentId) { + public void setAgentId(java.lang.String agentId) { this.agentId = agentId; } @@ -444,11 +414,11 @@ public class TSpan implements org.apache.thrift.TBase, jav } } - public String getApplicationName() { + public java.lang.String getApplicationName() { return this.applicationName; } - public void setApplicationName(String applicationName) { + public void setApplicationName(java.lang.String applicationName) { this.applicationName = applicationName; } @@ -477,16 +447,16 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetAgentStartTime() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __AGENTSTARTTIME_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __AGENTSTARTTIME_ISSET_ID); } /** Returns true if field agentStartTime is set (has been assigned a value) and false otherwise */ public boolean isSetAgentStartTime() { - return EncodingUtils.testBit(__isset_bitfield, __AGENTSTARTTIME_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __AGENTSTARTTIME_ISSET_ID); } public void setAgentStartTimeIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __AGENTSTARTTIME_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __AGENTSTARTTIME_ISSET_ID, value); } public byte[] getTransactionId() { @@ -494,15 +464,15 @@ public class TSpan implements org.apache.thrift.TBase, jav return transactionId == null ? null : transactionId.array(); } - public ByteBuffer bufferForTransactionId() { + public java.nio.ByteBuffer bufferForTransactionId() { return org.apache.thrift.TBaseHelper.copyBinary(transactionId); } public void setTransactionId(byte[] transactionId) { - this.transactionId = transactionId == null ? (ByteBuffer)null : ByteBuffer.wrap(Arrays.copyOf(transactionId, transactionId.length)); + this.transactionId = transactionId == null ? (java.nio.ByteBuffer)null : java.nio.ByteBuffer.wrap(transactionId.clone()); } - public void setTransactionId(ByteBuffer transactionId) { + public void setTransactionId(java.nio.ByteBuffer transactionId) { this.transactionId = org.apache.thrift.TBaseHelper.copyBinary(transactionId); } @@ -531,16 +501,16 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetSpanId() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SPANID_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __SPANID_ISSET_ID); } /** Returns true if field spanId is set (has been assigned a value) and false otherwise */ public boolean isSetSpanId() { - return EncodingUtils.testBit(__isset_bitfield, __SPANID_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __SPANID_ISSET_ID); } public void setSpanIdIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SPANID_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __SPANID_ISSET_ID, value); } public long getParentSpanId() { @@ -553,16 +523,16 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetParentSpanId() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PARENTSPANID_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __PARENTSPANID_ISSET_ID); } /** Returns true if field parentSpanId is set (has been assigned a value) and false otherwise */ public boolean isSetParentSpanId() { - return EncodingUtils.testBit(__isset_bitfield, __PARENTSPANID_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PARENTSPANID_ISSET_ID); } public void setParentSpanIdIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PARENTSPANID_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PARENTSPANID_ISSET_ID, value); } public long getStartTime() { @@ -575,16 +545,16 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetStartTime() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __STARTTIME_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __STARTTIME_ISSET_ID); } /** Returns true if field startTime is set (has been assigned a value) and false otherwise */ public boolean isSetStartTime() { - return EncodingUtils.testBit(__isset_bitfield, __STARTTIME_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __STARTTIME_ISSET_ID); } public void setStartTimeIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __STARTTIME_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __STARTTIME_ISSET_ID, value); } public int getElapsed() { @@ -597,23 +567,23 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetElapsed() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ELAPSED_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ELAPSED_ISSET_ID); } /** Returns true if field elapsed is set (has been assigned a value) and false otherwise */ public boolean isSetElapsed() { - return EncodingUtils.testBit(__isset_bitfield, __ELAPSED_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ELAPSED_ISSET_ID); } public void setElapsedIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ELAPSED_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ELAPSED_ISSET_ID, value); } - public String getRpc() { + public java.lang.String getRpc() { return this.rpc; } - public void setRpc(String rpc) { + public void setRpc(java.lang.String rpc) { this.rpc = rpc; } @@ -642,23 +612,23 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetServiceType() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SERVICETYPE_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __SERVICETYPE_ISSET_ID); } /** Returns true if field serviceType is set (has been assigned a value) and false otherwise */ public boolean isSetServiceType() { - return EncodingUtils.testBit(__isset_bitfield, __SERVICETYPE_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __SERVICETYPE_ISSET_ID); } public void setServiceTypeIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SERVICETYPE_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __SERVICETYPE_ISSET_ID, value); } - public String getEndPoint() { + public java.lang.String getEndPoint() { return this.endPoint; } - public void setEndPoint(String endPoint) { + public void setEndPoint(java.lang.String endPoint) { this.endPoint = endPoint; } @@ -677,11 +647,11 @@ public class TSpan implements org.apache.thrift.TBase, jav } } - public String getRemoteAddr() { + public java.lang.String getRemoteAddr() { return this.remoteAddr; } - public void setRemoteAddr(String remoteAddr) { + public void setRemoteAddr(java.lang.String remoteAddr) { this.remoteAddr = remoteAddr; } @@ -710,16 +680,16 @@ public class TSpan implements org.apache.thrift.TBase, jav public void addToAnnotations(TAnnotation elem) { if (this.annotations == null) { - this.annotations = new ArrayList(); + this.annotations = new java.util.ArrayList(); } this.annotations.add(elem); } - public List getAnnotations() { + public java.util.List getAnnotations() { return this.annotations; } - public void setAnnotations(List annotations) { + public void setAnnotations(java.util.List annotations) { this.annotations = annotations; } @@ -748,16 +718,16 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetFlag() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __FLAG_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __FLAG_ISSET_ID); } /** Returns true if field flag is set (has been assigned a value) and false otherwise */ public boolean isSetFlag() { - return EncodingUtils.testBit(__isset_bitfield, __FLAG_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __FLAG_ISSET_ID); } public void setFlagIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __FLAG_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __FLAG_ISSET_ID, value); } public int getErr() { @@ -770,16 +740,16 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetErr() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ERR_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ERR_ISSET_ID); } /** Returns true if field err is set (has been assigned a value) and false otherwise */ public boolean isSetErr() { - return EncodingUtils.testBit(__isset_bitfield, __ERR_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ERR_ISSET_ID); } public void setErrIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ERR_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ERR_ISSET_ID, value); } public int getSpanEventListSize() { @@ -792,16 +762,16 @@ public class TSpan implements org.apache.thrift.TBase, jav public void addToSpanEventList(TSpanEvent elem) { if (this.spanEventList == null) { - this.spanEventList = new ArrayList(); + this.spanEventList = new java.util.ArrayList(); } this.spanEventList.add(elem); } - public List getSpanEventList() { + public java.util.List getSpanEventList() { return this.spanEventList; } - public void setSpanEventList(List spanEventList) { + public void setSpanEventList(java.util.List spanEventList) { this.spanEventList = spanEventList; } @@ -820,11 +790,11 @@ public class TSpan implements org.apache.thrift.TBase, jav } } - public String getParentApplicationName() { + public java.lang.String getParentApplicationName() { return this.parentApplicationName; } - public void setParentApplicationName(String parentApplicationName) { + public void setParentApplicationName(java.lang.String parentApplicationName) { this.parentApplicationName = parentApplicationName; } @@ -853,23 +823,23 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetParentApplicationType() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PARENTAPPLICATIONTYPE_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __PARENTAPPLICATIONTYPE_ISSET_ID); } /** Returns true if field parentApplicationType is set (has been assigned a value) and false otherwise */ public boolean isSetParentApplicationType() { - return EncodingUtils.testBit(__isset_bitfield, __PARENTAPPLICATIONTYPE_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PARENTAPPLICATIONTYPE_ISSET_ID); } public void setParentApplicationTypeIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PARENTAPPLICATIONTYPE_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PARENTAPPLICATIONTYPE_ISSET_ID, value); } - public String getAcceptorHost() { + public java.lang.String getAcceptorHost() { return this.acceptorHost; } - public void setAcceptorHost(String acceptorHost) { + public void setAcceptorHost(java.lang.String acceptorHost) { this.acceptorHost = acceptorHost; } @@ -898,16 +868,16 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetApiId() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __APIID_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __APIID_ISSET_ID); } /** Returns true if field apiId is set (has been assigned a value) and false otherwise */ public boolean isSetApiId() { - return EncodingUtils.testBit(__isset_bitfield, __APIID_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __APIID_ISSET_ID); } public void setApiIdIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __APIID_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __APIID_ISSET_ID, value); } public TIntStringValue getExceptionInfo() { @@ -943,16 +913,16 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetApplicationServiceType() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __APPLICATIONSERVICETYPE_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __APPLICATIONSERVICETYPE_ISSET_ID); } /** Returns true if field applicationServiceType is set (has been assigned a value) and false otherwise */ public boolean isSetApplicationServiceType() { - return EncodingUtils.testBit(__isset_bitfield, __APPLICATIONSERVICETYPE_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __APPLICATIONSERVICETYPE_ISSET_ID); } public void setApplicationServiceTypeIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __APPLICATIONSERVICETYPE_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __APPLICATIONSERVICETYPE_ISSET_ID, value); } public byte getLoggingTransactionInfo() { @@ -965,25 +935,25 @@ public class TSpan implements org.apache.thrift.TBase, jav } public void unsetLoggingTransactionInfo() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __LOGGINGTRANSACTIONINFO_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __LOGGINGTRANSACTIONINFO_ISSET_ID); } /** Returns true if field loggingTransactionInfo is set (has been assigned a value) and false otherwise */ public boolean isSetLoggingTransactionInfo() { - return EncodingUtils.testBit(__isset_bitfield, __LOGGINGTRANSACTIONINFO_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __LOGGINGTRANSACTIONINFO_ISSET_ID); } public void setLoggingTransactionInfoIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __LOGGINGTRANSACTIONINFO_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __LOGGINGTRANSACTIONINFO_ISSET_ID, value); } - public void setFieldValue(_Fields field, Object value) { + public void setFieldValue(_Fields field, java.lang.Object value) { switch (field) { case AGENT_ID: if (value == null) { unsetAgentId(); } else { - setAgentId((String)value); + setAgentId((java.lang.String)value); } break; @@ -991,7 +961,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetApplicationName(); } else { - setApplicationName((String)value); + setApplicationName((java.lang.String)value); } break; @@ -999,7 +969,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetAgentStartTime(); } else { - setAgentStartTime((Long)value); + setAgentStartTime((java.lang.Long)value); } break; @@ -1007,7 +977,11 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetTransactionId(); } else { - setTransactionId((ByteBuffer)value); + if (value instanceof byte[]) { + setTransactionId((byte[])value); + } else { + setTransactionId((java.nio.ByteBuffer)value); + } } break; @@ -1015,7 +989,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetSpanId(); } else { - setSpanId((Long)value); + setSpanId((java.lang.Long)value); } break; @@ -1023,7 +997,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetParentSpanId(); } else { - setParentSpanId((Long)value); + setParentSpanId((java.lang.Long)value); } break; @@ -1031,7 +1005,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetStartTime(); } else { - setStartTime((Long)value); + setStartTime((java.lang.Long)value); } break; @@ -1039,7 +1013,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetElapsed(); } else { - setElapsed((Integer)value); + setElapsed((java.lang.Integer)value); } break; @@ -1047,7 +1021,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetRpc(); } else { - setRpc((String)value); + setRpc((java.lang.String)value); } break; @@ -1055,7 +1029,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetServiceType(); } else { - setServiceType((Short)value); + setServiceType((java.lang.Short)value); } break; @@ -1063,7 +1037,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetEndPoint(); } else { - setEndPoint((String)value); + setEndPoint((java.lang.String)value); } break; @@ -1071,7 +1045,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetRemoteAddr(); } else { - setRemoteAddr((String)value); + setRemoteAddr((java.lang.String)value); } break; @@ -1079,7 +1053,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetAnnotations(); } else { - setAnnotations((List)value); + setAnnotations((java.util.List)value); } break; @@ -1087,7 +1061,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetFlag(); } else { - setFlag((Short)value); + setFlag((java.lang.Short)value); } break; @@ -1095,7 +1069,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetErr(); } else { - setErr((Integer)value); + setErr((java.lang.Integer)value); } break; @@ -1103,7 +1077,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetSpanEventList(); } else { - setSpanEventList((List)value); + setSpanEventList((java.util.List)value); } break; @@ -1111,7 +1085,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetParentApplicationName(); } else { - setParentApplicationName((String)value); + setParentApplicationName((java.lang.String)value); } break; @@ -1119,7 +1093,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetParentApplicationType(); } else { - setParentApplicationType((Short)value); + setParentApplicationType((java.lang.Short)value); } break; @@ -1127,7 +1101,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetAcceptorHost(); } else { - setAcceptorHost((String)value); + setAcceptorHost((java.lang.String)value); } break; @@ -1135,7 +1109,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetApiId(); } else { - setApiId((Integer)value); + setApiId((java.lang.Integer)value); } break; @@ -1151,7 +1125,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetApplicationServiceType(); } else { - setApplicationServiceType((Short)value); + setApplicationServiceType((java.lang.Short)value); } break; @@ -1159,14 +1133,14 @@ public class TSpan implements org.apache.thrift.TBase, jav if (value == null) { unsetLoggingTransactionInfo(); } else { - setLoggingTransactionInfo((Byte)value); + setLoggingTransactionInfo((java.lang.Byte)value); } break; } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case AGENT_ID: return getAgentId(); @@ -1175,28 +1149,28 @@ public class TSpan implements org.apache.thrift.TBase, jav return getApplicationName(); case AGENT_START_TIME: - return Long.valueOf(getAgentStartTime()); + return getAgentStartTime(); case TRANSACTION_ID: return getTransactionId(); case SPAN_ID: - return Long.valueOf(getSpanId()); + return getSpanId(); case PARENT_SPAN_ID: - return Long.valueOf(getParentSpanId()); + return getParentSpanId(); case START_TIME: - return Long.valueOf(getStartTime()); + return getStartTime(); case ELAPSED: - return Integer.valueOf(getElapsed()); + return getElapsed(); case RPC: return getRpc(); case SERVICE_TYPE: - return Short.valueOf(getServiceType()); + return getServiceType(); case END_POINT: return getEndPoint(); @@ -1208,10 +1182,10 @@ public class TSpan implements org.apache.thrift.TBase, jav return getAnnotations(); case FLAG: - return Short.valueOf(getFlag()); + return getFlag(); case ERR: - return Integer.valueOf(getErr()); + return getErr(); case SPAN_EVENT_LIST: return getSpanEventList(); @@ -1220,31 +1194,31 @@ public class TSpan implements org.apache.thrift.TBase, jav return getParentApplicationName(); case PARENT_APPLICATION_TYPE: - return Short.valueOf(getParentApplicationType()); + return getParentApplicationType(); case ACCEPTOR_HOST: return getAcceptorHost(); case API_ID: - return Integer.valueOf(getApiId()); + return getApiId(); case EXCEPTION_INFO: return getExceptionInfo(); case APPLICATION_SERVICE_TYPE: - return Short.valueOf(getApplicationServiceType()); + return getApplicationServiceType(); case LOGGING_TRANSACTION_INFO: - return Byte.valueOf(getLoggingTransactionInfo()); + return getLoggingTransactionInfo(); } - 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) { @@ -1295,11 +1269,11 @@ public class TSpan implements org.apache.thrift.TBase, jav case LOGGING_TRANSACTION_INFO: return isSetLoggingTransactionInfo(); } - 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 TSpan) @@ -1310,6 +1284,8 @@ public class TSpan implements org.apache.thrift.TBase, jav public boolean equals(TSpan that) { if (that == null) return false; + if (this == that) + return true; boolean this_present_agentId = true && this.isSetAgentId(); boolean that_present_agentId = true && that.isSetAgentId(); @@ -1523,124 +1499,93 @@ public class TSpan implements org.apache.thrift.TBase, jav @Override public int hashCode() { - List list = new ArrayList(); + int hashCode = 1; - boolean present_agentId = true && (isSetAgentId()); - list.add(present_agentId); - if (present_agentId) - list.add(agentId); + hashCode = hashCode * 8191 + ((isSetAgentId()) ? 131071 : 524287); + if (isSetAgentId()) + hashCode = hashCode * 8191 + agentId.hashCode(); - boolean present_applicationName = true && (isSetApplicationName()); - list.add(present_applicationName); - if (present_applicationName) - list.add(applicationName); + hashCode = hashCode * 8191 + ((isSetApplicationName()) ? 131071 : 524287); + if (isSetApplicationName()) + hashCode = hashCode * 8191 + applicationName.hashCode(); - boolean present_agentStartTime = true; - list.add(present_agentStartTime); - if (present_agentStartTime) - list.add(agentStartTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(agentStartTime); - boolean present_transactionId = true && (isSetTransactionId()); - list.add(present_transactionId); - if (present_transactionId) - list.add(transactionId); + hashCode = hashCode * 8191 + ((isSetTransactionId()) ? 131071 : 524287); + if (isSetTransactionId()) + hashCode = hashCode * 8191 + transactionId.hashCode(); - boolean present_spanId = true; - list.add(present_spanId); - if (present_spanId) - list.add(spanId); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(spanId); - boolean present_parentSpanId = true && (isSetParentSpanId()); - list.add(present_parentSpanId); - if (present_parentSpanId) - list.add(parentSpanId); + hashCode = hashCode * 8191 + ((isSetParentSpanId()) ? 131071 : 524287); + if (isSetParentSpanId()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(parentSpanId); - boolean present_startTime = true; - list.add(present_startTime); - if (present_startTime) - list.add(startTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(startTime); - boolean present_elapsed = true && (isSetElapsed()); - list.add(present_elapsed); - if (present_elapsed) - list.add(elapsed); + hashCode = hashCode * 8191 + ((isSetElapsed()) ? 131071 : 524287); + if (isSetElapsed()) + hashCode = hashCode * 8191 + elapsed; - boolean present_rpc = true && (isSetRpc()); - list.add(present_rpc); - if (present_rpc) - list.add(rpc); + hashCode = hashCode * 8191 + ((isSetRpc()) ? 131071 : 524287); + if (isSetRpc()) + hashCode = hashCode * 8191 + rpc.hashCode(); - boolean present_serviceType = true; - list.add(present_serviceType); - if (present_serviceType) - list.add(serviceType); + hashCode = hashCode * 8191 + serviceType; - boolean present_endPoint = true && (isSetEndPoint()); - list.add(present_endPoint); - if (present_endPoint) - list.add(endPoint); + hashCode = hashCode * 8191 + ((isSetEndPoint()) ? 131071 : 524287); + if (isSetEndPoint()) + hashCode = hashCode * 8191 + endPoint.hashCode(); - boolean present_remoteAddr = true && (isSetRemoteAddr()); - list.add(present_remoteAddr); - if (present_remoteAddr) - list.add(remoteAddr); + hashCode = hashCode * 8191 + ((isSetRemoteAddr()) ? 131071 : 524287); + if (isSetRemoteAddr()) + hashCode = hashCode * 8191 + remoteAddr.hashCode(); - boolean present_annotations = true && (isSetAnnotations()); - list.add(present_annotations); - if (present_annotations) - list.add(annotations); + hashCode = hashCode * 8191 + ((isSetAnnotations()) ? 131071 : 524287); + if (isSetAnnotations()) + hashCode = hashCode * 8191 + annotations.hashCode(); - boolean present_flag = true && (isSetFlag()); - list.add(present_flag); - if (present_flag) - list.add(flag); + hashCode = hashCode * 8191 + ((isSetFlag()) ? 131071 : 524287); + if (isSetFlag()) + hashCode = hashCode * 8191 + flag; - boolean present_err = true && (isSetErr()); - list.add(present_err); - if (present_err) - list.add(err); + hashCode = hashCode * 8191 + ((isSetErr()) ? 131071 : 524287); + if (isSetErr()) + hashCode = hashCode * 8191 + err; - boolean present_spanEventList = true && (isSetSpanEventList()); - list.add(present_spanEventList); - if (present_spanEventList) - list.add(spanEventList); + hashCode = hashCode * 8191 + ((isSetSpanEventList()) ? 131071 : 524287); + if (isSetSpanEventList()) + hashCode = hashCode * 8191 + spanEventList.hashCode(); - boolean present_parentApplicationName = true && (isSetParentApplicationName()); - list.add(present_parentApplicationName); - if (present_parentApplicationName) - list.add(parentApplicationName); + hashCode = hashCode * 8191 + ((isSetParentApplicationName()) ? 131071 : 524287); + if (isSetParentApplicationName()) + hashCode = hashCode * 8191 + parentApplicationName.hashCode(); - boolean present_parentApplicationType = true && (isSetParentApplicationType()); - list.add(present_parentApplicationType); - if (present_parentApplicationType) - list.add(parentApplicationType); + hashCode = hashCode * 8191 + ((isSetParentApplicationType()) ? 131071 : 524287); + if (isSetParentApplicationType()) + hashCode = hashCode * 8191 + parentApplicationType; - boolean present_acceptorHost = true && (isSetAcceptorHost()); - list.add(present_acceptorHost); - if (present_acceptorHost) - list.add(acceptorHost); + hashCode = hashCode * 8191 + ((isSetAcceptorHost()) ? 131071 : 524287); + if (isSetAcceptorHost()) + hashCode = hashCode * 8191 + acceptorHost.hashCode(); - boolean present_apiId = true && (isSetApiId()); - list.add(present_apiId); - if (present_apiId) - list.add(apiId); + hashCode = hashCode * 8191 + ((isSetApiId()) ? 131071 : 524287); + if (isSetApiId()) + hashCode = hashCode * 8191 + apiId; - boolean present_exceptionInfo = true && (isSetExceptionInfo()); - list.add(present_exceptionInfo); - if (present_exceptionInfo) - list.add(exceptionInfo); + hashCode = hashCode * 8191 + ((isSetExceptionInfo()) ? 131071 : 524287); + if (isSetExceptionInfo()) + hashCode = hashCode * 8191 + exceptionInfo.hashCode(); - boolean present_applicationServiceType = true && (isSetApplicationServiceType()); - list.add(present_applicationServiceType); - if (present_applicationServiceType) - list.add(applicationServiceType); + hashCode = hashCode * 8191 + ((isSetApplicationServiceType()) ? 131071 : 524287); + if (isSetApplicationServiceType()) + hashCode = hashCode * 8191 + applicationServiceType; - boolean present_loggingTransactionInfo = true && (isSetLoggingTransactionInfo()); - list.add(present_loggingTransactionInfo); - if (present_loggingTransactionInfo) - list.add(loggingTransactionInfo); + hashCode = hashCode * 8191 + ((isSetLoggingTransactionInfo()) ? 131071 : 524287); + if (isSetLoggingTransactionInfo()) + hashCode = hashCode * 8191 + (int) (loggingTransactionInfo); - return list.hashCode(); + return hashCode; } @Override @@ -1651,7 +1596,7 @@ public class TSpan implements org.apache.thrift.TBase, jav int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetAgentId()).compareTo(other.isSetAgentId()); + lastComparison = java.lang.Boolean.valueOf(isSetAgentId()).compareTo(other.isSetAgentId()); if (lastComparison != 0) { return lastComparison; } @@ -1661,7 +1606,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetApplicationName()).compareTo(other.isSetApplicationName()); + lastComparison = java.lang.Boolean.valueOf(isSetApplicationName()).compareTo(other.isSetApplicationName()); if (lastComparison != 0) { return lastComparison; } @@ -1671,7 +1616,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetAgentStartTime()).compareTo(other.isSetAgentStartTime()); + lastComparison = java.lang.Boolean.valueOf(isSetAgentStartTime()).compareTo(other.isSetAgentStartTime()); if (lastComparison != 0) { return lastComparison; } @@ -1681,7 +1626,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetTransactionId()).compareTo(other.isSetTransactionId()); + lastComparison = java.lang.Boolean.valueOf(isSetTransactionId()).compareTo(other.isSetTransactionId()); if (lastComparison != 0) { return lastComparison; } @@ -1691,7 +1636,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetSpanId()).compareTo(other.isSetSpanId()); + lastComparison = java.lang.Boolean.valueOf(isSetSpanId()).compareTo(other.isSetSpanId()); if (lastComparison != 0) { return lastComparison; } @@ -1701,7 +1646,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetParentSpanId()).compareTo(other.isSetParentSpanId()); + lastComparison = java.lang.Boolean.valueOf(isSetParentSpanId()).compareTo(other.isSetParentSpanId()); if (lastComparison != 0) { return lastComparison; } @@ -1711,7 +1656,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetStartTime()).compareTo(other.isSetStartTime()); + lastComparison = java.lang.Boolean.valueOf(isSetStartTime()).compareTo(other.isSetStartTime()); if (lastComparison != 0) { return lastComparison; } @@ -1721,7 +1666,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetElapsed()).compareTo(other.isSetElapsed()); + lastComparison = java.lang.Boolean.valueOf(isSetElapsed()).compareTo(other.isSetElapsed()); if (lastComparison != 0) { return lastComparison; } @@ -1731,7 +1676,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetRpc()).compareTo(other.isSetRpc()); + lastComparison = java.lang.Boolean.valueOf(isSetRpc()).compareTo(other.isSetRpc()); if (lastComparison != 0) { return lastComparison; } @@ -1741,7 +1686,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetServiceType()).compareTo(other.isSetServiceType()); + lastComparison = java.lang.Boolean.valueOf(isSetServiceType()).compareTo(other.isSetServiceType()); if (lastComparison != 0) { return lastComparison; } @@ -1751,7 +1696,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetEndPoint()).compareTo(other.isSetEndPoint()); + lastComparison = java.lang.Boolean.valueOf(isSetEndPoint()).compareTo(other.isSetEndPoint()); if (lastComparison != 0) { return lastComparison; } @@ -1761,7 +1706,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetRemoteAddr()).compareTo(other.isSetRemoteAddr()); + lastComparison = java.lang.Boolean.valueOf(isSetRemoteAddr()).compareTo(other.isSetRemoteAddr()); if (lastComparison != 0) { return lastComparison; } @@ -1771,7 +1716,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetAnnotations()).compareTo(other.isSetAnnotations()); + lastComparison = java.lang.Boolean.valueOf(isSetAnnotations()).compareTo(other.isSetAnnotations()); if (lastComparison != 0) { return lastComparison; } @@ -1781,7 +1726,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetFlag()).compareTo(other.isSetFlag()); + lastComparison = java.lang.Boolean.valueOf(isSetFlag()).compareTo(other.isSetFlag()); if (lastComparison != 0) { return lastComparison; } @@ -1791,7 +1736,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetErr()).compareTo(other.isSetErr()); + lastComparison = java.lang.Boolean.valueOf(isSetErr()).compareTo(other.isSetErr()); if (lastComparison != 0) { return lastComparison; } @@ -1801,7 +1746,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetSpanEventList()).compareTo(other.isSetSpanEventList()); + lastComparison = java.lang.Boolean.valueOf(isSetSpanEventList()).compareTo(other.isSetSpanEventList()); if (lastComparison != 0) { return lastComparison; } @@ -1811,7 +1756,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetParentApplicationName()).compareTo(other.isSetParentApplicationName()); + lastComparison = java.lang.Boolean.valueOf(isSetParentApplicationName()).compareTo(other.isSetParentApplicationName()); if (lastComparison != 0) { return lastComparison; } @@ -1821,7 +1766,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetParentApplicationType()).compareTo(other.isSetParentApplicationType()); + lastComparison = java.lang.Boolean.valueOf(isSetParentApplicationType()).compareTo(other.isSetParentApplicationType()); if (lastComparison != 0) { return lastComparison; } @@ -1831,7 +1776,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetAcceptorHost()).compareTo(other.isSetAcceptorHost()); + lastComparison = java.lang.Boolean.valueOf(isSetAcceptorHost()).compareTo(other.isSetAcceptorHost()); if (lastComparison != 0) { return lastComparison; } @@ -1841,7 +1786,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetApiId()).compareTo(other.isSetApiId()); + lastComparison = java.lang.Boolean.valueOf(isSetApiId()).compareTo(other.isSetApiId()); if (lastComparison != 0) { return lastComparison; } @@ -1851,7 +1796,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetExceptionInfo()).compareTo(other.isSetExceptionInfo()); + lastComparison = java.lang.Boolean.valueOf(isSetExceptionInfo()).compareTo(other.isSetExceptionInfo()); if (lastComparison != 0) { return lastComparison; } @@ -1861,7 +1806,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetApplicationServiceType()).compareTo(other.isSetApplicationServiceType()); + lastComparison = java.lang.Boolean.valueOf(isSetApplicationServiceType()).compareTo(other.isSetApplicationServiceType()); if (lastComparison != 0) { return lastComparison; } @@ -1871,7 +1816,7 @@ public class TSpan implements org.apache.thrift.TBase, jav return lastComparison; } } - lastComparison = Boolean.valueOf(isSetLoggingTransactionInfo()).compareTo(other.isSetLoggingTransactionInfo()); + lastComparison = java.lang.Boolean.valueOf(isSetLoggingTransactionInfo()).compareTo(other.isSetLoggingTransactionInfo()); if (lastComparison != 0) { return lastComparison; } @@ -1889,16 +1834,16 @@ public class TSpan implements org.apache.thrift.TBase, jav } 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("TSpan("); + public java.lang.String toString() { + java.lang.StringBuilder sb = new java.lang.StringBuilder("TSpan("); boolean first = true; sb.append("agentId:"); @@ -2088,7 +2033,7 @@ public class TSpan implements org.apache.thrift.TBase, jav } } - 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; @@ -2098,13 +2043,13 @@ public class TSpan implements org.apache.thrift.TBase, jav } } - private static class TSpanStandardSchemeFactory implements SchemeFactory { + private static class TSpanStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory { public TSpanStandardScheme getScheme() { return new TSpanStandardScheme(); } } - private static class TSpanStandardScheme extends StandardScheme { + private static class TSpanStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TSpan struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -2216,7 +2161,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { org.apache.thrift.protocol.TList _list8 = iprot.readListBegin(); - struct.annotations = new ArrayList(_list8.size); + struct.annotations = new java.util.ArrayList(_list8.size); TAnnotation _elem9; for (int _i10 = 0; _i10 < _list8.size; ++_i10) { @@ -2251,7 +2196,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { org.apache.thrift.protocol.TList _list11 = iprot.readListBegin(); - struct.spanEventList = new ArrayList(_list11.size); + struct.spanEventList = new java.util.ArrayList(_list11.size); TSpanEvent _elem12; for (int _i13 = 0; _i13 < _list11.size; ++_i13) { @@ -2479,18 +2424,18 @@ public class TSpan implements org.apache.thrift.TBase, jav } - private static class TSpanTupleSchemeFactory implements SchemeFactory { + private static class TSpanTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory { public TSpanTupleScheme getScheme() { return new TSpanTupleScheme(); } } - private static class TSpanTupleScheme extends TupleScheme { + private static class TSpanTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TSpan 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.isSetAgentId()) { optionals.set(0); } @@ -2646,8 +2591,8 @@ public class TSpan implements org.apache.thrift.TBase, jav @Override public void read(org.apache.thrift.protocol.TProtocol prot, TSpan struct) throws org.apache.thrift.TException { - TTupleProtocol iprot = (TTupleProtocol) prot; - BitSet incoming = iprot.readBitSet(23); + org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot; + java.util.BitSet incoming = iprot.readBitSet(23); if (incoming.get(0)) { struct.agentId = iprot.readString(); struct.setAgentIdIsSet(true); @@ -2699,7 +2644,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (incoming.get(12)) { { org.apache.thrift.protocol.TList _list18 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.annotations = new ArrayList(_list18.size); + struct.annotations = new java.util.ArrayList(_list18.size); TAnnotation _elem19; for (int _i20 = 0; _i20 < _list18.size; ++_i20) { @@ -2721,7 +2666,7 @@ public class TSpan implements org.apache.thrift.TBase, jav if (incoming.get(15)) { { org.apache.thrift.protocol.TList _list21 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.spanEventList = new ArrayList(_list21.size); + struct.spanEventList = new java.util.ArrayList(_list21.size); TSpanEvent _elem22; for (int _i23 = 0; _i23 < _list21.size; ++_i23) { @@ -2764,5 +2709,8 @@ public class TSpan implements org.apache.thrift.TBase, jav } } + private static 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpanChunk.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpanChunk.java index 82bd42a73..4ed29060f 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpanChunk.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpanChunk.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TSpanChunk implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TSpanChunk"); @@ -48,20 +21,17 @@ public class TSpanChunk implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TSpanChunkStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TSpanChunkTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TSpanChunkStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TSpanChunkTupleSchemeFactory(); - private String agentId; // required - private String applicationName; // required + private java.lang.String agentId; // required + private java.lang.String applicationName; // required private long agentStartTime; // required private short serviceType; // required - private ByteBuffer transactionId; // required + private java.nio.ByteBuffer transactionId; // required private long spanId; // required - private String endPoint; // optional - private List spanEventList; // required + private java.lang.String endPoint; // optional + private java.util.List spanEventList; // required private short applicationServiceType; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ @@ -76,10 +46,10 @@ public class TSpanChunk implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -118,21 +88,21 @@ public class TSpanChunk implements org.apache.thrift.TBase 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.AGENT_ID, new org.apache.thrift.meta_data.FieldMetaData("agentId", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.APPLICATION_NAME, new org.apache.thrift.meta_data.FieldMetaData("applicationName", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -175,7 +145,7 @@ public class TSpanChunk implements org.apache.thrift.TBase spanEventList) + java.util.List spanEventList) { this(); this.agentId = agentId; @@ -225,7 +195,7 @@ public class TSpanChunk implements org.apache.thrift.TBase __this__spanEventList = new ArrayList(other.spanEventList.size()); + java.util.List __this__spanEventList = new java.util.ArrayList(other.spanEventList.size()); for (TSpanEvent other_element : other.spanEventList) { __this__spanEventList.add(new TSpanEvent(other_element)); } @@ -255,11 +225,11 @@ public class TSpanChunk implements org.apache.thrift.TBase(); + this.spanEventList = new java.util.ArrayList(); } this.spanEventList.add(elem); } - public List getSpanEventList() { + public java.util.List getSpanEventList() { return this.spanEventList; } - public void setSpanEventList(List spanEventList) { + public void setSpanEventList(java.util.List spanEventList) { this.spanEventList = spanEventList; } @@ -470,25 +440,25 @@ public class TSpanChunk implements org.apache.thrift.TBase)value); + setSpanEventList((java.util.List)value); } break; @@ -552,14 +526,14 @@ public class TSpanChunk implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_agentId = true && (isSetAgentId()); - list.add(present_agentId); - if (present_agentId) - list.add(agentId); + hashCode = hashCode * 8191 + ((isSetAgentId()) ? 131071 : 524287); + if (isSetAgentId()) + hashCode = hashCode * 8191 + agentId.hashCode(); - boolean present_applicationName = true && (isSetApplicationName()); - list.add(present_applicationName); - if (present_applicationName) - list.add(applicationName); + hashCode = hashCode * 8191 + ((isSetApplicationName()) ? 131071 : 524287); + if (isSetApplicationName()) + hashCode = hashCode * 8191 + applicationName.hashCode(); - boolean present_agentStartTime = true; - list.add(present_agentStartTime); - if (present_agentStartTime) - list.add(agentStartTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(agentStartTime); - boolean present_serviceType = true; - list.add(present_serviceType); - if (present_serviceType) - list.add(serviceType); + hashCode = hashCode * 8191 + serviceType; - boolean present_transactionId = true && (isSetTransactionId()); - list.add(present_transactionId); - if (present_transactionId) - list.add(transactionId); + hashCode = hashCode * 8191 + ((isSetTransactionId()) ? 131071 : 524287); + if (isSetTransactionId()) + hashCode = hashCode * 8191 + transactionId.hashCode(); - boolean present_spanId = true; - list.add(present_spanId); - if (present_spanId) - list.add(spanId); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(spanId); - boolean present_endPoint = true && (isSetEndPoint()); - list.add(present_endPoint); - if (present_endPoint) - list.add(endPoint); + hashCode = hashCode * 8191 + ((isSetEndPoint()) ? 131071 : 524287); + if (isSetEndPoint()) + hashCode = hashCode * 8191 + endPoint.hashCode(); - boolean present_spanEventList = true && (isSetSpanEventList()); - list.add(present_spanEventList); - if (present_spanEventList) - list.add(spanEventList); + hashCode = hashCode * 8191 + ((isSetSpanEventList()) ? 131071 : 524287); + if (isSetSpanEventList()) + hashCode = hashCode * 8191 + spanEventList.hashCode(); - boolean present_applicationServiceType = true && (isSetApplicationServiceType()); - list.add(present_applicationServiceType); - if (present_applicationServiceType) - list.add(applicationServiceType); + hashCode = hashCode * 8191 + ((isSetApplicationServiceType()) ? 131071 : 524287); + if (isSetApplicationServiceType()) + hashCode = hashCode * 8191 + applicationServiceType; - return list.hashCode(); + return hashCode; } @Override @@ -778,7 +739,7 @@ public class TSpanChunk implements org.apache.thrift.TBase { + private static class TSpanChunkStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TSpanChunk struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -1052,7 +1013,7 @@ public class TSpanChunk implements org.apache.thrift.TBase(_list24.size); + struct.spanEventList = new java.util.ArrayList(_list24.size); TSpanEvent _elem25; for (int _i26 = 0; _i26 < _list24.size; ++_i26) { @@ -1142,18 +1103,18 @@ public class TSpanChunk implements org.apache.thrift.TBase { + private static class TSpanChunkTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TSpanChunk 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.isSetAgentId()) { optionals.set(0); } @@ -1219,8 +1180,8 @@ public class TSpanChunk implements org.apache.thrift.TBase(_list29.size); + struct.spanEventList = new java.util.ArrayList(_list29.size); TSpanEvent _elem30; for (int _i31 = 0; _i31 < _list29.size; ++_i31) { @@ -1270,5 +1231,8 @@ public class TSpanChunk implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpanEvent.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpanEvent.java index fa51f2866..cffd592f8 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpanEvent.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSpanEvent.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TSpanEvent implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TSpanEvent"); @@ -55,23 +28,20 @@ public class TSpanEvent implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TSpanEventStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TSpanEventTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TSpanEventStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TSpanEventTupleSchemeFactory(); private long spanId; // optional private short sequence; // required private int startElapsed; // required private int endElapsed; // optional - private String rpc; // optional + private java.lang.String rpc; // optional private short serviceType; // required - private String endPoint; // optional - private List annotations; // optional + private java.lang.String endPoint; // optional + private java.util.List annotations; // optional private int depth; // optional private long nextSpanId; // optional - private String destinationId; // optional + private java.lang.String destinationId; // optional private int apiId; // optional private TIntStringValue exceptionInfo; // optional private int asyncId; // optional @@ -97,10 +67,10 @@ public class TSpanEvent implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -153,21 +123,21 @@ public class TSpanEvent implements org.apache.thrift.TBase 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.SPAN_ID, new org.apache.thrift.meta_data.FieldMetaData("spanId", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))); tmpMap.put(_Fields.SEQUENCE, new org.apache.thrift.meta_data.FieldMetaData("sequence", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -231,7 +201,7 @@ public class TSpanEvent implements org.apache.thrift.TBase __this__annotations = new ArrayList(other.annotations.size()); + java.util.List __this__annotations = new java.util.ArrayList(other.annotations.size()); for (TAnnotation other_element : other.annotations) { __this__annotations.add(new TAnnotation(other_element)); } @@ -340,16 +310,16 @@ public class TSpanEvent implements org.apache.thrift.TBase(); + this.annotations = new java.util.ArrayList(); } this.annotations.add(elem); } - public List getAnnotations() { + public java.util.List getAnnotations() { return this.annotations; } - public void setAnnotations(List annotations) { + public void setAnnotations(java.util.List annotations) { this.annotations = annotations; } @@ -534,16 +504,16 @@ public class TSpanEvent implements org.apache.thrift.TBase)value); + setAnnotations((java.util.List)value); } break; @@ -772,7 +742,7 @@ public class TSpanEvent implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_spanId = true && (isSetSpanId()); - list.add(present_spanId); - if (present_spanId) - list.add(spanId); + hashCode = hashCode * 8191 + ((isSetSpanId()) ? 131071 : 524287); + if (isSetSpanId()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(spanId); - boolean present_sequence = true; - list.add(present_sequence); - if (present_sequence) - list.add(sequence); + hashCode = hashCode * 8191 + sequence; - boolean present_startElapsed = true; - list.add(present_startElapsed); - if (present_startElapsed) - list.add(startElapsed); + hashCode = hashCode * 8191 + startElapsed; - boolean present_endElapsed = true && (isSetEndElapsed()); - list.add(present_endElapsed); - if (present_endElapsed) - list.add(endElapsed); + hashCode = hashCode * 8191 + ((isSetEndElapsed()) ? 131071 : 524287); + if (isSetEndElapsed()) + hashCode = hashCode * 8191 + endElapsed; - boolean present_rpc = true && (isSetRpc()); - list.add(present_rpc); - if (present_rpc) - list.add(rpc); + hashCode = hashCode * 8191 + ((isSetRpc()) ? 131071 : 524287); + if (isSetRpc()) + hashCode = hashCode * 8191 + rpc.hashCode(); - boolean present_serviceType = true; - list.add(present_serviceType); - if (present_serviceType) - list.add(serviceType); + hashCode = hashCode * 8191 + serviceType; - boolean present_endPoint = true && (isSetEndPoint()); - list.add(present_endPoint); - if (present_endPoint) - list.add(endPoint); + hashCode = hashCode * 8191 + ((isSetEndPoint()) ? 131071 : 524287); + if (isSetEndPoint()) + hashCode = hashCode * 8191 + endPoint.hashCode(); - boolean present_annotations = true && (isSetAnnotations()); - list.add(present_annotations); - if (present_annotations) - list.add(annotations); + hashCode = hashCode * 8191 + ((isSetAnnotations()) ? 131071 : 524287); + if (isSetAnnotations()) + hashCode = hashCode * 8191 + annotations.hashCode(); - boolean present_depth = true && (isSetDepth()); - list.add(present_depth); - if (present_depth) - list.add(depth); + hashCode = hashCode * 8191 + ((isSetDepth()) ? 131071 : 524287); + if (isSetDepth()) + hashCode = hashCode * 8191 + depth; - boolean present_nextSpanId = true && (isSetNextSpanId()); - list.add(present_nextSpanId); - if (present_nextSpanId) - list.add(nextSpanId); + hashCode = hashCode * 8191 + ((isSetNextSpanId()) ? 131071 : 524287); + if (isSetNextSpanId()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(nextSpanId); - boolean present_destinationId = true && (isSetDestinationId()); - list.add(present_destinationId); - if (present_destinationId) - list.add(destinationId); + hashCode = hashCode * 8191 + ((isSetDestinationId()) ? 131071 : 524287); + if (isSetDestinationId()) + hashCode = hashCode * 8191 + destinationId.hashCode(); - boolean present_apiId = true && (isSetApiId()); - list.add(present_apiId); - if (present_apiId) - list.add(apiId); + hashCode = hashCode * 8191 + ((isSetApiId()) ? 131071 : 524287); + if (isSetApiId()) + hashCode = hashCode * 8191 + apiId; - boolean present_exceptionInfo = true && (isSetExceptionInfo()); - list.add(present_exceptionInfo); - if (present_exceptionInfo) - list.add(exceptionInfo); + hashCode = hashCode * 8191 + ((isSetExceptionInfo()) ? 131071 : 524287); + if (isSetExceptionInfo()) + hashCode = hashCode * 8191 + exceptionInfo.hashCode(); - boolean present_asyncId = true && (isSetAsyncId()); - list.add(present_asyncId); - if (present_asyncId) - list.add(asyncId); + hashCode = hashCode * 8191 + ((isSetAsyncId()) ? 131071 : 524287); + if (isSetAsyncId()) + hashCode = hashCode * 8191 + asyncId; - boolean present_nextAsyncId = true && (isSetNextAsyncId()); - list.add(present_nextAsyncId); - if (present_nextAsyncId) - list.add(nextAsyncId); + hashCode = hashCode * 8191 + ((isSetNextAsyncId()) ? 131071 : 524287); + if (isSetNextAsyncId()) + hashCode = hashCode * 8191 + nextAsyncId; - boolean present_asyncSequence = true && (isSetAsyncSequence()); - list.add(present_asyncSequence); - if (present_asyncSequence) - list.add(asyncSequence); + hashCode = hashCode * 8191 + ((isSetAsyncSequence()) ? 131071 : 524287); + if (isSetAsyncSequence()) + hashCode = hashCode * 8191 + asyncSequence; - return list.hashCode(); + return hashCode; } @Override @@ -1187,7 +1137,7 @@ public class TSpanEvent implements org.apache.thrift.TBase { + private static class TSpanEventStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TSpanEvent struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -1584,7 +1534,7 @@ public class TSpanEvent implements org.apache.thrift.TBase(_list0.size); + struct.annotations = new java.util.ArrayList(_list0.size); TAnnotation _elem1; for (int _i2 = 0; _i2 < _list0.size; ++_i2) { @@ -1774,18 +1724,18 @@ public class TSpanEvent implements org.apache.thrift.TBase { + private static class TSpanEventTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TSpanEvent 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.isSetSpanId()) { optionals.set(0); } @@ -1893,8 +1843,8 @@ public class TSpanEvent implements org.apache.thrift.TBase(_list5.size); + struct.annotations = new java.util.ArrayList(_list5.size); TAnnotation _elem6; for (int _i7 = 0; _i7 < _list5.size; ++_i7) { @@ -1973,5 +1923,8 @@ public class TSpanEvent implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSqlMetaData.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSqlMetaData.java index 3013ee6dc..965b1148c 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSqlMetaData.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TSqlMetaData.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TSqlMetaData implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TSqlMetaData"); @@ -43,16 +16,13 @@ public class TSqlMetaData implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TSqlMetaDataStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TSqlMetaDataTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TSqlMetaDataStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TSqlMetaDataTupleSchemeFactory(); - private String agentId; // required + private java.lang.String agentId; // required private long agentStartTime; // required private int sqlId; // required - private String sql; // required + private java.lang.String sql; // 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 { @@ -61,10 +31,10 @@ public class TSqlMetaData implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -93,21 +63,21 @@ public class TSqlMetaData implements org.apache.thrift.TBase 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.AGENT_ID, new org.apache.thrift.meta_data.FieldMetaData("agentId", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.AGENT_START_TIME, new org.apache.thrift.meta_data.FieldMetaData("agentStartTime", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -136,7 +106,7 @@ public class TSqlMetaData implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_agentId = true && (isSetAgentId()); - list.add(present_agentId); - if (present_agentId) - list.add(agentId); + hashCode = hashCode * 8191 + ((isSetAgentId()) ? 131071 : 524287); + if (isSetAgentId()) + hashCode = hashCode * 8191 + agentId.hashCode(); - boolean present_agentStartTime = true; - list.add(present_agentStartTime); - if (present_agentStartTime) - list.add(agentStartTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(agentStartTime); - boolean present_sqlId = true; - list.add(present_sqlId); - if (present_sqlId) - list.add(sqlId); + hashCode = hashCode * 8191 + sqlId; - boolean present_sql = true && (isSetSql()); - list.add(present_sql); - if (present_sql) - list.add(sql); + hashCode = hashCode * 8191 + ((isSetSql()) ? 131071 : 524287); + if (isSetSql()) + hashCode = hashCode * 8191 + sql.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -438,7 +402,7 @@ public class TSqlMetaData implements org.apache.thrift.TBase { + private static class TSqlMetaDataStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TSqlMetaData struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -633,18 +597,18 @@ public class TSqlMetaData implements org.apache.thrift.TBase { + private static class TSqlMetaDataTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TSqlMetaData 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.isSetAgentId()) { optionals.set(0); } @@ -674,8 +638,8 @@ public class TSqlMetaData implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TStringMetaData.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TStringMetaData.java index 596b96b3a..a8c53da4c 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TStringMetaData.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TStringMetaData.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TStringMetaData implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TStringMetaData"); @@ -43,16 +16,13 @@ public class TStringMetaData implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TStringMetaDataStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TStringMetaDataTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TStringMetaDataStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TStringMetaDataTupleSchemeFactory(); - private String agentId; // required + private java.lang.String agentId; // required private long agentStartTime; // required private int stringId; // required - private String stringValue; // required + private java.lang.String stringValue; // 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 { @@ -61,10 +31,10 @@ public class TStringMetaData implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -93,21 +63,21 @@ public class TStringMetaData implements org.apache.thrift.TBase 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.AGENT_ID, new org.apache.thrift.meta_data.FieldMetaData("agentId", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.AGENT_START_TIME, new org.apache.thrift.meta_data.FieldMetaData("agentStartTime", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -136,7 +106,7 @@ public class TStringMetaData implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_agentId = true && (isSetAgentId()); - list.add(present_agentId); - if (present_agentId) - list.add(agentId); + hashCode = hashCode * 8191 + ((isSetAgentId()) ? 131071 : 524287); + if (isSetAgentId()) + hashCode = hashCode * 8191 + agentId.hashCode(); - boolean present_agentStartTime = true; - list.add(present_agentStartTime); - if (present_agentStartTime) - list.add(agentStartTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(agentStartTime); - boolean present_stringId = true; - list.add(present_stringId); - if (present_stringId) - list.add(stringId); + hashCode = hashCode * 8191 + stringId; - boolean present_stringValue = true && (isSetStringValue()); - list.add(present_stringValue); - if (present_stringValue) - list.add(stringValue); + hashCode = hashCode * 8191 + ((isSetStringValue()) ? 131071 : 524287); + if (isSetStringValue()) + hashCode = hashCode * 8191 + stringValue.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -438,7 +402,7 @@ public class TStringMetaData implements org.apache.thrift.TBase { + private static class TStringMetaDataStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TStringMetaData struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -633,18 +597,18 @@ public class TStringMetaData implements org.apache.thrift.TBase { + private static class TStringMetaDataTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TStringMetaData 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.isSetAgentId()) { optionals.set(0); } @@ -674,8 +638,8 @@ public class TStringMetaData implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TTransaction.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TTransaction.java index 0ca3744eb..1fb6361b8 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TTransaction.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/TTransaction.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto; -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 = "2015-10-29") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TTransaction implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TTransaction"); @@ -43,11 +16,8 @@ public class TTransaction implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TTransactionStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TTransactionTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TTransactionStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TTransactionTupleSchemeFactory(); private long sampledNewCount; // optional private long sampledContinuationCount; // optional @@ -61,10 +31,10 @@ public class TTransaction implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -93,21 +63,21 @@ public class TTransaction implements org.apache.thrift.TBase 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.SAMPLED_NEW_COUNT, new org.apache.thrift.meta_data.FieldMetaData("sampledNewCount", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))); tmpMap.put(_Fields.SAMPLED_CONTINUATION_COUNT, new org.apache.thrift.meta_data.FieldMetaData("sampledContinuationCount", org.apache.thrift.TFieldRequirementType.OPTIONAL, @@ -139,7 +109,7 @@ public class TTransaction implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_sampledNewCount = true && (isSetSampledNewCount()); - list.add(present_sampledNewCount); - if (present_sampledNewCount) - list.add(sampledNewCount); + hashCode = hashCode * 8191 + ((isSetSampledNewCount()) ? 131071 : 524287); + if (isSetSampledNewCount()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(sampledNewCount); - boolean present_sampledContinuationCount = true && (isSetSampledContinuationCount()); - list.add(present_sampledContinuationCount); - if (present_sampledContinuationCount) - list.add(sampledContinuationCount); + hashCode = hashCode * 8191 + ((isSetSampledContinuationCount()) ? 131071 : 524287); + if (isSetSampledContinuationCount()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(sampledContinuationCount); - boolean present_unsampledNewCount = true && (isSetUnsampledNewCount()); - list.add(present_unsampledNewCount); - if (present_unsampledNewCount) - list.add(unsampledNewCount); + hashCode = hashCode * 8191 + ((isSetUnsampledNewCount()) ? 131071 : 524287); + if (isSetUnsampledNewCount()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(unsampledNewCount); - boolean present_unsampledContinuationCount = true && (isSetUnsampledContinuationCount()); - list.add(present_unsampledContinuationCount); - if (present_unsampledContinuationCount) - list.add(unsampledContinuationCount); + hashCode = hashCode * 8191 + ((isSetUnsampledContinuationCount()) ? 131071 : 524287); + if (isSetUnsampledContinuationCount()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(unsampledContinuationCount); - return list.hashCode(); + return hashCode; } @Override @@ -422,7 +390,7 @@ public class TTransaction implements org.apache.thrift.TBase { + private static class TTransactionStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TTransaction struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -621,18 +589,18 @@ public class TTransaction implements org.apache.thrift.TBase { + private static class TTransactionTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TTransaction 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.isSetSampledNewCount()) { optionals.set(0); } @@ -662,8 +630,8 @@ public class TTransaction implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TActiveThreadDump.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TActiveThreadDump.java index 223498068..b55d1bf7a 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TActiveThreadDump.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TActiveThreadDump.java @@ -1,30 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -import org.apache.thrift.EncodingUtils; -import org.apache.thrift.protocol.TTupleProtocol; -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 javax.annotation.Generated; -import java.util.ArrayList; -import java.util.BitSet; -import java.util.Collections; -import java.util.EnumMap; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) -@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2017-1-2") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TActiveThreadDump implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TActiveThreadDump"); @@ -35,18 +18,15 @@ public class TActiveThreadDump implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TActiveThreadDumpStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TActiveThreadDumpTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TActiveThreadDumpStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TActiveThreadDumpTupleSchemeFactory(); private long startTime; // required private long localTraceId; // required private TThreadDump threadDump; // required private boolean sampled; // required - private String transactionId; // optional - private String entryPoint; // optional + private java.lang.String transactionId; // optional + private java.lang.String entryPoint; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { @@ -57,10 +37,10 @@ public class TActiveThreadDump implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -93,21 +73,21 @@ public class TActiveThreadDump implements org.apache.thrift.TBase 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.START_TIME, new org.apache.thrift.meta_data.FieldMetaData("startTime", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))); tmpMap.put(_Fields.LOCAL_TRACE_ID, new org.apache.thrift.meta_data.FieldMetaData("localTraceId", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -142,7 +122,7 @@ public class TActiveThreadDump implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_startTime = true; - list.add(present_startTime); - if (present_startTime) - list.add(startTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(startTime); - boolean present_localTraceId = true; - list.add(present_localTraceId); - if (present_localTraceId) - list.add(localTraceId); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(localTraceId); - boolean present_threadDump = true && (isSetThreadDump()); - list.add(present_threadDump); - if (present_threadDump) - list.add(threadDump); + hashCode = hashCode * 8191 + ((isSetThreadDump()) ? 131071 : 524287); + if (isSetThreadDump()) + hashCode = hashCode * 8191 + threadDump.hashCode(); - boolean present_sampled = true; - list.add(present_sampled); - if (present_sampled) - list.add(sampled); + hashCode = hashCode * 8191 + ((sampled) ? 131071 : 524287); - boolean present_transactionId = true && (isSetTransactionId()); - list.add(present_transactionId); - if (present_transactionId) - list.add(transactionId); + hashCode = hashCode * 8191 + ((isSetTransactionId()) ? 131071 : 524287); + if (isSetTransactionId()) + hashCode = hashCode * 8191 + transactionId.hashCode(); - boolean present_entryPoint = true && (isSetEntryPoint()); - list.add(present_entryPoint); - if (present_entryPoint) - list.add(entryPoint); + hashCode = hashCode * 8191 + ((isSetEntryPoint()) ? 131071 : 524287); + if (isSetEntryPoint()) + hashCode = hashCode * 8191 + entryPoint.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -553,7 +523,7 @@ public class TActiveThreadDump implements org.apache.thrift.TBase { + private static class TActiveThreadDumpStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TActiveThreadDump struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -816,18 +786,18 @@ public class TActiveThreadDump implements org.apache.thrift.TBase { + private static class TActiveThreadDumpTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TActiveThreadDump 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.isSetStartTime()) { optionals.set(0); } @@ -869,8 +839,8 @@ public class TActiveThreadDump implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TActiveThreadLightDump.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TActiveThreadLightDump.java index 4275646e8..c1b433e2c 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TActiveThreadLightDump.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TActiveThreadLightDump.java @@ -1,30 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -import org.apache.thrift.EncodingUtils; -import org.apache.thrift.protocol.TTupleProtocol; -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 javax.annotation.Generated; -import java.util.ArrayList; -import java.util.BitSet; -import java.util.Collections; -import java.util.EnumMap; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) -@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2017-1-2") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TActiveThreadLightDump implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TActiveThreadLightDump"); @@ -35,18 +18,15 @@ public class TActiveThreadLightDump implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TActiveThreadLightDumpStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TActiveThreadLightDumpTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TActiveThreadLightDumpStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TActiveThreadLightDumpTupleSchemeFactory(); private long startTime; // required private long localTraceId; // required private TThreadLightDump threadDump; // required private boolean sampled; // required - private String transactionId; // optional - private String entryPoint; // optional + private java.lang.String transactionId; // optional + private java.lang.String entryPoint; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { @@ -57,10 +37,10 @@ public class TActiveThreadLightDump implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -93,21 +73,21 @@ public class TActiveThreadLightDump implements org.apache.thrift.TBase 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.START_TIME, new org.apache.thrift.meta_data.FieldMetaData("startTime", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))); tmpMap.put(_Fields.LOCAL_TRACE_ID, new org.apache.thrift.meta_data.FieldMetaData("localTraceId", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -142,7 +122,7 @@ public class TActiveThreadLightDump implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_startTime = true; - list.add(present_startTime); - if (present_startTime) - list.add(startTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(startTime); - boolean present_localTraceId = true; - list.add(present_localTraceId); - if (present_localTraceId) - list.add(localTraceId); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(localTraceId); - boolean present_threadDump = true && (isSetThreadDump()); - list.add(present_threadDump); - if (present_threadDump) - list.add(threadDump); + hashCode = hashCode * 8191 + ((isSetThreadDump()) ? 131071 : 524287); + if (isSetThreadDump()) + hashCode = hashCode * 8191 + threadDump.hashCode(); - boolean present_sampled = true; - list.add(present_sampled); - if (present_sampled) - list.add(sampled); + hashCode = hashCode * 8191 + ((sampled) ? 131071 : 524287); - boolean present_transactionId = true && (isSetTransactionId()); - list.add(present_transactionId); - if (present_transactionId) - list.add(transactionId); + hashCode = hashCode * 8191 + ((isSetTransactionId()) ? 131071 : 524287); + if (isSetTransactionId()) + hashCode = hashCode * 8191 + transactionId.hashCode(); - boolean present_entryPoint = true && (isSetEntryPoint()); - list.add(present_entryPoint); - if (present_entryPoint) - list.add(entryPoint); + hashCode = hashCode * 8191 + ((isSetEntryPoint()) ? 131071 : 524287); + if (isSetEntryPoint()) + hashCode = hashCode * 8191 + entryPoint.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -553,7 +523,7 @@ public class TActiveThreadLightDump implements org.apache.thrift.TBase { + private static class TActiveThreadLightDumpStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TActiveThreadLightDump struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -816,18 +786,18 @@ public class TActiveThreadLightDump implements org.apache.thrift.TBase { + private static class TActiveThreadLightDumpTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TActiveThreadLightDump 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.isSetStartTime()) { optionals.set(0); } @@ -869,8 +839,8 @@ public class TActiveThreadLightDump implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadCount.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadCount.java index 43d2bdaaa..b70623f79 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadCount.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadCount.java @@ -1,59 +1,29 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -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 = "2015-9-2") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCmdActiveThreadCount implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCmdActiveThreadCount"); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCmdActiveThreadCountStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCmdActiveThreadCountTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCmdActiveThreadCountStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCmdActiveThreadCountTupleSchemeFactory(); /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { ; - private static final Map byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -74,21 +44,21 @@ public class TCmdActiveThreadCount implements org.apache.thrift.TBase 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); - metaDataMap = Collections.unmodifiableMap(tmpMap); + java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TCmdActiveThreadCount.class, metaDataMap); } @@ -125,30 +95,30 @@ public class TCmdActiveThreadCount implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - return list.hashCode(); + return hashCode; } @Override @@ -186,16 +158,16 @@ public class TCmdActiveThreadCount implements org.apache.thrift.TBase { + private static class TCmdActiveThreadCountStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCmdActiveThreadCount struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -260,24 +232,27 @@ public class TCmdActiveThreadCount implements org.apache.thrift.TBase { + private static class TCmdActiveThreadCountTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCmdActiveThreadCount struct) throws org.apache.thrift.TException { - TTupleProtocol oprot = (TTupleProtocol) prot; + org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot; } @Override public void read(org.apache.thrift.protocol.TProtocol prot, TCmdActiveThreadCount struct) throws org.apache.thrift.TException { - TTupleProtocol iprot = (TTupleProtocol) prot; + org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot; } } + private static 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadCountRes.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadCountRes.java index 133be8f53..4118678a7 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadCountRes.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadCountRes.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -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 = "2015-9-10") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCmdActiveThreadCountRes"); @@ -42,14 +15,11 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCmdActiveThreadCountResStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCmdActiveThreadCountResTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCmdActiveThreadCountResStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCmdActiveThreadCountResTupleSchemeFactory(); private int histogramSchemaType; // required - private List activeThreadCount; // required + private java.util.List activeThreadCount; // required private long timeStamp; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ @@ -58,10 +28,10 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -88,21 +58,21 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase 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.HISTOGRAM_SCHEMA_TYPE, new org.apache.thrift.meta_data.FieldMetaData("histogramSchemaType", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); tmpMap.put(_Fields.ACTIVE_THREAD_COUNT, new org.apache.thrift.meta_data.FieldMetaData("activeThreadCount", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -131,7 +101,7 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase activeThreadCount) + java.util.List activeThreadCount) { this(); this.histogramSchemaType = histogramSchemaType; @@ -155,7 +125,7 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase __this__activeThreadCount = new ArrayList(other.activeThreadCount); + java.util.List __this__activeThreadCount = new java.util.ArrayList(other.activeThreadCount); this.activeThreadCount = __this__activeThreadCount; } this.timeStamp = other.timeStamp; @@ -184,38 +154,38 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase getActiveThreadCountIterator() { + public java.util.Iterator getActiveThreadCountIterator() { return (this.activeThreadCount == null) ? null : this.activeThreadCount.iterator(); } public void addToActiveThreadCount(int elem) { if (this.activeThreadCount == null) { - this.activeThreadCount = new ArrayList(); + this.activeThreadCount = new java.util.ArrayList(); } this.activeThreadCount.add(elem); } - public List getActiveThreadCount() { + public java.util.List getActiveThreadCount() { return this.activeThreadCount; } - public void setActiveThreadCount(List activeThreadCount) { + public void setActiveThreadCount(java.util.List activeThreadCount) { this.activeThreadCount = activeThreadCount; } @@ -244,25 +214,25 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase)value); + setActiveThreadCount((java.util.List)value); } break; @@ -278,32 +248,32 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_histogramSchemaType = true; - list.add(present_histogramSchemaType); - if (present_histogramSchemaType) - list.add(histogramSchemaType); + hashCode = hashCode * 8191 + histogramSchemaType; - boolean present_activeThreadCount = true && (isSetActiveThreadCount()); - list.add(present_activeThreadCount); - if (present_activeThreadCount) - list.add(activeThreadCount); + hashCode = hashCode * 8191 + ((isSetActiveThreadCount()) ? 131071 : 524287); + if (isSetActiveThreadCount()) + hashCode = hashCode * 8191 + activeThreadCount.hashCode(); - boolean present_timeStamp = true && (isSetTimeStamp()); - list.add(present_timeStamp); - if (present_timeStamp) - list.add(timeStamp); + hashCode = hashCode * 8191 + ((isSetTimeStamp()) ? 131071 : 524287); + if (isSetTimeStamp()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(timeStamp); - return list.hashCode(); + return hashCode; } @Override @@ -390,7 +357,7 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase { + private static class TCmdActiveThreadCountResStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCmdActiveThreadCountRes struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -514,7 +481,7 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase(_list32.size); + struct.activeThreadCount = new java.util.ArrayList(_list32.size); int _elem33; for (int _i34 = 0; _i34 < _list32.size; ++_i34) { @@ -575,18 +542,18 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase { + private static class TCmdActiveThreadCountResTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCmdActiveThreadCountRes 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.isSetHistogramSchemaType()) { optionals.set(0); } @@ -616,8 +583,8 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase(_list37.size); + struct.activeThreadCount = new java.util.ArrayList(_list37.size); int _elem38; for (int _i39 = 0; _i39 < _list37.size; ++_i39) { @@ -642,5 +609,8 @@ public class TCmdActiveThreadCountRes implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadDump.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadDump.java index 8288dbca7..6c46948d4 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadDump.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadDump.java @@ -1,30 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -import org.apache.thrift.EncodingUtils; -import org.apache.thrift.protocol.TTupleProtocol; -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 javax.annotation.Generated; -import java.util.ArrayList; -import java.util.BitSet; -import java.util.Collections; -import java.util.EnumMap; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) -@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2017-1-2") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCmdActiveThreadDump implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCmdActiveThreadDump"); @@ -32,15 +15,12 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCmdActiveThreadDumpStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCmdActiveThreadDumpTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCmdActiveThreadDumpStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCmdActiveThreadDumpTupleSchemeFactory(); private int limit; // optional - private List threadNameList; // optional - private List localTraceIdList; // optional + private java.util.List threadNameList; // optional + private java.util.List localTraceIdList; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { @@ -48,10 +28,10 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -78,21 +58,21 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase 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.LIMIT, new org.apache.thrift.meta_data.FieldMetaData("limit", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); tmpMap.put(_Fields.THREAD_NAME_LIST, new org.apache.thrift.meta_data.FieldMetaData("threadNameList", org.apache.thrift.TFieldRequirementType.OPTIONAL, @@ -121,7 +101,7 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase __this__threadNameList = new ArrayList(other.threadNameList); + java.util.List __this__threadNameList = new java.util.ArrayList(other.threadNameList); this.threadNameList = __this__threadNameList; } if (other.isSetLocalTraceIdList()) { - List __this__localTraceIdList = new ArrayList(other.localTraceIdList); + java.util.List __this__localTraceIdList = new java.util.ArrayList(other.localTraceIdList); this.localTraceIdList = __this__localTraceIdList; } } @@ -166,38 +146,38 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase getThreadNameListIterator() { + public java.util.Iterator getThreadNameListIterator() { return (this.threadNameList == null) ? null : this.threadNameList.iterator(); } - public void addToThreadNameList(String elem) { + public void addToThreadNameList(java.lang.String elem) { if (this.threadNameList == null) { - this.threadNameList = new ArrayList(); + this.threadNameList = new java.util.ArrayList(); } this.threadNameList.add(elem); } - public List getThreadNameList() { + public java.util.List getThreadNameList() { return this.threadNameList; } - public void setThreadNameList(List threadNameList) { + public void setThreadNameList(java.util.List threadNameList) { this.threadNameList = threadNameList; } @@ -220,22 +200,22 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase getLocalTraceIdListIterator() { + public java.util.Iterator getLocalTraceIdListIterator() { return (this.localTraceIdList == null) ? null : this.localTraceIdList.iterator(); } public void addToLocalTraceIdList(long elem) { if (this.localTraceIdList == null) { - this.localTraceIdList = new ArrayList(); + this.localTraceIdList = new java.util.ArrayList(); } this.localTraceIdList.add(elem); } - public List getLocalTraceIdList() { + public java.util.List getLocalTraceIdList() { return this.localTraceIdList; } - public void setLocalTraceIdList(List localTraceIdList) { + public void setLocalTraceIdList(java.util.List localTraceIdList) { this.localTraceIdList = localTraceIdList; } @@ -254,13 +234,13 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase)value); + setThreadNameList((java.util.List)value); } break; @@ -276,17 +256,17 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase)value); + setLocalTraceIdList((java.util.List)value); } break; } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case LIMIT: - return Integer.valueOf(getLimit()); + return getLimit(); case THREAD_NAME_LIST: return getThreadNameList(); @@ -295,13 +275,13 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_limit = true && (isSetLimit()); - list.add(present_limit); - if (present_limit) - list.add(limit); + hashCode = hashCode * 8191 + ((isSetLimit()) ? 131071 : 524287); + if (isSetLimit()) + hashCode = hashCode * 8191 + limit; - boolean present_threadNameList = true && (isSetThreadNameList()); - list.add(present_threadNameList); - if (present_threadNameList) - list.add(threadNameList); + hashCode = hashCode * 8191 + ((isSetThreadNameList()) ? 131071 : 524287); + if (isSetThreadNameList()) + hashCode = hashCode * 8191 + threadNameList.hashCode(); - boolean present_localTraceIdList = true && (isSetLocalTraceIdList()); - list.add(present_localTraceIdList); - if (present_localTraceIdList) - list.add(localTraceIdList); + hashCode = hashCode * 8191 + ((isSetLocalTraceIdList()) ? 131071 : 524287); + if (isSetLocalTraceIdList()) + hashCode = hashCode * 8191 + localTraceIdList.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -388,7 +367,7 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase { + private static class TCmdActiveThreadDumpStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCmdActiveThreadDump struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -520,8 +499,8 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase(_list40.size); - String _elem41; + struct.threadNameList = new java.util.ArrayList(_list40.size); + java.lang.String _elem41; for (int _i42 = 0; _i42 < _list40.size; ++_i42) { _elem41 = iprot.readString(); @@ -538,7 +517,7 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase(_list43.size); + struct.localTraceIdList = new java.util.ArrayList(_list43.size); long _elem44; for (int _i45 = 0; _i45 < _list43.size; ++_i45) { @@ -575,7 +554,7 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase { + private static class TCmdActiveThreadDumpTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCmdActiveThreadDump 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.isSetLimit()) { optionals.set(0); } @@ -632,7 +611,7 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase(_list50.size); - String _elem51; + struct.threadNameList = new java.util.ArrayList(_list50.size); + java.lang.String _elem51; for (int _i52 = 0; _i52 < _list50.size; ++_i52) { _elem51 = iprot.readString(); @@ -673,7 +652,7 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase(_list53.size); + struct.localTraceIdList = new java.util.ArrayList(_list53.size); long _elem54; for (int _i55 = 0; _i55 < _list53.size; ++_i55) { @@ -686,5 +665,8 @@ public class TCmdActiveThreadDump implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadDumpRes.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadDumpRes.java index 005dd71ba..c10f8e5ec 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadDumpRes.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadDumpRes.java @@ -1,29 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -import org.apache.thrift.protocol.TTupleProtocol; -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 javax.annotation.Generated; -import java.util.ArrayList; -import java.util.BitSet; -import java.util.Collections; -import java.util.EnumMap; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) -@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2016-12-29") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCmdActiveThreadDumpRes"); @@ -32,16 +16,13 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCmdActiveThreadDumpResStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCmdActiveThreadDumpResTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCmdActiveThreadDumpResStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCmdActiveThreadDumpResTupleSchemeFactory(); - private List threadDumps; // required - private String type; // optional - private String subType; // optional - private String version; // optional + private java.util.List threadDumps; // required + private java.lang.String type; // optional + private java.lang.String subType; // optional + private java.lang.String version; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { @@ -50,10 +31,10 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -82,21 +63,21 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase 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.THREAD_DUMPS, new org.apache.thrift.meta_data.FieldMetaData("threadDumps", 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, TActiveThreadDump.class)))); @@ -124,7 +105,7 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase threadDumps) + java.util.List threadDumps) { this(); this.threadDumps = threadDumps; @@ -143,7 +124,7 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase __this__threadDumps = new ArrayList(other.threadDumps.size()); + java.util.List __this__threadDumps = new java.util.ArrayList(other.threadDumps.size()); for (TActiveThreadDump other_element : other.threadDumps) { __this__threadDumps.add(new TActiveThreadDump(other_element)); } @@ -182,16 +163,16 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase(); + this.threadDumps = new java.util.ArrayList(); } this.threadDumps.add(elem); } - public List getThreadDumps() { + public java.util.List getThreadDumps() { return this.threadDumps; } - public void setThreadDumps(List threadDumps) { + public void setThreadDumps(java.util.List threadDumps) { this.threadDumps = threadDumps; } @@ -210,11 +191,11 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase)value); + setThreadDumps((java.util.List)value); } break; @@ -293,7 +274,7 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_threadDumps = true && (isSetThreadDumps()); - list.add(present_threadDumps); - if (present_threadDumps) - list.add(threadDumps); + hashCode = hashCode * 8191 + ((isSetThreadDumps()) ? 131071 : 524287); + if (isSetThreadDumps()) + hashCode = hashCode * 8191 + threadDumps.hashCode(); - 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_subType = true && (isSetSubType()); - list.add(present_subType); - if (present_subType) - list.add(subType); + hashCode = hashCode * 8191 + ((isSetSubType()) ? 131071 : 524287); + if (isSetSubType()) + hashCode = hashCode * 8191 + subType.hashCode(); - boolean present_version = true && (isSetVersion()); - list.add(present_version); - if (present_version) - list.add(version); + hashCode = hashCode * 8191 + ((isSetVersion()) ? 131071 : 524287); + if (isSetVersion()) + hashCode = hashCode * 8191 + version.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -440,7 +419,7 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase { + private static class TCmdActiveThreadDumpResStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCmdActiveThreadDumpRes struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -584,7 +563,7 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase(_list72.size); + struct.threadDumps = new java.util.ArrayList(_list72.size); TActiveThreadDump _elem73; for (int _i74 = 0; _i74 < _list72.size; ++_i74) { @@ -675,18 +654,18 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase { + private static class TCmdActiveThreadDumpResTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCmdActiveThreadDumpRes 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.isSetThreadDumps()) { optionals.set(0); } @@ -722,12 +701,12 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase(_list77.size); + struct.threadDumps = new java.util.ArrayList(_list77.size); TActiveThreadDump _elem78; for (int _i79 = 0; _i79 < _list77.size; ++_i79) { @@ -753,5 +732,8 @@ public class TCmdActiveThreadDumpRes implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadLightDump.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadLightDump.java index 834ad9d9e..d07611a73 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadLightDump.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadLightDump.java @@ -1,30 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -import org.apache.thrift.EncodingUtils; -import org.apache.thrift.protocol.TTupleProtocol; -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 javax.annotation.Generated; -import java.util.ArrayList; -import java.util.BitSet; -import java.util.Collections; -import java.util.EnumMap; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) -@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2017-1-2") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCmdActiveThreadLightDump"); @@ -32,15 +15,12 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCmdActiveThreadLightDumpStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCmdActiveThreadLightDumpTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCmdActiveThreadLightDumpStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCmdActiveThreadLightDumpTupleSchemeFactory(); private int limit; // optional - private List threadNameList; // optional - private List localTraceIdList; // optional + private java.util.List threadNameList; // optional + private java.util.List localTraceIdList; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { @@ -48,10 +28,10 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -78,21 +58,21 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase 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.LIMIT, new org.apache.thrift.meta_data.FieldMetaData("limit", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); tmpMap.put(_Fields.THREAD_NAME_LIST, new org.apache.thrift.meta_data.FieldMetaData("threadNameList", org.apache.thrift.TFieldRequirementType.OPTIONAL, @@ -121,7 +101,7 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase __this__threadNameList = new ArrayList(other.threadNameList); + java.util.List __this__threadNameList = new java.util.ArrayList(other.threadNameList); this.threadNameList = __this__threadNameList; } if (other.isSetLocalTraceIdList()) { - List __this__localTraceIdList = new ArrayList(other.localTraceIdList); + java.util.List __this__localTraceIdList = new java.util.ArrayList(other.localTraceIdList); this.localTraceIdList = __this__localTraceIdList; } } @@ -166,38 +146,38 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase getThreadNameListIterator() { + public java.util.Iterator getThreadNameListIterator() { return (this.threadNameList == null) ? null : this.threadNameList.iterator(); } - public void addToThreadNameList(String elem) { + public void addToThreadNameList(java.lang.String elem) { if (this.threadNameList == null) { - this.threadNameList = new ArrayList(); + this.threadNameList = new java.util.ArrayList(); } this.threadNameList.add(elem); } - public List getThreadNameList() { + public java.util.List getThreadNameList() { return this.threadNameList; } - public void setThreadNameList(List threadNameList) { + public void setThreadNameList(java.util.List threadNameList) { this.threadNameList = threadNameList; } @@ -220,22 +200,22 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase getLocalTraceIdListIterator() { + public java.util.Iterator getLocalTraceIdListIterator() { return (this.localTraceIdList == null) ? null : this.localTraceIdList.iterator(); } public void addToLocalTraceIdList(long elem) { if (this.localTraceIdList == null) { - this.localTraceIdList = new ArrayList(); + this.localTraceIdList = new java.util.ArrayList(); } this.localTraceIdList.add(elem); } - public List getLocalTraceIdList() { + public java.util.List getLocalTraceIdList() { return this.localTraceIdList; } - public void setLocalTraceIdList(List localTraceIdList) { + public void setLocalTraceIdList(java.util.List localTraceIdList) { this.localTraceIdList = localTraceIdList; } @@ -254,13 +234,13 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase)value); + setThreadNameList((java.util.List)value); } break; @@ -276,17 +256,17 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase)value); + setLocalTraceIdList((java.util.List)value); } break; } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case LIMIT: - return Integer.valueOf(getLimit()); + return getLimit(); case THREAD_NAME_LIST: return getThreadNameList(); @@ -295,13 +275,13 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_limit = true && (isSetLimit()); - list.add(present_limit); - if (present_limit) - list.add(limit); + hashCode = hashCode * 8191 + ((isSetLimit()) ? 131071 : 524287); + if (isSetLimit()) + hashCode = hashCode * 8191 + limit; - boolean present_threadNameList = true && (isSetThreadNameList()); - list.add(present_threadNameList); - if (present_threadNameList) - list.add(threadNameList); + hashCode = hashCode * 8191 + ((isSetThreadNameList()) ? 131071 : 524287); + if (isSetThreadNameList()) + hashCode = hashCode * 8191 + threadNameList.hashCode(); - boolean present_localTraceIdList = true && (isSetLocalTraceIdList()); - list.add(present_localTraceIdList); - if (present_localTraceIdList) - list.add(localTraceIdList); + hashCode = hashCode * 8191 + ((isSetLocalTraceIdList()) ? 131071 : 524287); + if (isSetLocalTraceIdList()) + hashCode = hashCode * 8191 + localTraceIdList.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -388,7 +367,7 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase { + private static class TCmdActiveThreadLightDumpStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCmdActiveThreadLightDump struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -520,8 +499,8 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase(_list56.size); - String _elem57; + struct.threadNameList = new java.util.ArrayList(_list56.size); + java.lang.String _elem57; for (int _i58 = 0; _i58 < _list56.size; ++_i58) { _elem57 = iprot.readString(); @@ -538,7 +517,7 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase(_list59.size); + struct.localTraceIdList = new java.util.ArrayList(_list59.size); long _elem60; for (int _i61 = 0; _i61 < _list59.size; ++_i61) { @@ -575,7 +554,7 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase { + private static class TCmdActiveThreadLightDumpTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCmdActiveThreadLightDump 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.isSetLimit()) { optionals.set(0); } @@ -632,7 +611,7 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase(_list66.size); - String _elem67; + struct.threadNameList = new java.util.ArrayList(_list66.size); + java.lang.String _elem67; for (int _i68 = 0; _i68 < _list66.size; ++_i68) { _elem67 = iprot.readString(); @@ -673,7 +652,7 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase(_list69.size); + struct.localTraceIdList = new java.util.ArrayList(_list69.size); long _elem70; for (int _i71 = 0; _i71 < _list69.size; ++_i71) { @@ -686,5 +665,8 @@ public class TCmdActiveThreadLightDump implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadLightDumpRes.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadLightDumpRes.java index cf1a0368d..c2bceaa72 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadLightDumpRes.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCmdActiveThreadLightDumpRes.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -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 = "2016-12-29") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCmdActiveThreadLightDumpRes"); @@ -43,16 +16,13 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCmdActiveThreadLightDumpResStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCmdActiveThreadLightDumpResTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCmdActiveThreadLightDumpResStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCmdActiveThreadLightDumpResTupleSchemeFactory(); - private List threadDumps; // required - private String type; // optional - private String subType; // optional - private String version; // optional + private java.util.List threadDumps; // required + private java.lang.String type; // optional + private java.lang.String subType; // optional + private java.lang.String version; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { @@ -61,10 +31,10 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -93,21 +63,21 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase 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.THREAD_DUMPS, new org.apache.thrift.meta_data.FieldMetaData("threadDumps", 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, TActiveThreadLightDump.class)))); @@ -135,7 +105,7 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase threadDumps) + java.util.List threadDumps) { this(); this.threadDumps = threadDumps; @@ -154,7 +124,7 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase __this__threadDumps = new ArrayList(other.threadDumps.size()); + java.util.List __this__threadDumps = new java.util.ArrayList(other.threadDumps.size()); for (TActiveThreadLightDump other_element : other.threadDumps) { __this__threadDumps.add(new TActiveThreadLightDump(other_element)); } @@ -193,16 +163,16 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase(); + this.threadDumps = new java.util.ArrayList(); } this.threadDumps.add(elem); } - public List getThreadDumps() { + public java.util.List getThreadDumps() { return this.threadDumps; } - public void setThreadDumps(List threadDumps) { + public void setThreadDumps(java.util.List threadDumps) { this.threadDumps = threadDumps; } @@ -221,11 +191,11 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase)value); + setThreadDumps((java.util.List)value); } break; @@ -304,7 +274,7 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_threadDumps = true && (isSetThreadDumps()); - list.add(present_threadDumps); - if (present_threadDumps) - list.add(threadDumps); + hashCode = hashCode * 8191 + ((isSetThreadDumps()) ? 131071 : 524287); + if (isSetThreadDumps()) + hashCode = hashCode * 8191 + threadDumps.hashCode(); - 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_subType = true && (isSetSubType()); - list.add(present_subType); - if (present_subType) - list.add(subType); + hashCode = hashCode * 8191 + ((isSetSubType()) ? 131071 : 524287); + if (isSetSubType()) + hashCode = hashCode * 8191 + subType.hashCode(); - boolean present_version = true && (isSetVersion()); - list.add(present_version); - if (present_version) - list.add(version); + hashCode = hashCode * 8191 + ((isSetVersion()) ? 131071 : 524287); + if (isSetVersion()) + hashCode = hashCode * 8191 + version.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -451,7 +419,7 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase { + private static class TCmdActiveThreadLightDumpResStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCmdActiveThreadLightDumpRes struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -595,7 +563,7 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase(_list80.size); + struct.threadDumps = new java.util.ArrayList(_list80.size); TActiveThreadLightDump _elem81; for (int _i82 = 0; _i82 < _list80.size; ++_i82) { @@ -686,18 +654,18 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase { + private static class TCmdActiveThreadLightDumpResTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCmdActiveThreadLightDumpRes 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.isSetThreadDumps()) { optionals.set(0); } @@ -733,12 +701,12 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase(_list85.size); + struct.threadDumps = new java.util.ArrayList(_list85.size); TActiveThreadLightDump _elem86; for (int _i87 = 0; _i87 < _list85.size; ++_i87) { @@ -764,5 +732,8 @@ public class TCmdActiveThreadLightDumpRes implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandEcho.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandEcho.java index 9bfd260bd..7f31a3e70 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandEcho.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandEcho.java @@ -1,61 +1,31 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCommandEcho implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCommandEcho"); private static final org.apache.thrift.protocol.TField MESSAGE_FIELD_DESC = new org.apache.thrift.protocol.TField("message", org.apache.thrift.protocol.TType.STRING, (short)1); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCommandEchoStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCommandEchoTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCommandEchoStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCommandEchoTupleSchemeFactory(); - private String message; // required + private java.lang.String message; // 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 { MESSAGE((short)1, "message"); - private static final Map byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -78,21 +48,21 @@ public class TCommandEcho implements org.apache.thrift.TBase 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.MESSAGE, new org.apache.thrift.meta_data.FieldMetaData("message", 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(TCommandEcho.class, metaDataMap); } @@ -120,7 +90,7 @@ public class TCommandEcho implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_message = true && (isSetMessage()); - list.add(present_message); - if (present_message) - list.add(message); + hashCode = hashCode * 8191 + ((isSetMessage()) ? 131071 : 524287); + if (isSetMessage()) + hashCode = hashCode * 8191 + message.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -247,7 +218,7 @@ public class TCommandEcho implements org.apache.thrift.TBase { + private static class TCommandEchoStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCommandEcho struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -359,18 +330,18 @@ public class TCommandEcho implements org.apache.thrift.TBase { + private static class TCommandEchoTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCommandEcho 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.isSetMessage()) { optionals.set(0); } @@ -382,8 +353,8 @@ public class TCommandEcho implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandThreadDump.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandThreadDump.java index 325fe57be..d3f64646c 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandThreadDump.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandThreadDump.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCommandThreadDump implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCommandThreadDump"); @@ -42,14 +15,11 @@ public class TCommandThreadDump implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCommandThreadDumpStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCommandThreadDumpTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCommandThreadDumpStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCommandThreadDumpTupleSchemeFactory(); private TThreadDumpType type; // required - private String name; // optional + private java.lang.String name; // optional private long pendingTimeMillis; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ @@ -62,10 +32,10 @@ public class TCommandThreadDump implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -92,21 +62,21 @@ public class TCommandThreadDump implements org.apache.thrift.TBase 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, TThreadDumpType.class))); tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.PENDING_TIME_MILLIS, new org.apache.thrift.meta_data.FieldMetaData("pendingTimeMillis", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TCommandThreadDump.class, metaDataMap); } @@ -207,11 +177,11 @@ public class TCommandThreadDump implements org.apache.thrift.TBase list = new ArrayList(); + 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_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_pendingTimeMillis = true && (isSetPendingTimeMillis()); - list.add(present_pendingTimeMillis); - if (present_pendingTimeMillis) - list.add(pendingTimeMillis); + hashCode = hashCode * 8191 + ((isSetPendingTimeMillis()) ? 131071 : 524287); + if (isSetPendingTimeMillis()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(pendingTimeMillis); - return list.hashCode(); + return hashCode; } @Override @@ -386,7 +355,7 @@ public class TCommandThreadDump implements org.apache.thrift.TBase { + private static class TCommandThreadDumpStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCommandThreadDump struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -564,18 +533,18 @@ public class TCommandThreadDump implements org.apache.thrift.TBase { + private static class TCommandThreadDumpTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCommandThreadDump 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); } @@ -599,8 +568,8 @@ public class TCommandThreadDump implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandThreadDumpResponse.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandThreadDumpResponse.java index 1a8876af2..6d94db2cb 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandThreadDumpResponse.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandThreadDumpResponse.java @@ -1,61 +1,31 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCommandThreadDumpResponse implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCommandThreadDumpResponse"); private static final org.apache.thrift.protocol.TField THREAD_DUMPS_FIELD_DESC = new org.apache.thrift.protocol.TField("threadDumps", org.apache.thrift.protocol.TType.LIST, (short)1); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCommandThreadDumpResponseStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCommandThreadDumpResponseTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCommandThreadDumpResponseStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCommandThreadDumpResponseTupleSchemeFactory(); - private List threadDumps; // required + private java.util.List threadDumps; // 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 { THREAD_DUMPS((short)1, "threadDumps"); - private static final Map byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -78,21 +48,21 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase 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.THREAD_DUMPS, new org.apache.thrift.meta_data.FieldMetaData("threadDumps", 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, TThreadDump.class)))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TCommandThreadDumpResponse.class, metaDataMap); } @@ -121,7 +91,7 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase threadDumps) + java.util.List threadDumps) { this(); this.threadDumps = threadDumps; @@ -132,7 +102,7 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase __this__threadDumps = new ArrayList(other.threadDumps.size()); + java.util.List __this__threadDumps = new java.util.ArrayList(other.threadDumps.size()); for (TThreadDump other_element : other.threadDumps) { __this__threadDumps.add(new TThreadDump(other_element)); } @@ -159,16 +129,16 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase(); + this.threadDumps = new java.util.ArrayList(); } this.threadDumps.add(elem); } - public List getThreadDumps() { + public java.util.List getThreadDumps() { return this.threadDumps; } - public void setThreadDumps(List threadDumps) { + public void setThreadDumps(java.util.List threadDumps) { this.threadDumps = threadDumps; } @@ -187,43 +157,43 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase)value); + setThreadDumps((java.util.List)value); } break; } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case THREAD_DUMPS: return getThreadDumps(); } - 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 THREAD_DUMPS: return isSetThreadDumps(); } - 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 TCommandThreadDumpResponse) @@ -234,6 +204,8 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_threadDumps = true && (isSetThreadDumps()); - list.add(present_threadDumps); - if (present_threadDumps) - list.add(threadDumps); + hashCode = hashCode * 8191 + ((isSetThreadDumps()) ? 131071 : 524287); + if (isSetThreadDumps()) + hashCode = hashCode * 8191 + threadDumps.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -267,7 +238,7 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase { + private static class TCommandThreadDumpResponseStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCommandThreadDumpResponse struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -351,7 +322,7 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase(_list24.size); + struct.threadDumps = new java.util.ArrayList(_list24.size); TThreadDump _elem25; for (int _i26 = 0; _i26 < _list24.size; ++_i26) { @@ -397,18 +368,18 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase { + private static class TCommandThreadDumpResponseTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCommandThreadDumpResponse 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.isSetThreadDumps()) { optionals.set(0); } @@ -426,12 +397,12 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase(_list29.size); + struct.threadDumps = new java.util.ArrayList(_list29.size); TThreadDump _elem30; for (int _i31 = 0; _i31 < _list29.size; ++_i31) { @@ -445,5 +416,8 @@ public class TCommandThreadDumpResponse implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandTransfer.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandTransfer.java index 25d2dcb9a..228073ce5 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandTransfer.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandTransfer.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCommandTransfer implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCommandTransfer"); @@ -43,16 +16,13 @@ public class TCommandTransfer implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCommandTransferStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCommandTransferTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCommandTransferStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCommandTransferTupleSchemeFactory(); - private String applicationName; // required - private String agentId; // required + private java.lang.String applicationName; // required + private java.lang.String agentId; // required private long startTime; // optional - private ByteBuffer payload; // required + private java.nio.ByteBuffer payload; // 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 { @@ -61,10 +31,10 @@ public class TCommandTransfer implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -93,21 +63,21 @@ public class TCommandTransfer implements org.apache.thrift.TBase 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.APPLICATION_NAME, new org.apache.thrift.meta_data.FieldMetaData("applicationName", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.AGENT_ID, new org.apache.thrift.meta_data.FieldMetaData("agentId", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -136,7 +106,7 @@ public class TCommandTransfer implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_applicationName = true && (isSetApplicationName()); - list.add(present_applicationName); - if (present_applicationName) - list.add(applicationName); + hashCode = hashCode * 8191 + ((isSetApplicationName()) ? 131071 : 524287); + if (isSetApplicationName()) + hashCode = hashCode * 8191 + applicationName.hashCode(); - boolean present_agentId = true && (isSetAgentId()); - list.add(present_agentId); - if (present_agentId) - list.add(agentId); + hashCode = hashCode * 8191 + ((isSetAgentId()) ? 131071 : 524287); + if (isSetAgentId()) + hashCode = hashCode * 8191 + agentId.hashCode(); - boolean present_startTime = true && (isSetStartTime()); - list.add(present_startTime); - if (present_startTime) - list.add(startTime); + hashCode = hashCode * 8191 + ((isSetStartTime()) ? 131071 : 524287); + if (isSetStartTime()) + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(startTime); - boolean present_payload = true && (isSetPayload()); - list.add(present_payload); - if (present_payload) - list.add(payload); + hashCode = hashCode * 8191 + ((isSetPayload()) ? 131071 : 524287); + if (isSetPayload()) + hashCode = hashCode * 8191 + payload.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -445,7 +417,7 @@ public class TCommandTransfer implements org.apache.thrift.TBase { + private static class TCommandTransferStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCommandTransfer struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -650,18 +622,18 @@ public class TCommandTransfer implements org.apache.thrift.TBase { + private static class TCommandTransferTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCommandTransfer 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.isSetApplicationName()) { optionals.set(0); } @@ -691,8 +663,8 @@ public class TCommandTransfer implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandTransferResponse.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandTransferResponse.java index c4d12c325..334d2d5c4 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandTransferResponse.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TCommandTransferResponse.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -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 = "2015-8-18") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TCommandTransferResponse implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TCommandTransferResponse"); @@ -42,15 +15,12 @@ public class TCommandTransferResponse implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TCommandTransferResponseStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TCommandTransferResponseTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TCommandTransferResponseStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TCommandTransferResponseTupleSchemeFactory(); private TRouteResult routeResult; // required - private ByteBuffer payload; // required - private String message; // optional + private java.nio.ByteBuffer payload; // required + private java.lang.String message; // optional /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ public enum _Fields implements org.apache.thrift.TFieldIdEnum { @@ -62,10 +32,10 @@ public class TCommandTransferResponse implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -92,21 +62,21 @@ public class TCommandTransferResponse implements org.apache.thrift.TBase 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.ROUTE_RESULT, new org.apache.thrift.meta_data.FieldMetaData("routeResult", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, TRouteResult.class))); tmpMap.put(_Fields.PAYLOAD, new org.apache.thrift.meta_data.FieldMetaData("payload", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING , true))); tmpMap.put(_Fields.MESSAGE, new org.apache.thrift.meta_data.FieldMetaData("message", org.apache.thrift.TFieldRequirementType.OPTIONAL, 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(TCommandTransferResponse.class, metaDataMap); } @@ -140,7 +110,7 @@ public class TCommandTransferResponse implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_routeResult = true && (isSetRouteResult()); - list.add(present_routeResult); - if (present_routeResult) - list.add(routeResult.getValue()); + hashCode = hashCode * 8191 + ((isSetRouteResult()) ? 131071 : 524287); + if (isSetRouteResult()) + hashCode = hashCode * 8191 + routeResult.getValue(); - boolean present_payload = true && (isSetPayload()); - list.add(present_payload); - if (present_payload) - list.add(payload); + hashCode = hashCode * 8191 + ((isSetPayload()) ? 131071 : 524287); + if (isSetPayload()) + hashCode = hashCode * 8191 + payload.hashCode(); - boolean present_message = true && (isSetMessage()); - list.add(present_message); - if (present_message) - list.add(message); + hashCode = hashCode * 8191 + ((isSetMessage()) ? 131071 : 524287); + if (isSetMessage()) + hashCode = hashCode * 8191 + message.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -393,7 +366,7 @@ public class TCommandTransferResponse implements org.apache.thrift.TBase { + private static class TCommandTransferResponseStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TCommandTransferResponse struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -571,18 +544,18 @@ public class TCommandTransferResponse implements org.apache.thrift.TBase { + private static class TCommandTransferResponseTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TCommandTransferResponse 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.isSetRouteResult()) { optionals.set(0); } @@ -606,8 +579,8 @@ public class TCommandTransferResponse implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TMonitorInfo.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TMonitorInfo.java index d44053a6d..e40cbab55 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TMonitorInfo.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TMonitorInfo.java @@ -1,64 +1,34 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TMonitorInfo implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TMonitorInfo"); private static final org.apache.thrift.protocol.TField STACK_DEPTH_FIELD_DESC = new org.apache.thrift.protocol.TField("stackDepth", org.apache.thrift.protocol.TType.I32, (short)1); private static final org.apache.thrift.protocol.TField STACK_FRAME_FIELD_DESC = new org.apache.thrift.protocol.TField("stackFrame", org.apache.thrift.protocol.TType.STRING, (short)2); - private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TMonitorInfoStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TMonitorInfoTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TMonitorInfoStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TMonitorInfoTupleSchemeFactory(); private int stackDepth; // required - private String stackFrame; // required + private java.lang.String stackFrame; // 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 { STACK_DEPTH((short)1, "stackDepth"), STACK_FRAME((short)2, "stackFrame"); - private static final Map byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -83,21 +53,21 @@ public class TMonitorInfo implements org.apache.thrift.TBase 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.STACK_DEPTH, new org.apache.thrift.meta_data.FieldMetaData("stackDepth", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); tmpMap.put(_Fields.STACK_FRAME, new org.apache.thrift.meta_data.FieldMetaData("stackFrame", 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(TMonitorInfo.class, metaDataMap); } @@ -130,7 +100,7 @@ public class TMonitorInfo implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_stackDepth = true; - list.add(present_stackDepth); - if (present_stackDepth) - list.add(stackDepth); + hashCode = hashCode * 8191 + stackDepth; - boolean present_stackFrame = true && (isSetStackFrame()); - list.add(present_stackFrame); - if (present_stackFrame) - list.add(stackFrame); + hashCode = hashCode * 8191 + ((isSetStackFrame()) ? 131071 : 524287); + if (isSetStackFrame()) + hashCode = hashCode * 8191 + stackFrame.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -312,7 +280,7 @@ public class TMonitorInfo implements org.apache.thrift.TBase { + private static class TMonitorInfoStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TMonitorInfo struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -451,18 +419,18 @@ public class TMonitorInfo implements org.apache.thrift.TBase { + private static class TMonitorInfoTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TMonitorInfo 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.isSetStackDepth()) { optionals.set(0); } @@ -480,8 +448,8 @@ public class TMonitorInfo implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TRouteResult.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TRouteResult.java index 116c7cd53..b55f5ab26 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TRouteResult.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TRouteResult.java @@ -1,5 +1,5 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated @@ -69,7 +69,7 @@ public enum TRouteResult implements org.apache.thrift.TEnum { case -1: return UNKNOWN; default: - return UNKNOWN; + return null; } } } diff --git a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadDump.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadDump.java index 824c61f3e..e5bfac096 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadDump.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadDump.java @@ -1,40 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -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 = "2015-6-19") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TThreadDump implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TThreadDump"); @@ -54,27 +27,24 @@ public class TThreadDump implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TThreadDumpStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TThreadDumpTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TThreadDumpStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TThreadDumpTupleSchemeFactory(); - private String threadName; // required + private java.lang.String threadName; // required private long threadId; // required private long blockedTime; // required private long blockedCount; // required private long waitedTime; // required private long waitedCount; // required - private String lockName; // required + private java.lang.String lockName; // required private long lockOwnerId; // required - private String lockOwnerName; // required + private java.lang.String lockOwnerName; // required private boolean inNative; // required private boolean suspended; // required private TThreadState threadState; // required - private List stackTrace; // required - private List lockedMonitors; // required - private List lockedSynchronizers; // required + private java.util.List stackTrace; // required + private java.util.List lockedMonitors; // required + private java.util.List lockedSynchronizers; // 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 { @@ -98,10 +68,10 @@ public class TThreadDump implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -152,21 +122,21 @@ public class TThreadDump implements org.apache.thrift.TBase 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.THREAD_NAME, new org.apache.thrift.meta_data.FieldMetaData("threadName", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.THREAD_ID, new org.apache.thrift.meta_data.FieldMetaData("threadId", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -226,7 +196,7 @@ public class TThreadDump implements org.apache.thrift.TBase stackTrace, - List lockedMonitors, - List lockedSynchronizers) + java.util.List stackTrace, + java.util.List lockedMonitors, + java.util.List lockedSynchronizers) { this(); this.threadName = threadName; @@ -302,18 +272,18 @@ public class TThreadDump implements org.apache.thrift.TBase __this__stackTrace = new ArrayList(other.stackTrace); + java.util.List __this__stackTrace = new java.util.ArrayList(other.stackTrace); this.stackTrace = __this__stackTrace; } if (other.isSetLockedMonitors()) { - List __this__lockedMonitors = new ArrayList(other.lockedMonitors.size()); + java.util.List __this__lockedMonitors = new java.util.ArrayList(other.lockedMonitors.size()); for (TMonitorInfo other_element : other.lockedMonitors) { __this__lockedMonitors.add(new TMonitorInfo(other_element)); } this.lockedMonitors = __this__lockedMonitors; } if (other.isSetLockedSynchronizers()) { - List __this__lockedSynchronizers = new ArrayList(other.lockedSynchronizers); + java.util.List __this__lockedSynchronizers = new java.util.ArrayList(other.lockedSynchronizers); this.lockedSynchronizers = __this__lockedSynchronizers; } } @@ -349,11 +319,11 @@ public class TThreadDump implements org.apache.thrift.TBase getStackTraceIterator() { + public java.util.Iterator getStackTraceIterator() { return (this.stackTrace == null) ? null : this.stackTrace.iterator(); } - public void addToStackTrace(String elem) { + public void addToStackTrace(java.lang.String elem) { if (this.stackTrace == null) { - this.stackTrace = new ArrayList(); + this.stackTrace = new java.util.ArrayList(); } this.stackTrace.add(elem); } - public List getStackTrace() { + public java.util.List getStackTrace() { return this.stackTrace; } - public void setStackTrace(List stackTrace) { + public void setStackTrace(java.util.List stackTrace) { this.stackTrace = stackTrace; } @@ -673,16 +643,16 @@ public class TThreadDump implements org.apache.thrift.TBase(); + this.lockedMonitors = new java.util.ArrayList(); } this.lockedMonitors.add(elem); } - public List getLockedMonitors() { + public java.util.List getLockedMonitors() { return this.lockedMonitors; } - public void setLockedMonitors(List lockedMonitors) { + public void setLockedMonitors(java.util.List lockedMonitors) { this.lockedMonitors = lockedMonitors; } @@ -705,22 +675,22 @@ public class TThreadDump implements org.apache.thrift.TBase getLockedSynchronizersIterator() { + public java.util.Iterator getLockedSynchronizersIterator() { return (this.lockedSynchronizers == null) ? null : this.lockedSynchronizers.iterator(); } - public void addToLockedSynchronizers(String elem) { + public void addToLockedSynchronizers(java.lang.String elem) { if (this.lockedSynchronizers == null) { - this.lockedSynchronizers = new ArrayList(); + this.lockedSynchronizers = new java.util.ArrayList(); } this.lockedSynchronizers.add(elem); } - public List getLockedSynchronizers() { + public java.util.List getLockedSynchronizers() { return this.lockedSynchronizers; } - public void setLockedSynchronizers(List lockedSynchronizers) { + public void setLockedSynchronizers(java.util.List lockedSynchronizers) { this.lockedSynchronizers = lockedSynchronizers; } @@ -739,13 +709,13 @@ public class TThreadDump implements org.apache.thrift.TBase)value); + setStackTrace((java.util.List)value); } break; @@ -849,7 +819,7 @@ public class TThreadDump implements org.apache.thrift.TBase)value); + setLockedMonitors((java.util.List)value); } break; @@ -857,47 +827,47 @@ public class TThreadDump implements org.apache.thrift.TBase)value); + setLockedSynchronizers((java.util.List)value); } break; } } - public Object getFieldValue(_Fields field) { + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case THREAD_NAME: return getThreadName(); case THREAD_ID: - return Long.valueOf(getThreadId()); + return getThreadId(); case BLOCKED_TIME: - return Long.valueOf(getBlockedTime()); + return getBlockedTime(); case BLOCKED_COUNT: - return Long.valueOf(getBlockedCount()); + return getBlockedCount(); case WAITED_TIME: - return Long.valueOf(getWaitedTime()); + return getWaitedTime(); case WAITED_COUNT: - return Long.valueOf(getWaitedCount()); + return getWaitedCount(); case LOCK_NAME: return getLockName(); case LOCK_OWNER_ID: - return Long.valueOf(getLockOwnerId()); + return getLockOwnerId(); case LOCK_OWNER_NAME: return getLockOwnerName(); case IN_NATIVE: - return Boolean.valueOf(isInNative()); + return isInNative(); case SUSPENDED: - return Boolean.valueOf(isSuspended()); + return isSuspended(); case THREAD_STATE: return getThreadState(); @@ -912,13 +882,13 @@ public class TThreadDump implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_threadName = true && (isSetThreadName()); - list.add(present_threadName); - if (present_threadName) - list.add(threadName); + hashCode = hashCode * 8191 + ((isSetThreadName()) ? 131071 : 524287); + if (isSetThreadName()) + hashCode = hashCode * 8191 + threadName.hashCode(); - boolean present_threadId = true; - list.add(present_threadId); - if (present_threadId) - list.add(threadId); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(threadId); - boolean present_blockedTime = true; - list.add(present_blockedTime); - if (present_blockedTime) - list.add(blockedTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(blockedTime); - boolean present_blockedCount = true; - list.add(present_blockedCount); - if (present_blockedCount) - list.add(blockedCount); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(blockedCount); - boolean present_waitedTime = true; - list.add(present_waitedTime); - if (present_waitedTime) - list.add(waitedTime); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(waitedTime); - boolean present_waitedCount = true; - list.add(present_waitedCount); - if (present_waitedCount) - list.add(waitedCount); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(waitedCount); - boolean present_lockName = true && (isSetLockName()); - list.add(present_lockName); - if (present_lockName) - list.add(lockName); + hashCode = hashCode * 8191 + ((isSetLockName()) ? 131071 : 524287); + if (isSetLockName()) + hashCode = hashCode * 8191 + lockName.hashCode(); - boolean present_lockOwnerId = true; - list.add(present_lockOwnerId); - if (present_lockOwnerId) - list.add(lockOwnerId); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(lockOwnerId); - boolean present_lockOwnerName = true && (isSetLockOwnerName()); - list.add(present_lockOwnerName); - if (present_lockOwnerName) - list.add(lockOwnerName); + hashCode = hashCode * 8191 + ((isSetLockOwnerName()) ? 131071 : 524287); + if (isSetLockOwnerName()) + hashCode = hashCode * 8191 + lockOwnerName.hashCode(); - boolean present_inNative = true; - list.add(present_inNative); - if (present_inNative) - list.add(inNative); + hashCode = hashCode * 8191 + ((inNative) ? 131071 : 524287); - boolean present_suspended = true; - list.add(present_suspended); - if (present_suspended) - list.add(suspended); + hashCode = hashCode * 8191 + ((suspended) ? 131071 : 524287); - boolean present_threadState = true && (isSetThreadState()); - list.add(present_threadState); - if (present_threadState) - list.add(threadState.getValue()); + hashCode = hashCode * 8191 + ((isSetThreadState()) ? 131071 : 524287); + if (isSetThreadState()) + hashCode = hashCode * 8191 + threadState.getValue(); - boolean present_stackTrace = true && (isSetStackTrace()); - list.add(present_stackTrace); - if (present_stackTrace) - list.add(stackTrace); + hashCode = hashCode * 8191 + ((isSetStackTrace()) ? 131071 : 524287); + if (isSetStackTrace()) + hashCode = hashCode * 8191 + stackTrace.hashCode(); - boolean present_lockedMonitors = true && (isSetLockedMonitors()); - list.add(present_lockedMonitors); - if (present_lockedMonitors) - list.add(lockedMonitors); + hashCode = hashCode * 8191 + ((isSetLockedMonitors()) ? 131071 : 524287); + if (isSetLockedMonitors()) + hashCode = hashCode * 8191 + lockedMonitors.hashCode(); - boolean present_lockedSynchronizers = true && (isSetLockedSynchronizers()); - list.add(present_lockedSynchronizers); - if (present_lockedSynchronizers) - list.add(lockedSynchronizers); + hashCode = hashCode * 8191 + ((isSetLockedSynchronizers()) ? 131071 : 524287); + if (isSetLockedSynchronizers()) + hashCode = hashCode * 8191 + lockedSynchronizers.hashCode(); - return list.hashCode(); + return hashCode; } @Override @@ -1197,7 +1138,7 @@ public class TThreadDump implements org.apache.thrift.TBase { + private static class TThreadDumpStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TThreadDump struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -1599,8 +1540,8 @@ public class TThreadDump implements org.apache.thrift.TBase(_list0.size); - String _elem1; + struct.stackTrace = new java.util.ArrayList(_list0.size); + java.lang.String _elem1; for (int _i2 = 0; _i2 < _list0.size; ++_i2) { _elem1 = iprot.readString(); @@ -1617,7 +1558,7 @@ public class TThreadDump implements org.apache.thrift.TBase(_list3.size); + struct.lockedMonitors = new java.util.ArrayList(_list3.size); TMonitorInfo _elem4; for (int _i5 = 0; _i5 < _list3.size; ++_i5) { @@ -1636,8 +1577,8 @@ public class TThreadDump implements org.apache.thrift.TBase(_list6.size); - String _elem7; + struct.lockedSynchronizers = new java.util.ArrayList(_list6.size); + java.lang.String _elem7; for (int _i8 = 0; _i8 < _list6.size; ++_i8) { _elem7 = iprot.readString(); @@ -1711,7 +1652,7 @@ public class TThreadDump implements org.apache.thrift.TBase { + private static class TThreadDumpTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TThreadDump 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.isSetThreadName()) { optionals.set(0); } @@ -1846,7 +1787,7 @@ public class TThreadDump implements org.apache.thrift.TBase(_list15.size); - String _elem16; + struct.stackTrace = new java.util.ArrayList(_list15.size); + java.lang.String _elem16; for (int _i17 = 0; _i17 < _list15.size; ++_i17) { _elem16 = iprot.readString(); @@ -1940,7 +1881,7 @@ public class TThreadDump implements org.apache.thrift.TBase(_list18.size); + struct.lockedMonitors = new java.util.ArrayList(_list18.size); TMonitorInfo _elem19; for (int _i20 = 0; _i20 < _list18.size; ++_i20) { @@ -1954,8 +1895,8 @@ public class TThreadDump implements org.apache.thrift.TBase(_list21.size); - String _elem22; + struct.lockedSynchronizers = new java.util.ArrayList(_list21.size); + java.lang.String _elem22; for (int _i23 = 0; _i23 < _list21.size; ++_i23) { _elem22 = iprot.readString(); @@ -1967,5 +1908,8 @@ public class TThreadDump implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadDumpType.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadDumpType.java index 8da975430..27895ae0c 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadDumpType.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadDumpType.java @@ -1,5 +1,5 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated diff --git a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadLightDump.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadLightDump.java index e78750de2..0e2371b88 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadLightDump.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadLightDump.java @@ -1,30 +1,13 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package com.navercorp.pinpoint.thrift.dto.command; -import org.apache.thrift.EncodingUtils; -import org.apache.thrift.protocol.TTupleProtocol; -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 javax.annotation.Generated; -import java.util.ArrayList; -import java.util.BitSet; -import java.util.Collections; -import java.util.EnumMap; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) -@Generated(value = "Autogenerated by Thrift Compiler (0.9.2)", date = "2016-12-15") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)", date = "2017-03-16") public class TThreadLightDump implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TThreadLightDump"); @@ -32,13 +15,10 @@ public class TThreadLightDump implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new TThreadLightDumpStandardSchemeFactory()); - schemes.put(TupleScheme.class, new TThreadLightDumpTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TThreadLightDumpStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TThreadLightDumpTupleSchemeFactory(); - private String threadName; // required + private java.lang.String threadName; // required private long threadId; // required private TThreadState threadState; // optional @@ -52,10 +32,10 @@ public class TThreadLightDump implements org.apache.thrift.TBase byName = new HashMap(); + private static final java.util.Map byName = new java.util.HashMap(); static { - for (_Fields field : EnumSet.allOf(_Fields.class)) { + for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) { byName.put(field.getFieldName(), field); } } @@ -82,21 +62,21 @@ public class TThreadLightDump implements org.apache.thrift.TBase 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.THREAD_NAME, new org.apache.thrift.meta_data.FieldMetaData("threadName", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.THREAD_ID, new org.apache.thrift.meta_data.FieldMetaData("threadId", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))); tmpMap.put(_Fields.THREAD_STATE, new org.apache.thrift.meta_data.FieldMetaData("threadState", org.apache.thrift.TFieldRequirementType.OPTIONAL, new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, TThreadState.class))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TThreadLightDump.class, metaDataMap); } @@ -131,7 +111,7 @@ public class TThreadLightDump implements org.apache.thrift.TBase list = new ArrayList(); + int hashCode = 1; - boolean present_threadName = true && (isSetThreadName()); - list.add(present_threadName); - if (present_threadName) - list.add(threadName); + hashCode = hashCode * 8191 + ((isSetThreadName()) ? 131071 : 524287); + if (isSetThreadName()) + hashCode = hashCode * 8191 + threadName.hashCode(); - boolean present_threadId = true; - list.add(present_threadId); - if (present_threadId) - list.add(threadId); + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(threadId); - boolean present_threadState = true && (isSetThreadState()); - list.add(present_threadState); - if (present_threadState) - list.add(threadState.getValue()); + hashCode = hashCode * 8191 + ((isSetThreadState()) ? 131071 : 524287); + if (isSetThreadState()) + hashCode = hashCode * 8191 + threadState.getValue(); - return list.hashCode(); + return hashCode; } @Override @@ -376,7 +353,7 @@ public class TThreadLightDump implements org.apache.thrift.TBase { + private static class TThreadLightDumpStandardScheme extends org.apache.thrift.scheme.StandardScheme { public void read(org.apache.thrift.protocol.TProtocol iprot, TThreadLightDump struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -550,18 +527,18 @@ public class TThreadLightDump implements org.apache.thrift.TBase { + private static class TThreadLightDumpTupleScheme extends org.apache.thrift.scheme.TupleScheme { @Override public void write(org.apache.thrift.protocol.TProtocol prot, TThreadLightDump 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.isSetThreadName()) { optionals.set(0); } @@ -585,8 +562,8 @@ public class TThreadLightDump implements org.apache.thrift.TBase 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/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadState.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadState.java index 3217ae986..ebfc108ee 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadState.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/dto/command/TThreadState.java @@ -1,5 +1,5 @@ /** - * Autogenerated by Thrift Compiler (0.9.2) + * Autogenerated by Thrift Compiler (0.10.0) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated @@ -7,6 +7,10 @@ package com.navercorp.pinpoint.thrift.dto.command; +import java.util.Map; +import java.util.HashMap; +import org.apache.thrift.TEnum; + public enum TThreadState implements org.apache.thrift.TEnum { NEW(0), RUNNABLE(1), diff --git a/thrift/src/main/java/com/navercorp/pinpoint/thrift/io/NetworkAvailabilityCheckPacket.java b/thrift/src/main/java/com/navercorp/pinpoint/thrift/io/NetworkAvailabilityCheckPacket.java index 4a7a241d2..1d68d96ba 100644 --- a/thrift/src/main/java/com/navercorp/pinpoint/thrift/io/NetworkAvailabilityCheckPacket.java +++ b/thrift/src/main/java/com/navercorp/pinpoint/thrift/io/NetworkAvailabilityCheckPacket.java @@ -16,7 +16,6 @@ package com.navercorp.pinpoint.thrift.io; -import org.apache.thrift.TBase; import org.apache.thrift.TException; import org.apache.thrift.TFieldIdEnum; import org.apache.thrift.protocol.TProtocol; @@ -71,7 +70,7 @@ public class NetworkAvailabilityCheckPacket implements org.apache.thrift.TBase activeTraceCount + 2: optional i32 histogramSchemaType + 3: optional list activeTraceCount } struct TActiveTrace { - 1: optional TActiveTraceHistogram histogram + 1: optional TActiveTraceHistogram histogram } struct TAgentStat { diff --git a/thrift/src/main/thrift/Trace.thrift b/thrift/src/main/thrift/Trace.thrift index 7dc981ab6..dbdd72839 100644 --- a/thrift/src/main/thrift/Trace.thrift +++ b/thrift/src/main/thrift/Trace.thrift @@ -14,21 +14,21 @@ struct TIntStringStringValue { union TAnnotationValue { - 1: string stringValue - 2: bool boolValue; - 3: i32 intValue; - 4: i64 longValue; - 5: i16 shortValue - 6: double doubleValue; - 7: binary binaryValue; - 8: byte byteValue; - 9: TIntStringValue intStringValue; - 10: TIntStringStringValue intStringStringValue; + 1: string stringValue + 2: bool boolValue; + 3: i32 intValue; + 4: i64 longValue; + 5: i16 shortValue + 6: double doubleValue; + 7: binary binaryValue; + 8: i8 byteValue; + 9: TIntStringValue intStringValue; + 10: TIntStringStringValue intStringStringValue; } struct TAnnotation { - 1: i32 key, - 2: optional TAnnotationValue value + 1: i32 key, + 2: optional TAnnotationValue value } @@ -36,94 +36,94 @@ struct TAnnotation { struct TSpanEvent { - 7: optional i64 spanId - 8: i16 sequence + 7: optional i64 spanId + 8: i16 sequence - 9: i32 startElapsed - 10: optional i32 endElapsed = 0 + 9: i32 startElapsed + 10: optional i32 endElapsed = 0 - 11: optional string rpc - 12: i16 serviceType - 13: optional string endPoint + 11: optional string rpc + 12: i16 serviceType + 13: optional string endPoint - 14: optional list annotations + 14: optional list annotations - 15: optional i32 depth = -1 - 16: optional i64 nextSpanId = -1 + 15: optional i32 depth = -1 + 16: optional i64 nextSpanId = -1 - 20: optional string destinationId + 20: optional string destinationId - 25: optional i32 apiId; - 26: optional TIntStringValue exceptionInfo; - - 30: optional i32 asyncId; - 31: optional i32 nextAsyncId; - 32: optional i16 asyncSequence; + 25: optional i32 apiId; + 26: optional TIntStringValue exceptionInfo; + + 30: optional i32 asyncId; + 31: optional i32 nextAsyncId; + 32: optional i16 asyncSequence; } struct TSpan { - 1: string agentId - 2: string applicationName - 3: i64 agentStartTime + 1: string agentId + 2: string applicationName + 3: i64 agentStartTime - // identical to agentId if null - //4: optional string traceAgentId - //5: i64 traceAgentStartTime; - //6: i64 traceTransactionSequence; - 4: binary transactionId; + // identical to agentId if null + //4: optional string traceAgentId + //5: i64 traceAgentStartTime; + //6: i64 traceTransactionSequence; + 4: binary transactionId; - 7: i64 spanId - 8: optional i64 parentSpanId = -1 + 7: i64 spanId + 8: optional i64 parentSpanId = -1 - // span event's startTimestamp - 9: i64 startTime - 10: optional i32 elapsed = 0 + // span event's startTimestamp + 9: i64 startTime + 10: optional i32 elapsed = 0 - 11: optional string rpc + 11: optional string rpc - 12: i16 serviceType - 13: optional string endPoint - 14: optional string remoteAddr + 12: i16 serviceType + 13: optional string endPoint + 14: optional string remoteAddr - 15: optional list annotations - 16: optional i16 flag = 0 + 15: optional list annotations + 16: optional i16 flag = 0 - 17: optional i32 err + 17: optional i32 err - 18: optional list spanEventList + 18: optional list spanEventList - 19: optional string parentApplicationName - 20: optional i16 parentApplicationType - 21: optional string acceptorHost + 19: optional string parentApplicationName + 20: optional i16 parentApplicationType + 21: optional string acceptorHost - 25: optional i32 apiId; - 26: optional TIntStringValue exceptionInfo; + 25: optional i32 apiId; + 26: optional TIntStringValue exceptionInfo; - 30: optional i16 applicationServiceType; - 31: optional byte loggingTransactionInfo; + 30: optional i16 applicationServiceType; + 31: optional i8 loggingTransactionInfo; } struct TSpanChunk { - 1: string agentId - 2: string applicationName - 3: i64 agentStartTime + 1: string agentId + 2: string applicationName + 3: i64 agentStartTime - 4: i16 serviceType + 4: i16 serviceType - // identical to agentId if null -// 5: optional string traceAgentId -// 6: i64 traceAgentStartTime; -// 7: i64 traceTransactionSequence; + // identical to agentId if null + //5: optional string traceAgentId + //6: i64 traceAgentStartTime; + //7: i64 traceTransactionSequence; 5: binary transactionId; - 8: i64 spanId + 8: i64 spanId - 9: optional string endPoint + 9: optional string endPoint - 10: list spanEventList + 10: list spanEventList - 11: optional i16 applicationServiceType + 11: optional i16 applicationServiceType } @@ -147,17 +147,17 @@ struct TSqlMetaData { struct TApiMetaData { - 1: string agentId - 2: i64 agentStartTime + 1: string agentId + 2: i64 agentStartTime - 4: i32 apiId, - 5: string apiInfo, - 6: optional i32 line, + 4: i32 apiId, + 5: string apiInfo, + 6: optional i32 line, - 10: optional i32 type; + 10: optional i32 type; } struct TResult { - 1: bool success - 2: optional string message + 1: bool success + 2: optional string message } \ No newline at end of file