From 016d78139ab43eeb97a2bfce42207009c5c50e99 Mon Sep 17 00:00:00 2001 From: laura-ding <48548375+laura-ding@users.noreply.github.com> Date: Wed, 21 Apr 2021 17:45:41 +0800 Subject: [PATCH] Update fbthrift lib (#98) * fix meta leader change * update fbthrift lib and generate code * add whole_latency * fix test failed --- example/ScanVertexEdgeExample.py | 2 +- nebula2/common/constants.py | 5 +- nebula2/common/ttypes.py | 162 +- nebula2/data/ResultSet.py | 11 +- nebula2/fbthrift/TMultiplexedProcessor.py | 27 +- nebula2/fbthrift/TSCons.py | 25 +- nebula2/fbthrift/Thrift.py | 29 +- nebula2/fbthrift/__init__.py | 26 +- nebula2/fbthrift/protocol/TBinaryProtocol.py | 29 +- nebula2/fbthrift/protocol/TCompactProtocol.py | 20 +- nebula2/fbthrift/protocol/THeaderProtocol.py | 33 +- nebula2/fbthrift/protocol/TJSONProtocol.py | 53 +- .../fbthrift/protocol/TMultiplexedProtocol.py | 27 +- nebula2/fbthrift/protocol/TProtocol.py | 36 +- .../fbthrift/protocol/TProtocolDecorator.py | 27 +- .../fbthrift/protocol/TSimpleJSONProtocol.py | 122 +- nebula2/fbthrift/protocol/__init__.py | 28 +- nebula2/fbthrift/protocol/exceptions.py | 33 + nebula2/fbthrift/server/TAsyncioServer.py | 50 +- nebula2/fbthrift/server/TCppServer.py | 28 +- nebula2/fbthrift/server/TGeventServer.py | 123 - nebula2/fbthrift/server/TNonblockingServer.py | 471 ---- nebula2/fbthrift/server/TServer.py | 168 +- nebula2/fbthrift/server/TTrolliusServer.py | 174 -- nebula2/fbthrift/server/__init__.py | 27 +- .../transport/TFuzzyHeaderTransport.py | 257 -- .../fbthrift/transport/THeaderTransport.py | 63 +- nebula2/fbthrift/transport/THttpClient.py | 37 +- nebula2/fbthrift/transport/TSSLSocket.py | 43 +- .../transport/TSSLSocketOverHttpTunnel.py | 18 +- nebula2/fbthrift/transport/TSocket.py | 51 +- .../transport/TSocketOverHttpTunnel.py | 18 +- nebula2/fbthrift/transport/TSocketTest.py | 20 +- nebula2/fbthrift/transport/TTransport.py | 27 +- nebula2/fbthrift/transport/TTwisted.py | 253 -- nebula2/fbthrift/transport/__init__.py | 27 +- nebula2/fbthrift/util/BytesStrIO.py | 27 +- nebula2/fbthrift/util/Decorators.py | 63 +- nebula2/fbthrift/util/Recursive.py | 16 + nebula2/fbthrift/util/Serializer.py | 31 +- .../fbthrift/util/TCppServerTestManager.py | 16 +- .../util/TCppServerTestManagerTest.py | 14 + nebula2/fbthrift/util/TValidator.py | 27 +- nebula2/fbthrift/util/__init__.py | 124 +- nebula2/fbthrift/util/async_common.py | 34 +- nebula2/fbthrift/util/asyncio.py | 17 +- nebula2/fbthrift/util/converter.py | 74 + nebula2/fbthrift/util/fuzzer.py | 89 +- nebula2/fbthrift/util/inspect.py | 288 +++ nebula2/fbthrift/util/randomizer.py | 296 +-- nebula2/fbthrift/util/remote.py | 92 +- nebula2/fbthrift/util/trollius.py | 60 - nebula2/fbthrift/util/type_inspect.py | 277 +++ nebula2/gclient/net/__init__.py | 9 +- nebula2/graph/GraphService-fuzzer | 4 +- nebula2/graph/GraphService-remote | 8 +- nebula2/graph/GraphService.py | 101 +- nebula2/graph/constants.py | 5 +- nebula2/graph/ttypes.py | 119 +- nebula2/mclient/__init__.py | 132 +- nebula2/meta/MetaService-fuzzer | 4 +- nebula2/meta/MetaService-remote | 2 +- nebula2/meta/MetaService.py | 1667 +++---------- nebula2/meta/constants.py | 5 +- nebula2/meta/ttypes.py | 2210 +++++------------ nebula2/sclient/GraphStorageClient.py | 2 + nebula2/sclient/ScanResult.py | 2 + nebula2/storage/GeneralStorageService-fuzzer | 4 +- nebula2/storage/GeneralStorageService-remote | 2 +- nebula2/storage/GeneralStorageService.py | 87 +- nebula2/storage/GraphStorageService-fuzzer | 4 +- nebula2/storage/GraphStorageService-remote | 2 +- nebula2/storage/GraphStorageService.py | 307 +-- nebula2/storage/StorageAdminService-fuzzer | 4 +- nebula2/storage/StorageAdminService-remote | 2 +- nebula2/storage/StorageAdminService.py | 327 +-- nebula2/storage/constants.py | 5 +- nebula2/storage/ttypes.py | 480 +--- tests/test_data_from_server.py | 4 + tests/test_data_type.py | 2 +- tests/test_graph_storage_client.py | 2 +- 81 files changed, 3104 insertions(+), 6493 deletions(-) create mode 100644 nebula2/fbthrift/protocol/exceptions.py delete mode 100644 nebula2/fbthrift/server/TGeventServer.py delete mode 100644 nebula2/fbthrift/server/TNonblockingServer.py delete mode 100644 nebula2/fbthrift/server/TTrolliusServer.py delete mode 100644 nebula2/fbthrift/transport/TFuzzyHeaderTransport.py delete mode 100644 nebula2/fbthrift/transport/TTwisted.py create mode 100644 nebula2/fbthrift/util/converter.py create mode 100644 nebula2/fbthrift/util/inspect.py delete mode 100644 nebula2/fbthrift/util/trollius.py create mode 100644 nebula2/fbthrift/util/type_inspect.py diff --git a/example/ScanVertexEdgeExample.py b/example/ScanVertexEdgeExample.py index 378070a2..8ea550cb 100644 --- a/example/ScanVertexEdgeExample.py +++ b/example/ScanVertexEdgeExample.py @@ -24,7 +24,7 @@ def prepare_data(): # init connection pool connection_pool = ConnectionPool() # the graphd server's address - assert connection_pool.init([('172.28.3.1', 9669)], config) + assert connection_pool.init([('127.0.0.1', 9671)], config) client = connection_pool.get_session('root', 'nebula') client.execute('CREATE SPACE IF NOT EXISTS ScanSpace(' 'PARTITION_NUM=10,' diff --git a/nebula2/common/constants.py b/nebula2/common/constants.py index bd42fa1f..76864950 100644 --- a/nebula2/common/constants.py +++ b/nebula2/common/constants.py @@ -7,11 +7,12 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException -from .ttypes import * +from .ttypes import UTF8STRINGS, NullType, Date, Time, DateTime, Value, NList, NMap, NSet, Row, DataSet, Tag, Vertex, Edge, Step, Path, HostAddr, KeyValue, LogInfo, PartitionBackupInfo, GraphSpaceID, PartitionID, TagID, EdgeType, EdgeRanking, LogID, TermID, Timestamp, IndexID, Port, SessionID diff --git a/nebula2/common/ttypes.py b/nebula2/common/ttypes.py index 9eae81ba..8aae4691 100644 --- a/nebula2/common/ttypes.py +++ b/nebula2/common/ttypes.py @@ -7,8 +7,9 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException @@ -21,11 +22,10 @@ from nebula2.fbthrift.protocol import TCompactProtocol from nebula2.fbthrift.protocol import THeaderProtocol fastproto = None -if not '__pypy__' in sys.builtin_module_names: - try: - from nebula2.fbthrift.protocol import fastproto - except: - pass +try: + from nebula2.fbthrift.protocol import fastproto +except ImportError: + pass all_structs = [] UTF8STRINGS = bool(0) or sys.version_info.major >= 3 @@ -82,11 +82,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -112,10 +110,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -190,11 +184,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -225,10 +217,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -314,11 +302,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -364,10 +350,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -691,11 +673,9 @@ def read(self, iprot): self.value = None if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, True], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, True], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -935,11 +915,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -967,10 +945,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1029,11 +1003,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1063,10 +1035,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1126,11 +1094,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1158,10 +1124,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1220,11 +1182,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1252,10 +1212,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1315,11 +1271,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1362,10 +1316,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1436,11 +1386,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1475,10 +1423,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1547,11 +1491,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1585,10 +1527,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1660,11 +1598,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1721,10 +1657,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1828,11 +1760,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1883,10 +1813,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1979,11 +1905,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2017,10 +1941,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2088,11 +2008,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2113,10 +2031,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2181,11 +2095,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2206,10 +2118,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2274,11 +2182,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2299,10 +2205,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2366,11 +2268,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2400,10 +2300,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2466,7 +2362,7 @@ def __ne__(self, other): ) Date.thrift_struct_annotations = { - "cpp.type": """nebula::Date""", + "cpp.type": "nebula::Date", } Date.thrift_field_annotations = { } @@ -2497,7 +2393,7 @@ def Date__setstate__(self, state): ) Time.thrift_struct_annotations = { - "cpp.type": """nebula::Time""", + "cpp.type": "nebula::Time", } Time.thrift_field_annotations = { } @@ -2533,7 +2429,7 @@ def Time__setstate__(self, state): ) DateTime.thrift_struct_annotations = { - "cpp.type": """nebula::DateTime""", + "cpp.type": "nebula::DateTime", } DateTime.thrift_field_annotations = { } @@ -2583,29 +2479,29 @@ def DateTime__setstate__(self, state): ) Value.thrift_struct_annotations = { - "cpp.type": """nebula::Value""", + "cpp.type": "nebula::Value", } Value.thrift_field_annotations = { 9: { - "cpp.ref_type": """unique""", + "cpp.ref_type": "unique", }, 10: { - "cpp.ref_type": """unique""", + "cpp.ref_type": "unique", }, 11: { - "cpp.ref_type": """unique""", + "cpp.ref_type": "unique", }, 12: { - "cpp.ref_type": """unique""", + "cpp.ref_type": "unique", }, 13: { - "cpp.ref_type": """unique""", + "cpp.ref_type": "unique", }, 14: { - "cpp.ref_type": """unique""", + "cpp.ref_type": "unique", }, 15: { - "cpp.ref_type": """unique""", + "cpp.ref_type": "unique", }, } @@ -2682,7 +2578,7 @@ def Value__init__(self, nVal=None, bVal=None, iVal=None, fVal=None, sVal=None, d ) NList.thrift_struct_annotations = { - "cpp.type": """nebula::List""", + "cpp.type": "nebula::List", } NList.thrift_field_annotations = { } @@ -2706,7 +2602,7 @@ def NList__setstate__(self, state): ) NMap.thrift_struct_annotations = { - "cpp.type": """nebula::Map""", + "cpp.type": "nebula::Map", } NMap.thrift_field_annotations = { } @@ -2730,7 +2626,7 @@ def NMap__setstate__(self, state): ) NSet.thrift_struct_annotations = { - "cpp.type": """nebula::Set""", + "cpp.type": "nebula::Set", } NSet.thrift_field_annotations = { } @@ -2754,7 +2650,7 @@ def NSet__setstate__(self, state): ) Row.thrift_struct_annotations = { - "cpp.type": """nebula::Row""", + "cpp.type": "nebula::Row", } Row.thrift_field_annotations = { } @@ -2779,7 +2675,7 @@ def Row__setstate__(self, state): ) DataSet.thrift_struct_annotations = { - "cpp.type": """nebula::DataSet""", + "cpp.type": "nebula::DataSet", } DataSet.thrift_field_annotations = { } @@ -2806,7 +2702,7 @@ def DataSet__setstate__(self, state): ) Tag.thrift_struct_annotations = { - "cpp.type": """nebula::Tag""", + "cpp.type": "nebula::Tag", } Tag.thrift_field_annotations = { } @@ -2833,7 +2729,7 @@ def Tag__setstate__(self, state): ) Vertex.thrift_struct_annotations = { - "cpp.type": """nebula::Vertex""", + "cpp.type": "nebula::Vertex", } Vertex.thrift_field_annotations = { } @@ -2864,7 +2760,7 @@ def Vertex__setstate__(self, state): ) Edge.thrift_struct_annotations = { - "cpp.type": """nebula::Edge""", + "cpp.type": "nebula::Edge", } Edge.thrift_field_annotations = { } @@ -2902,7 +2798,7 @@ def Edge__setstate__(self, state): ) Step.thrift_struct_annotations = { - "cpp.type": """nebula::Step""", + "cpp.type": "nebula::Step", } Step.thrift_field_annotations = { } @@ -2935,7 +2831,7 @@ def Step__setstate__(self, state): ) Path.thrift_struct_annotations = { - "cpp.type": """nebula::Path""", + "cpp.type": "nebula::Path", } Path.thrift_field_annotations = { } @@ -2962,7 +2858,7 @@ def Path__setstate__(self, state): ) HostAddr.thrift_struct_annotations = { - "cpp.type": """nebula::HostAddr""", + "cpp.type": "nebula::HostAddr", } HostAddr.thrift_field_annotations = { } @@ -2989,7 +2885,7 @@ def HostAddr__setstate__(self, state): ) KeyValue.thrift_struct_annotations = { - "cpp.type": """nebula::KeyValue""", + "cpp.type": "nebula::KeyValue", } KeyValue.thrift_field_annotations = { } diff --git a/nebula2/data/ResultSet.py b/nebula2/data/ResultSet.py index 64e735c9..bc4e90de 100644 --- a/nebula2/data/ResultSet.py +++ b/nebula2/data/ResultSet.py @@ -12,13 +12,14 @@ class ResultSet(object): - def __init__(self, resp, decode_type='utf-8'): + def __init__(self, resp, _all_latency, decode_type='utf-8'): """ get data from ResultSet """ self._decode_type = decode_type self._resp = resp self._data_set_wrapper = None + self._all_latency = _all_latency; if self._resp.data is not None: self._data_set_wrapper = DataSetWrapper(resp.data, self._decode_type) @@ -45,10 +46,16 @@ def comment(self): def latency(self): """ - unit us + the server's latency, unit us """ return self._resp.latency_in_us + def whole_latency(self): + """ + the whole latency of the query + """ + return self._all_latency + def plan_desc(self): return self._resp.plan_desc diff --git a/nebula2/fbthrift/TMultiplexedProcessor.py b/nebula2/fbthrift/TMultiplexedProcessor.py index c3636ba1..af7eec5f 100644 --- a/nebula2/fbthrift/TMultiplexedProcessor.py +++ b/nebula2/fbthrift/TMultiplexedProcessor.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division diff --git a/nebula2/fbthrift/TSCons.py b/nebula2/fbthrift/TSCons.py index c039d2ef..b5c74702 100644 --- a/nebula2/fbthrift/TSCons.py +++ b/nebula2/fbthrift/TSCons.py @@ -1,21 +1,16 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. from __future__ import absolute_import from __future__ import division diff --git a/nebula2/fbthrift/Thrift.py b/nebula2/fbthrift/Thrift.py index c171e610..024e9e7c 100644 --- a/nebula2/fbthrift/Thrift.py +++ b/nebula2/fbthrift/Thrift.py @@ -1,27 +1,23 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals +import logging import six import sys import threading @@ -111,7 +107,8 @@ def handlerError(self, handler_context, fn_name, exception): Note that this method is NOT called if the handler threw an exception that is declared in the thrift service specification""" - pass + + logging.exception("Unexpected error in service handler " + fn_name + ":") class TServerInterface: diff --git a/nebula2/fbthrift/__init__.py b/nebula2/fbthrift/__init__.py index 45203c45..16a87b1a 100644 --- a/nebula2/fbthrift/__init__.py +++ b/nebula2/fbthrift/__init__.py @@ -1,21 +1,15 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. __all__ = ['Thrift', 'TSCons'] -trollius = False diff --git a/nebula2/fbthrift/protocol/TBinaryProtocol.py b/nebula2/fbthrift/protocol/TBinaryProtocol.py index 341b3caa..00505827 100644 --- a/nebula2/fbthrift/protocol/TBinaryProtocol.py +++ b/nebula2/fbthrift/protocol/TBinaryProtocol.py @@ -1,28 +1,25 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals -from .TProtocol import * +from nebula2.fbthrift.protocol.TProtocol import * from struct import pack, unpack class TBinaryProtocol(TProtocolBase): diff --git a/nebula2/fbthrift/protocol/TCompactProtocol.py b/nebula2/fbthrift/protocol/TCompactProtocol.py index 8823ddd0..1ff4a56e 100644 --- a/nebula2/fbthrift/protocol/TCompactProtocol.py +++ b/nebula2/fbthrift/protocol/TCompactProtocol.py @@ -1,10 +1,26 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe + from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals import sys -from .TProtocol import * +from nebula2.fbthrift.protocol.TProtocol import * from struct import pack, unpack __all__ = [ @@ -324,7 +340,7 @@ def readMessageBegin(self): if not (self.__version <= self.VERSION and self.__version >= self.VERSION_LOW): raise TProtocolException(TProtocolException.BAD_VERSION, - 'Bad version: %d (expect %d)' % (version, self.VERSION)) + 'Bad version: %d (expect %d)' % (self.__version, self.VERSION)) seqid = self.__readVarint() name = self.__readString() return (name, type, seqid) diff --git a/nebula2/fbthrift/protocol/THeaderProtocol.py b/nebula2/fbthrift/protocol/THeaderProtocol.py index 2998c5a7..ab32a6aa 100644 --- a/nebula2/fbthrift/protocol/THeaderProtocol.py +++ b/nebula2/fbthrift/protocol/THeaderProtocol.py @@ -1,31 +1,28 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals -from .TProtocol import TProtocolBase, TProtocolException +from nebula2.fbthrift.protocol.TProtocol import TProtocolBase, TProtocolException from nebula2.fbthrift.Thrift import TApplicationException, TMessageType -from .TBinaryProtocol import TBinaryProtocolAccelerated -from .TCompactProtocol import TCompactProtocolAccelerated +from nebula2.fbthrift.protocol.TBinaryProtocol import TBinaryProtocolAccelerated +from nebula2.fbthrift.protocol.TCompactProtocol import TCompactProtocolAccelerated from nebula2.fbthrift.transport.THeaderTransport import THeaderTransport, CLIENT_TYPE diff --git a/nebula2/fbthrift/protocol/TJSONProtocol.py b/nebula2/fbthrift/protocol/TJSONProtocol.py index 9b6f1a72..5083aa59 100644 --- a/nebula2/fbthrift/protocol/TJSONProtocol.py +++ b/nebula2/fbthrift/protocol/TJSONProtocol.py @@ -1,28 +1,26 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals -from .TProtocol import TProtocolBase, TProtocolException, TType +from nebula2.fbthrift.protocol.TProtocol import TProtocolBase, TProtocolException +from nebula2.fbthrift.Thrift import TType import json, base64, sys __all__ = ['TJSONProtocol', 'TJSONProtocolFactory'] @@ -100,6 +98,10 @@ class JSONPairContext(JSONBaseContext): def doIO(self, function): if self.first is True: + # Ignore extra commas at field start. Once context stack handling + # fix is fully rolled out this can be removed. + if self.protocol.reader.peek() == COMMA: + self.protocol.readJSONSyntaxChar(COMMA) self.first = False self.colon = True else: @@ -142,14 +144,15 @@ def peek(self): class TJSONProtocolBase(TProtocolBase): - def __init__(self, trans): + def __init__(self, trans, validJSON=True): TProtocolBase.__init__(self, trans) + self.validJSON = validJSON self.resetWriteContext() self.resetReadContext() def resetWriteContext(self): - self.contextStack = [] self.context = JSONBaseContext(self) + self.contextStack = [self.context] def resetReadContext(self): self.resetWriteContext() @@ -161,6 +164,8 @@ def pushContext(self, ctx): def popContext(self): self.contextStack.pop() + if self.validJSON: + self.context = self.contextStack[-1] def writeJSONString(self, string): # Python 3 JSON will not serialize bytes @@ -460,7 +465,7 @@ def writeBool(self, boolean): self.writeJSONNumber(1 if boolean is True else 0) def writeInteger(self, integer): - self.writeJSONNumber(integer) + self.writeJSONNumber(int(integer)) writeByte = writeInteger writeI16 = writeInteger writeI32 = writeInteger @@ -479,9 +484,11 @@ def writeBinary(self, binary): self.writeJSONBase64(binary) class TJSONProtocolFactory: - def __init__(self): - # type: () -> None - pass + # validJSON specifies whether to emit valid JSON or possibly invalid but + # backward-compatible one. + def __init__(self, validJSON=True): + # type: (bool) -> None + self.validJSON = validJSON def getProtocol(self, trans): - return TJSONProtocol(trans) + return TJSONProtocol(trans, self.validJSON) diff --git a/nebula2/fbthrift/protocol/TMultiplexedProtocol.py b/nebula2/fbthrift/protocol/TMultiplexedProtocol.py index 2a5bfc8d..f084a3bd 100644 --- a/nebula2/fbthrift/protocol/TMultiplexedProtocol.py +++ b/nebula2/fbthrift/protocol/TMultiplexedProtocol.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division diff --git a/nebula2/fbthrift/protocol/TProtocol.py b/nebula2/fbthrift/protocol/TProtocol.py index 69b36f9c..b889b1a5 100644 --- a/nebula2/fbthrift/protocol/TProtocol.py +++ b/nebula2/fbthrift/protocol/TProtocol.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division @@ -177,9 +174,7 @@ def readString(self): pass def skip(self, type): - if type == TType.STOP: - return - elif type == TType.BOOL: + if type == TType.BOOL: self.readBool() elif type == TType.BYTE: self.readByte() @@ -220,6 +215,11 @@ def skip(self, type): for _ in range(size): self.skip(etype) self.readListEnd() + else: + raise TProtocolException( + TProtocolException.INVALID_DATA, + "Unexpected type for skipping {}".format(type) + ) def readIntegral(self, type): if type == TType.BOOL: diff --git a/nebula2/fbthrift/protocol/TProtocolDecorator.py b/nebula2/fbthrift/protocol/TProtocolDecorator.py index 0fde3377..6cca18cf 100644 --- a/nebula2/fbthrift/protocol/TProtocolDecorator.py +++ b/nebula2/fbthrift/protocol/TProtocolDecorator.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division diff --git a/nebula2/fbthrift/protocol/TSimpleJSONProtocol.py b/nebula2/fbthrift/protocol/TSimpleJSONProtocol.py index c3864149..7a8e7ba2 100644 --- a/nebula2/fbthrift/protocol/TSimpleJSONProtocol.py +++ b/nebula2/fbthrift/protocol/TSimpleJSONProtocol.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division @@ -26,7 +23,7 @@ import json import sys -from .TProtocol import TProtocolBase, TProtocolException +from nebula2.fbthrift.protocol.TProtocol import TProtocolBase, TProtocolException from nebula2.fbthrift.Thrift import TType JSON_OBJECT_START = b'{' @@ -37,6 +34,7 @@ JSON_PAIR_SEPARATOR = b':' JSON_ELEM_SEPARATOR = b',' JSON_BACKSLASH = b'\\' +JSON_BACKSLASH_VALUE = ord(JSON_BACKSLASH) JSON_STRING_DELIMITER = b'"' JSON_ZERO_CHAR = b'0' JSON_TAB = b" " @@ -60,11 +58,32 @@ 1, 1,b'"', 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, \ ] + +JSON_CHARS_TO_ESCAPE = set() +for ch_value, mode in enumerate(JSON_CHAR_TABLE): + if mode == 1: + continue + if sys.version_info[0] == 3: + JSON_CHARS_TO_ESCAPE.add(chr(ch_value).encode('ascii')) + JSON_CHARS_TO_ESCAPE.add(chr(ch_value)) + else: + JSON_CHARS_TO_ESCAPE.add(chr(ch_value)) + JSON_CHARS_TO_ESCAPE.add(chr(ch_value).encode('utf-8')) +JSON_CHARS_TO_ESCAPE.add(JSON_BACKSLASH) +JSON_CHARS_TO_ESCAPE.add(JSON_BACKSLASH.decode('utf-8')) + ESCAPE_CHARS = b"\"\\bfnrt" ESCAPE_CHAR_VALS = [b'"', b'\\', b'\b', b'\f', b'\n', b'\r', b'\t'] NUMERIC_CHAR = b'+-.0123456789Ee' +WHITESPACE_CHARS = { + JSON_NEW_LINE, + TAB, + JSON_CARRIAGE_RETURN, + JSON_SPACE, +} + def hexChar(x): x &= 0x0f return hex(x)[2:] @@ -98,8 +117,7 @@ def writeNewLine(self, trans): self.indent(trans) def indent(self, trans): - for _i in range(self.indentLevel): - trans.write(JSON_TAB) + trans.write(JSON_TAB * self.indentLevel) class TJSONPairContext(TJSONContext): @@ -327,15 +345,46 @@ def skipWhitespace(self): skipped = 0 while True: ch = self.reader.peek() - if ch not in (JSON_NEW_LINE, - TAB, - JSON_CARRIAGE_RETURN, - JSON_SPACE): + if ch not in WHITESPACE_CHARS: break self.reader.read() skipped += 1 return skipped + def skip(self, _type): + self.context.read(self.reader) + self.skipWhitespace() + type = self.guessTypeIdFromFirstByte() + # Since self.context.read is called at the beginning of all readJSONxxx + # methods and we have already called it here, push an empty context so that + # it becomes a no-op. + self.pushContext(TJSONContext(protocol=self)) + if type == TType.STRUCT: + self.readJSONObjectStart() + while True: + (_, ftype, _) = self.readFieldBegin() + if ftype == TType.STOP: + break + self.skip(TType.VOID) + self.readJSONObjectEnd() + elif type == TType.LIST: + self.readJSONArrayStart() + while self.peekList(): + self.skip(TType.VOID) + self.readJSONArrayEnd() + elif type == TType.STRING: + self.readJSONString() + elif type == TType.DOUBLE: + self.readJSONDouble() + elif type == TType.BOOL: + self.readJSONBool() + else: + raise TProtocolException( + TProtocolException.INVALID_DATA, + "Unexpected type {} guessed when skipping".format(type) + ) + self.popContext() + def guessTypeIdFromFirstByte(self): self.skipWhitespace() byte = self.reader.peek() @@ -362,10 +411,10 @@ def writeJSONEscapeChar(self, ch): self.trans.write(hexChar(ch)) def writeJSONChar(self, ch): - charValue = ord(ch) if not isinstance(ch, int) else ch - ch = chr(ch) if isinstance(ch, int) else ch + charValue = ord(ch) if charValue >= 0x30: - if ch == JSON_BACKSLASH: # Only special character >= 0x30 is '\'. + # The only special character >= 0x30 is '\'. + if charValue == JSON_BACKSLASH_VALUE: self.trans.write(JSON_BACKSLASH) self.trans.write(JSON_BACKSLASH) else: @@ -383,11 +432,24 @@ def writeJSONChar(self, ch): def writeJSONString(self, outStr): self.context.write(self.trans) self.trans.write(JSON_STRING_DELIMITER) - is_bytes_type = isinstance(outStr, bytes) - for i in range(len(outStr)): - # Slicing of bytes in Py3 produces bytes! - ch = outStr[i:(i + 1)] if is_bytes_type else outStr[i] - self.writeJSONChar(ch) + outStrLen = len(outStr) + if outStrLen > 0: + is_int = isinstance(outStr[0], int) + pos = 0 + for idx, ch in enumerate(outStr): + if is_int: + ch = outStr[idx:idx + 1] + if ch in JSON_CHARS_TO_ESCAPE: + if pos < idx: + # Write previous chunk not requiring escaping + self.trans.write(outStr[pos:idx]) + # Write current char with escaping + self.writeJSONChar(ch) + # Advance pos + pos = idx + 1 + if pos < outStrLen: + # Write last chunk till outStrLen + self.trans.write(outStr[pos:outStrLen]) self.trans.write(JSON_STRING_DELIMITER) def writeJSONBase64(self, outStr): diff --git a/nebula2/fbthrift/protocol/__init__.py b/nebula2/fbthrift/protocol/__init__.py index 64478555..a0290902 100644 --- a/nebula2/fbthrift/protocol/__init__.py +++ b/nebula2/fbthrift/protocol/__init__.py @@ -1,23 +1,19 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. -__all__ = ['TProtocol', +__all__ = [ + 'TProtocol', 'TBinaryProtocol', 'fastproto', 'TSimpleJSONProtocol', diff --git a/nebula2/fbthrift/protocol/exceptions.py b/nebula2/fbthrift/protocol/exceptions.py new file mode 100644 index 00000000..2c89ceff --- /dev/null +++ b/nebula2/fbthrift/protocol/exceptions.py @@ -0,0 +1,33 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + + +def create_ThriftUnicodeDecodeError_from_UnicodeDecodeError(error, field_name): + if isinstance(error, ThriftUnicodeDecodeError): + error.field_names.append(field_name) + return error + return ThriftUnicodeDecodeError( + error.encoding, error.object, error.start, error.end, error.reason, field_name + ) + + +class ThriftUnicodeDecodeError(UnicodeDecodeError): + def __init__(self, encoding, object, start, end, reason, field_name): + super(ThriftUnicodeDecodeError, self).__init__(encoding, object, start, end, reason) + self.field_names = [field_name] + + def __str__(self): + return "{error} when decoding field '{field}'".format( + error=super(ThriftUnicodeDecodeError, self).__str__(), field="->".join(reversed(self.field_names)) + ) diff --git a/nebula2/fbthrift/server/TAsyncioServer.py b/nebula2/fbthrift/server/TAsyncioServer.py index 5f4ec61f..abc09376 100644 --- a/nebula2/fbthrift/server/TAsyncioServer.py +++ b/nebula2/fbthrift/server/TAsyncioServer.py @@ -1,4 +1,17 @@ #!/usr/bin/env python3 +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. import asyncio import functools @@ -34,10 +47,9 @@ # -@asyncio.coroutine -def ThriftAsyncServerFactory( +async def ThriftAsyncServerFactory( processor, *, interface=None, port=0, loop=None, nthreads=None, sock=None, - backlog=100, ssl=None, event_handler=None + backlog=100, ssl=None, event_handler=None, protocol_factory=None ): """ ThriftAsyncServerFactory(processor) -> asyncio.Server @@ -61,12 +73,19 @@ def ThriftAsyncServerFactory( thrift.server.TServer.TServerEventHandler is used. Specify a custom handler for custom event handling (e.g. handling new connections) + protocol_factory is a function that takes a triplet of + (processor, event_handler, loop=None) and returns a `asyncio.Protocol` instance + that will be passed to a call to `asyncio.create_server`. processor will be a + subclass of `TProcessor`, event_handler will be a subclass of `TServer`, and + loop is an `Optional[asyncio.AbstractEventLoop]`. If protocol_factory is None + `ThriftHeaderServerProtocol` is used. + Notes about the processor method handling: 1. By default all methods are executed synchronously on the event loop. This can lead to poor performance if a single run takes long to process. - 2. Mark coroutines with @asyncio.coroutine if you wish to use "yield from" + 2. Mark coroutines with `async def` if you wish to use `await` to call async services, schedule tasks with customized executors, etc. 3. Mark methods with @run_on_thread if you wish to run them on the thread @@ -105,8 +124,9 @@ def ThriftAsyncServerFactory( ThreadPoolExecutor(max_workers=nthreads), ) ehandler = TServerEventHandler() if event_handler is None else event_handler - pfactory = ThriftServerProtocolFactory(processor, ehandler, loop) - server = yield from loop.create_server( + protocol_factory = protocol_factory or ThriftHeaderServerProtocol + pfactory = functools.partial(protocol_factory, processor, ehandler, loop) + server = await loop.create_server( pfactory, interface, port, @@ -136,8 +156,7 @@ def __init__(self, processor, server_event_handler, loop=None): self.server_event_handler = server_event_handler self.server_context = None - @asyncio.coroutine - def message_received(self, frame): + async def message_received(self, frame): # Note: we are using a single `prot` for in and out so that # we can support legacy clients that only understand FRAMED. # The discovery of what the client supports happens in iprot's @@ -146,7 +165,7 @@ def message_received(self, frame): prot = THeaderProtocol(buf) try: - yield from self.processor.process( + await self.processor.process( prot, prot, self.server_context, ) msg = buf.getvalue() @@ -165,6 +184,9 @@ def message_received(self, frame): self.transport.close() def connection_made(self, transport): + self.upgrade_transport(transport) + + def upgrade_transport(self, transport): self.transport = transport socket = self.transport.get_extra_info("socket") if socket is not None: @@ -196,18 +218,16 @@ def ThriftClientProtocolFactory( class SenderTransport(WrappedTransport): - @asyncio.coroutine - def _send(self): + async def _send(self): while True: - msg = yield from self._queue.get() + msg = await self._queue.get() self._clean_producers() self._trans.write(msg) class ThriftHeaderClientProtocol(ThriftHeaderClientProtocolBase): - @asyncio.coroutine - def timeout_task(self, fname, seqid, delay): - yield from asyncio.sleep(delay, loop=self.loop) + async def timeout_task(self, fname, seqid, delay): + await asyncio.sleep(delay, loop=self.loop) self._handle_timeout(fname, seqid) def wrapAsyncioTransport(self, asyncio_transport): diff --git a/nebula2/fbthrift/server/TCppServer.py b/nebula2/fbthrift/server/TCppServer.py index 74d974c6..5fbdf429 100644 --- a/nebula2/fbthrift/server/TCppServer.py +++ b/nebula2/fbthrift/server/TCppServer.py @@ -1,3 +1,17 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + from __future__ import absolute_import from __future__ import division from __future__ import print_function @@ -87,10 +101,8 @@ def call_processor(self, input, headers, client_type, protocol_type, should_sample = self._shouldSample() timestamps = CallTimestamps() - timestamps.processBegin = 0 - timestamps.processEnd = 0 if self.observer and should_sample: - timestamps.processBegin = int(time.time() * 10**6) + timestamps.setProcessBeginNow() write_buf = TMemoryBuffer() trans = THeaderTransport(write_buf) @@ -116,7 +128,7 @@ def call_processor(self, input, headers, client_type, protocol_type, if self.observer: if should_sample: - timestamps.processEnd = int(time.time() * 10**6) + timestamps.setProcessEndNow() # This only bumps counters if `processBegin != 0` and # `processEnd != 0` and these will only be non-zero if @@ -175,7 +187,6 @@ def __init__(self): self.verify = SSLVerifyPeerEnum.VERIFY self.ssl_policy = SSLPolicy.PERMITTED self.ticket_file_path = '' - self.alpn_protocols = [] self.session_context = None self.ssl_version = None @@ -215,6 +226,7 @@ def __init__(self): self.ssl_cache_timeout_seconds = 86400 self.max_ssl_cache_size = 20480 self.ssl_cache_flush_size = 200 + self.ssl_handshake_validity_seconds = 259200 class TCppServer(CppServerWrapper, TServer): @@ -224,6 +236,7 @@ def __init__(self, processor): self.setAdapter(_ProcessorAdapter(self.processor)) self._setup_done = False self.serverEventHandler = None + self.setWrapperName("TCppServer-py") def setAdapter(self, adapter): self.processorAdapter = adapter @@ -252,6 +265,9 @@ def setSSLCacheOptions(self, cache_options): def setFastOpenOptions(self, enabled, tfo_max_queue): self.setCppFastOpenOptions(enabled, tfo_max_queue) + def useExistingSocket(self, socket): + self.useCppExistingSocket(socket) + def getTicketSeeds(self): return self.getCppTicketSeeds() @@ -259,8 +275,6 @@ def setup(self): if self._setup_done: return CppServerWrapper.setup(self) - # Task expire isn't supported in Python - CppServerWrapper.setTaskExpireTime(self, 0) if self.serverEventHandler is not None: self.serverEventHandler.preServe(self.getAddress()) self._setup_done = True diff --git a/nebula2/fbthrift/server/TGeventServer.py b/nebula2/fbthrift/server/TGeventServer.py deleted file mode 100644 index 5144ea67..00000000 --- a/nebula2/fbthrift/server/TGeventServer.py +++ /dev/null @@ -1,123 +0,0 @@ -# -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. -# - -from __future__ import absolute_import -from __future__ import division -from __future__ import print_function -from __future__ import unicode_literals - -import collections -import logging -import multiprocessing -from multiprocessing import Process -import gevent -from gevent.server import StreamServer - -from .TServer import TServer -from nebula2.fbthrift.transport.TTransport import TTransportException -from nebula2.fbthrift.transport.TSocket import TSocket -from nebula2.fbthrift.protocol.THeaderProtocol import THeaderProtocolFactory - -from gevent import monkey -monkey.patch_all(select=False) - -class TGeventServer(TServer): - - """ - Server with a fixed size pool of worker subprocesses which service requests. - Note that if you need shared state between the handlers - it's up to you! - Written by Dvir Volk, doat.com - """ - - def __init__(self, port, *args): - TServer.__init__(self, *args) - self.port = port - self.numWorkers = multiprocessing.cpu_count() - self.workers = [] - self.postForkCallback = None - - def setPostForkCallback(self, callback): - if not isinstance(callback, collections.Callable): - raise TypeError("This is not a callback!") - self.postForkCallback = callback - - def setNumWorkers(self, num): - """Set the number of worker threads that should be created""" - self.numWorkers = num - - def serveClient(self, socket, address): - """Process input/output from a client for as long as possible""" - client = TSocket() - client.setHandle(socket) - itrans = self.inputTransportFactory.getTransport(client) - otrans = self.outputTransportFactory.getTransport(client) - iprot = self.inputProtocolFactory.getProtocol(itrans) - if isinstance(self.inputProtocolFactory, THeaderProtocolFactory): - oprot = iprot - else: - oprot = self.outputProtocolFactory.getProtocol(otrans) - - try: - while True: - self.processor.process(iprot, oprot) - except TTransportException: - pass - except Exception as x: - logging.exception(x) - - itrans.close() - otrans.close() - - def serve_forever(self): - if self.postForkCallback: - self.postForkCallback() - while True: - try: - self.server.serve_forever() - except (KeyboardInterrupt, SystemExit): - return 0 - except Exception as x: - logging.exception(x) - - def serve(self, listener=None): - """Start a fixed number of worker threads and put client into a queue""" - - if not listener: - listener = ('', self.port) - - self.server = StreamServer(listener, self.serveClient) - # Temporary patch for gevent 0.13.x - # Remove pre_start when we are fully on gevent 1.0 - if gevent.version_info[0] == 0: - self.server.pre_start() - else: - self.server.init_socket() - - print('Starting %s workers' % self.numWorkers) - for _ in range(self.numWorkers - 1): # Current process also serves - p = Process(target=self.serve_forever) - self.workers.append(p) - p.start() - - self.serve_forever() - - def stop(self): - for worker in self.workers: - worker.terminate() - self.server.stop() diff --git a/nebula2/fbthrift/server/TNonblockingServer.py b/nebula2/fbthrift/server/TNonblockingServer.py deleted file mode 100644 index 3c44fed4..00000000 --- a/nebula2/fbthrift/server/TNonblockingServer.py +++ /dev/null @@ -1,471 +0,0 @@ -# -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. -# -"""Implementation of non-blocking server. - -The main idea of the server is receiving and sending requests -only from main thread. - -It also makes thread pool server in tasks terms, not connections. -""" - -from __future__ import absolute_import -from __future__ import division -from __future__ import print_function -from __future__ import unicode_literals - -import logging -import select -import socket -import struct -import sys -import threading -import time -import errno - -if sys.version_info[0] >= 3: - import queue - Queue = queue - xrange = range -else: - import Queue - -from nebula2.fbthrift.server import TServer -from nebula2.fbthrift.Thrift import TProcessor, TApplicationException -from nebula2.fbthrift.transport import TTransport, TSocket -from nebula2.fbthrift.protocol.TBinaryProtocol import TBinaryProtocolFactory -from nebula2.fbthrift.protocol.THeaderProtocol import THeaderProtocolFactory - -LOG_ERRORS_EVERY = 60 * 10 # once per 10 minutes - -__all__ = ['TNonblockingServer'] - -class Worker(threading.Thread): - """Worker is a small helper to process incoming connection.""" - def __init__(self, queue): - threading.Thread.__init__(self) - self.queue = queue - - def run(self): - """Process queries from task queue, stop if processor is None.""" - while True: - try: - processor, iprot, oprot, otrans, callback = self.queue.get() - if processor is None: - break - callback.getContext().setProtocols(iprot, oprot) - processor.process(iprot, oprot, callback.getContext()) - callback.success(reply=otrans.getvalue()) - except Exception: - logging.exception("Exception while processing request") - callback.failure() - -WAIT_LEN = 0 -WAIT_MESSAGE = 1 -WAIT_PROCESS = 2 -SEND_ANSWER = 3 -CLOSED = 4 - -def locked(func): - "Decorator which locks self.lock." - def nested(self, *args, **kwargs): - self.lock.acquire() - try: - return func(self, *args, **kwargs) - finally: - self.lock.release() - return nested - -def socket_exception(func): - "Decorator close object on socket.error." - def read(self, *args, **kwargs): - try: - return func(self, *args, **kwargs) - except socket.error: - self.close() - return read - -class Connection: - """Basic class is represented connection. - - It can be in state: - WAIT_LEN --- connection is reading request len. - WAIT_MESSAGE --- connection is reading request. - WAIT_PROCESS --- connection has just read whole request and - waits for call ready routine. - SEND_ANSWER --- connection is sending answer string (including length - of answer). - CLOSED --- socket was closed and connection should be deleted. - """ - def __init__(self, client_socket, server): - self.socket = client_socket.getHandle() - self.socket.setblocking(False) - self.lock = threading.RLock() - self._server = server - self._timer = None - self.len = 0 - self.message = b'' - self.context = TServer.TRpcConnectionContext(client_socket) - self._server.serverEventHandler.newConnection(self.context) - self._set_status(WAIT_LEN) - - @locked - def _set_status(self, status): - self.status = status - if self.status in (WAIT_LEN, WAIT_MESSAGE): - self._server.poller.read(self.fileno()) - if self._server._readTimeout is not None: - if self._timer is not None: - self._timer.cancel() - self._timer = threading.Timer(self._server._readTimeout, - self._cleanup) - self._timer.start() - elif self._timer is not None: - self._timer.cancel() - - if self.status == SEND_ANSWER: - self._server.poller.write(self.fileno()) - - if self.status in (WAIT_PROCESS, CLOSED): - self._server.poller.unregister(self.fileno()) - - - def getContext(self): - return self.context - - def success(self, reply): - self.ready(True, reply) - - def failure(self): - self.ready(False, b'') - - def _read_len(self): - """Reads length of request.""" - - read = self.socket.recv(4) - if len(read) == 0: - # if we read 0 bytes and self.message is empty, it means client - # closed the connection - if len(self.message) != 0: - logging.error("can't read frame size from socket") - self.close() - return - self.message += read - if len(self.message) == 4: - self.len, = struct.unpack(b'!i', self.message) - if self.len < 0: - logging.error("negative frame size, it seems client"\ - " doesn't use FramedTransport") - self.close() - elif self.len == 0: - logging.error("empty frame, it's really strange") - self.close() - else: - self.len += 4 # Include message length - self._set_status(WAIT_MESSAGE) - - @socket_exception - def read(self): - """Reads data from stream and switch state.""" - assert self.status in (WAIT_LEN, WAIT_MESSAGE) - - if self.status == WAIT_LEN: - self._read_len() - # go back to the main loop here for simplicity instead of - # falling through, even though there is a good chance that - # the message is already available - elif self.status == WAIT_MESSAGE: - read = self.socket.recv(self.len - len(self.message)) - if len(read) == 0: - logging.error("can't read frame from socket" + - " (got %d of %d bytes)" % - (len(self.message), self.len)) - self.close() - return - self.message += read - if len(self.message) == self.len: - self._set_status(WAIT_PROCESS) - - @socket_exception - def write(self): - """Writes data from socket and switch state.""" - assert self.status == SEND_ANSWER - sent = self.socket.send(self.message) - if sent == len(self.message): - self._set_status(WAIT_LEN) - self.message = b'' - self.len = 0 - else: - self.message = self.message[sent:] - - @locked - def ready(self, all_ok, message): - """Callback function for switching state and waking up main thread. - - This function is the only function which can be called asynchronous. - - The ready can switch Connection to three states: - WAIT_LEN if request was oneway. - SEND_ANSWER if request was processed in normal way. - CLOSED if request throws unexpected exception. - - The one wakes up main thread. - """ - if self.status != WAIT_PROCESS: - logging.error("Connection status switched to {} when" - "processing requests. Server bug?".format(self.status)) - all_ok = False - - if not all_ok: - self.close() - self._server.wake_up() - return - self.len = 0 - if len(message) == 0: - # it was a oneway request, do not write answer - self.message = b'' - self._set_status(WAIT_LEN) - else: - self.message = message - self._set_status(SEND_ANSWER) - self._server.wake_up() - - def fileno(self): - "Returns the file descriptor of the associated socket." - return self.socket.fileno() - - def close(self): - "Closes connection" - if self._timer is not None: - self._timer.cancel() - self._cleanup() - - def _cleanup(self): - self._set_status(CLOSED) - self._server.connection_closed(self) - self.socket.close() - -class TNonblockingServer(TServer.TServer): - """Non-blocking server.""" - def __init__(self, processor, lsocket, inputProtocolFactory=None, - outputProtocolFactory=None, threads=10, readTimeout=None, - maxQueueSize=0): - self.processor = self._getProcessor(processor) - self.socket = lsocket - self.in_protocol = inputProtocolFactory or TBinaryProtocolFactory() - self.out_protocol = outputProtocolFactory or self.in_protocol - self.threads = int(threads) - self.clients = {} - self.max_queue_size = maxQueueSize # do not set this as a hard size - # maximum - the queue may need - # extra space for close() - self.tasks = Queue.Queue() - self._read, self._write = _create_socketpair() - self.prepared = False - self._stop = False - self.serverEventHandler = TServer.TServerEventHandler() - self.select_timeout = DEFAULT_SELECT_TIMEOUT - self.poller = TSocket.ConnectionEpoll() if hasattr(select, "epoll") \ - else TSocket.ConnectionSelect() - self.last_logged_error = 0 - timeouts = [x for x in [self.select_timeout, readTimeout] \ - if x is not None] - if len(timeouts) > 0: - self.select_timeout = min(timeouts) - self._readTimeout = readTimeout - - def setServerEventHandler(self, handler): - """Sets the server event handler - - Arguments: - handler: instance of TServer.TServerEventHandler - """ - self.serverEventHandler = handler - - def setNumThreads(self, num): - """Set the number of worker threads that should be created.""" - # implement ThreadPool interface - assert not self.prepared, "You can't change number of threads for working server" - self.threads = num - - def prepare(self): - """Prepares server for serve requests.""" - if self.prepared: - return - self.socket.listen() - for name in self.socket.getSocketNames(): - self.serverEventHandler.preServe(name) - for _ in xrange(self.threads): - thread = Worker(self.tasks) - thread.setDaemon(True) - thread.start() - - for fileno in self.socket.handles: - self.poller.read(fileno) - self.poller.read(self._read.fileno()) - - self.prepared = True - - def wake_up(self): - """Wake up main thread. - - The server usualy waits in select call in we should terminate one. - The simplest way is using socketpair. - - Select always wait to read from the first socket of socketpair. - - In this case, we can just write anything to the second socket from - socketpair.""" - self._write.send(b'1') - - def stop(self): - """Stop the server. - - This method causes the serve() method to return. stop() may be invoked - from within your handler, or from another thread. - - After stop() is called, serve() will return but the server will still - be listening on the socket. serve() may then be called again to resume - processing requests. Alternatively, close() may be called after - serve() returns to close the server socket and shutdown all worker - threads. - """ - self._stop = True - self.wake_up() - - def log_poll_problem(self, msg): - """ Logs errors every LOG_ERRORS_EVERY since they may occur - frequently. """ - now = time.time() - if now - self.last_logged_error >= LOG_ERRORS_EVERY: - self.last_logged_error = now - logging.exception(msg) - - def _select(self): - """Does epoll or select on open connections.""" - try: - return self.poller.process(self.select_timeout) - except Exception as e: - if not (isinstance(e, IOError) and e.errno == errno.EINTR): - self.log_poll_problem("problem polling: %s" % e) - return [], [], [] - - def handle(self): - """Handle requests. - - WARNING! You must call prepare BEFORE calling handle. - """ - assert self.prepared, "You have to call prepare before handle" - rset, wset, xset = self._select() - for readable in rset: - if readable == self._read.fileno(): - # don't care i just need to clean readable flag - self._read.recv(1024) - elif readable in self.socket.handles: - client_socket = self.socket.accept() - connection = Connection(client_socket, self) - self.clients[client_socket.fileno()] = connection - else: - connection = self.clients[readable] - connection.read() - if connection.status == WAIT_PROCESS: - itransport = TTransport.TMemoryBuffer(connection.message) - - # Header protocol needs oprot == iprot. This implies the - # input memory buffer is reused for output too. - if isinstance(self.in_protocol, THeaderProtocolFactory): - omembuf = itransport - iprot = self.in_protocol.getProtocol(itransport) - oprot = iprot - else: - # Otherwise, assume we need a TFramedTransport. - omembuf = TTransport.TMemoryBuffer() - itransport = TTransport.TFramedTransport(itransport) - otransport = TTransport.TFramedTransport(omembuf) - iprot = self.in_protocol.getProtocol(itransport) - oprot = self.out_protocol.getProtocol(otransport) - - if self.max_queue_size == 0 or \ - self.tasks.qsize() <= self.max_queue_size: - self.tasks.put([self.processor, iprot, oprot, - omembuf, connection]) - else: - logging.error( - "Queue max size of %d exceeded. Request rejected.", - self.max_queue_size) - for writeable in wset: - self.clients[writeable].write() - for oob in xset: - if oob in self.clients: - connection = self.clients[oob] - connection.close() - - def close(self): - """Closes the server.""" - for _ in xrange(self.threads): - self.tasks.put([None, None, None, None, None]) - self.socket.close() - self.prepared = False - - def connection_closed(self, connection): - """Connection close callback""" - self.serverEventHandler.connectionDestroyed(connection.context) - del self.clients[connection.fileno()] - - def serve(self): - """Serve requests. - - Serve requests forever, or until stop() is called. - """ - self._stop = False - self.prepare() - while not self._stop: - self.handle() - - -if sys.platform == 'win32': - # The Windows select() implementation can't process signals during select. - # Default to a 1 second select timeout, so we'll wake up once a second to - # process any pending signals. - DEFAULT_SELECT_TIMEOUT = 1 - - # socket.socketpair() isn't supported on windows, so define our own - # equivalent - def _create_socketpair(): - # Create a socket to listen on an ephemeral port - listener = socket.socket() - listener.bind(('127.0.0.1', 0)) - listen_addr = listener.getsockname() - listener.listen(1) - - # Create a second socket to connect to it - connector = socket.socket() - # From my limited testing, just using a blocking connect seems to work. - # If we wanted to be more careful, we could set connector to - # non-blocking mode to perform the connect, so we can call accept on - # the listener. - connector.connect(listen_addr) - - (accepted, address) = listener.accept() - - listener.close() - - return (connector, accepted) -else: - DEFAULT_SELECT_TIMEOUT = None - _create_socketpair = socket.socketpair diff --git a/nebula2/fbthrift/server/TServer.py b/nebula2/fbthrift/server/TServer.py index 7437bdc3..359b49e4 100644 --- a/nebula2/fbthrift/server/TServer.py +++ b/nebula2/fbthrift/server/TServer.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division @@ -28,6 +25,7 @@ import threading if sys.version_info[0] >= 3: import queue + # pyre-fixme[11]: Annotation `queue` is not defined as a type. Queue = queue else: import Queue @@ -218,143 +216,3 @@ def handle(self, client): def serve(self): pass - - -class TSimpleServer(TServer): - - """Simple single-threaded server that just pumps around one transport.""" - - def __init__(self, *args): - warnings.warn("TSimpleServer is deprecated. Please use one of " - "Nonblocking, Twisted, or Gevent server instead.", - DeprecationWarning) - TServer.__init__(self, *args) - - def serve(self): - self.serverTransport.listen() - for name in self.serverTransport.getSocketNames(): - self.serverEventHandler.preServe(name) - while True: - client = self.serverTransport.accept() - self.handle(client) - - -class TThreadedServer(TServer): - - """Threaded server that spawns a new thread per each connection.""" - - def __init__(self, *args, **kwargs): - TServer.__init__(self, *args) - self.daemon = kwargs.get("daemon", False) - - def serve(self): - - self.serverTransport.listen() - for name in self.serverTransport.getSocketNames(): - self.serverEventHandler.preServe(name) - while True: - try: - client = self.serverTransport.accept() - t = threading.Thread(target=self.handle, args=(client,)) - t.daemon = self.daemon - t.start() - except KeyboardInterrupt: - raise - except Exception as x: - logging.exception(x) - - -class TForkingServer(TServer): - - """A Thrift server that forks a new process for each request""" - """ - This is more scalable than the threaded server as it does not cause - GIL contention. - - Note that this has different semantics from the threading server. - Specifically, updates to shared variables will no longer be shared. - It will also not work on windows. - - This code is heavily inspired by SocketServer.ForkingMixIn in the - Python stdlib. - """ - - def __init__(self, *args): - TServer.__init__(self, *args) - self.children = [] - - def serve(self): - def tryClose(file): - try: - file.close() - except IOError as e: - logging.warning(e, exc_info=True) - - self.serverTransport.listen() - for name in self.serverTransport.getSocketNames(): - self.serverEventHandler.preServe(name) - while True: - client = self.serverTransport.accept() - try: - - itrans = self.inputTransportFactory.getTransport(client) - otrans = self.outputTransportFactory.getTransport(client) - - iprot = self.inputProtocolFactory.getProtocol(itrans) - - if isinstance(self.inputProtocolFactory, - THeaderProtocolFactory): - oprot = iprot - else: - oprot = self.outputProtocolFactory.getProtocol(otrans) - - context = TRpcConnectionContext(client, iprot, oprot) - self._clientBegin(context, iprot, oprot) - - pid = os.fork() - - if pid: # parent - # add before collect, otherwise you race w/ waitpid - self.children.append(pid) - self._collectChildren() - - # Parent must close socket or the connection may not get - # closed promptly - tryClose(itrans) - tryClose(otrans) - - else: - - ecode = 0 - try: - try: - while True: - self.processor.process(iprot, oprot, context) - except TTransport.TTransportException: - pass - except Exception as e: - logging.exception(e) - ecode = 1 - finally: - self.serverEventHandler.connectionDestroyed(context) - tryClose(itrans) - tryClose(otrans) - - os._exit(ecode) - - except TTransport.TTransportException: - pass - except Exception as x: - logging.exception(x) - - def _collectChildren(self): - while self.children: - try: - pid, status = os.waitpid(0, os.WNOHANG) - except os.error: - pid = None - - if pid: - self.children.remove(pid) - else: - break diff --git a/nebula2/fbthrift/server/TTrolliusServer.py b/nebula2/fbthrift/server/TTrolliusServer.py deleted file mode 100644 index a4403a4f..00000000 --- a/nebula2/fbthrift/server/TTrolliusServer.py +++ /dev/null @@ -1,174 +0,0 @@ -#!/usr/bin/env python2 - -"""Implements what TAsyncioServer does, using the Trollius backport for -Python 2.""" - -from __future__ import absolute_import -from __future__ import division -from __future__ import print_function -from __future__ import unicode_literals - -import functools -import logging -import trollius as asyncio -import traceback - -from trollius import From, Return - -from nebula2.fbthrift.server.TServer import TServerEventHandler -from nebula2.fbthrift.Thrift import ( - TException, - TProcessor, -) -from nebula2.fbthrift.util.async_common import ( - AsyncioRpcConnectionContext, - FramedProtocol, - THeaderProtocol, - ThriftHeaderClientProtocolBase, - TReadWriteBuffer, - WrappedTransport, -) - - -__all__ = [ - 'ThriftClientProtocolFactory', -] - -logger = logging.getLogger(__name__) - - -# -# Thrift server support -# - - -@asyncio.coroutine -def ThriftAsyncServerFactory( - processor, interface=None, port=0, loop=None, nthreads=None, sock=None, - backlog=100, event_handler=None -): - if loop is None: - loop = asyncio.get_event_loop() - - if not isinstance(processor, TProcessor): - try: - processor = processor._processor_type(processor, loop=loop) - except AttributeError: - raise TypeError( - "Unsupported processor type: {}".format(type(processor)), - ) - - if nthreads: - from concurrent.futures import ThreadPoolExecutor - loop.set_default_executor( - ThreadPoolExecutor(max_workers=nthreads), - ) - - ehandler = TServerEventHandler() if event_handler is None else event_handler - pfactory = ThriftServerProtocolFactory(processor, ehandler, loop) - server = yield From(loop.create_server( - pfactory, - interface, - port, - sock=sock, - backlog=backlog, - )) - - if server.sockets: - for socket in server.sockets: - ehandler.preServe(socket.getsockname()) - - raise Return(server) - - -def ThriftServerProtocolFactory(processor, server_event_handler, loop=None): - return functools.partial( - ThriftHeaderServerProtocol, processor, server_event_handler, loop, - ) - - -class ThriftHeaderServerProtocol(FramedProtocol): - - def __init__(self, processor, server_event_handler, loop=None): - super(ThriftHeaderServerProtocol, self).__init__(loop=loop) - self.processor = processor - self.server_event_handler = server_event_handler - self.server_context = None - - @asyncio.coroutine - def message_received(self, frame): - # Note: we are using a single `prot` for in and out so that - # we can support legacy clients that only understand FRAMED. - # The discovery of what the client supports happens in iprot's - # transport so we have to reuse a single one here. - buf = TReadWriteBuffer(frame) - prot = THeaderProtocol(buf) - - try: - yield From(self.processor.process( - prot, prot, self.server_context, - )) - msg = buf.getvalue() - if len(msg) > 0: - self.transport.write(msg) - except TException as e: - logger.warning("TException while processing request: %s", str(e)) - msg = buf.getvalue() - if len(msg) > 0: - self.transport.write(msg) - except asyncio.CancelledError: - self.transport.close() - except BaseException as e: - logger.error("Exception while processing request: %s", str(e)) - logger.error(traceback.format_exc()) - self.transport.close() - - def connection_made(self, transport): - self.transport = transport - socket = self.transport.get_extra_info("socket") - if socket is not None: - self.server_context = AsyncioRpcConnectionContext(socket) - self.server_event_handler.newConnection(self.server_context) - - def connection_lost(self, exc): - self.server_event_handler.connectionDestroyed(self.server_context) - - -# -# Thrift client support -# - - -def ThriftClientProtocolFactory( - client_class, - thrift_factory=None, - loop=None, - timeouts=None, - client_type=None, -): - return functools.partial( - ThriftHeaderClientProtocol, - client_class, - loop, - timeouts, - client_type, - ) - - -class SenderTransport(WrappedTransport): - @asyncio.coroutine - def _send(self): - while True: - msg = yield From(self._queue.get()) - self._clean_producers() - self._trans.write(msg) - - -class ThriftHeaderClientProtocol(ThriftHeaderClientProtocolBase): - @asyncio.coroutine - def timeout_task(self, fname, seqid, delay=0): - yield From(asyncio.sleep(delay)) - self._handle_timeout(fname, seqid) - - def wrapAsyncioTransport(self, asyncio_transport): - return SenderTransport(asyncio_transport, self, self.loop) diff --git a/nebula2/fbthrift/server/__init__.py b/nebula2/fbthrift/server/__init__.py index 5ae0f917..8cab0d63 100644 --- a/nebula2/fbthrift/server/__init__.py +++ b/nebula2/fbthrift/server/__init__.py @@ -1,25 +1,20 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals -__all__ = ['TServer', 'TNonblockingServer', 'TAsyncioServer'] +__all__ = ['TServer', 'TAsyncioServer'] diff --git a/nebula2/fbthrift/transport/TFuzzyHeaderTransport.py b/nebula2/fbthrift/transport/TFuzzyHeaderTransport.py deleted file mode 100644 index 01f18d1f..00000000 --- a/nebula2/fbthrift/transport/TFuzzyHeaderTransport.py +++ /dev/null @@ -1,257 +0,0 @@ -from __future__ import absolute_import -from __future__ import division -from __future__ import print_function -from __future__ import unicode_literals - -import os -import random -import struct - -import six -import six.moves as sm -from six import StringIO - -from nebula2.fbthrift import Thrift -from nebula2.fbthrift.util import randomizer -from nebula2.fbthrift.protocol.TCompactProtocol import getVarint -from .THeaderTransport import ( - THeaderTransport, INFO, HEADER_MAGIC, _flush_info_headers -) - -class TFuzzyHeaderTransport(THeaderTransport): - """Transport that can optionally fuzz fields in the header or payload. - - The initializer accepts `fuzz_fields`, an iterable of names of fields in - the header (or payload) that should be fuzzed (mutated.) - - TFuzzyHeaderTransport should ONLY be used for testing purposes. - """ - - fuzzable_fields = frozenset({ - 'flags', - 'header_size', - 'identity', - 'length', - 'magic', - 'num_transforms', - 'padding', - 'padding_bytes', - 'payload', - 'proto_id', - 'seq_id', - 'transform_id', - 'version', - }) - - # Randomizers for message fields by data type - _randomizer_state = randomizer.RandomizerState() - _i32_randomizer = _randomizer_state.get_randomizer(Thrift.TType.I32, None, { - 'fuzz_max_delta': 32 - }) - _i16_randomizer = _randomizer_state.get_randomizer(Thrift.TType.I16, None, { - 'fuzz_max_delta': 32 - }) - _byte_randomizer = _randomizer_state.get_randomizer( - Thrift.TType.BYTE, None, {}) - - @classmethod - def _fuzz_char(cls, seed): - """Randomly modify a (binary) character""" - seed = six.byte2int(seed) - res = cls._byte_randomizer.generate(seed=seed) % (2 ** 8) - return six.int2byte(res) - - @classmethod - def _fuzz_i16(cls, seed): - """Randomly modify a 16-bit positive integer""" - res = cls._i16_randomizer.generate(seed=seed) - return res % (2 ** 16) - - @classmethod - def _fuzz_i32(cls, seed): - """Randomly modify a 32-bit positive integer""" - res = cls._i32_randomizer.generate(seed=seed) - return res % (2 ** 32) - - @classmethod - def _fuzz_str(cls, seed): - """Randomly modify one character of a string""" - fuzz_index = random.randint(0, len(seed) - 1) - fuzzed_char = six.int2byte(random.randint(0, 255)) - return seed[:fuzz_index] + fuzzed_char + seed[fuzz_index + 1:] - - # Map type names to arguments to struct.pack - _struct_type_map = { - 'char': '!c', - 'i16': '!H', - 'i32': '!I' - } - - @classmethod - def _serialize_field(cls, val, type_): - if type_ == 'str': - return six.binary_type(val) - if type_ in cls._struct_type_map: - struct_type = six.binary_type(cls._struct_type_map[type_]) - return struct.pack(struct_type, val) - else: - raise NotImplementedError("%s serializer not implemented" % type_) - - def __init__(self, trans, client_types=None, - fuzz_fields=None, fuzz_all_if_empty=True, verbose=False): - """Create a TFuzzyHeaderTransport instance. - - @param fuzz_fields(iterable) Collection of string names of fields to - fuzz. Each name must be a member of - TFuzzyHeaderTransport.fuzzable_fields. If the iterable is empty and - fuzz_all_if_empty is True, all fields will be fuzzed. If the iterable - is empty and fuzz_all_if_empty is False, no fields will be fuzzed. - - @param verbose(bool) Whether to print fuzzed fields to stdout - - @param fuzz_all_if_empty(bool) Whether to fuzz eveyr field if - the fuzz_fields iterable is None or empty. - - trans and client_type are forwarded to THeaderProtocol.__init__ - """ - cls = self.__class__ - THeaderTransport.__init__(self, trans, client_types=client_types) - - if fuzz_fields is None: - fuzz_fields = [] - - self._fuzz_fields = set() - for field_name in fuzz_fields: - if field_name not in cls.fuzzable_fields: - raise NameError("Invalid fuzz field: %s" % field_name) - self._fuzz_fields.add(field_name) - - if not self._fuzz_fields and fuzz_all_if_empty: - # No fields were explicitly included - self._fuzz_fields = cls.fuzzable_fields - - self._verbose = verbose - - def _print(self, s): - if self._verbose: - print(s) - - def _get_fuzzy_field(self, name, val, type_): - """Return a possibly-fuzzed version of val, depending on self._fuzz_set - - If `name` is included in the set of fields to fuzz, the field value - will be fuzzed. Otherwise, val will be returned unmodified.""" - cls = self.__class__ - - if name not in self._fuzz_fields: - return val - - if type_ == 'char': - fuzzed_val = cls._fuzz_char(val) - elif type_ == 'i16': - fuzzed_val = cls._fuzz_i16(val) - elif type_ == 'i32': - fuzzed_val = cls._fuzz_i32(val) - elif type_ == 'str': - fuzzed_val = cls._fuzz_str(val) - else: - raise NotImplementedError("%s fuzzing not implemented" % type_) - - self._print("Fuzzed field %s from %r to %r" % (name, val, fuzzed_val)) - return fuzzed_val - - def _write_fuzzy_field(self, buf, name, val, type_): - """Write a message field after (possibly) mutating the value - - @param buf(StringIO): Message buffer to write to - @param name(str): Name of the field (for checking whether to fuzz) - @param val(type_): Value to write to field - @param type_(type): Type of field (for fuzzing and serializing) - """ - val = self._get_fuzzy_field(name, val, type_) - serialized = self._serialize_field(val, type_) - buf.write(serialized) - - def _flushHeaderMessage(self, buf, wout, wsz): - """Write a message for CLIENT_TYPE.HEADER - - This method writes a message using the same logic as - THeaderTransport._flushHeaderMessage - but mutates fields included in self._fuzz_fields - """ - transform_data = StringIO() - num_transforms = len(self._THeaderTransport__write_transforms) - for trans_id in self._THeaderTransport__write_transforms: - trans_id = self._get_fuzzy_field('transform_id', trans_id, 'i32') - transform_data.write(getVarint(trans_id)) - - # Add in special flags. - if self._THeaderTransport__identity: - id_version = self._get_fuzzy_field( - 'version', self.ID_VERSION, 'str') - self._THeaderTransport__write_headers[self.ID_VERSION_HEADER] = ( - id_version) - identity = self._get_fuzzy_field( - 'identity', self._THeaderTransport__identity, 'str') - self._THeaderTransport__write_headers[self.IDENTITY_HEADER] = ( - identity) - - info_data = StringIO() - - # Write persistent kv-headers - _flush_info_headers( - info_data, - self._THeaderTransport__write_persistent_headers, - INFO.PERSISTENT) - - # Write non-persistent kv-headers - _flush_info_headers( - info_data, - self._THeaderTransport__write_headers, - INFO.NORMAL) - - header_data = StringIO() - proto_id = self._get_fuzzy_field( - 'proto_id', self._THeaderTransport__proto_id, 'i32') - header_data.write(getVarint(proto_id)) - num_transforms = self._get_fuzzy_field( - 'num_transforms', num_transforms, 'i32') - header_data.write(getVarint(num_transforms)) - - header_size = (transform_data.tell() + - header_data.tell() + - info_data.tell()) - - padding_size = 4 - (header_size % 4) - - # Fuzz padding size, but do not let total header size exceed 2**16 - 1 - padding_size = min((2 ** 16 - 1) - header_size, - self._get_fuzzy_field('padding', padding_size, 'i16')) - header_size = header_size + padding_size - - wsz += header_size + 10 - - self._write_fuzzy_field(buf, 'length', wsz, 'i32') - self._write_fuzzy_field(buf, 'magic', HEADER_MAGIC >> 16, 'i16') - self._write_fuzzy_field( - buf, 'flags', self.header_flags(), 'i16') - self._write_fuzzy_field( - buf, 'seq_id', self.seq_id, 'i32') - self._write_fuzzy_field(buf, 'header_size', header_size // 4, 'i16') - - buf.write(header_data.getvalue()) - buf.write(transform_data.getvalue()) - buf.write(info_data.getvalue()) - - # Pad out the header with 0x00 - if 'padding_bytes' in self._fuzz_fields: - # Print that padding bytes are being fuzzed in favor of printing - # the value of each individual padding byte - self._print("Fuzzing %d padding bytes" % padding_size) - old_verbose, self._verbose = self._verbose, False - for _ in sm.xrange(padding_size): - self._write_fuzzy_field( - buf, 'padding_bytes', six.int2byte(0), 'char') - self._verbose = old_verbose - - self._write_fuzzy_field(buf, 'payload', wout, 'str') diff --git a/nebula2/fbthrift/transport/THeaderTransport.py b/nebula2/fbthrift/transport/THeaderTransport.py index 2a388a49..b87aa5ea 100644 --- a/nebula2/fbthrift/transport/THeaderTransport.py +++ b/nebula2/fbthrift/transport/THeaderTransport.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division @@ -25,12 +22,13 @@ import sys if sys.version_info[0] >= 3: from http import server + # pyre-fixme[11]: Annotation `server` is not defined as a type. BaseHTTPServer = server xrange = range from io import BytesIO as StringIO PY3 = True else: - import BaseHTTPServer + import BaseHTTPServer # @manual from cStringIO import StringIO PY3 = False @@ -39,7 +37,9 @@ from nebula2.fbthrift.Thrift import TApplicationException from nebula2.fbthrift.protocol.TBinaryProtocol import TBinaryProtocol -from .TTransport import TTransportException, TTransportBase, CReadableTransport +from nebula2.fbthrift.transport.TTransport import ( + TTransportException, TTransportBase, CReadableTransport +) from nebula2.fbthrift.protocol.TCompactProtocol import ( getVarint, readVarint, TCompactProtocol ) @@ -59,7 +59,24 @@ def compress(self, buf): def decompress(self, buf): raise TTransportException(TTransportException.INVALID_TRANSFORM, 'snappy module not available') - snappy = DummySnappy() # type: ignore + snappy = DummySnappy() + +# Import the zstd module if it is available +try: + import zstd # @manual +except ImportError: + # If zstd is not available, don't fail immediately. + # Only raise an error if we actually ever need to perform zstd + # compression. + class DummyZstd(object): + def ZstdCompressor(self, write_content_size): + raise TTransportException(TTransportException.INVALID_TRANSFORM, + 'zstd module not available') + + def ZstdDecompressor(self): + raise TTransportException(TTransportException.INVALID_TRANSFORM, + 'zstd module not available') + zstd = DummyZstd() # Definitions from THeader.h @@ -72,7 +89,6 @@ class CLIENT_TYPE: HTTP_SERVER = 3 HTTP_CLIENT = 4 FRAMED_COMPACT = 5 - HEADER_SASL = 6 HTTP_GET = 7 UNKNOWN = 8 UNFRAMED_COMPACT_DEPRECATED = 9 @@ -81,7 +97,6 @@ class CLIENT_TYPE: class HEADER_FLAG: SUPPORT_OUT_OF_ORDER = 0x01 DUPLEX_REVERSE = 0x08 - SASL = 0x10 class TRANSFORM: @@ -341,9 +356,7 @@ def read_header_format(self, sz, header_size, data): # Read the headers. Data for each header varies. for _ in range(0, num_headers): trans_id = readVarint(data) - if trans_id == TRANSFORM.ZLIB: - self.__read_transforms.insert(0, trans_id) - elif trans_id == TRANSFORM.SNAPPY: + if trans_id in (TRANSFORM.ZLIB, TRANSFORM.SNAPPY, TRANSFORM.ZSTD): self.__read_transforms.insert(0, trans_id) elif trans_id == TRANSFORM.HMAC: raise TApplicationException( @@ -390,6 +403,8 @@ def transform(self, buf): buf = zlib.compress(buf) elif trans_id == TRANSFORM.SNAPPY: buf = snappy.compress(buf) + elif trans_id == TRANSFORM.ZSTD: + buf = zstd.ZstdCompressor(write_content_size=True).compress(buf) else: raise TTransportException(TTransportException.INVALID_TRANSFORM, "Unknown transform during send") @@ -401,6 +416,8 @@ def untransform(self, buf): buf = zlib.decompress(buf) elif trans_id == TRANSFORM.SNAPPY: buf = snappy.decompress(buf) + elif trans_id == TRANSFORM.ZSTD: + buf = zstd.ZstdDecompressor().decompress(buf) if trans_id not in self.__write_transforms: self.__write_transforms.append(trans_id) return buf diff --git a/nebula2/fbthrift/transport/THttpClient.py b/nebula2/fbthrift/transport/THttpClient.py index f004c405..9631999f 100644 --- a/nebula2/fbthrift/transport/THttpClient.py +++ b/nebula2/fbthrift/transport/THttpClient.py @@ -1,28 +1,25 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals -from .TTransport import * +from nebula2.fbthrift.transport.TTransport import * import os import socket @@ -33,20 +30,22 @@ from io import BytesIO as StringIO from urllib import parse from http import client + # pyre-fixme[11]: Annotation `parse` is not defined as a type. urlparse = parse urllib = parse + # pyre-fixme[11]: Annotation `client` is not defined as a type. httplib = client else: from cStringIO import StringIO import urlparse - import httplib + import httplib # @manual import urllib class THttpClient(TTransportBase): """Http implementation of TTransport base.""" - def __init__(self, uri_or_host, port=None, path=None): + def __init__(self, uri_or_host, port=None, path=None, ssl_context=None): """THttpClient supports two different types constructor parameters. THttpClient(host, port, path) - deprecated @@ -82,6 +81,7 @@ def __init__(self, uri_or_host, port=None, path=None): self.__http = None self.__timeout = None self.__custom_headers = None + self.ssl_context = ssl_context def open(self): if self.scheme == 'http': @@ -89,6 +89,7 @@ def open(self): timeout=self.__timeout) else: self.__http = httplib.HTTPSConnection(self.host, self.port, + context=self.ssl_context, timeout=self.__timeout) def close(self): diff --git a/nebula2/fbthrift/transport/TSSLSocket.py b/nebula2/fbthrift/transport/TSSLSocket.py index fa58a032..42beaa8f 100644 --- a/nebula2/fbthrift/transport/TSSLSocket.py +++ b/nebula2/fbthrift/transport/TSSLSocket.py @@ -1,10 +1,26 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe + from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals -from .TSocket import * -from .TTransport import * +from nebula2.fbthrift.transport.TSocket import * +from nebula2.fbthrift.transport.TTransport import * import socket import ssl import traceback @@ -57,7 +73,7 @@ def _best_possible_default_version(): def _warn_if_legacy(): global _has_warned if not _has_warned: - logging.warn( + logging.warning( 'You are using an old version of Python (< 2.7.9) that is ' 'limited to an old version of TLS (1.0) with known security ' 'vulnerabilities. ' @@ -85,13 +101,17 @@ def _warn_if_insecure_version_specified(version): if version is None: return - blacklist = [ssl.PROTOCOL_SSLv2, ssl.PROTOCOL_SSLv3, ssl.PROTOCOL_TLSv1] + blacklist = [ssl.PROTOCOL_TLSv1] + if hasattr(ssl, 'PROTOCOL_SSLv2'): + blacklist.append(ssl.PROTOCOL_SSLv2) + if hasattr(ssl, 'PROTOCOL_SSLv3'): + blacklist.append(ssl.PROTOCOL_SSLv3) if hasattr(ssl, 'PROTOCOL_TLSv1_1'): blacklist.append(ssl.PROTOCOL_TLSv1_1) if version in blacklist: - logging.warn( + logging.warning( 'You are constructing TSSLSocket and intentionally specifying ' 'a weak, vulnerable ssl_version on a platform that has secure ' 'versions available! Leave ssl_version unspecified and we will ' @@ -102,6 +122,7 @@ def _get_ssl_socket(socket, ssl_version, cert_reqs=ssl.CERT_NONE, ca_certs=None, keyfile=None, certfile=None, disable_weaker_versions=True): ctx = ssl.SSLContext(ssl_version) + ctx.verify_mode = cert_reqs if certfile is not None: ctx.load_cert_chain( certfile=certfile, @@ -223,7 +244,7 @@ def open(self): sslh.close() raise TTransportException(TTransportException.NOT_OPEN, "failed to verify certificate name") - self.handle = sslh + self.setHandle(sslh) except ssl.SSLError as e: raise TTransportException(TTransportException.NOT_OPEN, "SSL error during handshake: " + str(e)) @@ -273,9 +294,10 @@ class TSSLServerSocket(TServerSocket): This uses the ssl module's wrap_socket() method to provide SSL negotiated encryption. """ - SSL_VERSION = ssl.PROTOCOL_TLSv1 - def __init__(self, port=9090, certfile='cert.pem', unix_socket=None): + def __init__(self, port=9090, ssl_version=ssl.PROTOCOL_TLSv1, + cert_reqs=ssl.CERT_NONE, ca_certs=None, certfile='cert.pem', + unix_socket=None): """Initialize a TSSLServerSocket @param certfile: The filename of the server certificate file, defaults @@ -285,7 +307,8 @@ def __init__(self, port=9090, certfile='cert.pem', unix_socket=None): @type port: int """ self.setCertfile(certfile) - self.setCertReqs(ssl.CERT_NONE, None) + self.setCertReqs(cert_reqs, ca_certs) + self.ssl_version = ssl_version TServerSocket.__init__(self, port, unix_socket) def setCertfile(self, certfile): @@ -317,7 +340,7 @@ def accept(self): client = ssl.wrap_socket(plain_client, certfile=self.certfile, server_side=True, - ssl_version=self.SSL_VERSION, + ssl_version=self.ssl_version, cert_reqs=self.cert_reqs, ca_certs=self.ca_certs) except ssl.SSLError: diff --git a/nebula2/fbthrift/transport/TSSLSocketOverHttpTunnel.py b/nebula2/fbthrift/transport/TSSLSocketOverHttpTunnel.py index 6c588e89..d12c650e 100644 --- a/nebula2/fbthrift/transport/TSSLSocketOverHttpTunnel.py +++ b/nebula2/fbthrift/transport/TSSLSocketOverHttpTunnel.py @@ -1,3 +1,17 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + from __future__ import absolute_import from __future__ import division from __future__ import print_function @@ -6,8 +20,8 @@ import socket import ssl -from .TSocketOverHttpTunnel import TSocketOverHttpTunnel -from .TTransport import TTransportException +from nebula2.fbthrift.transport.TSocketOverHttpTunnel import TSocketOverHttpTunnel +from nebula2.fbthrift.transport.TTransport import TTransportException class TSSLSocketOverHttpTunnel(TSocketOverHttpTunnel): def __init__(self, host, port, proxy_host, proxy_port, diff --git a/nebula2/fbthrift/transport/TSocket.py b/nebula2/fbthrift/transport/TSocket.py index ba2961ec..93c0037d 100644 --- a/nebula2/fbthrift/transport/TSocket.py +++ b/nebula2/fbthrift/transport/TSocket.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division @@ -23,7 +20,7 @@ from __future__ import unicode_literals -from .TTransport import TTransportBase, TTransportException, \ +from nebula2.fbthrift.transport.TTransport import TTransportBase, TTransportException, \ TServerTransportBase import os import errno @@ -37,7 +34,15 @@ import fcntl except ImportError: # Windows doesn't have this module - fcntl = None # type: ignore + fcntl = None + + +def py2_compatible_process_time(): + if sys.version_info.major >= 3 and sys.version_info.minor >= 3: + return time.process_time() + else: + return time.clock() + class ConnectionEpoll: """ epoll is preferred over select due to its efficiency and ability to @@ -71,11 +76,13 @@ def process(self, timeout): # poll() invokes a "long" syscall that will be interrupted by any signal # that comes in, causing an EINTR error. If this happens, avoid dying # horribly by trying again with the appropriately shortened timout. - deadline = time.clock() + float(timeout or 0) + process_time = py2_compatible_process_time() + + deadline = process_time + float(timeout or 0) poll_timeout = float(timeout or -1) while True: if timeout is not None and timeout > 0: - poll_timeout = max(0, deadline - time.clock()) + poll_timeout = max(0, deadline - py2_compatible_process_time()) try: msgs = self.epoll.poll(timeout=poll_timeout) break @@ -128,11 +135,11 @@ def process(self, timeout): # signal that comes in, causing an EINTR error. If this happens, # avoid dying horribly by trying again with the appropriately # shortened timout. - deadline = time.clock() + float(timeout or 0) + deadline = py2_compatible_process_time() + float(timeout or 0) poll_timeout = timeout if timeout is None or timeout > 0 else None while True: if timeout is not None and timeout > 0: - poll_timeout = max(0, deadline - time.clock()) + poll_timeout = max(0, deadline - py2_compatible_process_time()) try: return select.select(list(self.readable), list(self.writable), list(self.readable), poll_timeout) @@ -277,7 +284,7 @@ def open(self): self.setCloseOnExec(self.close_on_exec) try: handle.connect(address) - except socket.error as e: + except socket.error: self.close() if res is not res0[-1]: continue diff --git a/nebula2/fbthrift/transport/TSocketOverHttpTunnel.py b/nebula2/fbthrift/transport/TSocketOverHttpTunnel.py index 96867d5b..35a124ca 100644 --- a/nebula2/fbthrift/transport/TSocketOverHttpTunnel.py +++ b/nebula2/fbthrift/transport/TSocketOverHttpTunnel.py @@ -1,10 +1,24 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals -from .TSocket import TSocket -from .TTransport import TTransportException +from nebula2.fbthrift.transport.TSocket import TSocket +from nebula2.fbthrift.transport.TTransport import TTransportException import socket diff --git a/nebula2/fbthrift/transport/TSocketTest.py b/nebula2/fbthrift/transport/TSocketTest.py index b37375dd..89a0d901 100644 --- a/nebula2/fbthrift/transport/TSocketTest.py +++ b/nebula2/fbthrift/transport/TSocketTest.py @@ -1,3 +1,17 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + from __future__ import absolute_import from __future__ import division from __future__ import print_function @@ -21,7 +35,7 @@ def test_usage_as_context_manager(self): Asserts that both TSocket and TServerSocket can be used with `with` and that their resources are disposed of at the close of the `with`. """ - text = "hi" # sample text to send over the wire + text = b"hi" # sample text to send over the wire with TSocket.TServerSocket(port=0, family=socket.AF_INET6) as server: addr = server.getSocketNames()[0] with TSocket.TSocket(host=addr[0], port=addr[1]) as conn: @@ -97,7 +111,7 @@ def test_deprecated_str_form_of_port(self): # Make sure that the deprecated form of the `port` parameter is # accepted in TServerSocket and TSocket. port = "0" - text = "hi" # sample text to send over the wire + text = b"hi" # sample text to send over the wire # NB: unfortunately unittest.TestCase.assertWarns isn't available until # py3. with TSocket.TServerSocket(port=port, family=socket.AF_INET6) as server: @@ -119,7 +133,7 @@ def test_bad_port(self): pass def test_unix_socket(self): - text = "hi" # sample text to send over the wire + text = b"hi" # sample text to send over the wire with tempfile.NamedTemporaryFile(delete=True) as fh: unix_socket = fh.name with TSocket.TServerSocket(unix_socket=unix_socket) as server: diff --git a/nebula2/fbthrift/transport/TTransport.py b/nebula2/fbthrift/transport/TTransport.py index cfbdb4fa..8ea15918 100644 --- a/nebula2/fbthrift/transport/TTransport.py +++ b/nebula2/fbthrift/transport/TTransport.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division diff --git a/nebula2/fbthrift/transport/TTwisted.py b/nebula2/fbthrift/transport/TTwisted.py deleted file mode 100644 index 2da18977..00000000 --- a/nebula2/fbthrift/transport/TTwisted.py +++ /dev/null @@ -1,253 +0,0 @@ -# -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. -# - -from __future__ import absolute_import -from __future__ import division -from __future__ import print_function -from __future__ import unicode_literals - -from zope.interface import implements, Interface, Attribute -from struct import unpack -from twisted.internet.protocol import Protocol, ServerFactory, ClientFactory, \ - connectionDone -from twisted.internet import defer -from twisted.protocols import basic -from twisted.python import log -from nebula2.fbthrift.protocol.THeaderProtocol import THeaderProtocolFactory -from nebula2.fbthrift.server import TServer -from nebula2.fbthrift.transport import TTransport - -import sys -if sys.version_info[0] >= 3: - from io import StringIO -else: - from cStringIO import StringIO - - -class TMessageSenderTransport(TTransport.TTransportBase): - - def __init__(self): - self.__wbuf = StringIO() - - def write(self, buf): - self.__wbuf.write(buf) - - def flush(self): - msg = self.__wbuf.getvalue() - self.__wbuf = StringIO() - self.sendMessage(msg) - - def sendMessage(self, message): - raise NotImplementedError - - -class TCallbackTransport(TMessageSenderTransport): - - def __init__(self, func): - TMessageSenderTransport.__init__(self) - self.func = func - - def sendMessage(self, message): - self.func(message) - - -class ThriftClientProtocol(basic.Int32StringReceiver): - MAX_LENGTH = 1 << 24 - - def __init__(self, client_class, iprot_factory, oprot_factory=None): - self._client_class = client_class - self._iprot_factory = iprot_factory - if oprot_factory is None: - self._oprot_factory = iprot_factory - else: - self._oprot_factory = oprot_factory - - self._errormsg = None - self.recv_map = {} - self.started = defer.Deferred() - - def dispatch(self, msg): - self.sendString(msg) - - def connectionMade(self): - tmo = TCallbackTransport(self.dispatch) - self.client = self._client_class(tmo, self._oprot_factory) - self.started.callback(self.client) - - def connectionLost(self, reason=connectionDone): - if sys.version_info[0] >= 3: - client_req_iter = self.client._reqs.items() - else: - client_req_iter = self.client._reqs.items() - for _, v in client_req_iter: - tex = TTransport.TTransportException( - type=TTransport.TTransportException.END_OF_FILE, - message=self._errormsg or 'Connection closed') - v.errback(tex) - - def stringReceived(self, frame): - tr = TTransport.TMemoryBuffer(frame) - iprot = self._iprot_factory.getProtocol(tr) - (fname, mtype, rseqid) = iprot.readMessageBegin() - - try: - method = self.recv_map[fname] - except KeyError: - method = getattr(self.client, 'recv_' + fname) - self.recv_map[fname] = method - - method(iprot, mtype, rseqid) - - def lengthLimitExceeded(self, length): - self._errormsg = 'Received frame too large (%s > %s)' % ( - length, self.MAX_LENGTH) - self.transport.loseConnection() - - -class TwistedRpcConnectionContext(TServer.TConnectionContext): - - def __init__(self, client_socket): - self._client_socket = client_socket - - def getPeerName(self): - return self._client_socket.getpeername() - - -class ThriftServerProtocol(basic.Int32StringReceiver): - MAX_LENGTH = 1 << 24 - - def dispatch(self, msg): - self.sendString(msg) - - def processError(self, error): - self.transport.loseConnection() - - def processOk(self, _, tmo): - msg = tmo.getvalue() - - if len(msg) > 0: - self.dispatch(msg) - - def stringReceived(self, frame): - tmi = TTransport.TMemoryBuffer(frame) - tmo = TTransport.TMemoryBuffer() - - iprot = self.factory.iprot_factory.getProtocol(tmi) - oprot = self.factory.oprot_factory.getProtocol(tmo) - - server_ctx = TwistedRpcConnectionContext(self.transport.socket) - d = self.factory.processor.process(iprot, oprot, server_ctx) - d.addCallbacks(self.processOk, self.processError, - callbackArgs=(tmo,)) - - -class ThriftHeaderServerProtocol(Protocol): - MAX_LENGTH = 1 << 24 - recvd = b"" - - def dataReceived(self, recvd): - self.recvd = self.recvd + recvd - while len(self.recvd) >= 4: - length, = unpack(b"!I", self.recvd[:4]) - if length > self.MAX_LENGTH: - self.transport.loseConnection() - return - if len(self.recvd) < length + 4: - break - packet = self.recvd[0:4 + length] - self.recvd = self.recvd[4 + length:] - self.stringReceived(packet) - - def processError(self, error): - self.transport.loseConnection() - - def processOk(self, _, tmo): - msg = tmo.getvalue() - - if len(msg) > 0: - # HeaderTransport will have already done msg length checking, - # and already adds the frame size. Write directly. - self.transport.write(msg) - - def stringReceived(self, frame): - tmi = TTransport.TMemoryBuffer(frame) - iprot = self.factory.iprot_factory.getProtocol(tmi) - oprot = iprot - tmo = tmi - - server_ctx = TwistedRpcConnectionContext(self.transport.socket) - d = self.factory.processor.process(iprot, oprot, server_ctx) - d.addCallbacks(self.processOk, self.processError, - callbackArgs=(tmo,)) - - -class IThriftServerFactory(Interface): - - processor = Attribute("Thrift processor") - - iprot_factory = Attribute("Input protocol factory") - - oprot_factory = Attribute("Output protocol factory") - - -class IThriftClientFactory(Interface): - - client_class = Attribute("Thrift client class") - - iprot_factory = Attribute("Input protocol factory") - - oprot_factory = Attribute("Output protocol factory") - - -class ThriftServerFactory(ServerFactory): - - implements(IThriftServerFactory) - - protocol = ThriftServerProtocol - - def __init__(self, processor, iprot_factory, oprot_factory=None): - self.processor = processor - self.iprot_factory = iprot_factory - if oprot_factory is None: - self.oprot_factory = iprot_factory - else: - self.oprot_factory = oprot_factory - - if isinstance(iprot_factory, THeaderProtocolFactory): - self.protocol = ThriftHeaderServerProtocol - -class ThriftClientFactory(ClientFactory): - - implements(IThriftClientFactory) - - protocol = ThriftClientProtocol - - def __init__(self, client_class, iprot_factory, oprot_factory=None): - self.client_class = client_class - self.iprot_factory = iprot_factory - if oprot_factory is None: - self.oprot_factory = iprot_factory - else: - self.oprot_factory = oprot_factory - - def buildProtocol(self, addr): - p = self.protocol(self.client_class, self.iprot_factory, - self.oprot_factory) - p.factory = self - return p diff --git a/nebula2/fbthrift/transport/__init__.py b/nebula2/fbthrift/transport/__init__.py index 1bf6e254..8daf2005 100644 --- a/nebula2/fbthrift/transport/__init__.py +++ b/nebula2/fbthrift/transport/__init__.py @@ -1,20 +1,13 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://www.apache.org/licenses/LICENSE-2.0 # -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. -# - -__all__ = ['TServer', 'TNonblockingServer'] +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. diff --git a/nebula2/fbthrift/util/BytesStrIO.py b/nebula2/fbthrift/util/BytesStrIO.py index e8ba5f10..1e96e19c 100644 --- a/nebula2/fbthrift/util/BytesStrIO.py +++ b/nebula2/fbthrift/util/BytesStrIO.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division diff --git a/nebula2/fbthrift/util/Decorators.py b/nebula2/fbthrift/util/Decorators.py index 093772c3..cd7e34f9 100644 --- a/nebula2/fbthrift/util/Decorators.py +++ b/nebula2/fbthrift/util/Decorators.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division @@ -71,11 +68,12 @@ def make_unknown_function_exception(name): ) -def process_main(twisted=False, asyncio=False): +def process_main(asyncio=False): """Decorator for process method.""" if asyncio and six.PY3: from asyncio import Future elif asyncio: + # pyre-fixme[21]: Could not find module `trollius`. from trollius import Future def _decorator(func): @@ -84,16 +82,13 @@ def nested(self, iprot, oprot, server_ctx=None): name, seqid = self.readMessageBegin(iprot) if self.doesKnowFunction(name): ret = self.callFunction(name, seqid, iprot, oprot, server_ctx) - if twisted or asyncio: + if asyncio: return ret # a Deferred/Future return True self.skipMessageStruct(iprot) exc = make_unknown_function_exception(name) self.writeException(oprot, name, seqid, exc) - if twisted: - from twisted.internet import defer - return defer.succeed(None) if asyncio: fut = Future(loop=self._loop) fut.set_result(None) @@ -140,7 +135,7 @@ def reset_request_context(processor): processor._handler.setRequestContext(None) -def process_method(argtype, oneway=False, twisted=False, asyncio=False): +def process_method(argtype, oneway=False, asyncio=False): """Decorator for process_xxx methods.""" def _decorator(func): def nested(self, seqid, iprot, oprot, server_ctx): @@ -164,7 +159,7 @@ def nested(self, seqid, iprot, oprot, server_ctx): if not oneway: self.writeException(oprot, fn_name, seqid, result) else: - if asyncio or twisted: + if asyncio: return func(self, args, handler_ctx, seqid, oprot, fn_name) result = func(self, args, handler_ctx) @@ -321,7 +316,7 @@ def write_results_after_future( reply_type = TMessageType.REPLY except TException as e: for exc_name, exc_type in known_exceptions.items(): - if type(e) is exc_type: + if isinstance(e, exc_type): setattr(result, exc_name, e) reply_type = TMessageType.REPLY event_handler.handlerException(handler_ctx, fn_name, e) @@ -337,28 +332,6 @@ def write_results_after_future( event_handler, handler_ctx, fn_name, oprot) -def write_results_success_callback(func): - """Decorator for twisted write_results_success_xxx methods. - No need to call func so it can be empty. - """ - def nested(self, success, result, seqid, oprot, handler_ctx): - fn_name = func.__name__.split('_', 3)[-1] - result.success = success - self.writeReply(oprot, handler_ctx, fn_name, seqid, result) - - return nested - - -def write_results_exception_callback(func): - """Decorator for twisted write_results_exception_xxx methods.""" - def nested(self, error, result, seqid, oprot, handler_ctx): - fn_name = func.__name__.split('_', 3)[-1] - _, result = func(self, error, result, handler_ctx) - self.writeReply(oprot, handler_ctx, fn_name, seqid, result) - - return nested - - @contextlib.contextmanager def protocol_manager(protocol): try: diff --git a/nebula2/fbthrift/util/Recursive.py b/nebula2/fbthrift/util/Recursive.py index d459b373..3493bc6f 100644 --- a/nebula2/fbthrift/util/Recursive.py +++ b/nebula2/fbthrift/util/Recursive.py @@ -1,3 +1,19 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe + from __future__ import absolute_import from __future__ import division from __future__ import print_function diff --git a/nebula2/fbthrift/util/Serializer.py b/nebula2/fbthrift/util/Serializer.py index 44045ab4..0f66e49b 100644 --- a/nebula2/fbthrift/util/Serializer.py +++ b/nebula2/fbthrift/util/Serializer.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division @@ -28,6 +25,8 @@ from nebula2.fbthrift.protocol import THeaderProtocol +# pyre-fixme[34]: `Variable[AnyStr <: [str, bytes]]` isn't present in the function's +# parameters. def serialize(protocol_factory, thr): # type: (Any, Any) -> AnyStr """Convenience method for serializing objects using the given @@ -50,6 +49,7 @@ def deserialize(protocol_factory, data, thr_out): argument.""" transport = TTransport.TMemoryBuffer(data) try: + # pyre-fixme[16]: `T` has no attribute `thrift_spec`. protocol = protocol_factory.getProtocol(transport, thr_out.thrift_spec) # noqa: T484 except TypeError: protocol = protocol_factory.getProtocol(transport) @@ -58,5 +58,6 @@ def deserialize(protocol_factory, data, thr_out): # protocol is, as well as looking at transforms, etc. protocol.trans.readFrame(0) protocol.reset_protocol() + # pyre-fixme[16]: `T` has no attribute `read`. thr_out.read(protocol) # noqa: T484 return thr_out diff --git a/nebula2/fbthrift/util/TCppServerTestManager.py b/nebula2/fbthrift/util/TCppServerTestManager.py index b0a42f87..f351ec8d 100644 --- a/nebula2/fbthrift/util/TCppServerTestManager.py +++ b/nebula2/fbthrift/util/TCppServerTestManager.py @@ -1,3 +1,17 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + from __future__ import absolute_import from __future__ import division from __future__ import print_function @@ -16,7 +30,7 @@ class TCppServerTestManager(object): Basic example: from mylib import MyServiceHandler - from thrift.util.TCppServerTestManager import TCppServerTestManager + from nebula2.fbthrift.util.TCppServerTestManager import TCppServerTestManager class MyServiceTest(unittest.TestCase) diff --git a/nebula2/fbthrift/util/TCppServerTestManagerTest.py b/nebula2/fbthrift/util/TCppServerTestManagerTest.py index 9319170a..ce2c6713 100644 --- a/nebula2/fbthrift/util/TCppServerTestManagerTest.py +++ b/nebula2/fbthrift/util/TCppServerTestManagerTest.py @@ -1,3 +1,17 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + from __future__ import absolute_import from __future__ import division from __future__ import print_function diff --git a/nebula2/fbthrift/util/TValidator.py b/nebula2/fbthrift/util/TValidator.py index ccb96188..0bcb0bb1 100644 --- a/nebula2/fbthrift/util/TValidator.py +++ b/nebula2/fbthrift/util/TValidator.py @@ -1,21 +1,18 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. +# http://www.apache.org/licenses/LICENSE-2.0 # +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe from __future__ import absolute_import from __future__ import division diff --git a/nebula2/fbthrift/util/__init__.py b/nebula2/fbthrift/util/__init__.py index 7c6f3418..4d37d3f5 100644 --- a/nebula2/fbthrift/util/__init__.py +++ b/nebula2/fbthrift/util/__init__.py @@ -1,36 +1,38 @@ +# Copyright (c) Facebook, Inc. and its affiliates. # -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://www.apache.org/licenses/LICENSE-2.0 # -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. -# -from __future__ import absolute_import -from __future__ import division -from __future__ import print_function -from __future__ import unicode_literals -from collections import namedtuple, OrderedDict -from future.utils import iteritems +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe + +from __future__ import absolute_import, division, print_function, unicode_literals + +from collections import OrderedDict, namedtuple from nebula2.fbthrift.Thrift import TType -__all__ = ['create_client', 'Serializer', 'struct_to_dict', 'parse_struct_spec'] -StructField = namedtuple('StructField', - 'id type name type_args default req_type') + +__all__ = ["create_client", "Serializer", "struct_to_dict", "parse_struct_spec"] +StructField = namedtuple("StructField", "id type name type_args default req_type") -def create_client(client_klass, host=None, port=None, client_type=None): +def create_client( + client_klass, + host=None, + port=None, + client_type=None, + path=None, + timeout=None, +): """ Given a thrift client class, and a host/port return a client using HeaderTransport @@ -38,11 +40,14 @@ def create_client(client_klass, host=None, port=None, client_type=None): from nebula2.fbthrift.transport.TSocket import TSocket from nebula2.fbthrift.protocol.THeaderProtocol import THeaderProtocol - sock = TSocket(host=host, port=port) + sock = TSocket(host=host, port=port, unix_socket=path) + sock.setTimeout(timeout) protocol = THeaderProtocol( sock, - client_types=client_type, # We accept the same as our inital send_ - client_type=client_type # Used for the inital send_ + client_types=[client_type] + if client_type + else None, # We accept the same as our inital send_ + client_type=client_type, # Used for the inital send_ ) sock.open() return client_klass(protocol) @@ -96,16 +101,16 @@ def struct_to_dict(struct, defaults=False): sub_dict = struct_to_dict(value, defaults=defaults) if sub_dict or defaults: # Do not include empty sub structs adict[field.name] = sub_dict - elif field.type == TType.LIST or field.type == TType.SET: - sub_list = __list_to_dict(value, - field.type_args, - defaults=defaults) + elif field.type == TType.LIST: + sub_list = __list_to_dict(value, field.type_args, defaults=defaults) if sub_list or defaults: adict[field.name] = sub_list + elif field.type == TType.SET: + sub_set = __set_to_dict(value, field.type_args, defaults=defaults) + if sub_set or defaults: + adict[field.name] = sub_set elif field.type == TType.MAP: - sub_map = __map_to_dict(value, - field.type_args, - defaults=defaults) + sub_map = __map_to_dict(value, field.type_args, defaults=defaults) if sub_map or defaults: adict[field.name] = sub_map else: @@ -121,7 +126,7 @@ def __list_to_dict(alist, type_args, defaults=False): convert it into a dict :param alist: a list or set :param defaults: return default values - :return: OrderedDict + :return: List """ if not alist: return alist @@ -129,26 +134,59 @@ def __list_to_dict(alist, type_args, defaults=False): element_type = type_args[0] if element_type == TType.STRUCT: return [struct_to_dict(element, defaults=defaults) for element in alist] - if element_type == TType.LIST or element_type == TType.SET: - sub_list = [__list_to_dict(element, type_args[1], defaults=defaults) - for element in alist] - return set(sub_list) if element_type == TType.SET else sub_list + if element_type == TType.LIST: + return [ + __list_to_dict(element, type_args[1], defaults=defaults) + for element in alist + ] + if element_type == TType.SET: + return [ + __set_to_dict(element, type_args[1], defaults=defaults) for element in alist + ] else: return alist +def __set_to_dict(aset, type_args, defaults=False): + """ + Given a python set-like collection, potentially containing Thrift Structs + and recursively parsing the elements + :param aset: a set + :param defaults: return default values + :return: Set + """ + if not aset: + return aset + + element_type = type_args[0] + if element_type == TType.STRUCT: + return {struct_to_dict(element, defaults=defaults) for element in aset} + if element_type == TType.LIST: + return { + __list_to_dict(element, type_args[1], defaults=defaults) + for element in aset + } + if element_type == TType.SET: + return { + __set_to_dict(element, type_args[1], defaults=defaults) for element in aset + } + else: + return aset + + def __map_to_dict(amap, type_args, defaults=False): """ Given a python dictionary, potentially containing Thrift Structs, convert it into a dict - :param alist: a list or set + :param amap: a map :param defaults: return default values - :return: OrderedDict + :return: Dict """ if not amap: return amap - keys, values = zip(*iteritems(amap)) + keys, values = zip(*amap.items()) + keys = __list_to_dict(keys, type_args[:2], defaults=defaults) values = __list_to_dict(values, type_args[2:4], defaults=defaults) diff --git a/nebula2/fbthrift/util/async_common.py b/nebula2/fbthrift/util/async_common.py index f0f1ba77..6a1e4176 100644 --- a/nebula2/fbthrift/util/async_common.py +++ b/nebula2/fbthrift/util/async_common.py @@ -1,3 +1,19 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe + """ Common base for asyncio and Trollius (the Python 2 asyncio backport). Ideally this would be all that's necessary but we can't use the async/await @@ -33,9 +49,10 @@ TMessageType, ) -if six.PY3 and not nebula2.fbthrift.trollius: +if six.PY3: import asyncio else: + # pyre-fixme[21]: Could not find module `trollius`. import trollius as asyncio # We support the deprecated FRAMED transport for old fb303 @@ -152,8 +169,7 @@ def __init__(self, trans, proto, loop): self._consumer = self._loop.create_task(self._send()) self._producers = [] - @asyncio.coroutine - def _send(self): + async def _send(self): raise NotImplementedError def send_message(self, msg): @@ -207,6 +223,7 @@ def __del__(self): ) +# pyre-fixme[11]: Annotation `Protocol` is not defined as a type. class FramedProtocol(asyncio.Protocol): """Unpacks Thrift frames and reads them asynchronously.""" @@ -214,8 +231,7 @@ def __init__(self, loop=None): self.loop = loop or asyncio.get_event_loop() self.recvd = b"" - @asyncio.coroutine - def message_received(self, frame): + async def message_received(self, frame): raise NotImplementedError def data_received(self, data): @@ -281,12 +297,10 @@ def __init__( self.pending_tasks = {} self.transport = None # TTransport wrapping an asyncio.Transport - @asyncio.coroutine - def message_received(self, frame): + async def message_received(self, frame): self._handle_message(frame, clear_timeout=True) - @asyncio.coroutine - def timeout_task(self, fname, delay): + async def timeout_task(self, fname, delay): # timeout_task must to be implemented in a subclass raise NotImplementedError @@ -366,8 +380,8 @@ def _handle_message_received(self, iprot, fname, mtype, seqid): try: method(iprot, mtype, seqid) except ( - asyncio.futures.InvalidStateError, asyncio.CancelledError, + asyncio.InvalidStateError, ) as e: logger.warning("Method %r cancelled: %s", fname, str(e)) diff --git a/nebula2/fbthrift/util/asyncio.py b/nebula2/fbthrift/util/asyncio.py index 4eeebd7c..6ac199c0 100644 --- a/nebula2/fbthrift/util/asyncio.py +++ b/nebula2/fbthrift/util/asyncio.py @@ -1,4 +1,17 @@ #!/usr/bin/env python3 +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. import asyncio @@ -39,7 +52,8 @@ def create_client( sock=None, loop=None, timeouts=None, - client_type=None + client_type=None, + ssl=None, ): """ create an asyncio thrift client and return an async context @@ -78,6 +92,7 @@ def create_client( host=host, port=port, sock=sock, + ssl=ssl, ) return async_protocol_manager(coro) diff --git a/nebula2/fbthrift/util/converter.py b/nebula2/fbthrift/util/converter.py new file mode 100644 index 00000000..d5e44c1c --- /dev/null +++ b/nebula2/fbthrift/util/converter.py @@ -0,0 +1,74 @@ +#! /usr/bin/python3 +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe + +from typing import Any, Type, TypeVar + +from nebula2.fbthrift.py3.types import Enum, Struct +from nebula2.fbthrift.Thrift import TType +from nebula2.fbthrift.util import parse_struct_spec + + +T = TypeVar("T") + + +def to_py_struct(cls: Type[T], obj: Struct) -> T: + return _to_py_struct(cls, obj) + + +def _to_py_struct(cls: Type[T], obj: Struct) -> T: + # pyre-fixme[16]: `T` has no attribute `isUnion`. + if cls.isUnion(): + return cls( + **{ + field.name: _to_py_field( + field.type, field.type_args, getattr(obj, field.name) + ) + for field in parse_struct_spec(cls) + # pyre-fixme[16]: `Struct` has no attribute `type`. + if field.name == obj.type.name + } + ) + else: + return cls( + **{ + field.name: _to_py_field( + field.type, field.type_args, getattr(obj, field.name) + ) + for field in parse_struct_spec(cls) + } + ) + + +def _to_py_field(field_type: TType, type_args: Any, obj: Any) -> Any: + if obj is None: + return None + if field_type == TType.STRUCT: + return _to_py_struct(type_args[0], obj) + if field_type == TType.LIST: + return [_to_py_field(type_args[0], type_args[1], elem) for elem in obj] + if field_type == TType.SET: + return {_to_py_field(type_args[0], type_args[1], elem) for elem in obj} + if field_type == TType.MAP: + return { + _to_py_field(type_args[0], type_args[1], k): _to_py_field( + type_args[2], type_args[3], v + ) + for k, v in obj.items() + } + if isinstance(obj, Enum): + return obj.value + return obj diff --git a/nebula2/fbthrift/util/fuzzer.py b/nebula2/fbthrift/util/fuzzer.py index d54ca3b3..97b923c2 100644 --- a/nebula2/fbthrift/util/fuzzer.py +++ b/nebula2/fbthrift/util/fuzzer.py @@ -1,3 +1,19 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe + """ Fuzz Testing for Thrift Services """ @@ -22,7 +38,8 @@ from six.moves.urllib.parse import urlparse try: - from ServiceRouter import ConnConfigs, ServiceOptions, ServiceRouter + # pyre-fixme[21]: Could not find module `ServiceRouter`. + from ServiceRouter import ConnConfigs, ServiceOptions, ServiceRouter # @manual SR_AVAILABLE = True except ImportError: SR_AVAILABLE = False @@ -30,8 +47,7 @@ from nebula2.fbthrift import Thrift from nebula2.fbthrift.transport import TTransport, TSocket, TSSLSocket, THttpClient from nebula2.fbthrift.protocol import TBinaryProtocol, TCompactProtocol, THeaderProtocol - -from . import randomizer +from nebula2.fbthrift.util import randomizer if six.PY3: from importlib.machinery import SourceFileLoader @@ -364,7 +380,7 @@ def load_service(self): parent_path, service_filename = os.path.split(service_path) service_name = service_filename[:-3] # Truncate extension - logging.info("Service name: %s" (service_name)) + logging.info("Service name: %s" % (service_name)) parent_path = os.path.dirname(service_path) ttypes_path = os.path.join(parent_path, 'ttypes.py') @@ -439,47 +455,48 @@ def load_methods(self, exclude_ifaces=None): """Load a service's methods. If exclude_ifaces is not None, it should be a collection and only - the method from thrift interfaces not included in that collection will + methods from nebula2.fbthrift interfaces not included in that collection will be considered.""" exclude_ifaces = exclude_ifaces or [] - # Can only have single inheritance in thrift - thrift_inheritance_chain = self.service.Iface.__mro__ + pred = inspect.isfunction if six.PY3 else inspect.ismethod methods = {} - # We iterate inheritance from parent to base so we can override - # parent's methods with the base's one. - for klass in thrift_inheritance_chain[::-1]: - if klass in exclude_ifaces: + exclude_methods = [] + + for klass in exclude_ifaces: + exclude_methods.extend(inspect.getmembers(klass, predicate=pred)) + + klass_methods = inspect.getmembers(self.service.Iface, predicate=pred) + + for method_name, method in klass_methods: + if (method_name, method) in exclude_methods: continue - pred = inspect.isfunction if six.PY3 else inspect.ismethod - klass_methods = inspect.getmembers(klass, predicate=pred) - module = inspect.getmodule(klass) + module = inspect.getmodule(method) - for method_name, _ in klass_methods: - args = getattr(module, method_name + "_args", None) - if args is None: - continue - result = getattr(module, method_name + "_result", None) - - thrift_exceptions = [] - if result is not None: - for res_spec in result.thrift_spec: - if res_spec is None: - continue - if res_spec[2] != "success": - # This is an exception return type - spec_args = res_spec[3] - exception_type = spec_args[0] - thrift_exceptions.append(exception_type) - - methods[method_name] = { - "args_class": args, - "result_spec": result, - "thrift_exceptions": tuple(thrift_exceptions), - } + args = getattr(module, method_name + "_args", None) + if args is None: + continue + result = getattr(module, method_name + "_result", None) + + thrift_exceptions = [] + if result is not None: + for res_spec in result.thrift_spec: + if res_spec is None: + continue + if res_spec[2] != "success": + # This is an exception return type + spec_args = res_spec[3] + exception_type = spec_args[0] + thrift_exceptions.append(exception_type) + + methods[method_name] = { + "args_class": args, + "result_spec": result, + "thrift_exceptions": tuple(thrift_exceptions), + } self.methods = methods diff --git a/nebula2/fbthrift/util/inspect.py b/nebula2/fbthrift/util/inspect.py new file mode 100644 index 00000000..58d35fd8 --- /dev/null +++ b/nebula2/fbthrift/util/inspect.py @@ -0,0 +1,288 @@ +#!/usr/bin/env python3 +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +from nebula2.fbthrift.Thrift import TType + +import inspect +import sys +from typing import Any, Dict, List, Optional, Tuple, Type, cast +from types import ModuleType + +ExtraTypeSpec = Any +FieldSpec = Tuple[ + int, # field id + TType, + str, # field_name + ExtraTypeSpec, + Any, # default value + int, # 0=required, 1=optional, 2=default +] + +_args_suffix = "_args" +_result_suffix = "_result" + + +class NoSuchFunctionError(ValueError): + pass + + +class Function: + """A class describing the argument types and return type of a thrift function.""" + + def __init__( + self, + name: str, + module: ModuleType, + arg_specs: List[FieldSpec], + result_spec: Optional[Tuple[FieldSpec]], + ) -> None: + self.name = name + self.module = module + self.arg_specs = arg_specs + self.result_spec = result_spec + + @property + def service_name(self) -> str: + return self.module.__name__ + + def __str__(self) -> str: + arg_info = [] + for info in self.arg_specs: + if info is None: + # The thrift_spec format is pretty dumb, and attempts to make the tuple + # indices match up with the field ID numbers in most cases (when the + # field IDs are positive). It fills gaps in the field IDs with None + # elements. + continue + ( + _field_id, + thrift_type, # enum describing thrift base type + arg_name, + extra_type_spec, + _default_value, + _required, + ) = info + type_name = get_type_name(thrift_type, extra_type_spec) + arg_info.append(f"{arg_name}: {type_name}") + + args_str = ", ".join(arg_info) + if self.result_spec is None: + # This is a oneway function. The server sends no response at all (and + # therefore cannot even indicate errors). There is no confirmation that the + # request was even received or processed. + return f"{self.name}({args_str}) [oneway]" + else: + result_str = _get_result_str(self.result_spec) + return f"{self.name}({args_str}) -> {result_str}" + + +def get_service_module_hierarchy(service_module: ModuleType) -> List[ModuleType]: + """Given a thrift service module, return a list containing it plus all + of the modules for its parent services. + """ + iface_class = getattr(service_module, "Iface", None) + if iface_class is None: + raise TypeError( + f"{service_module!r} does not look like a thrift service module" + ) + + result = [] + for cls in iface_class.__mro__: + module = sys.modules[cls.__module__] + # Check to make sure this actually looks like a thrift service module. + # The MRO hierarchy will include the base "object" class which is not from a + # thrift module. + if hasattr(module, "Iface"): + result.append(module) + + return result + + +def list_all_functions(service_module: ModuleType) -> Dict[str, Function]: + """Given a thrift service module, return information about the functions exposed by + this service, including all of its inherited functions. + """ + modules = get_service_module_hierarchy(service_module) + functions: Dict[str, Function] = {} + for module in reversed(modules): + functions.update(list_service_functions(module)) + + return functions + + +def list_service_functions(service_module: ModuleType) -> Dict[str, Function]: + """Given a thrift service module, return information about the functions it exposes. + This returns only the functions directly defined by this service, excluding + functions inherited from parent service interfaces. Use list_all_functions() if you + also want inherited functions to be returned. + """ + functions = {} + for name in dir(service_module): + if not name.endswith(_args_suffix): + continue + fn_name = name[: -len(_args_suffix)] + functions[fn_name] = get_function_info(service_module, fn_name) + + return functions + + +def get_function_info( + service_module: ModuleType, fn_name: str, search_parent_interfaces: bool = True +) -> Function: + """Return a Function object describing the interface of the specified function + in the supplied thrift service module. + """ + if search_parent_interfaces: + modules = get_service_module_hierarchy(service_module) + else: + modules = [service_module] + + for module in modules: + fn_info = _get_function_info(module, fn_name) + if fn_info is not None: + return fn_info + + raise NoSuchFunctionError(f"no function named {fn_name}") + + +def _get_function_info(service_module: ModuleType, fn_name: str) -> Optional[Function]: + args_type = getattr(service_module, fn_name + _args_suffix, None) + if args_type is None: + # This function is not defined by this module + return None + + ordered_arg_specs = _get_function_arg_specs(service_module, fn_name) + result_type = getattr(service_module, fn_name + _result_suffix, None) + + result_spec = ( + None if result_type is None else cast(Tuple[FieldSpec], result_type.thrift_spec) + ) + return Function(fn_name, service_module, ordered_arg_specs, result_spec) + + +def _get_function_arg_specs( + service_module: ModuleType, fn_name: str +) -> List[FieldSpec]: + args_type = getattr(service_module, fn_name + _args_suffix) + + # Re-order the argument types to actually match the python function argument + # ordering. + # + # The entries in the thrift spec will be ordered by thrift field ID numbers (and + # it actually tries to match up the tuple indices to the thrift field IDs, which + # results in huge tuples if you happen to use a large ID value). + # + # The field ID numbers do not necessarily match the source code order of the + # arguments. + iface_class = getattr(service_module, "Iface") + py_fn = getattr(iface_class, fn_name) + sig = inspect.signature(py_fn) + + # First build a dictionary of the thrift specs by name + arg_specs = {} + for spec in args_type.thrift_spec: + if spec is None: + continue + arg_name = spec[2] + arg_specs[arg_name] = spec + + # Now put them in the correct order + ordered_arg_specs = [] + for param in list(sig.parameters)[1:]: # skip the initial "self" parameter + arg_spec = arg_specs.pop(param) + ordered_arg_specs.append(arg_spec) + + assert ( + not arg_specs + ), f"did not consume all thrift arguments for {fn_name}: {arg_specs}" + + return ordered_arg_specs + + +def get_type_name(thrift_type: TType, extra_type_spec: Any) -> str: + """Convert information about a thrift type into a human-readable string.""" + if thrift_type == TType.STRING: + is_binary = not cast(bool, extra_type_spec) + if is_binary: + return "binary" + else: + return "string" + elif thrift_type == TType.BOOL: + return "bool" + elif thrift_type == TType.BYTE: + return "byte" + elif thrift_type == TType.DOUBLE: + return "double" + elif thrift_type == TType.I16: + return "i16" + elif thrift_type == TType.I32: + if extra_type_spec is None: + return "i32" + else: + # This is an enum, and the extra_type_spec contains the enum type + python_type = cast(Type, extra_type_spec) + return f"{python_type.__module__}.{python_type.__qualname__}" + elif thrift_type == TType.I64: + return "i64" + elif thrift_type == TType.DOUBLE: + return "double" + elif thrift_type == TType.FLOAT: + return "float" + elif thrift_type == TType.STRUCT: + python_type, type_spec, is_union = extra_type_spec + return f"{python_type.__module__}.{python_type.__qualname__}" + elif thrift_type == TType.MAP: + ( + key_thrift_type, + key_extra_spec, + value_thrift_type, + value_extra_spec, + ) = extra_type_spec + key_type_name = get_type_name(key_thrift_type, key_extra_spec) + value_type_name = get_type_name(value_thrift_type, value_extra_spec) + return f"map<{key_type_name}, {value_type_name}>" + elif thrift_type == TType.SET: + (elem_thrift_type, elem_extra_spec) = extra_type_spec + elem_type_name = get_type_name(elem_thrift_type, elem_extra_spec) + return f"set<{elem_type_name}>" + elif thrift_type == TType.LIST: + (elem_thrift_type, elem_extra_spec) = extra_type_spec + elem_type_name = get_type_name(elem_thrift_type, elem_extra_spec) + return f"list<{elem_type_name}>" + else: + # The thrift compiler currently does not emit any other + # types for python. (C++ also has a "STREAM" type but this is not + # currently supported for python.) + return "unsupported thrift type" + + +def _get_result_str(result_spec: Tuple[FieldSpec]) -> str: + # The entry with field ID 0 is the success result. If the function returns void + # this will not be present. + # All other entries are possible exception types that may be thrown. + for info in result_spec: + if info is None: + continue + ( + field_id, + thrift_type, # enum describing thrift base type + _arg_name, + extra_type_spec, + _default_value, + _required, + ) = info + if field_id == 0: + return get_type_name(thrift_type, extra_type_spec) + return "void" diff --git a/nebula2/fbthrift/util/randomizer.py b/nebula2/fbthrift/util/randomizer.py index adb7898f..7814c51d 100644 --- a/nebula2/fbthrift/util/randomizer.py +++ b/nebula2/fbthrift/util/randomizer.py @@ -1,3 +1,19 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe + """ Classes for generating random values for thrift types """ @@ -16,6 +32,9 @@ from nebula2.fbthrift import Thrift +from nebula2.fbthrift.util.type_inspect import get_spec, ThriftPyTypeSpec + + INFINITY = float('inf') if sys.version_info[0] >= 3: @@ -44,8 +63,6 @@ class BaseRandomizer(object): Class Attributes: - name (str): The name of the thrift type. - ttype (int (enum)): The attribute of Thrift.TTypes corresponding to the type default_constraints (dict): Default values for randomizers' constraint @@ -53,8 +70,8 @@ class BaseRandomizer(object): Instance Attributes: - spec_args (tuple): The Thrift spec_args tuple. Provides additional - information about the field beyond thrift type. + type_spec (ThriftTypeSpec): The thrift spec wrapper. Provides additional + information about the type beyond thrift type. state (RandomizerState): State attributes to be preserved across randomizer components in recursive and nested randomizer structures. Includes @@ -66,7 +83,6 @@ class BaseRandomizer(object): recursively updated with the key/value pairs in the constraint dict passed to __init__. """ - name = None ttype = None default_constraints = { @@ -75,27 +91,15 @@ class BaseRandomizer(object): 'p_fuzz': 1 # If seed not ignored, chance of fuzzing seed } - @classmethod - def get_type_name(cls, spec_args): - """ - Get the name of this type that should be used to index into the - type constraint stack dictionary. For basic types, it should - be the name of the thrift type. For collection types it should - include with the element type. For user-defined types - it should be the user-defined name. - """ - return cls.name - - def __init__(self, spec_args, state, constraints): + def __init__(self, type_spec, state, constraints): """ spec_args: thrift arguments for this field state: RandomizerState instance constraints: dict of constraints specific to this randomizer """ - cls = self.__class__ - self.spec_args = spec_args + self.type_spec = type_spec self.state = state - self.type_name = cls.get_type_name(spec_args) + self.type_name = type_spec.get_type_name() self.constraints = self.flatten_constraints(constraints) self.preprocessing_done = False @@ -127,6 +131,9 @@ def flatten_constraints(self, constraints): flattened = {} deep_dict_update(flattened, cls.default_constraints) + # Put the default constraints of the whole stack + deep_dict_update(flattened, self.state.default_constraints) + type_name = self.type_name for type_constraints in self.state.type_constraint_stacks[type_name]: deep_dict_update(flattened, type_constraints) @@ -139,7 +146,7 @@ def __eq__(self, other): """Check if this randomizer is equal to `other` randomizer. If two randomizers are equal, they have the same type and constraints and are expected to behave identically (up to random number generation.)""" - return ((self.spec_args == other.spec_args) and + return ((self.type_spec == other.type_spec) and (self.constraints == other.constraints)) @property @@ -233,7 +240,6 @@ def _randomize(self): return None class BoolRandomizer(BaseRandomizer): - name = "bool" ttype = Thrift.TType.BOOL default_constraints = dict(BaseRandomizer.default_constraints) @@ -270,7 +276,6 @@ def random_int_k_bits(): return random_int_k_bits class EnumRandomizer(ScalarTypeRandomizer): - name = "enum" ttype = Thrift.TType.I32 random_int_32 = staticmethod(_random_int_factory(32)) @@ -281,15 +286,9 @@ class EnumRandomizer(ScalarTypeRandomizer): 'p_invalid': 0.01, }) - @classmethod - def get_type_name(cls, spec_args): - return spec_args.__name__ - def _preprocess_constraints(self): - self.ttype = self.spec_args - self._whiteset = set() - for _, val in six.iteritems(self.ttype._NAMES_TO_VALUES): + for val in six.itervalues(self.type_spec.names_to_values()): self._whiteset.add(val) self._whitelist = list(self._whiteset) @@ -300,24 +299,26 @@ def _randomize(self): val = super(EnumRandomizer, self)._randomize() if val is not None: if isinstance(val, six.string_types): - return self.ttype._NAMES_TO_VALUES[val] + return self.type_spec.names_to_values()[val] else: - return val + return self.type_spec.construct_instance(val) if random.random() < self.constraints['p_invalid']: # Generate an i32 value that does not correspond to an enum member n = None while (n in self._whiteset) or (n is None): n = cls.random_int_32() - return n + return self.type_spec.construct_instance(n) else: - return random.choice(self._whitelist) + return self.type_spec.construct_instance(random.choice(self._whitelist)) def eval_seed(self, seed): if isinstance(seed, six.string_types): - return self.ttype._NAMES_TO_VALUES[seed] - else: + seed = self.type_spec.names_to_values()[seed] + elif not isinstance(seed, int): + # Assume the seed is given in its native type return seed + return self.type_spec.construct_instance(seed) @property def universe_size(self): @@ -334,7 +335,6 @@ def _integer_randomizer_factory(name, ttype, n_bits): _random_i32 = _random_int_factory(_n_bits) class NBitIntegerRandomizer(ScalarTypeRandomizer): - name = _name ttype = _ttype default_constraints = dict(ScalarTypeRandomizer.default_constraints) @@ -398,7 +398,7 @@ def eval_seed(self, seed): return NBitIntegerRandomizer -ByteRandomizer = _integer_randomizer_factory("byte", Thrift.TType.BYTE, 8) +ByteRandomizer = _integer_randomizer_factory("i8", Thrift.TType.BYTE, 8) I16Randomizer = _integer_randomizer_factory("i16", Thrift.TType.I16, 16) I32Randomizer = _integer_randomizer_factory("i32", Thrift.TType.I32, 32) I64Randomizer = _integer_randomizer_factory("i64", Thrift.TType.I64, 64) @@ -446,13 +446,11 @@ def eval_seed(self, seed): raise TypeError("Invalid %s seed: %s" % (self.__class__.name, seed)) class SinglePrecisionFloatRandomizer(FloatingPointRandomizer): - name = "float" ttype = Thrift.TType.FLOAT _universe_size = 2 ** 32 class DoublePrecisionFloatRandomizer(FloatingPointRandomizer): - name = "double" ttype = Thrift.TType.DOUBLE _universe_size = 2 ** 64 @@ -474,10 +472,13 @@ def _get_length(self): if mean == 0: return 0 else: - return int(random.expovariate(1 / mean)) + val = int(random.expovariate(1 / mean)) + max_len = self.constraints.get('max_length', None) + if max_len is not None and val > max_len: + val = max_len + return val class StringRandomizer(CollectionTypeRandomizer, ScalarTypeRandomizer): - name = "string" ttype = Thrift.TType.STRING ascii_range = (0, 127) @@ -498,17 +499,47 @@ def _randomize(self): for _ in sm.xrange(length): chars.append(chr(random.randint(*cls.ascii_range))) - if six.PY3: - return six.binary_type(''.join(chars), 'ascii') - else: - return six.binary_type(''.join(chars)) + return ''.join(chars) def eval_seed(self, seed): if isinstance(seed, six.string_types): return seed + elif isinstance(seed, six.binary_type): + return seed else: raise TypeError("Invalid string seed: %s" % seed) + +class BinaryRandomizer(CollectionTypeRandomizer, ScalarTypeRandomizer): + ttype = Thrift.TType.UTF8 + + byte_range = (0, 255) + + default_constraints = dict(CollectionTypeRandomizer.default_constraints) + default_constraints.update(ScalarTypeRandomizer.default_constraints) + + def _randomize(self): + val = ScalarTypeRandomizer._randomize(self) + if val is not None: + return self.type_spec.construct_instance(val) + + length = self._get_length() + bs = [] + + for _ in sm.xrange(length): + bs.append(six.int2byte(random.randint(*self.byte_range))) + + return self.type_spec.construct_instance(six.ensure_binary('').join(bs)) + + def eval_seed(self, seed): + if isinstance(seed, six.string_types): + return self.type_spec.construct_instance(six.ensure_binary(seed)) + elif isinstance(seed, six.binary_type): + return self.type_spec.construct_instance(seed) + else: + raise TypeError("Invalid binary seed: %s" % seed) + + class NonAssociativeContainerRandomizer(CollectionTypeRandomizer): """Randomizer class for lists and sets""" @@ -517,21 +548,13 @@ class NonAssociativeContainerRandomizer(CollectionTypeRandomizer): 'element': {} }) - @classmethod - def get_type_name(cls, spec_args): - elem_ttype, elem_spec_args = spec_args - elem_randomizer_cls = _get_randomizer_class(elem_ttype, elem_spec_args) - elem_type_name = elem_randomizer_cls.get_type_name(elem_spec_args) - return "%s<%s>" % (cls.name, elem_type_name) - def _init_subrandomizers(self): - elem_ttype, elem_spec_args = self.spec_args + elem_spec = self.type_spec.get_subtypes()[ThriftPyTypeSpec.SUBTYPE_ELEMENT] elem_constraints = self.constraints['element'] - self._element_randomizer = self.state.get_randomizer( - elem_ttype, elem_spec_args, elem_constraints) + self._element_randomizer = self.state.get_randomizer_for_spec( + elem_spec, elem_constraints) class ListRandomizer(NonAssociativeContainerRandomizer): - name = "list" ttype = Thrift.TType.LIST def _randomize(self): @@ -543,11 +566,10 @@ def _randomize(self): if element is not None: elements.append(element) - return elements + return self.type_spec.construct_instance(elements) def _fuzz_insert(self, seed): """Fuzz a list seed by inserting a random element at a random index""" - seed = self.eval_seed(seed) randomizer = self._element_randomizer new_elem = randomizer.generate() insertion_index = random.randint(0, len(seed)) @@ -558,7 +580,6 @@ def _fuzz_delete(self, seed): """Fuzz a list seed by deleting a random element Requires len(seed) >= 1""" - seed = self.eval_seed(seed) delete_index = random.randint(0, len(seed) - 1) seed.pop(delete_index) return seed @@ -571,15 +592,18 @@ def _fuzz_one_element(self, seed): randomizer = self._element_randomizer fuzzed_elem = randomizer.generate(seed=seed[fuzz_index]) - seed = self.eval_seed(seed) seed[fuzz_index] = fuzzed_elem return seed def _fuzz(self, seed): + seed = self.eval_seed(seed) + # Convert to list if needed. The thrift list type may be immutable + if not isinstance(seed, list): + seed = list(seed) if len(seed) == 0: # Seed is an empty list. The only valid fuzzer function # is the insert function - return self._fuzz_insert(seed) + fuzzed = self._fuzz_insert(seed) else: # All fuzzer functions are valid fuzz_fn = random.choice([ @@ -587,13 +611,15 @@ def _fuzz(self, seed): self._fuzz_delete, self._fuzz_one_element ]) - return fuzz_fn(seed) + fuzzed = fuzz_fn(seed) + return self.type_spec.construct_instance(fuzzed) def eval_seed(self, seed): - return [self._element_randomizer.eval_seed(e) for e in seed] + return self.type_spec.construct_instance( + [self._element_randomizer.eval_seed(e) for e in seed] + ) class SetRandomizer(NonAssociativeContainerRandomizer): - name = "set" ttype = Thrift.TType.SET def _randomize(self): @@ -616,13 +642,14 @@ def _randomize(self): elements.add(element) i += 1 - return elements + return self.type_spec.construct_instance(elements) def eval_seed(self, seed): - return {self._element_randomizer.eval_seed(e) for e in seed} + return self.type_spec.construct_instance( + {self._element_randomizer.eval_seed(e) for e in seed} + ) class MapRandomizer(CollectionTypeRandomizer): - name = "map" ttype = Thrift.TType.MAP default_constraints = dict(CollectionTypeRandomizer.default_constraints) @@ -631,28 +658,18 @@ class MapRandomizer(CollectionTypeRandomizer): 'value': {} }) - @classmethod - def get_type_name(cls, spec_args): - key_ttype, key_spec_args, val_ttype, val_spec_args = spec_args - - key_randomizer_cls = _get_randomizer_class(key_ttype, key_spec_args) - key_type_name = key_randomizer_cls.get_type_name(key_spec_args) - - val_randomizer_cls = _get_randomizer_class(val_ttype, val_spec_args) - val_type_name = val_randomizer_cls.get_type_name(val_spec_args) - - return "%s<%s, %s>" % (cls.name, key_type_name, val_type_name) - def _init_subrandomizers(self): - key_ttype, key_spec_args, val_ttype, val_spec_args = self.spec_args + subtypes = self.type_spec.get_subtypes() + key_spec = subtypes[ThriftPyTypeSpec.SUBTYPE_KEY] + val_spec = subtypes[ThriftPyTypeSpec.SUBTYPE_VALUE] key_constraints = self.constraints['key'] val_constraints = self.constraints['value'] - self._key_randomizer = self.state.get_randomizer( - key_ttype, key_spec_args, key_constraints) - self._val_randomizer = self.state.get_randomizer( - val_ttype, val_spec_args, val_constraints) + self._key_randomizer = self.state.get_randomizer_for_spec( + key_spec, key_constraints) + self._val_randomizer = self.state.get_randomizer_for_spec( + val_spec, val_constraints) def _randomize(self): key_randomizer = self._key_randomizer @@ -669,11 +686,19 @@ def _randomize(self): while len(elements) < length and i < N: key = key_randomizer.generate() val = val_randomizer.generate() - if key is not None and val is not None: - elements[key] = val + try: + if key is not None and val is not None: + elements[key] = val + except TypeError: + # If we have a type error here it means that the key + # can't be hashed. There can be structs that have + # keys python doesn't like. + # + # For now just bail out. + return self.type_spec.construct_instance(elements) i += 1 - return elements + return self.type_spec.construct_instance(elements) def eval_seed(self, seed): res = {} @@ -681,10 +706,9 @@ def eval_seed(self, seed): key = self._key_randomizer.eval_seed(key) val = self._val_randomizer.eval_seed(val) res[key] = val - return res + return self.type_spec.construct_instance(res) class StructRandomizer(BaseRandomizer): - name = "struct" ttype = Thrift.TType.STRUCT default_constraints = dict(BaseRandomizer.default_constraints) @@ -694,42 +718,21 @@ class StructRandomizer(BaseRandomizer): 'per_field': {} }) - @classmethod - def get_type_name(cls, spec_args): - ttype = spec_args[0] - return ttype.__name__ - @property def universe_size(self): return INFINITY - def _field_is_required(self, required_value): - """Enum defined in /thrift/compiler/parse/t_field.h: - - T_REQUIRED = 0 - T_OPTIONAL = 1 - T_OPT_IN_REQ_OUT = 2 - - Return True iff required_value is T_REQUIRED - """ - return required_value == 0 - def _init_subrandomizers(self): - ttype, specs, is_union = self.spec_args - - self.type_name = ttype.__name__ + subtypes = self.type_spec.get_subtypes() + requiredness = self.type_spec.get_subtype_requiredness() field_rules = {} - for spec in specs: - if spec is None: - continue - (key, field_ttype, name, field_spec_args, default_value, req) = spec - - field_required = self._field_is_required(req) + for name, field_spec in six.iteritems(subtypes): + field_required = requiredness[name] field_constraints = self.constraints.get(name, {}) - field_randomizer = self.state.get_randomizer( - field_ttype, field_spec_args, field_constraints) + field_randomizer = self.state.get_randomizer_for_spec( + field_spec, field_constraints) field_rules[name] = { 'required': field_required, @@ -738,8 +741,8 @@ def _init_subrandomizers(self): field_rules[name].update(self.constraints['per_field'].get(name, {})) self._field_rules = field_rules - self._is_union = is_union - self._ttype = ttype + self._is_union = self.type_spec.is_union + self._field_names = list(self._field_rules) def _increase_recursion_depth(self): """Increase the depth in the recursion trace for this struct type. @@ -806,11 +809,11 @@ def _randomize(self): return None fields = {} - fields_to_randomize = list(self._field_rules) + fields_to_randomize = self._field_names p_include = self.constraints['p_include'] if self._is_union: - if random.random() < p_include: + if fields_to_randomize and random.random() < p_include: fields_to_randomize = [random.choice(fields_to_randomize)] p_include = 1.0 else: @@ -820,8 +823,8 @@ def _randomize(self): rule = self._field_rules[field_name] required = rule['required'] - p_include = rule.get('p_include', p_include) - if not required and not (random.random() < p_include): + field_p_include = rule.get('p_include', p_include) + if not required and not (random.random() < field_p_include): continue value = rule['randomizer'].generate() @@ -840,23 +843,31 @@ def _randomize(self): self._decrease_recursion_depth(is_top_level) - if fields is None: + if (fields is None) or (self._is_union and not fields): return None else: - return self._ttype(**fields) + if self._is_union: + for f in self._field_names: + fields.setdefault(f, None) + return self.type_spec.construct_instance(**fields) def _fuzz(self, seed): """Fuzz a single field of the struct at random""" fields = {} field_rules = self._field_rules - + seed = self.type_spec.value_to_dict(seed) if self._is_union: + if not seed: + # The seed could be malformed. + # If that's the case just return none + return None # The seed should be a single key/value pair field_name, seed_val = six.next(six.iteritems(seed)) field_randomizer = field_rules[field_name]['randomizer'] fuzzed_val = field_randomizer.generate(seed=seed_val) fields[field_name] = fuzzed_val - + for f in self._field_names: + fields.setdefault(f, None) elif field_rules: # Fuzz only one field and leave the rest with the seed value fuzz_field_name = random.choice(list(field_rules)) @@ -878,15 +889,20 @@ def _fuzz(self, seed): field_randomizer = field_rules[field_name]['randomizer'] fields[field_name] = field_randomizer.eval_seed(seed_val) - return self._ttype(**fields) + return self.type_spec.construct_instance(**fields) def eval_seed(self, seed): fields = {} + seed = self.type_spec.value_to_dict(seed) for key, val in six.iteritems(seed): field_randomizer = self._field_rules[key]['randomizer'] val = field_randomizer.eval_seed(val) fields[key] = val - return self._ttype(**fields) + + if self._is_union: + for f in self._field_names: + fields.setdefault(f, None) + return self.type_spec.construct_instance(**fields) _ttype_to_randomizer = {} @@ -906,14 +922,11 @@ def _init_types(): _init_types() -def _get_randomizer_class(ttype, spec_args): +def _get_randomizer_class(type_spec): # Special case: i32 and enum have separate classes but the same ttype - if ttype == Thrift.TType.I32: - if spec_args is None: - return I32Randomizer - else: - return EnumRandomizer - return _ttype_to_randomizer[ttype] + if type_spec.is_enum(): + return EnumRandomizer + return _ttype_to_randomizer[type_spec.ttype] class RandomizerState(object): @@ -960,17 +973,22 @@ class RandomizerState(object): their constraint dictionaries. """ - def __init__(self): + def __init__(self, default_constraints=None): self.randomizers = collections.defaultdict(list) self.recursion_trace = {} self.type_constraint_stacks = collections.defaultdict(list) + self.default_constraints = default_constraints or {} def get_randomizer(self, ttype, spec_args, constraints): + type_spec = get_spec(ttype, spec_args) + return self.get_randomizer_for_spec(type_spec, constraints) + + def get_randomizer_for_spec(self, type_spec, constraints): """Get a randomizer object. Return an already-preprocessed randomizer if available and create a new one and preprocess it otherwise""" - randomizer_class = _get_randomizer_class(ttype, spec_args) - randomizer = randomizer_class(spec_args, self, constraints) + randomizer_class = _get_randomizer_class(type_spec) + randomizer = randomizer_class(type_spec, self, constraints) # Check if this randomizer is already in self.randomizers randomizers = self.randomizers[randomizer.__class__.ttype] diff --git a/nebula2/fbthrift/util/remote.py b/nebula2/fbthrift/util/remote.py index c4903326..1e837c01 100644 --- a/nebula2/fbthrift/util/remote.py +++ b/nebula2/fbthrift/util/remote.py @@ -1,3 +1,19 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe + """ PyRemote @@ -35,7 +51,6 @@ from nebula2.fbthrift import Thrift from nebula2.fbthrift.transport import TTransport, TSocket, TSSLSocket, THttpClient from nebula2.fbthrift.transport.THeaderTransport import THeaderTransport -from nebula2.fbthrift.transport.TFuzzyHeaderTransport import TFuzzyHeaderTransport from nebula2.fbthrift.protocol import TBinaryProtocol, TCompactProtocol, \ TJSONProtocol, THeaderProtocol, TSimpleJSONProtocol @@ -430,6 +445,16 @@ def run(self, cmdline_args): self._exit(status=0) +def ssl_parsed_bool(arg): + if isinstance(arg, bool): + return arg + if arg in ('true', '1'): + return True + elif arg in ('false', '0'): + return False + else: + raise argparse.ArgumentTypeError('argument must be one of true, 1, false, or 0') + class RemoteTransportClient(RemoteClient): """Abstract class for clients with transport manually opened and closed""" CMDLINE_OPTIONS = [ @@ -443,8 +468,11 @@ class RemoteTransportClient(RemoteClient): ), ( ('-s', '--ssl'), { - 'action': 'store_true', - 'default': False, + 'action': 'store', + 'type': ssl_parsed_bool, + 'default': True, + 'const': True, + 'nargs': '?', 'help': 'Use SSL socket' } ), ( @@ -492,26 +520,21 @@ def _get_client_by_transport(self, options, transport, socket=None): elif socket is not None: # If json, compact, framed, and unframed are not specified, - # THeaderProtocol is the default. Create a protocol using either - # fuzzy or non-fuzzy transport depending on if options.fuzz is set. - if options.fuzz is not None: - transport = TFuzzyHeaderTransport( - socket, fuzz_fields=options.fuzz, verbose=True) - else: - transport = THeaderTransport(socket) - if options.headers is not None: - try: - parsed_headers = eval(options.headers) - except Exception: - self._exit( - error_message='Request headers (--headers) argument' - ' failed eval') - if not isinstance(parsed_headers, dict): - self._exit( - error_message='Request headers (--headers) argument' - ' must evaluate to a dict') - for header_name, header_value in parsed_headers.items(): - transport.set_header(header_name, header_value) + # THeaderProtocol is the default. + transport = THeaderTransport(socket) + if options.headers is not None: + try: + parsed_headers = eval(options.headers) + except Exception: + self._exit( + error_message='Request headers (--headers) argument' + ' failed eval') + if not isinstance(parsed_headers, dict): + self._exit( + error_message='Request headers (--headers) argument' + ' must evaluate to a dict') + for header_name, header_value in parsed_headers.items(): + transport.set_header(header_name, header_value) protocol = THeaderProtocol.THeaderProtocol(transport) else: self._exit(error_message=('No valid protocol ' @@ -525,7 +548,7 @@ def _get_client_by_transport(self, options, transport, socket=None): return client - def close_client(self): + def _close_client(self): self._transport.close() def _validate_options(self, options): @@ -554,29 +577,8 @@ class RemoteHostClient(RemoteTransportClient): 'metavar': 'HOST[:PORT]', 'help': 'The host and port to connect to' } - ), ( - ('-F', '--fuzz'), - { - 'type': str, - 'nargs': '*', - 'default': None, - 'help': ('Use TFuzzyHeaderTransport to send a fuzzed message for ' - 'testing thrift transport. Optionally include a list of ' - 'message field names to fuzz after this flag. Fields: ' + - ', '.join(TFuzzyHeaderTransport.fuzzable_fields)) - } )] - def _validate_options(self, options): - super(RemoteHostClient, self)._validate_options(options) - if (options.fuzz is not None and - any([options.framed, options.unframed, - options.json, options.compact])): - self._exit(error_message=('Transport fuzzing only supported for ' - 'THeaderTransport (no framed, unframed, ' - 'json, or compact.)'), - status=os.EX_USAGE) - def _get_client(self, options): host, port = self._parse_host_port(options.host, self.default_port) socket = (TSSLSocket.TSSLSocket(host, port) if options.ssl diff --git a/nebula2/fbthrift/util/trollius.py b/nebula2/fbthrift/util/trollius.py deleted file mode 100644 index 14669af0..00000000 --- a/nebula2/fbthrift/util/trollius.py +++ /dev/null @@ -1,60 +0,0 @@ -from __future__ import absolute_import -from __future__ import division -from __future__ import print_function -from __future__ import unicode_literals - -import trollius as asyncio - -from trollius import (From, Return, ) -from nebula2.fbthrift.server.TTrolliusServer import ThriftClientProtocolFactory -from nebula2.fbthrift.util.Decorators import protocol_manager - - -@asyncio.coroutine -def async_protocol_manager(coro): - _, protocol = yield From(coro) - raise Return(protocol_manager(protocol)) - - -def create_client(client_klass, - host=None, - port=None, - loop=None, - timeouts=None, - client_type=None): - """ - create a Trollius thrift client and return a context manager for it - This is a coroutine - :param client_klass: thrift Client class - :param host: hostname/ip, None = loopback - :param port: port number - :param loop: Trollius event loop - :returns: a Context manager which provides the thrift client - """ - if not loop: - loop = asyncio.get_event_loop() - coro = loop.create_connection( - ThriftClientProtocolFactory( - client_klass, - loop=loop, - timeouts=timeouts, - client_type=client_type, - ), - host=host, - port=port, - ) - return async_protocol_manager(coro) - - -def call_as_future(callable, loop, *args, **kwargs): - """This is a copy of thrift.util.asyncio. So, let's consider unifying them. - - call_as_future(callable, *args, **kwargs) -> trollius.Task - - Like trollius.ensure_future() but takes any callable and converts - it to a coroutine function first. - """ - if not asyncio.iscoroutinefunction(callable): - callable = asyncio.coroutine(callable) - - return asyncio.ensure_future(callable(*args, **kwargs), loop=loop) diff --git a/nebula2/fbthrift/util/type_inspect.py b/nebula2/fbthrift/util/type_inspect.py new file mode 100644 index 00000000..4a61f09d --- /dev/null +++ b/nebula2/fbthrift/util/type_inspect.py @@ -0,0 +1,277 @@ +# Copyright (c) Facebook, Inc. and its affiliates. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pyre-unsafe + +""" +Support classes for generating random values for thrift types +""" + +from __future__ import absolute_import +from __future__ import division +from __future__ import print_function +from __future__ import unicode_literals + +from nebula2.fbthrift import Thrift + + +def get_spec(ttype, spec_args): + """Create or get an existing introspection wrapper for a thrift type. + + Args: + ttype (Thrift.TType): the thrift type + spec_args: optional type-dependent additional information generated by + the thrift compiler (e.g. the type of a list's elements) + """ + for s in get_spec.cache: + if s.ttype == ttype and s.spec_args == spec_args: + return s + + # enums and i32s share the same thrift type. They can be distinguished + # based on spec_args, which is None for ints + if ttype == Thrift.TType.I32 and spec_args: + return ThriftEnumSpec(ttype, spec_args) + type_map = { + Thrift.TType.BOOL: ThriftBoolSpec, + Thrift.TType.BYTE: ThriftByteSpec, + Thrift.TType.I16: ThriftI16Spec, + Thrift.TType.I32: ThriftI32Spec, + Thrift.TType.I64: ThriftI64Spec, + Thrift.TType.FLOAT: ThriftFloatSpec, + Thrift.TType.DOUBLE: ThriftDoubleSpec, + Thrift.TType.STRING: ThriftScalarSpec, + Thrift.TType.LIST: ThriftListSpec, + Thrift.TType.SET: ThriftSetSpec, + Thrift.TType.MAP: ThriftMapSpec, + Thrift.TType.STRUCT: ThriftStructSpec, + } + spec = type_map[ttype](ttype, spec_args) + get_spec.cache.append(spec) + spec._init_subelements() + return spec + + +get_spec.cache = [] + + +class ThriftTypeSpec(object): + """Base class that abstracts the functionality required by the randomizer""" + SUBTYPE_ELEMENT = "element" + SUBTYPE_KEY = "key" + SUBTYPE_VALUE = "value" + + def __init__(self, ttype): + self.ttype = ttype + + @classmethod + def is_enum(cls): + return False + + def get_type_name(self): + raise NotImplementedError + + def get_type(self): + raise NotImplementedError + + def construct_instance(self, *args, **kwargs): + """Construct a thrift type instance from appropriate arguments""" + return self.get_type()(*args, **kwargs) + + def get_subtypes(self): + """Return a mapping from each subtype to its ThriftTypeSpec. Non-empty + for lists, sets, maps and structs. The key identifies the field name + for structs; for other types, names defined above are used + """ + return {} + + def get_subtype_requiredness(self): + """Return a mapping from each subtype to its requiredness. The keys are + the same as for get_subtypes and the values are booleans + """ + return {} + + def value_to_dict(self, thrift_value): + """Return a mapping from field names to values. Only required for + structs + """ + raise NotImplementedError + + +class ThriftPyTypeSpec(ThriftTypeSpec): + """TypeSpec implementation for python thrift structures""" + name = "" + + def __init__(self, ttype, spec_args): + super(ThriftPyTypeSpec, self).__init__(ttype) + self.spec_args = spec_args + + def __eq__(self, other): + return ( + self.ttype == other.ttype + and self.spec_args == other.spec_args + ) + + def _init_subelements(self): + pass + + +class ThriftScalarSpec(ThriftPyTypeSpec): + def get_type_name(self): + return self.name + + +class ThriftEnumSpec(ThriftPyTypeSpec): + @classmethod + def is_enum(cls): + return True + + def names_to_values(self): + return self.spec_args._NAMES_TO_VALUES + + def get_type_name(self): + return self.spec_args.__name__ + + def get_type(self): + return self.spec_args + + def construct_instance(self, value): + # enums are ints. The thrift enum type (self.spec_args) is not supposed to be + # instantiated + return int(value) + + +def _build_scalar_type_spec(_name): + class _ScalarTypeSpec(ThriftScalarSpec): + name = _name + + return _ScalarTypeSpec + + +ThriftBoolSpec = _build_scalar_type_spec("bool") +ThriftByteSpec = _build_scalar_type_spec("byte") +ThriftI16Spec = _build_scalar_type_spec("i16") +ThriftI32Spec = _build_scalar_type_spec("i32") +ThriftI64Spec = _build_scalar_type_spec("i64") +ThriftFloatSpec = _build_scalar_type_spec("float") +ThriftDoubleSpec = _build_scalar_type_spec("double") +ThriftStringSpec = _build_scalar_type_spec("string") + + +class ThriftNonAssociativeContainerSpec(ThriftPyTypeSpec): + def _init_subelements(self): + elem_ttype, elem_spec_args = self.spec_args + self.elem_spec = get_spec(elem_ttype, elem_spec_args) + + def get_type_name(self): + return "{}<{}>".format(self.name, self.elem_spec.get_type_name()) + + def get_subtypes(self): + return {self.SUBTYPE_ELEMENT: self.elem_spec} + + +class ThriftListSpec(ThriftNonAssociativeContainerSpec): + name = "list" + + def get_type(self): + return list + +class ThriftSetSpec(ThriftNonAssociativeContainerSpec): + name = "set" + + def get_type(self): + return set + +class ThriftMapSpec(ThriftPyTypeSpec): + name = "map" + + def get_type(self): + return dict + + def _init_subelements(self): + key_ttype, key_spec_args, val_ttype, val_spec_args = self.spec_args + self.key_spec = get_spec(key_ttype, key_spec_args) + self.val_spec = get_spec(val_ttype, val_spec_args) + + def get_type_name(self): + return "{}<{}, {}>".format( + self.name, + self.key_spec.get_type_name(), + self.val_spec.get_type_name(), + ) + + def get_subtypes(self): + return { + self.SUBTYPE_KEY: self.key_spec, + self.SUBTYPE_VALUE: self.val_spec + } + + +class ThriftStructSpec(ThriftPyTypeSpec): + def _is_required(self, required_value): + """Enum defined in /thrift/compiler/parse/t_field.h: + + T_REQUIRED = 0 + T_OPTIONAL = 1 + T_OPT_IN_REQ_OUT = 2 + + Return True iff required_value is T_REQUIRED + """ + return required_value == 0 + + def _init_subelements(self): + # For a TType.STRUCT, the spec_args is a triple + # (py thrift type, py thrift type spec, kind), + # where kind is True for a union and False otherwise + self.type_class, self.type_spec, self.is_union = self.spec_args + + self.subtypes = {} + self.subtype_requiredness = {} + for attr_spec in self.type_spec: + if attr_spec is None: + continue + _, ttype, attr_name, spec_args, _, req = attr_spec + self.subtypes[attr_name] = get_spec(ttype, spec_args) + self.subtype_requiredness[attr_name] = self._is_required(req) + + def get_type_name(self): + return self.type_class.__name__ + + def get_type(self): + return self.type_class + + def get_subtypes(self): + return self.subtypes + + def get_subtype_requiredness(self): + return self.subtype_requiredness + + def value_to_dict(self, thrift_value): + if isinstance(thrift_value, dict): + return thrift_value + res = {} + if self.is_union: + field = getattr(thrift_value, 'field', None) + value = getattr(thrift_value, 'value', None) + thrift_spec = getattr(thrift_value, 'thrift_spec', None) + if not field or not thrift_spec: + return res + field_spec = thrift_spec[field] + if not field_spec or len(field_spec) < 3: + return res + res[field_spec[2]] = value + else: + for key, value in vars(thrift_value).items(): + if value is not None: + res[key] = value + return res diff --git a/nebula2/gclient/net/__init__.py b/nebula2/gclient/net/__init__.py index 40df4754..67b8d830 100644 --- a/nebula2/gclient/net/__init__.py +++ b/nebula2/gclient/net/__init__.py @@ -54,7 +54,10 @@ def execute(self, stmt): if self._connection is None: raise RuntimeError('The session has released') try: - return ResultSet(self._connection.execute(self.session_id, stmt)) + start_time = time.time() + resp = self._connection.execute(self.session_id, stmt) + end_time = time.time() + return ResultSet(resp, int((end_time - start_time) * 1000000)) except IOErrorException as ie: if ie.type == IOErrorException.E_CONNECT_BROKEN: self._pool.update_servers_status() @@ -63,7 +66,9 @@ def execute(self, stmt): logging.warning('Retry connect failed') raise IOErrorException(IOErrorException.E_ALL_BROKEN, 'All connections are broken') try: - return ResultSet(self._connection.execute(self.session_id, stmt)) + resp = self._connection.execute(self.session_id, stmt) + end_time = time.time() + return ResultSet(resp, int((end_time - start_time) * 1000000)) except Exception: raise raise diff --git a/nebula2/graph/GraphService-fuzzer b/nebula2/graph/GraphService-fuzzer index 7e0b6880..1857e335 100755 --- a/nebula2/graph/GraphService-fuzzer +++ b/nebula2/graph/GraphService-fuzzer @@ -30,7 +30,7 @@ if (not sys.argv[0].endswith("par") and print("""WARNING You are trying to run *-fuzzer.py which is incorrect as the paths are not set up correctly. - Instead, you should generate your fbthrift file with + Instead, you should generate your thrift file with thrift_library and then run the resulting *-fuzzer.par. For more information, please read @@ -42,4 +42,4 @@ from . import ttypes from . import constants import nebula2.fbthrift.util.fuzzer -nebula2.fbthrift.util.fuzzer.fuzz_service(GraphService, ttypes, constants) +thrift.util.fuzzer.fuzz_service(GraphService, ttypes, constants) diff --git a/nebula2/graph/GraphService-remote b/nebula2/graph/GraphService-remote index 3b02f3f2..0f79a1db 100755 --- a/nebula2/graph/GraphService-remote +++ b/nebula2/graph/GraphService-remote @@ -28,7 +28,7 @@ if (not sys.argv[0].endswith("par") and print("""WARNING You are trying to run *-remote.py which is incorrect as the paths are not set up correctly. - Instead, you should generate your fbthrift file with + Instead, you should generate your thrift file with thrift_library and then run the resulting *-remote.par. For more information, please read @@ -42,10 +42,10 @@ from nebula2.fbthrift.util.remote import Function from nebula2.fbthrift.remote import Remote FUNCTIONS = { - 'authenticate': Function('authenticate', 'GraphService', 'AuthResponse', [('string', 'username', 'string'), ('string', 'password', 'string')]), + 'authenticate': Function('authenticate', 'GraphService', 'AuthResponse', [('binary', 'username', 'binary'), ('binary', 'password', 'binary')]), 'signout': Function('signout', 'GraphService', None, [('i64', 'sessionId', 'i64')]), - 'execute': Function('execute', 'GraphService', 'ExecutionResponse', [('i64', 'sessionId', 'i64'), ('string', 'stmt', 'string')]), - 'executeJson': Function('executeJson', 'GraphService', 'string', [('i64', 'sessionId', 'i64'), ('string', 'stmt', 'string')]), + 'execute': Function('execute', 'GraphService', 'ExecutionResponse', [('i64', 'sessionId', 'i64'), ('binary', 'stmt', 'binary')]), + 'executeJson': Function('executeJson', 'GraphService', 'binary', [('i64', 'sessionId', 'i64'), ('binary', 'stmt', 'binary')]), } SERVICE_NAMES = ['GraphService', ] diff --git a/nebula2/graph/GraphService.py b/nebula2/graph/GraphService.py index 43248deb..2c2864c6 100644 --- a/nebula2/graph/GraphService.py +++ b/nebula2/graph/GraphService.py @@ -7,12 +7,13 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException -from .ttypes import * +from .ttypes import UTF8STRINGS, ErrorCode, ProfilingStats, PlanNodeBranchInfo, Pair, PlanNodeDescription, PlanDescription, ExecutionResponse, AuthResponse import nebula2.common.ttypes from nebula2.fbthrift.Thrift import TProcessor @@ -24,16 +25,22 @@ from nebula2.fbthrift.protocol import TCompactProtocol from nebula2.fbthrift.protocol import THeaderProtocol fastproto = None -if not '__pypy__' in sys.builtin_module_names: - try: - from nebula2.fbthrift.protocol import fastproto - except: - pass +try: + from nebula2.fbthrift.protocol import fastproto +except ImportError: + pass all_structs = [] UTF8STRINGS = bool(0) or sys.version_info.major >= 3 -from nebula2.fbthrift.util.Decorators import * +from nebula2.fbthrift.util.Decorators import ( + future_process_main, + future_process_method, + process_main as thrift_process_main, + process_method as thrift_process_method, + should_run_on_thread, + write_results_after_future, +) class Iface: def authenticate(self, username=None, password=None): @@ -121,11 +128,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -146,10 +151,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -239,11 +240,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -260,10 +259,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -341,11 +336,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -361,10 +354,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -444,11 +433,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -469,10 +456,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -562,11 +545,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -583,10 +564,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -665,11 +642,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -690,10 +665,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -783,11 +754,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -803,10 +772,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1015,10 +980,10 @@ def onewayMethods(self): l.extend(Processor._onewayMethods) return tuple(l) - @process_main() + @thrift_process_main() def process(self,): pass - @process_method(authenticate_args, oneway=False) + @thrift_process_method(authenticate_args, oneway=False) def process_authenticate(self, args, handler_ctx): result = authenticate_result() try: @@ -1026,19 +991,19 @@ def process_authenticate(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'authenticate', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(signout_args, oneway=True) + @thrift_process_method(signout_args, oneway=True) def process_signout(self, args, handler_ctx): try: self._handler.signout(args.sessionId) except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'signout', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) - @process_method(execute_args, oneway=False) + @thrift_process_method(execute_args, oneway=False) def process_execute(self, args, handler_ctx): result = execute_result() try: @@ -1046,10 +1011,10 @@ def process_execute(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'execute', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(executeJson_args, oneway=False) + @thrift_process_method(executeJson_args, oneway=False) def process_executeJson(self, args, handler_ctx): result = executeJson_result() try: @@ -1057,7 +1022,7 @@ def process_executeJson(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'executeJson', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result Iface._processor_type = Processor @@ -1084,10 +1049,10 @@ def onewayMethods(self): l.extend(ContextProcessor._onewayMethods) return tuple(l) - @process_main() + @thrift_process_main() def process(self,): pass - @process_method(authenticate_args, oneway=False) + @thrift_process_method(authenticate_args, oneway=False) def process_authenticate(self, args, handler_ctx): result = authenticate_result() try: @@ -1095,19 +1060,19 @@ def process_authenticate(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'authenticate', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(signout_args, oneway=True) + @thrift_process_method(signout_args, oneway=True) def process_signout(self, args, handler_ctx): try: self._handler.signout(handler_ctx, args.sessionId) except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'signout', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) - @process_method(execute_args, oneway=False) + @thrift_process_method(execute_args, oneway=False) def process_execute(self, args, handler_ctx): result = execute_result() try: @@ -1115,10 +1080,10 @@ def process_execute(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'execute', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(executeJson_args, oneway=False) + @thrift_process_method(executeJson_args, oneway=False) def process_executeJson(self, args, handler_ctx): result = executeJson_result() try: @@ -1126,7 +1091,7 @@ def process_executeJson(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'executeJson', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result ContextIface._processor_type = ContextProcessor diff --git a/nebula2/graph/constants.py b/nebula2/graph/constants.py index 19858098..f10843ef 100644 --- a/nebula2/graph/constants.py +++ b/nebula2/graph/constants.py @@ -7,13 +7,14 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException import nebula2.common.ttypes -from .ttypes import * +from .ttypes import UTF8STRINGS, ErrorCode, ProfilingStats, PlanNodeBranchInfo, Pair, PlanNodeDescription, PlanDescription, ExecutionResponse, AuthResponse diff --git a/nebula2/graph/ttypes.py b/nebula2/graph/ttypes.py index d652d345..de2848e7 100644 --- a/nebula2/graph/ttypes.py +++ b/nebula2/graph/ttypes.py @@ -7,8 +7,9 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException @@ -23,11 +24,10 @@ from nebula2.fbthrift.protocol import TCompactProtocol from nebula2.fbthrift.protocol import THeaderProtocol fastproto = None -if not '__pypy__' in sys.builtin_module_names: - try: - from nebula2.fbthrift.protocol import fastproto - except: - pass +try: + from nebula2.fbthrift.protocol import fastproto +except ImportError: + pass all_structs = [] UTF8STRINGS = bool(0) or sys.version_info.major >= 3 @@ -106,11 +106,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -153,19 +151,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.rows == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'rows' was not found in serialized data! Struct: ProfilingStats") - - if self.exec_duration_in_us == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'exec_duration_in_us' was not found in serialized data! Struct: ProfilingStats") - - if self.total_duration_in_us == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'total_duration_in_us' was not found in serialized data! Struct: ProfilingStats") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -250,11 +235,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -275,16 +258,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.is_do_branch == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'is_do_branch' was not found in serialized data! Struct: PlanNodeBranchInfo") - - if self.condition_node_id == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'condition_node_id' was not found in serialized data! Struct: PlanNodeBranchInfo") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -349,11 +322,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -374,16 +345,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.key == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'key' was not found in serialized data! Struct: Pair") - - if self.value == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'value' was not found in serialized data! Struct: Pair") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -453,11 +414,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -538,19 +497,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.name == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'name' was not found in serialized data! Struct: PlanNodeDescription") - - if self.id == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'id' was not found in serialized data! Struct: PlanNodeDescription") - - if self.output_var == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'output_var' was not found in serialized data! Struct: PlanNodeDescription") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -666,11 +612,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -725,22 +669,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.plan_node_descs == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'plan_node_descs' was not found in serialized data! Struct: PlanDescription") - - if self.node_index_map == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'node_index_map' was not found in serialized data! Struct: PlanDescription") - - if self.format == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'format' was not found in serialized data! Struct: PlanDescription") - - if self.optimize_time_in_us == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'optimize_time_in_us' was not found in serialized data! Struct: PlanDescription") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -833,11 +761,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -885,16 +811,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.error_code == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'error_code' was not found in serialized data! Struct: ExecutionResponse") - - if self.latency_in_us == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'latency_in_us' was not found in serialized data! Struct: ExecutionResponse") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1000,11 +916,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1030,13 +944,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.error_code == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'error_code' was not found in serialized data! Struct: AuthResponse") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1101,7 +1008,7 @@ def __ne__(self, other): ) ProfilingStats.thrift_struct_annotations = { - "cpp.type": """nebula::ProfilingStats""", + "cpp.type": "nebula::ProfilingStats", } ProfilingStats.thrift_field_annotations = { } @@ -1132,7 +1039,7 @@ def ProfilingStats__setstate__(self, state): ) PlanNodeBranchInfo.thrift_struct_annotations = { - "cpp.type": """nebula::PlanNodeBranchInfo""", + "cpp.type": "nebula::PlanNodeBranchInfo", } PlanNodeBranchInfo.thrift_field_annotations = { } @@ -1159,7 +1066,7 @@ def PlanNodeBranchInfo__setstate__(self, state): ) Pair.thrift_struct_annotations = { - "cpp.type": """nebula::Pair""", + "cpp.type": "nebula::Pair", } Pair.thrift_field_annotations = { } @@ -1191,7 +1098,7 @@ def Pair__setstate__(self, state): ) PlanNodeDescription.thrift_struct_annotations = { - "cpp.type": """nebula::PlanNodeDescription""", + "cpp.type": "nebula::PlanNodeDescription", } PlanNodeDescription.thrift_field_annotations = { } @@ -1230,7 +1137,7 @@ def PlanNodeDescription__setstate__(self, state): ) PlanDescription.thrift_struct_annotations = { - "cpp.type": """nebula::PlanDescription""", + "cpp.type": "nebula::PlanDescription", } PlanDescription.thrift_field_annotations = { } @@ -1266,7 +1173,7 @@ def PlanDescription__setstate__(self, state): ) ExecutionResponse.thrift_struct_annotations = { - "cpp.type": """nebula::ExecutionResponse""", + "cpp.type": "nebula::ExecutionResponse", } ExecutionResponse.thrift_field_annotations = { } @@ -1304,7 +1211,7 @@ def ExecutionResponse__setstate__(self, state): ) AuthResponse.thrift_struct_annotations = { - "cpp.type": """nebula::AuthResponse""", + "cpp.type": "nebula::AuthResponse", } AuthResponse.thrift_field_annotations = { } diff --git a/nebula2/mclient/__init__.py b/nebula2/mclient/__init__.py index 2eacc9f9..20c7b62d 100644 --- a/nebula2/mclient/__init__.py +++ b/nebula2/mclient/__init__.py @@ -8,7 +8,6 @@ import logging import socket -import threading from _thread import RLock from nebula2.Exception import ( @@ -25,7 +24,8 @@ ListSpacesReq, GetPartsAllocReq, ErrorCode, - ListHostsReq + ListHostsReq, + HostRole ) from nebula2.meta import ( ttypes, @@ -40,17 +40,16 @@ class MetaClient(object): def __init__(self, addresses, timeout): if len(addresses) == 0: raise RuntimeError('Input empty addresses') - self._addresses = [] self._timeout = timeout - + self._connection = None + self._retry_count = 3 + self._addresses = addresses for address in addresses: try: - ip = socket.gethostbyname(address[0]) + socket.gethostbyname(address[0]) except Exception: raise InValidHostname(str(address[0])) - self._addresses.append((ip, address[1])) self._leader = self._addresses[0] - self._connection = None self._lock = RLock() def open(self): @@ -72,12 +71,19 @@ def list_tags(self, space_id): raise RuntimeError('The connection is no open') req = ListTagsReq() req.space_id = space_id - resp = self._connection.listTags(req) - if resp.code != ErrorCode.SUCCEEDED: - self.update_leader() - raise RuntimeError("List tags from space id:{} failed, error code: {}" - .format(space_id, ErrorCode._VALUES_TO_NAMES(resp.code))) - return resp.tags + count = 0 + while count < self._retry_count: + resp = self._connection.listTags(req) + if resp.code != ErrorCode.SUCCEEDED: + if resp.code == ErrorCode.E_LEADER_CHANGED: + self.update_leader(resp.leader) + count = count + 1 + continue + raise RuntimeError("List tags from space id:{} failed, error code: {}" + .format(space_id, ErrorCode._VALUES_TO_NAMES(resp.code))) + return resp.tags + raise RuntimeError("List tags from space id:{} failed, error code: {}" + .format(space_id, ErrorCode._VALUES_TO_NAMES(resp.code))) def list_edges(self, space_id): with self._lock: @@ -85,37 +91,58 @@ def list_edges(self, space_id): raise RuntimeError('The connection is no open') req = ListEdgesReq() req.space_id = space_id - resp = self._connection.listEdges(req) - if resp.code != ErrorCode.SUCCEEDED: - self.update_leader() - raise RuntimeError("List edges from space id:{} failed, error code: {}" - .format(space_id, ErrorCode._VALUES_TO_NAMES(resp.code))) - return resp.edges + count = 0 + while count < self._retry_count: + resp = self._connection.listEdges(req) + if resp.code != ErrorCode.SUCCEEDED: + if resp.code == ErrorCode.E_LEADER_CHANGED: + self.update_leader(resp.leader) + count = count + 1 + continue + raise RuntimeError("List edges from space id:{} failed, error code: {}" + .format(space_id, ErrorCode._VALUES_TO_NAMES(resp.code))) + return resp.edges + raise RuntimeError("List edges from space id:{} failed, error code: {}" + .format(space_id, ErrorCode._VALUES_TO_NAMES(resp.code))) def list_spaces(self): with self._lock: if self._connection is None: raise RuntimeError('The connection is no open') req = ListSpacesReq() - resp = self._connection.listSpaces(req) - if resp.code != ErrorCode.SUCCEEDED: - self.update_leader() - raise RuntimeError("List spaces failed, error code: {}" - .format(ErrorCode._VALUES_TO_NAMES(resp.code))) - return resp.spaces + count = 0 + while count < self._retry_count: + resp = self._connection.listSpaces(req) + if resp.code != ErrorCode.SUCCEEDED: + if resp.code == ErrorCode.E_LEADER_CHANGED: + self.update_leader(resp.leader) + count = count + 1 + continue + raise RuntimeError("List spaces failed, error code: {}" + .format(ErrorCode._VALUES_TO_NAMES(resp.code))) + return resp.spaces + raise RuntimeError("List spaces failed, error code: {}" + .format(ErrorCode._VALUES_TO_NAMES[resp.code])) def list_hosts(self): with self._lock: if self._connection is None: raise RuntimeError('The connection is no open') req = ListHostsReq() - # req.role = HostRole.STORAGE - resp = self._connection.listHosts(req) - if resp.code != ErrorCode.SUCCEEDED: - self.update_leader() - raise RuntimeError("List spaces failed, error code: {}" - .format(ErrorCode._VALUES_TO_NAMES(resp.code))) - return resp.hosts + req.role = HostRole.STORAGE + count = 0 + while count < self._retry_count: + resp = self._connection.listHosts(req) + if resp.code != ErrorCode.SUCCEEDED: + if resp.code == ErrorCode.E_LEADER_CHANGED: + self.update_leader(resp.leader) + count = count + 1 + continue + raise RuntimeError("List spaces failed, error code: {}" + .format(ErrorCode._VALUES_TO_NAMES(resp.code))) + return resp.hosts + raise RuntimeError("List spaces failed, error code: {}" + .format(ErrorCode._VALUES_TO_NAMES(resp.code))) def get_parts_alloc(self, space_id): with self._lock: @@ -123,12 +150,19 @@ def get_parts_alloc(self, space_id): raise RuntimeError('The connection is no open') req = GetPartsAllocReq() req.space_id = space_id - resp = self._connection.getPartsAlloc(req) - if resp.code != ErrorCode.SUCCEEDED: - self.update_leader() - raise RuntimeError("List parts from space id:{} failed, error code: {}" - .format(space_id, ErrorCode._VALUES_TO_NAMES(resp.code))) - return resp.parts + count = 0 + while count < self._retry_count: + resp = self._connection.getPartsAlloc(req) + if resp.code != ErrorCode.SUCCEEDED: + if resp.code == ErrorCode.E_LEADER_CHANGED: + self.update_leader(resp.leader) + count = count + 1 + continue + raise RuntimeError("List parts from space id:{} failed, error code: {}" + .format(space_id, ErrorCode._VALUES_TO_NAMES(resp.code))) + return resp.parts + raise RuntimeError("List parts from space id:{} failed, error code: {}" + .format(space_id, ErrorCode._VALUES_TO_NAMES(resp.code))) def close(self): try: @@ -137,15 +171,12 @@ def close(self): except Exception: raise - def update_leader(self, resp): - if resp.code == ErrorCode.E_LEADER_CHANGED: - try: - if resp.leader is not None: - with self._lock: - self._leader = (resp.leader.host, resp.leader.port) - self.open() - except Exception as e: - logging.error(e) + def update_leader(self, leader): + try: + self._leader = (leader.host, leader.port) + self.open() + except Exception as e: + logging.error(e) def __del__(self): self.close() @@ -172,18 +203,20 @@ def __init__(self, meta_addrs, timeout=2000, load_period=10, decode_type='utf-8' self._decode_type = decode_type self._load_period = load_period self._lock = RLock() - self._meta_client = MetaClient(meta_addrs, timeout) - self._meta_client.open() self._space_caches = {} self._space_id_names = {} self._storage_addrs = [] self._storage_leader = {} self._close = False + self._meta_client = MetaClient(meta_addrs, timeout) + self._meta_client.open() # load meta data self._load_all() def close(self): + if self._close: + return self._close = True if self._meta_client is not None: self._meta_client.close() @@ -239,7 +272,6 @@ def _load_all(self): self._storage_leader[space_name] = {} for part_id in parts_alloc: self._storage_leader[space_name][part_id] = parts_alloc[part_id][0] - except Exception as x: logging.error('Update meta data failed: {}'.format(x)) import traceback diff --git a/nebula2/meta/MetaService-fuzzer b/nebula2/meta/MetaService-fuzzer index d760c6ca..cb23ff5c 100755 --- a/nebula2/meta/MetaService-fuzzer +++ b/nebula2/meta/MetaService-fuzzer @@ -30,7 +30,7 @@ if (not sys.argv[0].endswith("par") and print("""WARNING You are trying to run *-fuzzer.py which is incorrect as the paths are not set up correctly. - Instead, you should generate your fbthrift file with + Instead, you should generate your thrift file with thrift_library and then run the resulting *-fuzzer.par. For more information, please read @@ -42,4 +42,4 @@ from . import ttypes from . import constants import nebula2.fbthrift.util.fuzzer -nebula2.fbthrift.util.fuzzer.fuzz_service(MetaService, ttypes, constants) +thrift.util.fuzzer.fuzz_service(MetaService, ttypes, constants) diff --git a/nebula2/meta/MetaService-remote b/nebula2/meta/MetaService-remote index 3b1ab2c1..8811ae9f 100755 --- a/nebula2/meta/MetaService-remote +++ b/nebula2/meta/MetaService-remote @@ -28,7 +28,7 @@ if (not sys.argv[0].endswith("par") and print("""WARNING You are trying to run *-remote.py which is incorrect as the paths are not set up correctly. - Instead, you should generate your fbthrift file with + Instead, you should generate your thrift file with thrift_library and then run the resulting *-remote.par. For more information, please read diff --git a/nebula2/meta/MetaService.py b/nebula2/meta/MetaService.py index dfe9a52e..e9d32ad5 100644 --- a/nebula2/meta/MetaService.py +++ b/nebula2/meta/MetaService.py @@ -7,12 +7,13 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException -from .ttypes import * +from .ttypes import UTF8STRINGS, ErrorCode, AlterSchemaOp, RoleType, PropertyType, IsolationLevel, HostStatus, SnapshotStatus, AdminJobOp, AdminCmd, JobStatus, ListHostType, HostRole, TaskResult, ConfigModule, ConfigMode, ListenerType, FTServiceType, ID, ColumnTypeDef, ColumnDef, SchemaProp, Schema, IdName, SpaceDesc, SpaceItem, TagItem, AlterSchemaItem, EdgeItem, SchemaID, IndexItem, HostItem, UserItem, RoleItem, ExecResp, AdminJobReq, JobDesc, TaskDesc, AdminJobResult, AdminJobResp, Correlativity, StatisItem, CreateSpaceReq, DropSpaceReq, ListSpacesReq, ListSpacesResp, GetSpaceReq, GetSpaceResp, CreateTagReq, AlterTagReq, DropTagReq, ListTagsReq, ListTagsResp, GetTagReq, GetTagResp, CreateEdgeReq, AlterEdgeReq, GetEdgeReq, GetEdgeResp, DropEdgeReq, ListEdgesReq, ListEdgesResp, ListHostsReq, ListHostsResp, PartItem, ListPartsReq, ListPartsResp, GetPartsAllocReq, GetPartsAllocResp, MultiPutReq, GetReq, GetResp, MultiGetReq, MultiGetResp, RemoveReq, RemoveRangeReq, ScanReq, ScanResp, HBResp, HBReq, IndexFieldDef, CreateTagIndexReq, DropTagIndexReq, GetTagIndexReq, GetTagIndexResp, ListTagIndexesReq, ListTagIndexesResp, CreateEdgeIndexReq, DropEdgeIndexReq, GetEdgeIndexReq, GetEdgeIndexResp, ListEdgeIndexesReq, ListEdgeIndexesResp, RebuildIndexReq, CreateUserReq, DropUserReq, AlterUserReq, GrantRoleReq, RevokeRoleReq, ListUsersReq, ListUsersResp, ListRolesReq, ListRolesResp, GetUserRolesReq, ChangePasswordReq, BalanceReq, BalanceTask, BalanceResp, LeaderBalanceReq, ConfigItem, RegConfigReq, GetConfigReq, GetConfigResp, SetConfigReq, ListConfigsReq, ListConfigsResp, CreateSnapshotReq, DropSnapshotReq, ListSnapshotsReq, Snapshot, ListSnapshotsResp, ListIndexStatusReq, IndexStatus, ListIndexStatusResp, AddZoneReq, DropZoneReq, AddHostIntoZoneReq, DropHostFromZoneReq, GetZoneReq, GetZoneResp, ListZonesReq, Zone, ListZonesResp, AddGroupReq, DropGroupReq, AddZoneIntoGroupReq, DropZoneFromGroupReq, GetGroupReq, GetGroupResp, ListGroupsReq, Group, ListGroupsResp, AddListenerReq, RemoveListenerReq, ListListenerReq, ListenerInfo, ListListenerResp, GetStatisReq, GetStatisResp, CheckpointInfo, SpaceBackupInfo, BackupMeta, CreateBackupReq, CreateBackupResp, HostPair, RestoreMetaReq, FTClient, SignInFTServiceReq, SignOutFTServiceReq, ListFTClientsReq, ListFTClientsResp, Session, CreateSessionReq, CreateSessionResp, UpdateSessionsReq, ListSessionsReq, ListSessionsResp, GetSessionReq, GetSessionResp, RemoveSessionReq, ReportTaskReq, SchemaVer, ClusterID import nebula2.common.ttypes from nebula2.fbthrift.Thrift import TProcessor @@ -24,16 +25,22 @@ from nebula2.fbthrift.protocol import TCompactProtocol from nebula2.fbthrift.protocol import THeaderProtocol fastproto = None -if not '__pypy__' in sys.builtin_module_names: - try: - from nebula2.fbthrift.protocol import fastproto - except: - pass +try: + from nebula2.fbthrift.protocol import fastproto +except ImportError: + pass all_structs = [] UTF8STRINGS = bool(0) or sys.version_info.major >= 3 -from nebula2.fbthrift.util.Decorators import * +from nebula2.fbthrift.util.Decorators import ( + future_process_main, + future_process_method, + process_main as thrift_process_main, + process_method as thrift_process_method, + should_run_on_thread, + write_results_after_future, +) class Iface: def createSpace(self, req=None): @@ -1206,11 +1213,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1227,10 +1232,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1309,11 +1310,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1330,10 +1329,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1411,11 +1406,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1432,10 +1425,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1514,11 +1503,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1535,10 +1522,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1616,11 +1599,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1637,10 +1618,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1719,11 +1696,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1740,10 +1715,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1821,11 +1792,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1842,10 +1811,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1924,11 +1889,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1945,10 +1908,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2026,11 +1985,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2047,10 +2004,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2129,11 +2082,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2150,10 +2101,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2231,11 +2178,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2252,10 +2197,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2334,11 +2275,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2355,10 +2294,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2436,11 +2371,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2457,10 +2390,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2539,11 +2468,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2560,10 +2487,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2641,11 +2564,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2662,10 +2583,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2744,11 +2661,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2765,10 +2680,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2846,11 +2757,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2867,10 +2776,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2949,11 +2854,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2970,10 +2873,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3051,11 +2950,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3072,10 +2969,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3154,11 +3047,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3175,10 +3066,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3256,11 +3143,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3277,10 +3162,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3359,11 +3240,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3380,10 +3259,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3461,11 +3336,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3482,10 +3355,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3564,11 +3433,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3585,10 +3452,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3666,11 +3529,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3687,10 +3548,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3769,11 +3626,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3790,10 +3645,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3871,11 +3722,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3892,10 +3741,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3974,11 +3819,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3995,10 +3838,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4076,11 +3915,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4097,10 +3934,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4179,11 +4012,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4200,10 +4031,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4281,11 +4108,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4302,10 +4127,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4384,11 +4205,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4405,10 +4224,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4486,11 +4301,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4507,10 +4320,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4589,11 +4398,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4610,10 +4417,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4691,11 +4494,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4712,10 +4513,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4794,11 +4591,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4815,10 +4610,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4896,11 +4687,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4917,10 +4706,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4999,11 +4784,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5020,10 +4803,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5101,11 +4880,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5122,10 +4899,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5204,11 +4977,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5225,10 +4996,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5306,11 +5073,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5327,10 +5092,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5409,11 +5170,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5430,10 +5189,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5511,11 +5266,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5532,10 +5285,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5614,11 +5363,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5635,10 +5382,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5716,11 +5459,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5737,10 +5478,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5819,11 +5556,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5840,10 +5575,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5921,11 +5652,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5942,10 +5671,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6024,11 +5749,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6045,10 +5768,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6126,11 +5845,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6147,10 +5864,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6229,11 +5942,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6250,10 +5961,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6331,11 +6038,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6352,10 +6057,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6434,11 +6135,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6455,10 +6154,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6536,11 +6231,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6557,10 +6250,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6639,11 +6328,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6660,10 +6347,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6741,11 +6424,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6762,10 +6443,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6844,11 +6521,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6865,10 +6540,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6946,11 +6617,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6967,10 +6636,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7049,11 +6714,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7070,10 +6733,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7151,11 +6810,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7172,10 +6829,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7254,11 +6907,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7275,10 +6926,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7356,11 +7003,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7377,10 +7022,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7459,11 +7100,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7480,10 +7119,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7561,11 +7196,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7582,10 +7215,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7664,11 +7293,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7685,10 +7312,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7766,11 +7389,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7787,10 +7408,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7869,11 +7486,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7890,10 +7505,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7971,11 +7582,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7992,10 +7601,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8074,11 +7679,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8095,10 +7698,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8176,11 +7775,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8197,10 +7794,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8279,11 +7872,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8300,10 +7891,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8381,11 +7968,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8402,10 +7987,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8484,11 +8065,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8505,10 +8084,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8586,11 +8161,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8607,10 +8180,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8689,11 +8258,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8710,10 +8277,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8791,11 +8354,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8812,10 +8373,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8894,11 +8451,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8915,10 +8470,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8996,11 +8547,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9017,10 +8566,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9099,11 +8644,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9120,10 +8663,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9201,11 +8740,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9222,10 +8759,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9304,11 +8837,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9325,10 +8856,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9406,11 +8933,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9427,10 +8952,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9509,11 +9030,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9530,10 +9049,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9611,11 +9126,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9632,10 +9145,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9714,11 +9223,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9735,10 +9242,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9816,11 +9319,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9837,10 +9338,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9919,11 +9416,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9940,10 +9435,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10021,11 +9512,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10042,10 +9531,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10124,11 +9609,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10145,10 +9628,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10226,11 +9705,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10247,10 +9724,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10329,11 +9802,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10350,10 +9821,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10431,11 +9898,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10452,10 +9917,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10534,11 +9995,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10555,10 +10014,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10636,11 +10091,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10657,10 +10110,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10739,11 +10188,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10760,10 +10207,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10841,11 +10284,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10862,10 +10303,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10944,11 +10381,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10965,10 +10400,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11046,11 +10477,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11067,10 +10496,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11149,11 +10574,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11170,10 +10593,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11251,11 +10670,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11272,10 +10689,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11354,11 +10767,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11375,10 +10786,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11456,11 +10863,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11477,10 +10882,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11559,11 +10960,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11580,10 +10979,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11661,11 +11056,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11682,10 +11075,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11764,11 +11153,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11785,10 +11172,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11866,11 +11249,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11887,10 +11268,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11969,11 +11346,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11990,10 +11365,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12071,11 +11442,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12092,10 +11461,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12174,11 +11539,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12195,10 +11558,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12276,11 +11635,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12297,10 +11654,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12379,11 +11732,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12400,10 +11751,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12481,11 +11828,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12502,10 +11847,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12584,11 +11925,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12605,10 +11944,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12686,11 +12021,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12707,10 +12040,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12789,11 +12118,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12810,10 +12137,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12891,11 +12214,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12912,10 +12233,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12994,11 +12311,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13015,10 +12330,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13096,11 +12407,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13117,10 +12426,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13199,11 +12504,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13220,10 +12523,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13301,11 +12600,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13322,10 +12619,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13404,11 +12697,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13425,10 +12716,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13506,11 +12793,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13527,10 +12812,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13609,11 +12890,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13630,10 +12909,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13711,11 +12986,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13732,10 +13005,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13814,11 +13083,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13835,10 +13102,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13916,11 +13179,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13937,10 +13198,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14019,11 +13276,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14040,10 +13295,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14121,11 +13372,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14142,10 +13391,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14224,11 +13469,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14245,10 +13488,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14326,11 +13565,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14347,10 +13584,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14429,11 +13662,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14450,10 +13681,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14531,11 +13758,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14552,10 +13777,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14634,11 +13855,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14655,10 +13874,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14736,11 +13951,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14757,10 +13970,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14839,11 +14048,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14860,10 +14067,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14941,11 +14144,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14962,10 +14163,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15044,11 +14241,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15065,10 +14260,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15146,11 +14337,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15167,10 +14356,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15249,11 +14434,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15270,10 +14453,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15351,11 +14530,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15372,10 +14549,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15454,11 +14627,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15475,10 +14646,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15556,11 +14723,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15577,10 +14742,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15659,11 +14820,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15680,10 +14839,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15761,11 +14916,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15782,10 +14935,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15864,11 +15013,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15885,10 +15032,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15966,11 +15109,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15987,10 +15128,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16069,11 +15206,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16090,10 +15225,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16171,11 +15302,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16192,10 +15321,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16274,11 +15399,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16295,10 +15418,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16376,11 +15495,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16397,10 +15514,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16479,11 +15592,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16500,10 +15611,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16581,11 +15688,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16602,10 +15707,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16684,11 +15785,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16705,10 +15804,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16786,11 +15881,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16807,10 +15900,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16889,11 +15978,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16910,10 +15997,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16991,11 +16074,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17012,10 +16093,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17094,11 +16171,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17115,10 +16190,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17196,11 +16267,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17217,10 +16286,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17299,11 +16364,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17320,10 +16383,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17401,11 +16460,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17422,10 +16479,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17504,11 +16557,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17525,10 +16576,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17606,11 +16653,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17627,10 +16672,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17709,11 +16750,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17730,10 +16769,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17811,11 +16846,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17832,10 +16865,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17914,11 +16943,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17935,10 +16962,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -20653,10 +19676,10 @@ def onewayMethods(self): l.extend(Processor._onewayMethods) return tuple(l) - @process_main() + @thrift_process_main() def process(self,): pass - @process_method(createSpace_args, oneway=False) + @thrift_process_method(createSpace_args, oneway=False) def process_createSpace(self, args, handler_ctx): result = createSpace_result() try: @@ -20664,10 +19687,10 @@ def process_createSpace(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createSpace', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropSpace_args, oneway=False) + @thrift_process_method(dropSpace_args, oneway=False) def process_dropSpace(self, args, handler_ctx): result = dropSpace_result() try: @@ -20675,10 +19698,10 @@ def process_dropSpace(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropSpace', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getSpace_args, oneway=False) + @thrift_process_method(getSpace_args, oneway=False) def process_getSpace(self, args, handler_ctx): result = getSpace_result() try: @@ -20686,10 +19709,10 @@ def process_getSpace(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getSpace', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listSpaces_args, oneway=False) + @thrift_process_method(listSpaces_args, oneway=False) def process_listSpaces(self, args, handler_ctx): result = listSpaces_result() try: @@ -20697,10 +19720,10 @@ def process_listSpaces(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listSpaces', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createTag_args, oneway=False) + @thrift_process_method(createTag_args, oneway=False) def process_createTag(self, args, handler_ctx): result = createTag_result() try: @@ -20708,10 +19731,10 @@ def process_createTag(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createTag', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(alterTag_args, oneway=False) + @thrift_process_method(alterTag_args, oneway=False) def process_alterTag(self, args, handler_ctx): result = alterTag_result() try: @@ -20719,10 +19742,10 @@ def process_alterTag(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'alterTag', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropTag_args, oneway=False) + @thrift_process_method(dropTag_args, oneway=False) def process_dropTag(self, args, handler_ctx): result = dropTag_result() try: @@ -20730,10 +19753,10 @@ def process_dropTag(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropTag', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getTag_args, oneway=False) + @thrift_process_method(getTag_args, oneway=False) def process_getTag(self, args, handler_ctx): result = getTag_result() try: @@ -20741,10 +19764,10 @@ def process_getTag(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getTag', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listTags_args, oneway=False) + @thrift_process_method(listTags_args, oneway=False) def process_listTags(self, args, handler_ctx): result = listTags_result() try: @@ -20752,10 +19775,10 @@ def process_listTags(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listTags', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createEdge_args, oneway=False) + @thrift_process_method(createEdge_args, oneway=False) def process_createEdge(self, args, handler_ctx): result = createEdge_result() try: @@ -20763,10 +19786,10 @@ def process_createEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(alterEdge_args, oneway=False) + @thrift_process_method(alterEdge_args, oneway=False) def process_alterEdge(self, args, handler_ctx): result = alterEdge_result() try: @@ -20774,10 +19797,10 @@ def process_alterEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'alterEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropEdge_args, oneway=False) + @thrift_process_method(dropEdge_args, oneway=False) def process_dropEdge(self, args, handler_ctx): result = dropEdge_result() try: @@ -20785,10 +19808,10 @@ def process_dropEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getEdge_args, oneway=False) + @thrift_process_method(getEdge_args, oneway=False) def process_getEdge(self, args, handler_ctx): result = getEdge_result() try: @@ -20796,10 +19819,10 @@ def process_getEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listEdges_args, oneway=False) + @thrift_process_method(listEdges_args, oneway=False) def process_listEdges(self, args, handler_ctx): result = listEdges_result() try: @@ -20807,10 +19830,10 @@ def process_listEdges(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listEdges', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listHosts_args, oneway=False) + @thrift_process_method(listHosts_args, oneway=False) def process_listHosts(self, args, handler_ctx): result = listHosts_result() try: @@ -20818,10 +19841,10 @@ def process_listHosts(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listHosts', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getPartsAlloc_args, oneway=False) + @thrift_process_method(getPartsAlloc_args, oneway=False) def process_getPartsAlloc(self, args, handler_ctx): result = getPartsAlloc_result() try: @@ -20829,10 +19852,10 @@ def process_getPartsAlloc(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getPartsAlloc', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listParts_args, oneway=False) + @thrift_process_method(listParts_args, oneway=False) def process_listParts(self, args, handler_ctx): result = listParts_result() try: @@ -20840,10 +19863,10 @@ def process_listParts(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listParts', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(multiPut_args, oneway=False) + @thrift_process_method(multiPut_args, oneway=False) def process_multiPut(self, args, handler_ctx): result = multiPut_result() try: @@ -20851,10 +19874,10 @@ def process_multiPut(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'multiPut', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(get_args, oneway=False) + @thrift_process_method(get_args, oneway=False) def process_get(self, args, handler_ctx): result = get_result() try: @@ -20862,10 +19885,10 @@ def process_get(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'get', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(multiGet_args, oneway=False) + @thrift_process_method(multiGet_args, oneway=False) def process_multiGet(self, args, handler_ctx): result = multiGet_result() try: @@ -20873,10 +19896,10 @@ def process_multiGet(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'multiGet', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(remove_args, oneway=False) + @thrift_process_method(remove_args, oneway=False) def process_remove(self, args, handler_ctx): result = remove_result() try: @@ -20884,10 +19907,10 @@ def process_remove(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'remove', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(removeRange_args, oneway=False) + @thrift_process_method(removeRange_args, oneway=False) def process_removeRange(self, args, handler_ctx): result = removeRange_result() try: @@ -20895,10 +19918,10 @@ def process_removeRange(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'removeRange', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(scan_args, oneway=False) + @thrift_process_method(scan_args, oneway=False) def process_scan(self, args, handler_ctx): result = scan_result() try: @@ -20906,10 +19929,10 @@ def process_scan(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'scan', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createTagIndex_args, oneway=False) + @thrift_process_method(createTagIndex_args, oneway=False) def process_createTagIndex(self, args, handler_ctx): result = createTagIndex_result() try: @@ -20917,10 +19940,10 @@ def process_createTagIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createTagIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropTagIndex_args, oneway=False) + @thrift_process_method(dropTagIndex_args, oneway=False) def process_dropTagIndex(self, args, handler_ctx): result = dropTagIndex_result() try: @@ -20928,10 +19951,10 @@ def process_dropTagIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropTagIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getTagIndex_args, oneway=False) + @thrift_process_method(getTagIndex_args, oneway=False) def process_getTagIndex(self, args, handler_ctx): result = getTagIndex_result() try: @@ -20939,10 +19962,10 @@ def process_getTagIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getTagIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listTagIndexes_args, oneway=False) + @thrift_process_method(listTagIndexes_args, oneway=False) def process_listTagIndexes(self, args, handler_ctx): result = listTagIndexes_result() try: @@ -20950,10 +19973,10 @@ def process_listTagIndexes(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listTagIndexes', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(rebuildTagIndex_args, oneway=False) + @thrift_process_method(rebuildTagIndex_args, oneway=False) def process_rebuildTagIndex(self, args, handler_ctx): result = rebuildTagIndex_result() try: @@ -20961,10 +19984,10 @@ def process_rebuildTagIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'rebuildTagIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listTagIndexStatus_args, oneway=False) + @thrift_process_method(listTagIndexStatus_args, oneway=False) def process_listTagIndexStatus(self, args, handler_ctx): result = listTagIndexStatus_result() try: @@ -20972,10 +19995,10 @@ def process_listTagIndexStatus(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listTagIndexStatus', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createEdgeIndex_args, oneway=False) + @thrift_process_method(createEdgeIndex_args, oneway=False) def process_createEdgeIndex(self, args, handler_ctx): result = createEdgeIndex_result() try: @@ -20983,10 +20006,10 @@ def process_createEdgeIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createEdgeIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropEdgeIndex_args, oneway=False) + @thrift_process_method(dropEdgeIndex_args, oneway=False) def process_dropEdgeIndex(self, args, handler_ctx): result = dropEdgeIndex_result() try: @@ -20994,10 +20017,10 @@ def process_dropEdgeIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropEdgeIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getEdgeIndex_args, oneway=False) + @thrift_process_method(getEdgeIndex_args, oneway=False) def process_getEdgeIndex(self, args, handler_ctx): result = getEdgeIndex_result() try: @@ -21005,10 +20028,10 @@ def process_getEdgeIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getEdgeIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listEdgeIndexes_args, oneway=False) + @thrift_process_method(listEdgeIndexes_args, oneway=False) def process_listEdgeIndexes(self, args, handler_ctx): result = listEdgeIndexes_result() try: @@ -21016,10 +20039,10 @@ def process_listEdgeIndexes(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listEdgeIndexes', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(rebuildEdgeIndex_args, oneway=False) + @thrift_process_method(rebuildEdgeIndex_args, oneway=False) def process_rebuildEdgeIndex(self, args, handler_ctx): result = rebuildEdgeIndex_result() try: @@ -21027,10 +20050,10 @@ def process_rebuildEdgeIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'rebuildEdgeIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listEdgeIndexStatus_args, oneway=False) + @thrift_process_method(listEdgeIndexStatus_args, oneway=False) def process_listEdgeIndexStatus(self, args, handler_ctx): result = listEdgeIndexStatus_result() try: @@ -21038,10 +20061,10 @@ def process_listEdgeIndexStatus(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listEdgeIndexStatus', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createUser_args, oneway=False) + @thrift_process_method(createUser_args, oneway=False) def process_createUser(self, args, handler_ctx): result = createUser_result() try: @@ -21049,10 +20072,10 @@ def process_createUser(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createUser', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropUser_args, oneway=False) + @thrift_process_method(dropUser_args, oneway=False) def process_dropUser(self, args, handler_ctx): result = dropUser_result() try: @@ -21060,10 +20083,10 @@ def process_dropUser(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropUser', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(alterUser_args, oneway=False) + @thrift_process_method(alterUser_args, oneway=False) def process_alterUser(self, args, handler_ctx): result = alterUser_result() try: @@ -21071,10 +20094,10 @@ def process_alterUser(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'alterUser', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(grantRole_args, oneway=False) + @thrift_process_method(grantRole_args, oneway=False) def process_grantRole(self, args, handler_ctx): result = grantRole_result() try: @@ -21082,10 +20105,10 @@ def process_grantRole(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'grantRole', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(revokeRole_args, oneway=False) + @thrift_process_method(revokeRole_args, oneway=False) def process_revokeRole(self, args, handler_ctx): result = revokeRole_result() try: @@ -21093,10 +20116,10 @@ def process_revokeRole(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'revokeRole', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listUsers_args, oneway=False) + @thrift_process_method(listUsers_args, oneway=False) def process_listUsers(self, args, handler_ctx): result = listUsers_result() try: @@ -21104,10 +20127,10 @@ def process_listUsers(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listUsers', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listRoles_args, oneway=False) + @thrift_process_method(listRoles_args, oneway=False) def process_listRoles(self, args, handler_ctx): result = listRoles_result() try: @@ -21115,10 +20138,10 @@ def process_listRoles(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listRoles', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getUserRoles_args, oneway=False) + @thrift_process_method(getUserRoles_args, oneway=False) def process_getUserRoles(self, args, handler_ctx): result = getUserRoles_result() try: @@ -21126,10 +20149,10 @@ def process_getUserRoles(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getUserRoles', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(changePassword_args, oneway=False) + @thrift_process_method(changePassword_args, oneway=False) def process_changePassword(self, args, handler_ctx): result = changePassword_result() try: @@ -21137,10 +20160,10 @@ def process_changePassword(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'changePassword', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(heartBeat_args, oneway=False) + @thrift_process_method(heartBeat_args, oneway=False) def process_heartBeat(self, args, handler_ctx): result = heartBeat_result() try: @@ -21148,10 +20171,10 @@ def process_heartBeat(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'heartBeat', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(balance_args, oneway=False) + @thrift_process_method(balance_args, oneway=False) def process_balance(self, args, handler_ctx): result = balance_result() try: @@ -21159,10 +20182,10 @@ def process_balance(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'balance', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(leaderBalance_args, oneway=False) + @thrift_process_method(leaderBalance_args, oneway=False) def process_leaderBalance(self, args, handler_ctx): result = leaderBalance_result() try: @@ -21170,10 +20193,10 @@ def process_leaderBalance(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'leaderBalance', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(regConfig_args, oneway=False) + @thrift_process_method(regConfig_args, oneway=False) def process_regConfig(self, args, handler_ctx): result = regConfig_result() try: @@ -21181,10 +20204,10 @@ def process_regConfig(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'regConfig', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getConfig_args, oneway=False) + @thrift_process_method(getConfig_args, oneway=False) def process_getConfig(self, args, handler_ctx): result = getConfig_result() try: @@ -21192,10 +20215,10 @@ def process_getConfig(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getConfig', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(setConfig_args, oneway=False) + @thrift_process_method(setConfig_args, oneway=False) def process_setConfig(self, args, handler_ctx): result = setConfig_result() try: @@ -21203,10 +20226,10 @@ def process_setConfig(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'setConfig', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listConfigs_args, oneway=False) + @thrift_process_method(listConfigs_args, oneway=False) def process_listConfigs(self, args, handler_ctx): result = listConfigs_result() try: @@ -21214,10 +20237,10 @@ def process_listConfigs(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listConfigs', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createSnapshot_args, oneway=False) + @thrift_process_method(createSnapshot_args, oneway=False) def process_createSnapshot(self, args, handler_ctx): result = createSnapshot_result() try: @@ -21225,10 +20248,10 @@ def process_createSnapshot(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createSnapshot', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropSnapshot_args, oneway=False) + @thrift_process_method(dropSnapshot_args, oneway=False) def process_dropSnapshot(self, args, handler_ctx): result = dropSnapshot_result() try: @@ -21236,10 +20259,10 @@ def process_dropSnapshot(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropSnapshot', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listSnapshots_args, oneway=False) + @thrift_process_method(listSnapshots_args, oneway=False) def process_listSnapshots(self, args, handler_ctx): result = listSnapshots_result() try: @@ -21247,10 +20270,10 @@ def process_listSnapshots(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listSnapshots', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(runAdminJob_args, oneway=False) + @thrift_process_method(runAdminJob_args, oneway=False) def process_runAdminJob(self, args, handler_ctx): result = runAdminJob_result() try: @@ -21258,10 +20281,10 @@ def process_runAdminJob(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'runAdminJob', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addZone_args, oneway=False) + @thrift_process_method(addZone_args, oneway=False) def process_addZone(self, args, handler_ctx): result = addZone_result() try: @@ -21269,10 +20292,10 @@ def process_addZone(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addZone', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropZone_args, oneway=False) + @thrift_process_method(dropZone_args, oneway=False) def process_dropZone(self, args, handler_ctx): result = dropZone_result() try: @@ -21280,10 +20303,10 @@ def process_dropZone(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropZone', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addHostIntoZone_args, oneway=False) + @thrift_process_method(addHostIntoZone_args, oneway=False) def process_addHostIntoZone(self, args, handler_ctx): result = addHostIntoZone_result() try: @@ -21291,10 +20314,10 @@ def process_addHostIntoZone(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addHostIntoZone', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropHostFromZone_args, oneway=False) + @thrift_process_method(dropHostFromZone_args, oneway=False) def process_dropHostFromZone(self, args, handler_ctx): result = dropHostFromZone_result() try: @@ -21302,10 +20325,10 @@ def process_dropHostFromZone(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropHostFromZone', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getZone_args, oneway=False) + @thrift_process_method(getZone_args, oneway=False) def process_getZone(self, args, handler_ctx): result = getZone_result() try: @@ -21313,10 +20336,10 @@ def process_getZone(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getZone', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listZones_args, oneway=False) + @thrift_process_method(listZones_args, oneway=False) def process_listZones(self, args, handler_ctx): result = listZones_result() try: @@ -21324,10 +20347,10 @@ def process_listZones(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listZones', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addGroup_args, oneway=False) + @thrift_process_method(addGroup_args, oneway=False) def process_addGroup(self, args, handler_ctx): result = addGroup_result() try: @@ -21335,10 +20358,10 @@ def process_addGroup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addGroup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropGroup_args, oneway=False) + @thrift_process_method(dropGroup_args, oneway=False) def process_dropGroup(self, args, handler_ctx): result = dropGroup_result() try: @@ -21346,10 +20369,10 @@ def process_dropGroup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropGroup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addZoneIntoGroup_args, oneway=False) + @thrift_process_method(addZoneIntoGroup_args, oneway=False) def process_addZoneIntoGroup(self, args, handler_ctx): result = addZoneIntoGroup_result() try: @@ -21357,10 +20380,10 @@ def process_addZoneIntoGroup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addZoneIntoGroup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropZoneFromGroup_args, oneway=False) + @thrift_process_method(dropZoneFromGroup_args, oneway=False) def process_dropZoneFromGroup(self, args, handler_ctx): result = dropZoneFromGroup_result() try: @@ -21368,10 +20391,10 @@ def process_dropZoneFromGroup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropZoneFromGroup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getGroup_args, oneway=False) + @thrift_process_method(getGroup_args, oneway=False) def process_getGroup(self, args, handler_ctx): result = getGroup_result() try: @@ -21379,10 +20402,10 @@ def process_getGroup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getGroup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listGroups_args, oneway=False) + @thrift_process_method(listGroups_args, oneway=False) def process_listGroups(self, args, handler_ctx): result = listGroups_result() try: @@ -21390,10 +20413,10 @@ def process_listGroups(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listGroups', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createBackup_args, oneway=False) + @thrift_process_method(createBackup_args, oneway=False) def process_createBackup(self, args, handler_ctx): result = createBackup_result() try: @@ -21401,10 +20424,10 @@ def process_createBackup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createBackup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(restoreMeta_args, oneway=False) + @thrift_process_method(restoreMeta_args, oneway=False) def process_restoreMeta(self, args, handler_ctx): result = restoreMeta_result() try: @@ -21412,10 +20435,10 @@ def process_restoreMeta(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'restoreMeta', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addListener_args, oneway=False) + @thrift_process_method(addListener_args, oneway=False) def process_addListener(self, args, handler_ctx): result = addListener_result() try: @@ -21423,10 +20446,10 @@ def process_addListener(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addListener', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(removeListener_args, oneway=False) + @thrift_process_method(removeListener_args, oneway=False) def process_removeListener(self, args, handler_ctx): result = removeListener_result() try: @@ -21434,10 +20457,10 @@ def process_removeListener(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'removeListener', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listListener_args, oneway=False) + @thrift_process_method(listListener_args, oneway=False) def process_listListener(self, args, handler_ctx): result = listListener_result() try: @@ -21445,10 +20468,10 @@ def process_listListener(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listListener', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getStatis_args, oneway=False) + @thrift_process_method(getStatis_args, oneway=False) def process_getStatis(self, args, handler_ctx): result = getStatis_result() try: @@ -21456,10 +20479,10 @@ def process_getStatis(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getStatis', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(signInFTService_args, oneway=False) + @thrift_process_method(signInFTService_args, oneway=False) def process_signInFTService(self, args, handler_ctx): result = signInFTService_result() try: @@ -21467,10 +20490,10 @@ def process_signInFTService(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'signInFTService', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(signOutFTService_args, oneway=False) + @thrift_process_method(signOutFTService_args, oneway=False) def process_signOutFTService(self, args, handler_ctx): result = signOutFTService_result() try: @@ -21478,10 +20501,10 @@ def process_signOutFTService(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'signOutFTService', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listFTClients_args, oneway=False) + @thrift_process_method(listFTClients_args, oneway=False) def process_listFTClients(self, args, handler_ctx): result = listFTClients_result() try: @@ -21489,10 +20512,10 @@ def process_listFTClients(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listFTClients', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createSession_args, oneway=False) + @thrift_process_method(createSession_args, oneway=False) def process_createSession(self, args, handler_ctx): result = createSession_result() try: @@ -21500,10 +20523,10 @@ def process_createSession(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createSession', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(updateSessions_args, oneway=False) + @thrift_process_method(updateSessions_args, oneway=False) def process_updateSessions(self, args, handler_ctx): result = updateSessions_result() try: @@ -21511,10 +20534,10 @@ def process_updateSessions(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'updateSessions', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listSessions_args, oneway=False) + @thrift_process_method(listSessions_args, oneway=False) def process_listSessions(self, args, handler_ctx): result = listSessions_result() try: @@ -21522,10 +20545,10 @@ def process_listSessions(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listSessions', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getSession_args, oneway=False) + @thrift_process_method(getSession_args, oneway=False) def process_getSession(self, args, handler_ctx): result = getSession_result() try: @@ -21533,10 +20556,10 @@ def process_getSession(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getSession', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(removeSession_args, oneway=False) + @thrift_process_method(removeSession_args, oneway=False) def process_removeSession(self, args, handler_ctx): result = removeSession_result() try: @@ -21544,10 +20567,10 @@ def process_removeSession(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'removeSession', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(reportTaskFinish_args, oneway=False) + @thrift_process_method(reportTaskFinish_args, oneway=False) def process_reportTaskFinish(self, args, handler_ctx): result = reportTaskFinish_result() try: @@ -21555,7 +20578,7 @@ def process_reportTaskFinish(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'reportTaskFinish', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result Iface._processor_type = Processor @@ -21738,10 +20761,10 @@ def onewayMethods(self): l.extend(ContextProcessor._onewayMethods) return tuple(l) - @process_main() + @thrift_process_main() def process(self,): pass - @process_method(createSpace_args, oneway=False) + @thrift_process_method(createSpace_args, oneway=False) def process_createSpace(self, args, handler_ctx): result = createSpace_result() try: @@ -21749,10 +20772,10 @@ def process_createSpace(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createSpace', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropSpace_args, oneway=False) + @thrift_process_method(dropSpace_args, oneway=False) def process_dropSpace(self, args, handler_ctx): result = dropSpace_result() try: @@ -21760,10 +20783,10 @@ def process_dropSpace(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropSpace', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getSpace_args, oneway=False) + @thrift_process_method(getSpace_args, oneway=False) def process_getSpace(self, args, handler_ctx): result = getSpace_result() try: @@ -21771,10 +20794,10 @@ def process_getSpace(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getSpace', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listSpaces_args, oneway=False) + @thrift_process_method(listSpaces_args, oneway=False) def process_listSpaces(self, args, handler_ctx): result = listSpaces_result() try: @@ -21782,10 +20805,10 @@ def process_listSpaces(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listSpaces', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createTag_args, oneway=False) + @thrift_process_method(createTag_args, oneway=False) def process_createTag(self, args, handler_ctx): result = createTag_result() try: @@ -21793,10 +20816,10 @@ def process_createTag(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createTag', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(alterTag_args, oneway=False) + @thrift_process_method(alterTag_args, oneway=False) def process_alterTag(self, args, handler_ctx): result = alterTag_result() try: @@ -21804,10 +20827,10 @@ def process_alterTag(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'alterTag', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropTag_args, oneway=False) + @thrift_process_method(dropTag_args, oneway=False) def process_dropTag(self, args, handler_ctx): result = dropTag_result() try: @@ -21815,10 +20838,10 @@ def process_dropTag(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropTag', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getTag_args, oneway=False) + @thrift_process_method(getTag_args, oneway=False) def process_getTag(self, args, handler_ctx): result = getTag_result() try: @@ -21826,10 +20849,10 @@ def process_getTag(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getTag', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listTags_args, oneway=False) + @thrift_process_method(listTags_args, oneway=False) def process_listTags(self, args, handler_ctx): result = listTags_result() try: @@ -21837,10 +20860,10 @@ def process_listTags(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listTags', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createEdge_args, oneway=False) + @thrift_process_method(createEdge_args, oneway=False) def process_createEdge(self, args, handler_ctx): result = createEdge_result() try: @@ -21848,10 +20871,10 @@ def process_createEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(alterEdge_args, oneway=False) + @thrift_process_method(alterEdge_args, oneway=False) def process_alterEdge(self, args, handler_ctx): result = alterEdge_result() try: @@ -21859,10 +20882,10 @@ def process_alterEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'alterEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropEdge_args, oneway=False) + @thrift_process_method(dropEdge_args, oneway=False) def process_dropEdge(self, args, handler_ctx): result = dropEdge_result() try: @@ -21870,10 +20893,10 @@ def process_dropEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getEdge_args, oneway=False) + @thrift_process_method(getEdge_args, oneway=False) def process_getEdge(self, args, handler_ctx): result = getEdge_result() try: @@ -21881,10 +20904,10 @@ def process_getEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listEdges_args, oneway=False) + @thrift_process_method(listEdges_args, oneway=False) def process_listEdges(self, args, handler_ctx): result = listEdges_result() try: @@ -21892,10 +20915,10 @@ def process_listEdges(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listEdges', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listHosts_args, oneway=False) + @thrift_process_method(listHosts_args, oneway=False) def process_listHosts(self, args, handler_ctx): result = listHosts_result() try: @@ -21903,10 +20926,10 @@ def process_listHosts(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listHosts', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getPartsAlloc_args, oneway=False) + @thrift_process_method(getPartsAlloc_args, oneway=False) def process_getPartsAlloc(self, args, handler_ctx): result = getPartsAlloc_result() try: @@ -21914,10 +20937,10 @@ def process_getPartsAlloc(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getPartsAlloc', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listParts_args, oneway=False) + @thrift_process_method(listParts_args, oneway=False) def process_listParts(self, args, handler_ctx): result = listParts_result() try: @@ -21925,10 +20948,10 @@ def process_listParts(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listParts', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(multiPut_args, oneway=False) + @thrift_process_method(multiPut_args, oneway=False) def process_multiPut(self, args, handler_ctx): result = multiPut_result() try: @@ -21936,10 +20959,10 @@ def process_multiPut(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'multiPut', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(get_args, oneway=False) + @thrift_process_method(get_args, oneway=False) def process_get(self, args, handler_ctx): result = get_result() try: @@ -21947,10 +20970,10 @@ def process_get(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'get', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(multiGet_args, oneway=False) + @thrift_process_method(multiGet_args, oneway=False) def process_multiGet(self, args, handler_ctx): result = multiGet_result() try: @@ -21958,10 +20981,10 @@ def process_multiGet(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'multiGet', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(remove_args, oneway=False) + @thrift_process_method(remove_args, oneway=False) def process_remove(self, args, handler_ctx): result = remove_result() try: @@ -21969,10 +20992,10 @@ def process_remove(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'remove', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(removeRange_args, oneway=False) + @thrift_process_method(removeRange_args, oneway=False) def process_removeRange(self, args, handler_ctx): result = removeRange_result() try: @@ -21980,10 +21003,10 @@ def process_removeRange(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'removeRange', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(scan_args, oneway=False) + @thrift_process_method(scan_args, oneway=False) def process_scan(self, args, handler_ctx): result = scan_result() try: @@ -21991,10 +21014,10 @@ def process_scan(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'scan', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createTagIndex_args, oneway=False) + @thrift_process_method(createTagIndex_args, oneway=False) def process_createTagIndex(self, args, handler_ctx): result = createTagIndex_result() try: @@ -22002,10 +21025,10 @@ def process_createTagIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createTagIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropTagIndex_args, oneway=False) + @thrift_process_method(dropTagIndex_args, oneway=False) def process_dropTagIndex(self, args, handler_ctx): result = dropTagIndex_result() try: @@ -22013,10 +21036,10 @@ def process_dropTagIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropTagIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getTagIndex_args, oneway=False) + @thrift_process_method(getTagIndex_args, oneway=False) def process_getTagIndex(self, args, handler_ctx): result = getTagIndex_result() try: @@ -22024,10 +21047,10 @@ def process_getTagIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getTagIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listTagIndexes_args, oneway=False) + @thrift_process_method(listTagIndexes_args, oneway=False) def process_listTagIndexes(self, args, handler_ctx): result = listTagIndexes_result() try: @@ -22035,10 +21058,10 @@ def process_listTagIndexes(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listTagIndexes', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(rebuildTagIndex_args, oneway=False) + @thrift_process_method(rebuildTagIndex_args, oneway=False) def process_rebuildTagIndex(self, args, handler_ctx): result = rebuildTagIndex_result() try: @@ -22046,10 +21069,10 @@ def process_rebuildTagIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'rebuildTagIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listTagIndexStatus_args, oneway=False) + @thrift_process_method(listTagIndexStatus_args, oneway=False) def process_listTagIndexStatus(self, args, handler_ctx): result = listTagIndexStatus_result() try: @@ -22057,10 +21080,10 @@ def process_listTagIndexStatus(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listTagIndexStatus', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createEdgeIndex_args, oneway=False) + @thrift_process_method(createEdgeIndex_args, oneway=False) def process_createEdgeIndex(self, args, handler_ctx): result = createEdgeIndex_result() try: @@ -22068,10 +21091,10 @@ def process_createEdgeIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createEdgeIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropEdgeIndex_args, oneway=False) + @thrift_process_method(dropEdgeIndex_args, oneway=False) def process_dropEdgeIndex(self, args, handler_ctx): result = dropEdgeIndex_result() try: @@ -22079,10 +21102,10 @@ def process_dropEdgeIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropEdgeIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getEdgeIndex_args, oneway=False) + @thrift_process_method(getEdgeIndex_args, oneway=False) def process_getEdgeIndex(self, args, handler_ctx): result = getEdgeIndex_result() try: @@ -22090,10 +21113,10 @@ def process_getEdgeIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getEdgeIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listEdgeIndexes_args, oneway=False) + @thrift_process_method(listEdgeIndexes_args, oneway=False) def process_listEdgeIndexes(self, args, handler_ctx): result = listEdgeIndexes_result() try: @@ -22101,10 +21124,10 @@ def process_listEdgeIndexes(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listEdgeIndexes', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(rebuildEdgeIndex_args, oneway=False) + @thrift_process_method(rebuildEdgeIndex_args, oneway=False) def process_rebuildEdgeIndex(self, args, handler_ctx): result = rebuildEdgeIndex_result() try: @@ -22112,10 +21135,10 @@ def process_rebuildEdgeIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'rebuildEdgeIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listEdgeIndexStatus_args, oneway=False) + @thrift_process_method(listEdgeIndexStatus_args, oneway=False) def process_listEdgeIndexStatus(self, args, handler_ctx): result = listEdgeIndexStatus_result() try: @@ -22123,10 +21146,10 @@ def process_listEdgeIndexStatus(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listEdgeIndexStatus', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createUser_args, oneway=False) + @thrift_process_method(createUser_args, oneway=False) def process_createUser(self, args, handler_ctx): result = createUser_result() try: @@ -22134,10 +21157,10 @@ def process_createUser(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createUser', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropUser_args, oneway=False) + @thrift_process_method(dropUser_args, oneway=False) def process_dropUser(self, args, handler_ctx): result = dropUser_result() try: @@ -22145,10 +21168,10 @@ def process_dropUser(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropUser', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(alterUser_args, oneway=False) + @thrift_process_method(alterUser_args, oneway=False) def process_alterUser(self, args, handler_ctx): result = alterUser_result() try: @@ -22156,10 +21179,10 @@ def process_alterUser(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'alterUser', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(grantRole_args, oneway=False) + @thrift_process_method(grantRole_args, oneway=False) def process_grantRole(self, args, handler_ctx): result = grantRole_result() try: @@ -22167,10 +21190,10 @@ def process_grantRole(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'grantRole', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(revokeRole_args, oneway=False) + @thrift_process_method(revokeRole_args, oneway=False) def process_revokeRole(self, args, handler_ctx): result = revokeRole_result() try: @@ -22178,10 +21201,10 @@ def process_revokeRole(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'revokeRole', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listUsers_args, oneway=False) + @thrift_process_method(listUsers_args, oneway=False) def process_listUsers(self, args, handler_ctx): result = listUsers_result() try: @@ -22189,10 +21212,10 @@ def process_listUsers(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listUsers', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listRoles_args, oneway=False) + @thrift_process_method(listRoles_args, oneway=False) def process_listRoles(self, args, handler_ctx): result = listRoles_result() try: @@ -22200,10 +21223,10 @@ def process_listRoles(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listRoles', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getUserRoles_args, oneway=False) + @thrift_process_method(getUserRoles_args, oneway=False) def process_getUserRoles(self, args, handler_ctx): result = getUserRoles_result() try: @@ -22211,10 +21234,10 @@ def process_getUserRoles(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getUserRoles', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(changePassword_args, oneway=False) + @thrift_process_method(changePassword_args, oneway=False) def process_changePassword(self, args, handler_ctx): result = changePassword_result() try: @@ -22222,10 +21245,10 @@ def process_changePassword(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'changePassword', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(heartBeat_args, oneway=False) + @thrift_process_method(heartBeat_args, oneway=False) def process_heartBeat(self, args, handler_ctx): result = heartBeat_result() try: @@ -22233,10 +21256,10 @@ def process_heartBeat(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'heartBeat', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(balance_args, oneway=False) + @thrift_process_method(balance_args, oneway=False) def process_balance(self, args, handler_ctx): result = balance_result() try: @@ -22244,10 +21267,10 @@ def process_balance(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'balance', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(leaderBalance_args, oneway=False) + @thrift_process_method(leaderBalance_args, oneway=False) def process_leaderBalance(self, args, handler_ctx): result = leaderBalance_result() try: @@ -22255,10 +21278,10 @@ def process_leaderBalance(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'leaderBalance', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(regConfig_args, oneway=False) + @thrift_process_method(regConfig_args, oneway=False) def process_regConfig(self, args, handler_ctx): result = regConfig_result() try: @@ -22266,10 +21289,10 @@ def process_regConfig(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'regConfig', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getConfig_args, oneway=False) + @thrift_process_method(getConfig_args, oneway=False) def process_getConfig(self, args, handler_ctx): result = getConfig_result() try: @@ -22277,10 +21300,10 @@ def process_getConfig(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getConfig', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(setConfig_args, oneway=False) + @thrift_process_method(setConfig_args, oneway=False) def process_setConfig(self, args, handler_ctx): result = setConfig_result() try: @@ -22288,10 +21311,10 @@ def process_setConfig(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'setConfig', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listConfigs_args, oneway=False) + @thrift_process_method(listConfigs_args, oneway=False) def process_listConfigs(self, args, handler_ctx): result = listConfigs_result() try: @@ -22299,10 +21322,10 @@ def process_listConfigs(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listConfigs', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createSnapshot_args, oneway=False) + @thrift_process_method(createSnapshot_args, oneway=False) def process_createSnapshot(self, args, handler_ctx): result = createSnapshot_result() try: @@ -22310,10 +21333,10 @@ def process_createSnapshot(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createSnapshot', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropSnapshot_args, oneway=False) + @thrift_process_method(dropSnapshot_args, oneway=False) def process_dropSnapshot(self, args, handler_ctx): result = dropSnapshot_result() try: @@ -22321,10 +21344,10 @@ def process_dropSnapshot(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropSnapshot', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listSnapshots_args, oneway=False) + @thrift_process_method(listSnapshots_args, oneway=False) def process_listSnapshots(self, args, handler_ctx): result = listSnapshots_result() try: @@ -22332,10 +21355,10 @@ def process_listSnapshots(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listSnapshots', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(runAdminJob_args, oneway=False) + @thrift_process_method(runAdminJob_args, oneway=False) def process_runAdminJob(self, args, handler_ctx): result = runAdminJob_result() try: @@ -22343,10 +21366,10 @@ def process_runAdminJob(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'runAdminJob', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addZone_args, oneway=False) + @thrift_process_method(addZone_args, oneway=False) def process_addZone(self, args, handler_ctx): result = addZone_result() try: @@ -22354,10 +21377,10 @@ def process_addZone(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addZone', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropZone_args, oneway=False) + @thrift_process_method(dropZone_args, oneway=False) def process_dropZone(self, args, handler_ctx): result = dropZone_result() try: @@ -22365,10 +21388,10 @@ def process_dropZone(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropZone', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addHostIntoZone_args, oneway=False) + @thrift_process_method(addHostIntoZone_args, oneway=False) def process_addHostIntoZone(self, args, handler_ctx): result = addHostIntoZone_result() try: @@ -22376,10 +21399,10 @@ def process_addHostIntoZone(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addHostIntoZone', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropHostFromZone_args, oneway=False) + @thrift_process_method(dropHostFromZone_args, oneway=False) def process_dropHostFromZone(self, args, handler_ctx): result = dropHostFromZone_result() try: @@ -22387,10 +21410,10 @@ def process_dropHostFromZone(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropHostFromZone', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getZone_args, oneway=False) + @thrift_process_method(getZone_args, oneway=False) def process_getZone(self, args, handler_ctx): result = getZone_result() try: @@ -22398,10 +21421,10 @@ def process_getZone(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getZone', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listZones_args, oneway=False) + @thrift_process_method(listZones_args, oneway=False) def process_listZones(self, args, handler_ctx): result = listZones_result() try: @@ -22409,10 +21432,10 @@ def process_listZones(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listZones', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addGroup_args, oneway=False) + @thrift_process_method(addGroup_args, oneway=False) def process_addGroup(self, args, handler_ctx): result = addGroup_result() try: @@ -22420,10 +21443,10 @@ def process_addGroup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addGroup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropGroup_args, oneway=False) + @thrift_process_method(dropGroup_args, oneway=False) def process_dropGroup(self, args, handler_ctx): result = dropGroup_result() try: @@ -22431,10 +21454,10 @@ def process_dropGroup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropGroup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addZoneIntoGroup_args, oneway=False) + @thrift_process_method(addZoneIntoGroup_args, oneway=False) def process_addZoneIntoGroup(self, args, handler_ctx): result = addZoneIntoGroup_result() try: @@ -22442,10 +21465,10 @@ def process_addZoneIntoGroup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addZoneIntoGroup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropZoneFromGroup_args, oneway=False) + @thrift_process_method(dropZoneFromGroup_args, oneway=False) def process_dropZoneFromGroup(self, args, handler_ctx): result = dropZoneFromGroup_result() try: @@ -22453,10 +21476,10 @@ def process_dropZoneFromGroup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropZoneFromGroup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getGroup_args, oneway=False) + @thrift_process_method(getGroup_args, oneway=False) def process_getGroup(self, args, handler_ctx): result = getGroup_result() try: @@ -22464,10 +21487,10 @@ def process_getGroup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getGroup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listGroups_args, oneway=False) + @thrift_process_method(listGroups_args, oneway=False) def process_listGroups(self, args, handler_ctx): result = listGroups_result() try: @@ -22475,10 +21498,10 @@ def process_listGroups(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listGroups', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createBackup_args, oneway=False) + @thrift_process_method(createBackup_args, oneway=False) def process_createBackup(self, args, handler_ctx): result = createBackup_result() try: @@ -22486,10 +21509,10 @@ def process_createBackup(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createBackup', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(restoreMeta_args, oneway=False) + @thrift_process_method(restoreMeta_args, oneway=False) def process_restoreMeta(self, args, handler_ctx): result = restoreMeta_result() try: @@ -22497,10 +21520,10 @@ def process_restoreMeta(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'restoreMeta', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addListener_args, oneway=False) + @thrift_process_method(addListener_args, oneway=False) def process_addListener(self, args, handler_ctx): result = addListener_result() try: @@ -22508,10 +21531,10 @@ def process_addListener(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addListener', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(removeListener_args, oneway=False) + @thrift_process_method(removeListener_args, oneway=False) def process_removeListener(self, args, handler_ctx): result = removeListener_result() try: @@ -22519,10 +21542,10 @@ def process_removeListener(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'removeListener', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listListener_args, oneway=False) + @thrift_process_method(listListener_args, oneway=False) def process_listListener(self, args, handler_ctx): result = listListener_result() try: @@ -22530,10 +21553,10 @@ def process_listListener(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listListener', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getStatis_args, oneway=False) + @thrift_process_method(getStatis_args, oneway=False) def process_getStatis(self, args, handler_ctx): result = getStatis_result() try: @@ -22541,10 +21564,10 @@ def process_getStatis(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getStatis', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(signInFTService_args, oneway=False) + @thrift_process_method(signInFTService_args, oneway=False) def process_signInFTService(self, args, handler_ctx): result = signInFTService_result() try: @@ -22552,10 +21575,10 @@ def process_signInFTService(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'signInFTService', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(signOutFTService_args, oneway=False) + @thrift_process_method(signOutFTService_args, oneway=False) def process_signOutFTService(self, args, handler_ctx): result = signOutFTService_result() try: @@ -22563,10 +21586,10 @@ def process_signOutFTService(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'signOutFTService', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listFTClients_args, oneway=False) + @thrift_process_method(listFTClients_args, oneway=False) def process_listFTClients(self, args, handler_ctx): result = listFTClients_result() try: @@ -22574,10 +21597,10 @@ def process_listFTClients(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listFTClients', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createSession_args, oneway=False) + @thrift_process_method(createSession_args, oneway=False) def process_createSession(self, args, handler_ctx): result = createSession_result() try: @@ -22585,10 +21608,10 @@ def process_createSession(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createSession', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(updateSessions_args, oneway=False) + @thrift_process_method(updateSessions_args, oneway=False) def process_updateSessions(self, args, handler_ctx): result = updateSessions_result() try: @@ -22596,10 +21619,10 @@ def process_updateSessions(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'updateSessions', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(listSessions_args, oneway=False) + @thrift_process_method(listSessions_args, oneway=False) def process_listSessions(self, args, handler_ctx): result = listSessions_result() try: @@ -22607,10 +21630,10 @@ def process_listSessions(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'listSessions', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getSession_args, oneway=False) + @thrift_process_method(getSession_args, oneway=False) def process_getSession(self, args, handler_ctx): result = getSession_result() try: @@ -22618,10 +21641,10 @@ def process_getSession(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getSession', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(removeSession_args, oneway=False) + @thrift_process_method(removeSession_args, oneway=False) def process_removeSession(self, args, handler_ctx): result = removeSession_result() try: @@ -22629,10 +21652,10 @@ def process_removeSession(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'removeSession', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(reportTaskFinish_args, oneway=False) + @thrift_process_method(reportTaskFinish_args, oneway=False) def process_reportTaskFinish(self, args, handler_ctx): result = reportTaskFinish_result() try: @@ -22640,7 +21663,7 @@ def process_reportTaskFinish(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'reportTaskFinish', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result ContextIface._processor_type = ContextProcessor diff --git a/nebula2/meta/constants.py b/nebula2/meta/constants.py index 19858098..a3b6989b 100644 --- a/nebula2/meta/constants.py +++ b/nebula2/meta/constants.py @@ -7,13 +7,14 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException import nebula2.common.ttypes -from .ttypes import * +from .ttypes import UTF8STRINGS, ErrorCode, AlterSchemaOp, RoleType, PropertyType, IsolationLevel, HostStatus, SnapshotStatus, AdminJobOp, AdminCmd, JobStatus, ListHostType, HostRole, TaskResult, ConfigModule, ConfigMode, ListenerType, FTServiceType, ID, ColumnTypeDef, ColumnDef, SchemaProp, Schema, IdName, SpaceDesc, SpaceItem, TagItem, AlterSchemaItem, EdgeItem, SchemaID, IndexItem, HostItem, UserItem, RoleItem, ExecResp, AdminJobReq, JobDesc, TaskDesc, AdminJobResult, AdminJobResp, Correlativity, StatisItem, CreateSpaceReq, DropSpaceReq, ListSpacesReq, ListSpacesResp, GetSpaceReq, GetSpaceResp, CreateTagReq, AlterTagReq, DropTagReq, ListTagsReq, ListTagsResp, GetTagReq, GetTagResp, CreateEdgeReq, AlterEdgeReq, GetEdgeReq, GetEdgeResp, DropEdgeReq, ListEdgesReq, ListEdgesResp, ListHostsReq, ListHostsResp, PartItem, ListPartsReq, ListPartsResp, GetPartsAllocReq, GetPartsAllocResp, MultiPutReq, GetReq, GetResp, MultiGetReq, MultiGetResp, RemoveReq, RemoveRangeReq, ScanReq, ScanResp, HBResp, HBReq, IndexFieldDef, CreateTagIndexReq, DropTagIndexReq, GetTagIndexReq, GetTagIndexResp, ListTagIndexesReq, ListTagIndexesResp, CreateEdgeIndexReq, DropEdgeIndexReq, GetEdgeIndexReq, GetEdgeIndexResp, ListEdgeIndexesReq, ListEdgeIndexesResp, RebuildIndexReq, CreateUserReq, DropUserReq, AlterUserReq, GrantRoleReq, RevokeRoleReq, ListUsersReq, ListUsersResp, ListRolesReq, ListRolesResp, GetUserRolesReq, ChangePasswordReq, BalanceReq, BalanceTask, BalanceResp, LeaderBalanceReq, ConfigItem, RegConfigReq, GetConfigReq, GetConfigResp, SetConfigReq, ListConfigsReq, ListConfigsResp, CreateSnapshotReq, DropSnapshotReq, ListSnapshotsReq, Snapshot, ListSnapshotsResp, ListIndexStatusReq, IndexStatus, ListIndexStatusResp, AddZoneReq, DropZoneReq, AddHostIntoZoneReq, DropHostFromZoneReq, GetZoneReq, GetZoneResp, ListZonesReq, Zone, ListZonesResp, AddGroupReq, DropGroupReq, AddZoneIntoGroupReq, DropZoneFromGroupReq, GetGroupReq, GetGroupResp, ListGroupsReq, Group, ListGroupsResp, AddListenerReq, RemoveListenerReq, ListListenerReq, ListenerInfo, ListListenerResp, GetStatisReq, GetStatisResp, CheckpointInfo, SpaceBackupInfo, BackupMeta, CreateBackupReq, CreateBackupResp, HostPair, RestoreMetaReq, FTClient, SignInFTServiceReq, SignOutFTServiceReq, ListFTClientsReq, ListFTClientsResp, Session, CreateSessionReq, CreateSessionResp, UpdateSessionsReq, ListSessionsReq, ListSessionsResp, GetSessionReq, GetSessionResp, RemoveSessionReq, ReportTaskReq, SchemaVer, ClusterID diff --git a/nebula2/meta/ttypes.py b/nebula2/meta/ttypes.py index 8c378605..3c4be607 100644 --- a/nebula2/meta/ttypes.py +++ b/nebula2/meta/ttypes.py @@ -7,8 +7,9 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException @@ -23,11 +24,10 @@ from nebula2.fbthrift.protocol import TCompactProtocol from nebula2.fbthrift.protocol import THeaderProtocol fastproto = None -if not '__pypy__' in sys.builtin_module_names: - try: - from nebula2.fbthrift.protocol import fastproto - except: - pass +try: + from nebula2.fbthrift.protocol import fastproto +except ImportError: + pass all_structs = [] UTF8STRINGS = bool(0) or sys.version_info.major >= 3 @@ -632,11 +632,9 @@ def read(self, iprot): self.value = None if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, True], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, True], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -747,11 +745,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -772,13 +768,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.type == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'type' was not found in serialized data! Struct: ColumnTypeDef") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -845,11 +834,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -881,16 +868,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.name == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'name' was not found in serialized data! Struct: ColumnDef") - - if self.type == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'type' was not found in serialized data! Struct: ColumnDef") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -971,11 +948,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -996,10 +971,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1064,11 +1035,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1102,10 +1071,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1173,11 +1138,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1199,10 +1162,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1273,11 +1232,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1329,10 +1286,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1445,11 +1398,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1471,10 +1422,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1541,11 +1488,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1577,10 +1522,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1661,11 +1602,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1687,10 +1626,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1757,11 +1692,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1793,10 +1726,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1914,11 +1843,9 @@ def read(self, iprot): self.value = None if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, True], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, True], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1996,11 +1923,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2049,10 +1974,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2149,11 +2070,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2264,10 +2183,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2390,11 +2305,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2435,10 +2348,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2536,11 +2445,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2566,10 +2473,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2643,11 +2546,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2675,10 +2576,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2752,11 +2649,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2792,10 +2687,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2875,11 +2766,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2930,10 +2819,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3037,11 +2922,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3083,10 +2966,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3185,11 +3064,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3244,10 +3121,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3335,11 +3208,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3367,10 +3238,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3443,11 +3310,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3468,10 +3333,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3525,7 +3386,8 @@ class StatisItem: - edges - space_vertices - space_edges - - part_corelativity + - positive_part_correlativity + - negative_part_correlativity - status """ @@ -3540,11 +3402,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3597,7 +3457,7 @@ def read(self, iprot): iprot.skip(ftype) elif fid == 5: if ftype == TType.MAP: - self.part_corelativity = {} + self.positive_part_correlativity = {} (_ktype119, _vtype120, _size118 ) = iprot.readMapBegin() if _size118 >= 0: for _i122 in six.moves.range(_size118): @@ -3615,7 +3475,7 @@ def read(self, iprot): _elem131.read(iprot) _val124.append(_elem131) iprot.readListEnd() - self.part_corelativity[_key123] = _val124 + self.positive_part_correlativity[_key123] = _val124 else: while iprot.peekMap(): _key132 = iprot.readI32() @@ -3632,11 +3492,52 @@ def read(self, iprot): _elem140.read(iprot) _val133.append(_elem140) iprot.readListEnd() - self.part_corelativity[_key132] = _val133 + self.positive_part_correlativity[_key132] = _val133 iprot.readMapEnd() else: iprot.skip(ftype) elif fid == 6: + if ftype == TType.MAP: + self.negative_part_correlativity = {} + (_ktype142, _vtype143, _size141 ) = iprot.readMapBegin() + if _size141 >= 0: + for _i145 in six.moves.range(_size141): + _key146 = iprot.readI32() + _val147 = [] + (_etype151, _size148) = iprot.readListBegin() + if _size148 >= 0: + for _i152 in six.moves.range(_size148): + _elem153 = Correlativity() + _elem153.read(iprot) + _val147.append(_elem153) + else: + while iprot.peekList(): + _elem154 = Correlativity() + _elem154.read(iprot) + _val147.append(_elem154) + iprot.readListEnd() + self.negative_part_correlativity[_key146] = _val147 + else: + while iprot.peekMap(): + _key155 = iprot.readI32() + _val156 = [] + (_etype160, _size157) = iprot.readListBegin() + if _size157 >= 0: + for _i161 in six.moves.range(_size157): + _elem162 = Correlativity() + _elem162.read(iprot) + _val156.append(_elem162) + else: + while iprot.peekList(): + _elem163 = Correlativity() + _elem163.read(iprot) + _val156.append(_elem163) + iprot.readListEnd() + self.negative_part_correlativity[_key155] = _val156 + iprot.readMapEnd() + else: + iprot.skip(ftype) + elif fid == 7: if ftype == TType.I32: self.status = iprot.readI32() else: @@ -3645,10 +3546,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3661,17 +3558,17 @@ def write(self, oprot): if self.tag_vertices != None: oprot.writeFieldBegin('tag_vertices', TType.MAP, 1) oprot.writeMapBegin(TType.STRING, TType.I64, len(self.tag_vertices)) - for kiter141,viter142 in self.tag_vertices.items(): - oprot.writeString(kiter141) - oprot.writeI64(viter142) + for kiter164,viter165 in self.tag_vertices.items(): + oprot.writeString(kiter164) + oprot.writeI64(viter165) oprot.writeMapEnd() oprot.writeFieldEnd() if self.edges != None: oprot.writeFieldBegin('edges', TType.MAP, 2) oprot.writeMapBegin(TType.STRING, TType.I64, len(self.edges)) - for kiter143,viter144 in self.edges.items(): - oprot.writeString(kiter143) - oprot.writeI64(viter144) + for kiter166,viter167 in self.edges.items(): + oprot.writeString(kiter166) + oprot.writeI64(viter167) oprot.writeMapEnd() oprot.writeFieldEnd() if self.space_vertices != None: @@ -3682,19 +3579,30 @@ def write(self, oprot): oprot.writeFieldBegin('space_edges', TType.I64, 4) oprot.writeI64(self.space_edges) oprot.writeFieldEnd() - if self.part_corelativity != None: - oprot.writeFieldBegin('part_corelativity', TType.MAP, 5) - oprot.writeMapBegin(TType.I32, TType.LIST, len(self.part_corelativity)) - for kiter145,viter146 in self.part_corelativity.items(): - oprot.writeI32(kiter145) - oprot.writeListBegin(TType.STRUCT, len(viter146)) - for iter147 in viter146: - iter147.write(oprot) + if self.positive_part_correlativity != None: + oprot.writeFieldBegin('positive_part_correlativity', TType.MAP, 5) + oprot.writeMapBegin(TType.I32, TType.LIST, len(self.positive_part_correlativity)) + for kiter168,viter169 in self.positive_part_correlativity.items(): + oprot.writeI32(kiter168) + oprot.writeListBegin(TType.STRUCT, len(viter169)) + for iter170 in viter169: + iter170.write(oprot) + oprot.writeListEnd() + oprot.writeMapEnd() + oprot.writeFieldEnd() + if self.negative_part_correlativity != None: + oprot.writeFieldBegin('negative_part_correlativity', TType.MAP, 6) + oprot.writeMapBegin(TType.I32, TType.LIST, len(self.negative_part_correlativity)) + for kiter171,viter172 in self.negative_part_correlativity.items(): + oprot.writeI32(kiter171) + oprot.writeListBegin(TType.STRUCT, len(viter172)) + for iter173 in viter172: + iter173.write(oprot) oprot.writeListEnd() oprot.writeMapEnd() oprot.writeFieldEnd() if self.status != None: - oprot.writeFieldBegin('status', TType.I32, 6) + oprot.writeFieldBegin('status', TType.I32, 7) oprot.writeI32(self.status) oprot.writeFieldEnd() oprot.writeFieldStop() @@ -3719,10 +3627,14 @@ def __repr__(self): value = pprint.pformat(self.space_edges, indent=0) value = padding.join(value.splitlines(True)) L.append(' space_edges=%s' % (value)) - if self.part_corelativity is not None: - value = pprint.pformat(self.part_corelativity, indent=0) + if self.positive_part_correlativity is not None: + value = pprint.pformat(self.positive_part_correlativity, indent=0) + value = padding.join(value.splitlines(True)) + L.append(' positive_part_correlativity=%s' % (value)) + if self.negative_part_correlativity is not None: + value = pprint.pformat(self.negative_part_correlativity, indent=0) value = padding.join(value.splitlines(True)) - L.append(' part_corelativity=%s' % (value)) + L.append(' negative_part_correlativity=%s' % (value)) if self.status is not None: value = pprint.pformat(self.status, indent=0) value = padding.join(value.splitlines(True)) @@ -3760,11 +3672,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3786,10 +3696,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3854,11 +3760,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3879,10 +3783,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3941,11 +3841,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3956,10 +3854,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4009,11 +3903,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4034,17 +3926,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.spaces = [] - (_etype151, _size148) = iprot.readListBegin() - if _size148 >= 0: - for _i152 in six.moves.range(_size148): - _elem153 = IdName() - _elem153.read(iprot) - self.spaces.append(_elem153) + (_etype177, _size174) = iprot.readListBegin() + if _size174 >= 0: + for _i178 in six.moves.range(_size174): + _elem179 = IdName() + _elem179.read(iprot) + self.spaces.append(_elem179) else: while iprot.peekList(): - _elem154 = IdName() - _elem154.read(iprot) - self.spaces.append(_elem154) + _elem180 = IdName() + _elem180.read(iprot) + self.spaces.append(_elem180) iprot.readListEnd() else: iprot.skip(ftype) @@ -4052,10 +3944,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4076,8 +3964,8 @@ def write(self, oprot): if self.spaces != None: oprot.writeFieldBegin('spaces', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.spaces)) - for iter155 in self.spaces: - iter155.write(oprot) + for iter181 in self.spaces: + iter181.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -4130,11 +4018,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4150,10 +4036,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4211,11 +4093,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4243,10 +4123,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4321,11 +4197,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4357,10 +4231,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4443,11 +4313,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4467,17 +4335,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.tag_items = [] - (_etype159, _size156) = iprot.readListBegin() - if _size156 >= 0: - for _i160 in six.moves.range(_size156): - _elem161 = AlterSchemaItem() - _elem161.read(iprot) - self.tag_items.append(_elem161) + (_etype185, _size182) = iprot.readListBegin() + if _size182 >= 0: + for _i186 in six.moves.range(_size182): + _elem187 = AlterSchemaItem() + _elem187.read(iprot) + self.tag_items.append(_elem187) else: while iprot.peekList(): - _elem162 = AlterSchemaItem() - _elem162.read(iprot) - self.tag_items.append(_elem162) + _elem188 = AlterSchemaItem() + _elem188.read(iprot) + self.tag_items.append(_elem188) iprot.readListEnd() else: iprot.skip(ftype) @@ -4491,10 +4359,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4515,8 +4379,8 @@ def write(self, oprot): if self.tag_items != None: oprot.writeFieldBegin('tag_items', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.tag_items)) - for iter163 in self.tag_items: - iter163.write(oprot) + for iter189 in self.tag_items: + iter189.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.schema_prop != None: @@ -4579,11 +4443,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4609,10 +4471,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4684,11 +4542,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4704,10 +4560,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4765,11 +4617,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4790,17 +4640,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.tags = [] - (_etype167, _size164) = iprot.readListBegin() - if _size164 >= 0: - for _i168 in six.moves.range(_size164): - _elem169 = TagItem() - _elem169.read(iprot) - self.tags.append(_elem169) + (_etype193, _size190) = iprot.readListBegin() + if _size190 >= 0: + for _i194 in six.moves.range(_size190): + _elem195 = TagItem() + _elem195.read(iprot) + self.tags.append(_elem195) else: while iprot.peekList(): - _elem170 = TagItem() - _elem170.read(iprot) - self.tags.append(_elem170) + _elem196 = TagItem() + _elem196.read(iprot) + self.tags.append(_elem196) iprot.readListEnd() else: iprot.skip(ftype) @@ -4808,10 +4658,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4832,8 +4678,8 @@ def write(self, oprot): if self.tags != None: oprot.writeFieldBegin('tags', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.tags)) - for iter171 in self.tags: - iter171.write(oprot) + for iter197 in self.tags: + iter197.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -4888,11 +4734,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4918,10 +4762,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4995,11 +4835,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5027,10 +4865,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5105,11 +4939,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5141,10 +4973,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5227,11 +5055,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5251,17 +5077,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.edge_items = [] - (_etype175, _size172) = iprot.readListBegin() - if _size172 >= 0: - for _i176 in six.moves.range(_size172): - _elem177 = AlterSchemaItem() - _elem177.read(iprot) - self.edge_items.append(_elem177) + (_etype201, _size198) = iprot.readListBegin() + if _size198 >= 0: + for _i202 in six.moves.range(_size198): + _elem203 = AlterSchemaItem() + _elem203.read(iprot) + self.edge_items.append(_elem203) else: while iprot.peekList(): - _elem178 = AlterSchemaItem() - _elem178.read(iprot) - self.edge_items.append(_elem178) + _elem204 = AlterSchemaItem() + _elem204.read(iprot) + self.edge_items.append(_elem204) iprot.readListEnd() else: iprot.skip(ftype) @@ -5275,10 +5101,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5299,8 +5121,8 @@ def write(self, oprot): if self.edge_items != None: oprot.writeFieldBegin('edge_items', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.edge_items)) - for iter179 in self.edge_items: - iter179.write(oprot) + for iter205 in self.edge_items: + iter205.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.schema_prop != None: @@ -5363,11 +5185,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5393,10 +5213,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5470,11 +5286,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5502,10 +5316,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5579,11 +5389,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5609,10 +5417,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5684,11 +5488,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5704,10 +5506,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5765,11 +5563,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5790,17 +5586,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.edges = [] - (_etype183, _size180) = iprot.readListBegin() - if _size180 >= 0: - for _i184 in six.moves.range(_size180): - _elem185 = EdgeItem() - _elem185.read(iprot) - self.edges.append(_elem185) + (_etype209, _size206) = iprot.readListBegin() + if _size206 >= 0: + for _i210 in six.moves.range(_size206): + _elem211 = EdgeItem() + _elem211.read(iprot) + self.edges.append(_elem211) else: while iprot.peekList(): - _elem186 = EdgeItem() - _elem186.read(iprot) - self.edges.append(_elem186) + _elem212 = EdgeItem() + _elem212.read(iprot) + self.edges.append(_elem212) iprot.readListEnd() else: iprot.skip(ftype) @@ -5808,10 +5604,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5832,8 +5624,8 @@ def write(self, oprot): if self.edges != None: oprot.writeFieldBegin('edges', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.edges)) - for iter187 in self.edges: - iter187.write(oprot) + for iter213 in self.edges: + iter213.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -5886,11 +5678,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5906,10 +5696,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5967,11 +5753,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5992,17 +5776,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.hosts = [] - (_etype191, _size188) = iprot.readListBegin() - if _size188 >= 0: - for _i192 in six.moves.range(_size188): - _elem193 = HostItem() - _elem193.read(iprot) - self.hosts.append(_elem193) + (_etype217, _size214) = iprot.readListBegin() + if _size214 >= 0: + for _i218 in six.moves.range(_size214): + _elem219 = HostItem() + _elem219.read(iprot) + self.hosts.append(_elem219) else: while iprot.peekList(): - _elem194 = HostItem() - _elem194.read(iprot) - self.hosts.append(_elem194) + _elem220 = HostItem() + _elem220.read(iprot) + self.hosts.append(_elem220) iprot.readListEnd() else: iprot.skip(ftype) @@ -6010,10 +5794,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6034,8 +5814,8 @@ def write(self, oprot): if self.hosts != None: oprot.writeFieldBegin('hosts', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.hosts)) - for iter195 in self.hosts: - iter195.write(oprot) + for iter221 in self.hosts: + iter221.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -6091,11 +5871,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6116,34 +5894,34 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.peers = [] - (_etype199, _size196) = iprot.readListBegin() - if _size196 >= 0: - for _i200 in six.moves.range(_size196): - _elem201 = nebula2.common.ttypes.HostAddr() - _elem201.read(iprot) - self.peers.append(_elem201) + (_etype225, _size222) = iprot.readListBegin() + if _size222 >= 0: + for _i226 in six.moves.range(_size222): + _elem227 = nebula2.common.ttypes.HostAddr() + _elem227.read(iprot) + self.peers.append(_elem227) else: while iprot.peekList(): - _elem202 = nebula2.common.ttypes.HostAddr() - _elem202.read(iprot) - self.peers.append(_elem202) + _elem228 = nebula2.common.ttypes.HostAddr() + _elem228.read(iprot) + self.peers.append(_elem228) iprot.readListEnd() else: iprot.skip(ftype) elif fid == 4: if ftype == TType.LIST: self.losts = [] - (_etype206, _size203) = iprot.readListBegin() - if _size203 >= 0: - for _i207 in six.moves.range(_size203): - _elem208 = nebula2.common.ttypes.HostAddr() - _elem208.read(iprot) - self.losts.append(_elem208) + (_etype232, _size229) = iprot.readListBegin() + if _size229 >= 0: + for _i233 in six.moves.range(_size229): + _elem234 = nebula2.common.ttypes.HostAddr() + _elem234.read(iprot) + self.losts.append(_elem234) else: while iprot.peekList(): - _elem209 = nebula2.common.ttypes.HostAddr() - _elem209.read(iprot) - self.losts.append(_elem209) + _elem235 = nebula2.common.ttypes.HostAddr() + _elem235.read(iprot) + self.losts.append(_elem235) iprot.readListEnd() else: iprot.skip(ftype) @@ -6151,19 +5929,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.part_id == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'part_id' was not found in serialized data! Struct: PartItem") - - if self.peers == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'peers' was not found in serialized data! Struct: PartItem") - - if self.losts == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'losts' was not found in serialized data! Struct: PartItem") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6184,15 +5949,15 @@ def write(self, oprot): if self.peers != None: oprot.writeFieldBegin('peers', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.peers)) - for iter210 in self.peers: - iter210.write(oprot) + for iter236 in self.peers: + iter236.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.losts != None: oprot.writeFieldBegin('losts', TType.LIST, 4) oprot.writeListBegin(TType.STRUCT, len(self.losts)) - for iter211 in self.losts: - iter211.write(oprot) + for iter237 in self.losts: + iter237.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -6250,11 +6015,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6269,15 +6032,15 @@ def read(self, iprot): elif fid == 2: if ftype == TType.LIST: self.part_ids = [] - (_etype215, _size212) = iprot.readListBegin() - if _size212 >= 0: - for _i216 in six.moves.range(_size212): - _elem217 = iprot.readI32() - self.part_ids.append(_elem217) + (_etype241, _size238) = iprot.readListBegin() + if _size238 >= 0: + for _i242 in six.moves.range(_size238): + _elem243 = iprot.readI32() + self.part_ids.append(_elem243) else: while iprot.peekList(): - _elem218 = iprot.readI32() - self.part_ids.append(_elem218) + _elem244 = iprot.readI32() + self.part_ids.append(_elem244) iprot.readListEnd() else: iprot.skip(ftype) @@ -6285,10 +6048,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6305,8 +6064,8 @@ def write(self, oprot): if self.part_ids != None: oprot.writeFieldBegin('part_ids', TType.LIST, 2) oprot.writeListBegin(TType.I32, len(self.part_ids)) - for iter219 in self.part_ids: - oprot.writeI32(iter219) + for iter245 in self.part_ids: + oprot.writeI32(iter245) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -6357,11 +6116,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6382,17 +6139,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.parts = [] - (_etype223, _size220) = iprot.readListBegin() - if _size220 >= 0: - for _i224 in six.moves.range(_size220): - _elem225 = PartItem() - _elem225.read(iprot) - self.parts.append(_elem225) + (_etype249, _size246) = iprot.readListBegin() + if _size246 >= 0: + for _i250 in six.moves.range(_size246): + _elem251 = PartItem() + _elem251.read(iprot) + self.parts.append(_elem251) else: while iprot.peekList(): - _elem226 = PartItem() - _elem226.read(iprot) - self.parts.append(_elem226) + _elem252 = PartItem() + _elem252.read(iprot) + self.parts.append(_elem252) iprot.readListEnd() else: iprot.skip(ftype) @@ -6400,10 +6157,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6424,8 +6177,8 @@ def write(self, oprot): if self.parts != None: oprot.writeFieldBegin('parts', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.parts)) - for iter227 in self.parts: - iter227.write(oprot) + for iter253 in self.parts: + iter253.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -6478,11 +6231,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6498,10 +6249,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6559,11 +6306,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6584,41 +6329,41 @@ def read(self, iprot): elif fid == 3: if ftype == TType.MAP: self.parts = {} - (_ktype229, _vtype230, _size228 ) = iprot.readMapBegin() - if _size228 >= 0: - for _i232 in six.moves.range(_size228): - _key233 = iprot.readI32() - _val234 = [] - (_etype238, _size235) = iprot.readListBegin() - if _size235 >= 0: - for _i239 in six.moves.range(_size235): - _elem240 = nebula2.common.ttypes.HostAddr() - _elem240.read(iprot) - _val234.append(_elem240) + (_ktype255, _vtype256, _size254 ) = iprot.readMapBegin() + if _size254 >= 0: + for _i258 in six.moves.range(_size254): + _key259 = iprot.readI32() + _val260 = [] + (_etype264, _size261) = iprot.readListBegin() + if _size261 >= 0: + for _i265 in six.moves.range(_size261): + _elem266 = nebula2.common.ttypes.HostAddr() + _elem266.read(iprot) + _val260.append(_elem266) else: while iprot.peekList(): - _elem241 = nebula2.common.ttypes.HostAddr() - _elem241.read(iprot) - _val234.append(_elem241) + _elem267 = nebula2.common.ttypes.HostAddr() + _elem267.read(iprot) + _val260.append(_elem267) iprot.readListEnd() - self.parts[_key233] = _val234 + self.parts[_key259] = _val260 else: while iprot.peekMap(): - _key242 = iprot.readI32() - _val243 = [] - (_etype247, _size244) = iprot.readListBegin() - if _size244 >= 0: - for _i248 in six.moves.range(_size244): - _elem249 = nebula2.common.ttypes.HostAddr() - _elem249.read(iprot) - _val243.append(_elem249) + _key268 = iprot.readI32() + _val269 = [] + (_etype273, _size270) = iprot.readListBegin() + if _size270 >= 0: + for _i274 in six.moves.range(_size270): + _elem275 = nebula2.common.ttypes.HostAddr() + _elem275.read(iprot) + _val269.append(_elem275) else: while iprot.peekList(): - _elem250 = nebula2.common.ttypes.HostAddr() - _elem250.read(iprot) - _val243.append(_elem250) + _elem276 = nebula2.common.ttypes.HostAddr() + _elem276.read(iprot) + _val269.append(_elem276) iprot.readListEnd() - self.parts[_key242] = _val243 + self.parts[_key268] = _val269 iprot.readMapEnd() else: iprot.skip(ftype) @@ -6626,10 +6371,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6650,11 +6391,11 @@ def write(self, oprot): if self.parts != None: oprot.writeFieldBegin('parts', TType.MAP, 3) oprot.writeMapBegin(TType.I32, TType.LIST, len(self.parts)) - for kiter251,viter252 in self.parts.items(): - oprot.writeI32(kiter251) - oprot.writeListBegin(TType.STRUCT, len(viter252)) - for iter253 in viter252: - iter253.write(oprot) + for kiter277,viter278 in self.parts.items(): + oprot.writeI32(kiter277) + oprot.writeListBegin(TType.STRUCT, len(viter278)) + for iter279 in viter278: + iter279.write(oprot) oprot.writeListEnd() oprot.writeMapEnd() oprot.writeFieldEnd() @@ -6709,11 +6450,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6728,17 +6467,17 @@ def read(self, iprot): elif fid == 2: if ftype == TType.LIST: self.pairs = [] - (_etype257, _size254) = iprot.readListBegin() - if _size254 >= 0: - for _i258 in six.moves.range(_size254): - _elem259 = nebula2.common.ttypes.KeyValue() - _elem259.read(iprot) - self.pairs.append(_elem259) + (_etype283, _size280) = iprot.readListBegin() + if _size280 >= 0: + for _i284 in six.moves.range(_size280): + _elem285 = nebula2.common.ttypes.KeyValue() + _elem285.read(iprot) + self.pairs.append(_elem285) else: while iprot.peekList(): - _elem260 = nebula2.common.ttypes.KeyValue() - _elem260.read(iprot) - self.pairs.append(_elem260) + _elem286 = nebula2.common.ttypes.KeyValue() + _elem286.read(iprot) + self.pairs.append(_elem286) iprot.readListEnd() else: iprot.skip(ftype) @@ -6746,10 +6485,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6766,8 +6501,8 @@ def write(self, oprot): if self.pairs != None: oprot.writeFieldBegin('pairs', TType.LIST, 2) oprot.writeListBegin(TType.STRUCT, len(self.pairs)) - for iter261 in self.pairs: - iter261.write(oprot) + for iter287 in self.pairs: + iter287.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -6817,11 +6552,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6842,10 +6575,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6911,11 +6640,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6942,10 +6669,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7018,11 +6741,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7037,15 +6758,15 @@ def read(self, iprot): elif fid == 2: if ftype == TType.LIST: self.keys = [] - (_etype265, _size262) = iprot.readListBegin() - if _size262 >= 0: - for _i266 in six.moves.range(_size262): - _elem267 = iprot.readString() - self.keys.append(_elem267) + (_etype291, _size288) = iprot.readListBegin() + if _size288 >= 0: + for _i292 in six.moves.range(_size288): + _elem293 = iprot.readString() + self.keys.append(_elem293) else: while iprot.peekList(): - _elem268 = iprot.readString() - self.keys.append(_elem268) + _elem294 = iprot.readString() + self.keys.append(_elem294) iprot.readListEnd() else: iprot.skip(ftype) @@ -7053,10 +6774,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7073,8 +6790,8 @@ def write(self, oprot): if self.keys != None: oprot.writeFieldBegin('keys', TType.LIST, 2) oprot.writeListBegin(TType.STRING, len(self.keys)) - for iter269 in self.keys: - oprot.writeString(iter269) + for iter295 in self.keys: + oprot.writeString(iter295) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -7125,11 +6842,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7150,15 +6865,15 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.values = [] - (_etype273, _size270) = iprot.readListBegin() - if _size270 >= 0: - for _i274 in six.moves.range(_size270): - _elem275 = iprot.readString() - self.values.append(_elem275) + (_etype299, _size296) = iprot.readListBegin() + if _size296 >= 0: + for _i300 in six.moves.range(_size296): + _elem301 = iprot.readString() + self.values.append(_elem301) else: while iprot.peekList(): - _elem276 = iprot.readString() - self.values.append(_elem276) + _elem302 = iprot.readString() + self.values.append(_elem302) iprot.readListEnd() else: iprot.skip(ftype) @@ -7166,10 +6881,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7190,8 +6901,8 @@ def write(self, oprot): if self.values != None: oprot.writeFieldBegin('values', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.values)) - for iter277 in self.values: - oprot.writeString(iter277) + for iter303 in self.values: + oprot.writeString(iter303) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -7245,11 +6956,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7270,10 +6979,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7339,11 +7044,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7369,10 +7072,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7446,11 +7145,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7476,10 +7173,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7553,11 +7246,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7578,15 +7269,15 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.values = [] - (_etype281, _size278) = iprot.readListBegin() - if _size278 >= 0: - for _i282 in six.moves.range(_size278): - _elem283 = iprot.readString() - self.values.append(_elem283) + (_etype307, _size304) = iprot.readListBegin() + if _size304 >= 0: + for _i308 in six.moves.range(_size304): + _elem309 = iprot.readString() + self.values.append(_elem309) else: while iprot.peekList(): - _elem284 = iprot.readString() - self.values.append(_elem284) + _elem310 = iprot.readString() + self.values.append(_elem310) iprot.readListEnd() else: iprot.skip(ftype) @@ -7594,10 +7285,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7618,8 +7305,8 @@ def write(self, oprot): if self.values != None: oprot.writeFieldBegin('values', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.values)) - for iter285 in self.values: - oprot.writeString(iter285) + for iter311 in self.values: + oprot.writeString(iter311) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -7675,11 +7362,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7711,10 +7396,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7798,11 +7479,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7828,37 +7507,37 @@ def read(self, iprot): elif fid == 4: if ftype == TType.MAP: self.leader_partIds = {} - (_ktype287, _vtype288, _size286 ) = iprot.readMapBegin() - if _size286 >= 0: - for _i290 in six.moves.range(_size286): - _key291 = iprot.readI32() - _val292 = [] - (_etype296, _size293) = iprot.readListBegin() - if _size293 >= 0: - for _i297 in six.moves.range(_size293): - _elem298 = iprot.readI32() - _val292.append(_elem298) + (_ktype313, _vtype314, _size312 ) = iprot.readMapBegin() + if _size312 >= 0: + for _i316 in six.moves.range(_size312): + _key317 = iprot.readI32() + _val318 = [] + (_etype322, _size319) = iprot.readListBegin() + if _size319 >= 0: + for _i323 in six.moves.range(_size319): + _elem324 = iprot.readI32() + _val318.append(_elem324) else: while iprot.peekList(): - _elem299 = iprot.readI32() - _val292.append(_elem299) + _elem325 = iprot.readI32() + _val318.append(_elem325) iprot.readListEnd() - self.leader_partIds[_key291] = _val292 + self.leader_partIds[_key317] = _val318 else: while iprot.peekMap(): - _key300 = iprot.readI32() - _val301 = [] - (_etype305, _size302) = iprot.readListBegin() - if _size302 >= 0: - for _i306 in six.moves.range(_size302): - _elem307 = iprot.readI32() - _val301.append(_elem307) + _key326 = iprot.readI32() + _val327 = [] + (_etype331, _size328) = iprot.readListBegin() + if _size328 >= 0: + for _i332 in six.moves.range(_size328): + _elem333 = iprot.readI32() + _val327.append(_elem333) else: while iprot.peekList(): - _elem308 = iprot.readI32() - _val301.append(_elem308) + _elem334 = iprot.readI32() + _val327.append(_elem334) iprot.readListEnd() - self.leader_partIds[_key300] = _val301 + self.leader_partIds[_key326] = _val327 iprot.readMapEnd() else: iprot.skip(ftype) @@ -7871,10 +7550,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7899,11 +7574,11 @@ def write(self, oprot): if self.leader_partIds != None: oprot.writeFieldBegin('leader_partIds', TType.MAP, 4) oprot.writeMapBegin(TType.I32, TType.LIST, len(self.leader_partIds)) - for kiter309,viter310 in self.leader_partIds.items(): - oprot.writeI32(kiter309) - oprot.writeListBegin(TType.I32, len(viter310)) - for iter311 in viter310: - oprot.writeI32(iter311) + for kiter335,viter336 in self.leader_partIds.items(): + oprot.writeI32(kiter335) + oprot.writeListBegin(TType.I32, len(viter336)) + for iter337 in viter336: + oprot.writeI32(iter337) oprot.writeListEnd() oprot.writeMapEnd() oprot.writeFieldEnd() @@ -7970,11 +7645,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7995,13 +7668,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.name == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'name' was not found in serialized data! Struct: IndexFieldDef") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8069,11 +7735,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8098,17 +7762,17 @@ def read(self, iprot): elif fid == 4: if ftype == TType.LIST: self.fields = [] - (_etype315, _size312) = iprot.readListBegin() - if _size312 >= 0: - for _i316 in six.moves.range(_size312): - _elem317 = IndexFieldDef() - _elem317.read(iprot) - self.fields.append(_elem317) + (_etype341, _size338) = iprot.readListBegin() + if _size338 >= 0: + for _i342 in six.moves.range(_size338): + _elem343 = IndexFieldDef() + _elem343.read(iprot) + self.fields.append(_elem343) else: while iprot.peekList(): - _elem318 = IndexFieldDef() - _elem318.read(iprot) - self.fields.append(_elem318) + _elem344 = IndexFieldDef() + _elem344.read(iprot) + self.fields.append(_elem344) iprot.readListEnd() else: iprot.skip(ftype) @@ -8121,10 +7785,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8149,8 +7809,8 @@ def write(self, oprot): if self.fields != None: oprot.writeFieldBegin('fields', TType.LIST, 4) oprot.writeListBegin(TType.STRUCT, len(self.fields)) - for iter319 in self.fields: - iter319.write(oprot) + for iter345 in self.fields: + iter345.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.if_not_exists != None: @@ -8217,11 +7877,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8247,10 +7905,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8323,11 +7977,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8348,10 +8000,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8417,11 +8065,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8449,10 +8095,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8524,11 +8166,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8544,10 +8184,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8605,11 +8241,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8630,17 +8264,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.items = [] - (_etype323, _size320) = iprot.readListBegin() - if _size320 >= 0: - for _i324 in six.moves.range(_size320): - _elem325 = IndexItem() - _elem325.read(iprot) - self.items.append(_elem325) + (_etype349, _size346) = iprot.readListBegin() + if _size346 >= 0: + for _i350 in six.moves.range(_size346): + _elem351 = IndexItem() + _elem351.read(iprot) + self.items.append(_elem351) else: while iprot.peekList(): - _elem326 = IndexItem() - _elem326.read(iprot) - self.items.append(_elem326) + _elem352 = IndexItem() + _elem352.read(iprot) + self.items.append(_elem352) iprot.readListEnd() else: iprot.skip(ftype) @@ -8648,10 +8282,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8672,8 +8302,8 @@ def write(self, oprot): if self.items != None: oprot.writeFieldBegin('items', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.items)) - for iter327 in self.items: - iter327.write(oprot) + for iter353 in self.items: + iter353.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -8730,11 +8360,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8759,17 +8387,17 @@ def read(self, iprot): elif fid == 4: if ftype == TType.LIST: self.fields = [] - (_etype331, _size328) = iprot.readListBegin() - if _size328 >= 0: - for _i332 in six.moves.range(_size328): - _elem333 = IndexFieldDef() - _elem333.read(iprot) - self.fields.append(_elem333) + (_etype357, _size354) = iprot.readListBegin() + if _size354 >= 0: + for _i358 in six.moves.range(_size354): + _elem359 = IndexFieldDef() + _elem359.read(iprot) + self.fields.append(_elem359) else: while iprot.peekList(): - _elem334 = IndexFieldDef() - _elem334.read(iprot) - self.fields.append(_elem334) + _elem360 = IndexFieldDef() + _elem360.read(iprot) + self.fields.append(_elem360) iprot.readListEnd() else: iprot.skip(ftype) @@ -8782,10 +8410,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8810,8 +8434,8 @@ def write(self, oprot): if self.fields != None: oprot.writeFieldBegin('fields', TType.LIST, 4) oprot.writeListBegin(TType.STRUCT, len(self.fields)) - for iter335 in self.fields: - iter335.write(oprot) + for iter361 in self.fields: + iter361.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.if_not_exists != None: @@ -8878,11 +8502,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8908,10 +8530,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8984,11 +8602,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9009,10 +8625,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9078,11 +8690,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9110,10 +8720,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9185,11 +8791,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9205,10 +8809,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9266,11 +8866,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9291,17 +8889,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.items = [] - (_etype339, _size336) = iprot.readListBegin() - if _size336 >= 0: - for _i340 in six.moves.range(_size336): - _elem341 = IndexItem() - _elem341.read(iprot) - self.items.append(_elem341) + (_etype365, _size362) = iprot.readListBegin() + if _size362 >= 0: + for _i366 in six.moves.range(_size362): + _elem367 = IndexItem() + _elem367.read(iprot) + self.items.append(_elem367) else: while iprot.peekList(): - _elem342 = IndexItem() - _elem342.read(iprot) - self.items.append(_elem342) + _elem368 = IndexItem() + _elem368.read(iprot) + self.items.append(_elem368) iprot.readListEnd() else: iprot.skip(ftype) @@ -9309,10 +8907,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9333,8 +8927,8 @@ def write(self, oprot): if self.items != None: oprot.writeFieldBegin('items', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.items)) - for iter343 in self.items: - iter343.write(oprot) + for iter369 in self.items: + iter369.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -9388,11 +8982,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9413,10 +9005,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9482,11 +9070,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9512,10 +9098,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9588,11 +9170,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9613,10 +9193,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9681,11 +9257,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9706,10 +9280,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9773,11 +9343,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9794,10 +9362,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9853,11 +9417,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9874,10 +9436,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9928,11 +9486,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -9943,10 +9499,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -9996,11 +9548,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10021,17 +9571,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.MAP: self.users = {} - (_ktype345, _vtype346, _size344 ) = iprot.readMapBegin() - if _size344 >= 0: - for _i348 in six.moves.range(_size344): - _key349 = iprot.readString() - _val350 = iprot.readString() - self.users[_key349] = _val350 + (_ktype371, _vtype372, _size370 ) = iprot.readMapBegin() + if _size370 >= 0: + for _i374 in six.moves.range(_size370): + _key375 = iprot.readString() + _val376 = iprot.readString() + self.users[_key375] = _val376 else: while iprot.peekMap(): - _key351 = iprot.readString() - _val352 = iprot.readString() - self.users[_key351] = _val352 + _key377 = iprot.readString() + _val378 = iprot.readString() + self.users[_key377] = _val378 iprot.readMapEnd() else: iprot.skip(ftype) @@ -10039,10 +9589,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10063,9 +9609,9 @@ def write(self, oprot): if self.users != None: oprot.writeFieldBegin('users', TType.MAP, 3) oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.users)) - for kiter353,viter354 in self.users.items(): - oprot.writeString(kiter353) - oprot.writeString(viter354) + for kiter379,viter380 in self.users.items(): + oprot.writeString(kiter379) + oprot.writeString(viter380) oprot.writeMapEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -10118,11 +9664,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10138,10 +9682,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10199,11 +9739,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10224,17 +9762,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.roles = [] - (_etype358, _size355) = iprot.readListBegin() - if _size355 >= 0: - for _i359 in six.moves.range(_size355): - _elem360 = RoleItem() - _elem360.read(iprot) - self.roles.append(_elem360) + (_etype384, _size381) = iprot.readListBegin() + if _size381 >= 0: + for _i385 in six.moves.range(_size381): + _elem386 = RoleItem() + _elem386.read(iprot) + self.roles.append(_elem386) else: while iprot.peekList(): - _elem361 = RoleItem() - _elem361.read(iprot) - self.roles.append(_elem361) + _elem387 = RoleItem() + _elem387.read(iprot) + self.roles.append(_elem387) iprot.readListEnd() else: iprot.skip(ftype) @@ -10242,10 +9780,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10266,8 +9800,8 @@ def write(self, oprot): if self.roles != None: oprot.writeFieldBegin('roles', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.roles)) - for iter362 in self.roles: - iter362.write(oprot) + for iter388 in self.roles: + iter388.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -10320,11 +9854,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10340,10 +9872,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10401,11 +9929,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10431,10 +9957,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10510,11 +10032,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10534,17 +10054,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.host_del = [] - (_etype366, _size363) = iprot.readListBegin() - if _size363 >= 0: - for _i367 in six.moves.range(_size363): - _elem368 = nebula2.common.ttypes.HostAddr() - _elem368.read(iprot) - self.host_del.append(_elem368) + (_etype392, _size389) = iprot.readListBegin() + if _size389 >= 0: + for _i393 in six.moves.range(_size389): + _elem394 = nebula2.common.ttypes.HostAddr() + _elem394.read(iprot) + self.host_del.append(_elem394) else: while iprot.peekList(): - _elem369 = nebula2.common.ttypes.HostAddr() - _elem369.read(iprot) - self.host_del.append(_elem369) + _elem395 = nebula2.common.ttypes.HostAddr() + _elem395.read(iprot) + self.host_del.append(_elem395) iprot.readListEnd() else: iprot.skip(ftype) @@ -10562,10 +10082,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10586,8 +10102,8 @@ def write(self, oprot): if self.host_del != None: oprot.writeFieldBegin('host_del', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.host_del)) - for iter370 in self.host_del: - iter370.write(oprot) + for iter396 in self.host_del: + iter396.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.stop != None: @@ -10657,11 +10173,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10682,10 +10196,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10752,11 +10262,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10782,17 +10290,17 @@ def read(self, iprot): elif fid == 4: if ftype == TType.LIST: self.tasks = [] - (_etype374, _size371) = iprot.readListBegin() - if _size371 >= 0: - for _i375 in six.moves.range(_size371): - _elem376 = BalanceTask() - _elem376.read(iprot) - self.tasks.append(_elem376) + (_etype400, _size397) = iprot.readListBegin() + if _size397 >= 0: + for _i401 in six.moves.range(_size397): + _elem402 = BalanceTask() + _elem402.read(iprot) + self.tasks.append(_elem402) else: while iprot.peekList(): - _elem377 = BalanceTask() - _elem377.read(iprot) - self.tasks.append(_elem377) + _elem403 = BalanceTask() + _elem403.read(iprot) + self.tasks.append(_elem403) iprot.readListEnd() else: iprot.skip(ftype) @@ -10800,10 +10308,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10828,8 +10332,8 @@ def write(self, oprot): if self.tasks != None: oprot.writeFieldBegin('tasks', TType.LIST, 4) oprot.writeListBegin(TType.STRUCT, len(self.tasks)) - for iter378 in self.tasks: - iter378.write(oprot) + for iter404 in self.tasks: + iter404.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -10881,11 +10385,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10896,10 +10398,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -10950,11 +10448,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -10986,10 +10482,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11069,11 +10561,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11083,17 +10573,17 @@ def read(self, iprot): if fid == 1: if ftype == TType.LIST: self.items = [] - (_etype382, _size379) = iprot.readListBegin() - if _size379 >= 0: - for _i383 in six.moves.range(_size379): - _elem384 = ConfigItem() - _elem384.read(iprot) - self.items.append(_elem384) + (_etype408, _size405) = iprot.readListBegin() + if _size405 >= 0: + for _i409 in six.moves.range(_size405): + _elem410 = ConfigItem() + _elem410.read(iprot) + self.items.append(_elem410) else: while iprot.peekList(): - _elem385 = ConfigItem() - _elem385.read(iprot) - self.items.append(_elem385) + _elem411 = ConfigItem() + _elem411.read(iprot) + self.items.append(_elem411) iprot.readListEnd() else: iprot.skip(ftype) @@ -11101,10 +10591,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11117,8 +10603,8 @@ def write(self, oprot): if self.items != None: oprot.writeFieldBegin('items', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.items)) - for iter386 in self.items: - iter386.write(oprot) + for iter412 in self.items: + iter412.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -11163,11 +10649,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11184,10 +10668,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11245,11 +10725,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11270,17 +10748,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.items = [] - (_etype390, _size387) = iprot.readListBegin() - if _size387 >= 0: - for _i391 in six.moves.range(_size387): - _elem392 = ConfigItem() - _elem392.read(iprot) - self.items.append(_elem392) + (_etype416, _size413) = iprot.readListBegin() + if _size413 >= 0: + for _i417 in six.moves.range(_size413): + _elem418 = ConfigItem() + _elem418.read(iprot) + self.items.append(_elem418) else: while iprot.peekList(): - _elem393 = ConfigItem() - _elem393.read(iprot) - self.items.append(_elem393) + _elem419 = ConfigItem() + _elem419.read(iprot) + self.items.append(_elem419) iprot.readListEnd() else: iprot.skip(ftype) @@ -11288,10 +10766,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11312,8 +10786,8 @@ def write(self, oprot): if self.items != None: oprot.writeFieldBegin('items', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.items)) - for iter394 in self.items: - iter394.write(oprot) + for iter420 in self.items: + iter420.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -11366,11 +10840,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11387,10 +10859,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11447,11 +10915,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11472,10 +10938,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11541,11 +11003,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11566,17 +11026,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.items = [] - (_etype398, _size395) = iprot.readListBegin() - if _size395 >= 0: - for _i399 in six.moves.range(_size395): - _elem400 = ConfigItem() - _elem400.read(iprot) - self.items.append(_elem400) + (_etype424, _size421) = iprot.readListBegin() + if _size421 >= 0: + for _i425 in six.moves.range(_size421): + _elem426 = ConfigItem() + _elem426.read(iprot) + self.items.append(_elem426) else: while iprot.peekList(): - _elem401 = ConfigItem() - _elem401.read(iprot) - self.items.append(_elem401) + _elem427 = ConfigItem() + _elem427.read(iprot) + self.items.append(_elem427) iprot.readListEnd() else: iprot.skip(ftype) @@ -11584,10 +11044,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11608,8 +11064,8 @@ def write(self, oprot): if self.items != None: oprot.writeFieldBegin('items', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.items)) - for iter402 in self.items: - iter402.write(oprot) + for iter428 in self.items: + iter428.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -11657,11 +11113,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11672,10 +11126,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11723,11 +11173,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11743,10 +11191,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11797,11 +11241,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11812,10 +11254,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11865,11 +11303,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11895,10 +11331,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -11972,11 +11404,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -11997,17 +11427,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.snapshots = [] - (_etype406, _size403) = iprot.readListBegin() - if _size403 >= 0: - for _i407 in six.moves.range(_size403): - _elem408 = Snapshot() - _elem408.read(iprot) - self.snapshots.append(_elem408) + (_etype432, _size429) = iprot.readListBegin() + if _size429 >= 0: + for _i433 in six.moves.range(_size429): + _elem434 = Snapshot() + _elem434.read(iprot) + self.snapshots.append(_elem434) else: while iprot.peekList(): - _elem409 = Snapshot() - _elem409.read(iprot) - self.snapshots.append(_elem409) + _elem435 = Snapshot() + _elem435.read(iprot) + self.snapshots.append(_elem435) iprot.readListEnd() else: iprot.skip(ftype) @@ -12015,10 +11445,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12039,8 +11465,8 @@ def write(self, oprot): if self.snapshots != None: oprot.writeFieldBegin('snapshots', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.snapshots)) - for iter410 in self.snapshots: - iter410.write(oprot) + for iter436 in self.snapshots: + iter436.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -12093,11 +11519,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12113,10 +11537,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12173,11 +11593,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12198,10 +11616,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12267,11 +11681,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12292,17 +11704,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.statuses = [] - (_etype414, _size411) = iprot.readListBegin() - if _size411 >= 0: - for _i415 in six.moves.range(_size411): - _elem416 = IndexStatus() - _elem416.read(iprot) - self.statuses.append(_elem416) + (_etype440, _size437) = iprot.readListBegin() + if _size437 >= 0: + for _i441 in six.moves.range(_size437): + _elem442 = IndexStatus() + _elem442.read(iprot) + self.statuses.append(_elem442) else: while iprot.peekList(): - _elem417 = IndexStatus() - _elem417.read(iprot) - self.statuses.append(_elem417) + _elem443 = IndexStatus() + _elem443.read(iprot) + self.statuses.append(_elem443) iprot.readListEnd() else: iprot.skip(ftype) @@ -12310,10 +11722,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12334,8 +11742,8 @@ def write(self, oprot): if self.statuses != None: oprot.writeFieldBegin('statuses', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.statuses)) - for iter418 in self.statuses: - iter418.write(oprot) + for iter444 in self.statuses: + iter444.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -12389,11 +11797,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12408,17 +11814,17 @@ def read(self, iprot): elif fid == 2: if ftype == TType.LIST: self.nodes = [] - (_etype422, _size419) = iprot.readListBegin() - if _size419 >= 0: - for _i423 in six.moves.range(_size419): - _elem424 = nebula2.common.ttypes.HostAddr() - _elem424.read(iprot) - self.nodes.append(_elem424) + (_etype448, _size445) = iprot.readListBegin() + if _size445 >= 0: + for _i449 in six.moves.range(_size445): + _elem450 = nebula2.common.ttypes.HostAddr() + _elem450.read(iprot) + self.nodes.append(_elem450) else: while iprot.peekList(): - _elem425 = nebula2.common.ttypes.HostAddr() - _elem425.read(iprot) - self.nodes.append(_elem425) + _elem451 = nebula2.common.ttypes.HostAddr() + _elem451.read(iprot) + self.nodes.append(_elem451) iprot.readListEnd() else: iprot.skip(ftype) @@ -12426,10 +11832,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12446,8 +11848,8 @@ def write(self, oprot): if self.nodes != None: oprot.writeFieldBegin('nodes', TType.LIST, 2) oprot.writeListBegin(TType.STRUCT, len(self.nodes)) - for iter426 in self.nodes: - iter426.write(oprot) + for iter452 in self.nodes: + iter452.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -12496,11 +11898,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12516,10 +11916,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12576,11 +11972,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12602,10 +11996,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12670,11 +12060,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12696,10 +12084,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12763,11 +12147,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12783,10 +12165,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12844,11 +12222,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12869,17 +12245,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.hosts = [] - (_etype430, _size427) = iprot.readListBegin() - if _size427 >= 0: - for _i431 in six.moves.range(_size427): - _elem432 = nebula2.common.ttypes.HostAddr() - _elem432.read(iprot) - self.hosts.append(_elem432) + (_etype456, _size453) = iprot.readListBegin() + if _size453 >= 0: + for _i457 in six.moves.range(_size453): + _elem458 = nebula2.common.ttypes.HostAddr() + _elem458.read(iprot) + self.hosts.append(_elem458) else: while iprot.peekList(): - _elem433 = nebula2.common.ttypes.HostAddr() - _elem433.read(iprot) - self.hosts.append(_elem433) + _elem459 = nebula2.common.ttypes.HostAddr() + _elem459.read(iprot) + self.hosts.append(_elem459) iprot.readListEnd() else: iprot.skip(ftype) @@ -12887,10 +12263,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -12911,8 +12283,8 @@ def write(self, oprot): if self.hosts != None: oprot.writeFieldBegin('hosts', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.hosts)) - for iter434 in self.hosts: - iter434.write(oprot) + for iter460 in self.hosts: + iter460.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -12960,11 +12332,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -12975,10 +12345,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13027,11 +12393,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13046,17 +12410,17 @@ def read(self, iprot): elif fid == 2: if ftype == TType.LIST: self.nodes = [] - (_etype438, _size435) = iprot.readListBegin() - if _size435 >= 0: - for _i439 in six.moves.range(_size435): - _elem440 = nebula2.common.ttypes.HostAddr() - _elem440.read(iprot) - self.nodes.append(_elem440) + (_etype464, _size461) = iprot.readListBegin() + if _size461 >= 0: + for _i465 in six.moves.range(_size461): + _elem466 = nebula2.common.ttypes.HostAddr() + _elem466.read(iprot) + self.nodes.append(_elem466) else: while iprot.peekList(): - _elem441 = nebula2.common.ttypes.HostAddr() - _elem441.read(iprot) - self.nodes.append(_elem441) + _elem467 = nebula2.common.ttypes.HostAddr() + _elem467.read(iprot) + self.nodes.append(_elem467) iprot.readListEnd() else: iprot.skip(ftype) @@ -13064,10 +12428,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13084,8 +12444,8 @@ def write(self, oprot): if self.nodes != None: oprot.writeFieldBegin('nodes', TType.LIST, 2) oprot.writeListBegin(TType.STRUCT, len(self.nodes)) - for iter442 in self.nodes: - iter442.write(oprot) + for iter468 in self.nodes: + iter468.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -13136,11 +12496,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13161,17 +12519,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.zones = [] - (_etype446, _size443) = iprot.readListBegin() - if _size443 >= 0: - for _i447 in six.moves.range(_size443): - _elem448 = Zone() - _elem448.read(iprot) - self.zones.append(_elem448) + (_etype472, _size469) = iprot.readListBegin() + if _size469 >= 0: + for _i473 in six.moves.range(_size469): + _elem474 = Zone() + _elem474.read(iprot) + self.zones.append(_elem474) else: while iprot.peekList(): - _elem449 = Zone() - _elem449.read(iprot) - self.zones.append(_elem449) + _elem475 = Zone() + _elem475.read(iprot) + self.zones.append(_elem475) iprot.readListEnd() else: iprot.skip(ftype) @@ -13179,10 +12537,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13203,8 +12557,8 @@ def write(self, oprot): if self.zones != None: oprot.writeFieldBegin('zones', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.zones)) - for iter450 in self.zones: - iter450.write(oprot) + for iter476 in self.zones: + iter476.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -13258,11 +12612,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13277,15 +12629,15 @@ def read(self, iprot): elif fid == 2: if ftype == TType.LIST: self.zone_names = [] - (_etype454, _size451) = iprot.readListBegin() - if _size451 >= 0: - for _i455 in six.moves.range(_size451): - _elem456 = iprot.readString() - self.zone_names.append(_elem456) + (_etype480, _size477) = iprot.readListBegin() + if _size477 >= 0: + for _i481 in six.moves.range(_size477): + _elem482 = iprot.readString() + self.zone_names.append(_elem482) else: while iprot.peekList(): - _elem457 = iprot.readString() - self.zone_names.append(_elem457) + _elem483 = iprot.readString() + self.zone_names.append(_elem483) iprot.readListEnd() else: iprot.skip(ftype) @@ -13293,10 +12645,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13313,8 +12661,8 @@ def write(self, oprot): if self.zone_names != None: oprot.writeFieldBegin('zone_names', TType.LIST, 2) oprot.writeListBegin(TType.STRING, len(self.zone_names)) - for iter458 in self.zone_names: - oprot.writeString(iter458) + for iter484 in self.zone_names: + oprot.writeString(iter484) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -13363,11 +12711,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13383,10 +12729,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13443,11 +12785,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13468,10 +12808,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13536,11 +12872,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13561,10 +12895,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13628,11 +12958,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13648,10 +12976,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13709,11 +13033,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13734,15 +13056,15 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.zone_names = [] - (_etype462, _size459) = iprot.readListBegin() - if _size459 >= 0: - for _i463 in six.moves.range(_size459): - _elem464 = iprot.readString() - self.zone_names.append(_elem464) + (_etype488, _size485) = iprot.readListBegin() + if _size485 >= 0: + for _i489 in six.moves.range(_size485): + _elem490 = iprot.readString() + self.zone_names.append(_elem490) else: while iprot.peekList(): - _elem465 = iprot.readString() - self.zone_names.append(_elem465) + _elem491 = iprot.readString() + self.zone_names.append(_elem491) iprot.readListEnd() else: iprot.skip(ftype) @@ -13750,10 +13072,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13774,8 +13092,8 @@ def write(self, oprot): if self.zone_names != None: oprot.writeFieldBegin('zone_names', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.zone_names)) - for iter466 in self.zone_names: - oprot.writeString(iter466) + for iter492 in self.zone_names: + oprot.writeString(iter492) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -13823,11 +13141,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13838,10 +13154,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13890,11 +13202,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -13909,15 +13219,15 @@ def read(self, iprot): elif fid == 2: if ftype == TType.LIST: self.zone_names = [] - (_etype470, _size467) = iprot.readListBegin() - if _size467 >= 0: - for _i471 in six.moves.range(_size467): - _elem472 = iprot.readString() - self.zone_names.append(_elem472) + (_etype496, _size493) = iprot.readListBegin() + if _size493 >= 0: + for _i497 in six.moves.range(_size493): + _elem498 = iprot.readString() + self.zone_names.append(_elem498) else: while iprot.peekList(): - _elem473 = iprot.readString() - self.zone_names.append(_elem473) + _elem499 = iprot.readString() + self.zone_names.append(_elem499) iprot.readListEnd() else: iprot.skip(ftype) @@ -13925,10 +13235,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -13945,8 +13251,8 @@ def write(self, oprot): if self.zone_names != None: oprot.writeFieldBegin('zone_names', TType.LIST, 2) oprot.writeListBegin(TType.STRING, len(self.zone_names)) - for iter474 in self.zone_names: - oprot.writeString(iter474) + for iter500 in self.zone_names: + oprot.writeString(iter500) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -13997,11 +13303,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14022,17 +13326,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.groups = [] - (_etype478, _size475) = iprot.readListBegin() - if _size475 >= 0: - for _i479 in six.moves.range(_size475): - _elem480 = Group() - _elem480.read(iprot) - self.groups.append(_elem480) + (_etype504, _size501) = iprot.readListBegin() + if _size501 >= 0: + for _i505 in six.moves.range(_size501): + _elem506 = Group() + _elem506.read(iprot) + self.groups.append(_elem506) else: while iprot.peekList(): - _elem481 = Group() - _elem481.read(iprot) - self.groups.append(_elem481) + _elem507 = Group() + _elem507.read(iprot) + self.groups.append(_elem507) iprot.readListEnd() else: iprot.skip(ftype) @@ -14040,10 +13344,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14064,8 +13364,8 @@ def write(self, oprot): if self.groups != None: oprot.writeFieldBegin('groups', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.groups)) - for iter482 in self.groups: - iter482.write(oprot) + for iter508 in self.groups: + iter508.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -14120,11 +13420,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14144,17 +13442,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.hosts = [] - (_etype486, _size483) = iprot.readListBegin() - if _size483 >= 0: - for _i487 in six.moves.range(_size483): - _elem488 = nebula2.common.ttypes.HostAddr() - _elem488.read(iprot) - self.hosts.append(_elem488) + (_etype512, _size509) = iprot.readListBegin() + if _size509 >= 0: + for _i513 in six.moves.range(_size509): + _elem514 = nebula2.common.ttypes.HostAddr() + _elem514.read(iprot) + self.hosts.append(_elem514) else: while iprot.peekList(): - _elem489 = nebula2.common.ttypes.HostAddr() - _elem489.read(iprot) - self.hosts.append(_elem489) + _elem515 = nebula2.common.ttypes.HostAddr() + _elem515.read(iprot) + self.hosts.append(_elem515) iprot.readListEnd() else: iprot.skip(ftype) @@ -14162,10 +13460,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14186,8 +13480,8 @@ def write(self, oprot): if self.hosts != None: oprot.writeFieldBegin('hosts', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.hosts)) - for iter490 in self.hosts: - iter490.write(oprot) + for iter516 in self.hosts: + iter516.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -14241,11 +13535,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14266,10 +13558,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14333,11 +13621,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14353,10 +13639,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14415,11 +13697,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14451,10 +13731,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14536,11 +13812,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14561,17 +13835,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.listeners = [] - (_etype494, _size491) = iprot.readListBegin() - if _size491 >= 0: - for _i495 in six.moves.range(_size491): - _elem496 = ListenerInfo() - _elem496.read(iprot) - self.listeners.append(_elem496) + (_etype520, _size517) = iprot.readListBegin() + if _size517 >= 0: + for _i521 in six.moves.range(_size517): + _elem522 = ListenerInfo() + _elem522.read(iprot) + self.listeners.append(_elem522) else: while iprot.peekList(): - _elem497 = ListenerInfo() - _elem497.read(iprot) - self.listeners.append(_elem497) + _elem523 = ListenerInfo() + _elem523.read(iprot) + self.listeners.append(_elem523) iprot.readListEnd() else: iprot.skip(ftype) @@ -14579,10 +13853,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14603,8 +13873,8 @@ def write(self, oprot): if self.listeners != None: oprot.writeFieldBegin('listeners', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.listeners)) - for iter498 in self.listeners: - iter498.write(oprot) + for iter524 in self.listeners: + iter524.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -14657,11 +13927,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14677,10 +13945,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14738,11 +14002,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14770,10 +14032,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14846,11 +14104,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14872,10 +14128,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -14941,11 +14193,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -14967,17 +14217,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.cp_dirs = [] - (_etype502, _size499) = iprot.readListBegin() - if _size499 >= 0: - for _i503 in six.moves.range(_size499): - _elem504 = CheckpointInfo() - _elem504.read(iprot) - self.cp_dirs.append(_elem504) + (_etype528, _size525) = iprot.readListBegin() + if _size525 >= 0: + for _i529 in six.moves.range(_size525): + _elem530 = CheckpointInfo() + _elem530.read(iprot) + self.cp_dirs.append(_elem530) else: while iprot.peekList(): - _elem505 = CheckpointInfo() - _elem505.read(iprot) - self.cp_dirs.append(_elem505) + _elem531 = CheckpointInfo() + _elem531.read(iprot) + self.cp_dirs.append(_elem531) iprot.readListEnd() else: iprot.skip(ftype) @@ -14985,10 +14235,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15009,8 +14255,8 @@ def write(self, oprot): if self.cp_dirs != None: oprot.writeFieldBegin('cp_dirs', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.cp_dirs)) - for iter506 in self.cp_dirs: - iter506.write(oprot) + for iter532 in self.cp_dirs: + iter532.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -15065,11 +14311,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15079,34 +14323,34 @@ def read(self, iprot): if fid == 1: if ftype == TType.MAP: self.backup_info = {} - (_ktype508, _vtype509, _size507 ) = iprot.readMapBegin() - if _size507 >= 0: - for _i511 in six.moves.range(_size507): - _key512 = iprot.readI32() - _val513 = SpaceBackupInfo() - _val513.read(iprot) - self.backup_info[_key512] = _val513 + (_ktype534, _vtype535, _size533 ) = iprot.readMapBegin() + if _size533 >= 0: + for _i537 in six.moves.range(_size533): + _key538 = iprot.readI32() + _val539 = SpaceBackupInfo() + _val539.read(iprot) + self.backup_info[_key538] = _val539 else: while iprot.peekMap(): - _key514 = iprot.readI32() - _val515 = SpaceBackupInfo() - _val515.read(iprot) - self.backup_info[_key514] = _val515 + _key540 = iprot.readI32() + _val541 = SpaceBackupInfo() + _val541.read(iprot) + self.backup_info[_key540] = _val541 iprot.readMapEnd() else: iprot.skip(ftype) elif fid == 2: if ftype == TType.LIST: self.meta_files = [] - (_etype519, _size516) = iprot.readListBegin() - if _size516 >= 0: - for _i520 in six.moves.range(_size516): - _elem521 = iprot.readString() - self.meta_files.append(_elem521) + (_etype545, _size542) = iprot.readListBegin() + if _size542 >= 0: + for _i546 in six.moves.range(_size542): + _elem547 = iprot.readString() + self.meta_files.append(_elem547) else: while iprot.peekList(): - _elem522 = iprot.readString() - self.meta_files.append(_elem522) + _elem548 = iprot.readString() + self.meta_files.append(_elem548) iprot.readListEnd() else: iprot.skip(ftype) @@ -15119,10 +14363,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15135,16 +14375,16 @@ def write(self, oprot): if self.backup_info != None: oprot.writeFieldBegin('backup_info', TType.MAP, 1) oprot.writeMapBegin(TType.I32, TType.STRUCT, len(self.backup_info)) - for kiter523,viter524 in self.backup_info.items(): - oprot.writeI32(kiter523) - viter524.write(oprot) + for kiter549,viter550 in self.backup_info.items(): + oprot.writeI32(kiter549) + viter550.write(oprot) oprot.writeMapEnd() oprot.writeFieldEnd() if self.meta_files != None: oprot.writeFieldBegin('meta_files', TType.LIST, 2) oprot.writeListBegin(TType.STRING, len(self.meta_files)) - for iter525 in self.meta_files: - oprot.writeString(iter525) + for iter551 in self.meta_files: + oprot.writeString(iter551) oprot.writeListEnd() oprot.writeFieldEnd() if self.backup_name != None: @@ -15201,11 +14441,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15215,15 +14453,15 @@ def read(self, iprot): if fid == 1: if ftype == TType.LIST: self.spaces = [] - (_etype529, _size526) = iprot.readListBegin() - if _size526 >= 0: - for _i530 in six.moves.range(_size526): - _elem531 = iprot.readString() - self.spaces.append(_elem531) + (_etype555, _size552) = iprot.readListBegin() + if _size552 >= 0: + for _i556 in six.moves.range(_size552): + _elem557 = iprot.readString() + self.spaces.append(_elem557) else: while iprot.peekList(): - _elem532 = iprot.readString() - self.spaces.append(_elem532) + _elem558 = iprot.readString() + self.spaces.append(_elem558) iprot.readListEnd() else: iprot.skip(ftype) @@ -15231,10 +14469,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15247,8 +14481,8 @@ def write(self, oprot): if self.spaces != None: oprot.writeFieldBegin('spaces', TType.LIST, 1) oprot.writeListBegin(TType.STRING, len(self.spaces)) - for iter533 in self.spaces: - oprot.writeString(iter533) + for iter559 in self.spaces: + oprot.writeString(iter559) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -15295,11 +14529,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15327,10 +14559,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15403,11 +14631,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15430,10 +14656,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15498,11 +14720,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15512,32 +14732,32 @@ def read(self, iprot): if fid == 1: if ftype == TType.LIST: self.files = [] - (_etype537, _size534) = iprot.readListBegin() - if _size534 >= 0: - for _i538 in six.moves.range(_size534): - _elem539 = iprot.readString() - self.files.append(_elem539) + (_etype563, _size560) = iprot.readListBegin() + if _size560 >= 0: + for _i564 in six.moves.range(_size560): + _elem565 = iprot.readString() + self.files.append(_elem565) else: while iprot.peekList(): - _elem540 = iprot.readString() - self.files.append(_elem540) + _elem566 = iprot.readString() + self.files.append(_elem566) iprot.readListEnd() else: iprot.skip(ftype) elif fid == 2: if ftype == TType.LIST: self.hosts = [] - (_etype544, _size541) = iprot.readListBegin() - if _size541 >= 0: - for _i545 in six.moves.range(_size541): - _elem546 = HostPair() - _elem546.read(iprot) - self.hosts.append(_elem546) + (_etype570, _size567) = iprot.readListBegin() + if _size567 >= 0: + for _i571 in six.moves.range(_size567): + _elem572 = HostPair() + _elem572.read(iprot) + self.hosts.append(_elem572) else: while iprot.peekList(): - _elem547 = HostPair() - _elem547.read(iprot) - self.hosts.append(_elem547) + _elem573 = HostPair() + _elem573.read(iprot) + self.hosts.append(_elem573) iprot.readListEnd() else: iprot.skip(ftype) @@ -15545,10 +14765,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15561,15 +14777,15 @@ def write(self, oprot): if self.files != None: oprot.writeFieldBegin('files', TType.LIST, 1) oprot.writeListBegin(TType.STRING, len(self.files)) - for iter548 in self.files: - oprot.writeString(iter548) + for iter574 in self.files: + oprot.writeString(iter574) oprot.writeListEnd() oprot.writeFieldEnd() if self.hosts != None: oprot.writeFieldBegin('hosts', TType.LIST, 2) oprot.writeListBegin(TType.STRUCT, len(self.hosts)) - for iter549 in self.hosts: - iter549.write(oprot) + for iter575 in self.hosts: + iter575.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -15620,11 +14836,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15651,13 +14865,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.host == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'host' was not found in serialized data! Struct: FTClient") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15730,11 +14937,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15749,17 +14954,17 @@ def read(self, iprot): elif fid == 2: if ftype == TType.LIST: self.clients = [] - (_etype553, _size550) = iprot.readListBegin() - if _size550 >= 0: - for _i554 in six.moves.range(_size550): - _elem555 = FTClient() - _elem555.read(iprot) - self.clients.append(_elem555) + (_etype579, _size576) = iprot.readListBegin() + if _size576 >= 0: + for _i580 in six.moves.range(_size576): + _elem581 = FTClient() + _elem581.read(iprot) + self.clients.append(_elem581) else: while iprot.peekList(): - _elem556 = FTClient() - _elem556.read(iprot) - self.clients.append(_elem556) + _elem582 = FTClient() + _elem582.read(iprot) + self.clients.append(_elem582) iprot.readListEnd() else: iprot.skip(ftype) @@ -15767,10 +14972,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15787,8 +14988,8 @@ def write(self, oprot): if self.clients != None: oprot.writeFieldBegin('clients', TType.LIST, 2) oprot.writeListBegin(TType.STRUCT, len(self.clients)) - for iter557 in self.clients: - iter557.write(oprot) + for iter583 in self.clients: + iter583.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -15832,11 +15033,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15847,10 +15046,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15893,11 +15088,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15908,10 +15101,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -15961,11 +15150,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -15986,17 +15173,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.clients = [] - (_etype561, _size558) = iprot.readListBegin() - if _size558 >= 0: - for _i562 in six.moves.range(_size558): - _elem563 = FTClient() - _elem563.read(iprot) - self.clients.append(_elem563) + (_etype587, _size584) = iprot.readListBegin() + if _size584 >= 0: + for _i588 in six.moves.range(_size584): + _elem589 = FTClient() + _elem589.read(iprot) + self.clients.append(_elem589) else: while iprot.peekList(): - _elem564 = FTClient() - _elem564.read(iprot) - self.clients.append(_elem564) + _elem590 = FTClient() + _elem590.read(iprot) + self.clients.append(_elem590) iprot.readListEnd() else: iprot.skip(ftype) @@ -16004,10 +15191,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16028,8 +15211,8 @@ def write(self, oprot): if self.clients != None: oprot.writeFieldBegin('clients', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.clients)) - for iter565 in self.clients: - iter565.write(oprot) + for iter591 in self.clients: + iter591.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -16090,11 +15273,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16145,19 +15326,19 @@ def read(self, iprot): elif fid == 9: if ftype == TType.MAP: self.configs = {} - (_ktype567, _vtype568, _size566 ) = iprot.readMapBegin() - if _size566 >= 0: - for _i570 in six.moves.range(_size566): - _key571 = iprot.readString() - _val572 = nebula2.common.ttypes.Value() - _val572.read(iprot) - self.configs[_key571] = _val572 + (_ktype593, _vtype594, _size592 ) = iprot.readMapBegin() + if _size592 >= 0: + for _i596 in six.moves.range(_size592): + _key597 = iprot.readString() + _val598 = nebula2.common.ttypes.Value() + _val598.read(iprot) + self.configs[_key597] = _val598 else: while iprot.peekMap(): - _key573 = iprot.readString() - _val574 = nebula2.common.ttypes.Value() - _val574.read(iprot) - self.configs[_key573] = _val574 + _key599 = iprot.readString() + _val600 = nebula2.common.ttypes.Value() + _val600.read(iprot) + self.configs[_key599] = _val600 iprot.readMapEnd() else: iprot.skip(ftype) @@ -16165,10 +15346,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16213,9 +15390,9 @@ def write(self, oprot): if self.configs != None: oprot.writeFieldBegin('configs', TType.MAP, 9) oprot.writeMapBegin(TType.STRING, TType.STRUCT, len(self.configs)) - for kiter575,viter576 in self.configs.items(): - oprot.writeString(kiter575) - viter576.write(oprot) + for kiter601,viter602 in self.configs.items(): + oprot.writeString(kiter601) + viter602.write(oprot) oprot.writeMapEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -16294,11 +15471,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16325,10 +15500,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16402,11 +15573,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16434,10 +15603,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16509,11 +15674,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16523,17 +15686,17 @@ def read(self, iprot): if fid == 1: if ftype == TType.LIST: self.sessions = [] - (_etype580, _size577) = iprot.readListBegin() - if _size577 >= 0: - for _i581 in six.moves.range(_size577): - _elem582 = Session() - _elem582.read(iprot) - self.sessions.append(_elem582) + (_etype606, _size603) = iprot.readListBegin() + if _size603 >= 0: + for _i607 in six.moves.range(_size603): + _elem608 = Session() + _elem608.read(iprot) + self.sessions.append(_elem608) else: while iprot.peekList(): - _elem583 = Session() - _elem583.read(iprot) - self.sessions.append(_elem583) + _elem609 = Session() + _elem609.read(iprot) + self.sessions.append(_elem609) iprot.readListEnd() else: iprot.skip(ftype) @@ -16541,10 +15704,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16557,8 +15716,8 @@ def write(self, oprot): if self.sessions != None: oprot.writeFieldBegin('sessions', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.sessions)) - for iter584 in self.sessions: - iter584.write(oprot) + for iter610 in self.sessions: + iter610.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -16598,11 +15757,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16613,10 +15770,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16666,11 +15819,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16691,17 +15842,17 @@ def read(self, iprot): elif fid == 3: if ftype == TType.LIST: self.sessions = [] - (_etype588, _size585) = iprot.readListBegin() - if _size585 >= 0: - for _i589 in six.moves.range(_size585): - _elem590 = Session() - _elem590.read(iprot) - self.sessions.append(_elem590) + (_etype614, _size611) = iprot.readListBegin() + if _size611 >= 0: + for _i615 in six.moves.range(_size611): + _elem616 = Session() + _elem616.read(iprot) + self.sessions.append(_elem616) else: while iprot.peekList(): - _elem591 = Session() - _elem591.read(iprot) - self.sessions.append(_elem591) + _elem617 = Session() + _elem617.read(iprot) + self.sessions.append(_elem617) iprot.readListEnd() else: iprot.skip(ftype) @@ -16709,10 +15860,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16733,8 +15880,8 @@ def write(self, oprot): if self.sessions != None: oprot.writeFieldBegin('sessions', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.sessions)) - for iter592 in self.sessions: - iter592.write(oprot) + for iter618 in self.sessions: + iter618.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -16787,11 +15934,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16807,10 +15952,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16868,11 +16009,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16900,10 +16039,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -16975,11 +16110,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -16995,10 +16128,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17057,11 +16186,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -17093,10 +16220,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -17906,8 +17029,9 @@ def Correlativity__setstate__(self, state): (2, TType.MAP, 'edges', (TType.STRING,False,TType.I64,None), None, 2, ), # 2 (3, TType.I64, 'space_vertices', None, None, 2, ), # 3 (4, TType.I64, 'space_edges', None, None, 2, ), # 4 - (5, TType.MAP, 'part_corelativity', (TType.I32,None,TType.LIST,(TType.STRUCT,[Correlativity, Correlativity.thrift_spec, False])), None, 2, ), # 5 - (6, TType.I32, 'status', JobStatus, None, 2, ), # 6 + (5, TType.MAP, 'positive_part_correlativity', (TType.I32,None,TType.LIST,(TType.STRUCT,[Correlativity, Correlativity.thrift_spec, False])), None, 2, ), # 5 + (6, TType.MAP, 'negative_part_correlativity', (TType.I32,None,TType.LIST,(TType.STRUCT,[Correlativity, Correlativity.thrift_spec, False])), None, 2, ), # 6 + (7, TType.I32, 'status', JobStatus, None, 2, ), # 7 ) StatisItem.thrift_struct_annotations = { @@ -17915,12 +17039,13 @@ def Correlativity__setstate__(self, state): StatisItem.thrift_field_annotations = { } -def StatisItem__init__(self, tag_vertices=None, edges=None, space_vertices=None, space_edges=None, part_corelativity=None, status=None,): +def StatisItem__init__(self, tag_vertices=None, edges=None, space_vertices=None, space_edges=None, positive_part_correlativity=None, negative_part_correlativity=None, status=None,): self.tag_vertices = tag_vertices self.edges = edges self.space_vertices = space_vertices self.space_edges = space_edges - self.part_corelativity = part_corelativity + self.positive_part_correlativity = positive_part_correlativity + self.negative_part_correlativity = negative_part_correlativity self.status = status StatisItem.__init__ = StatisItem__init__ @@ -17930,7 +17055,8 @@ def StatisItem__setstate__(self, state): state.setdefault('edges', None) state.setdefault('space_vertices', None) state.setdefault('space_edges', None) - state.setdefault('part_corelativity', None) + state.setdefault('positive_part_correlativity', None) + state.setdefault('negative_part_correlativity', None) state.setdefault('status', None) self.__dict__ = state diff --git a/nebula2/sclient/GraphStorageClient.py b/nebula2/sclient/GraphStorageClient.py index 315a6603..cfcdd996 100644 --- a/nebula2/sclient/GraphStorageClient.py +++ b/nebula2/sclient/GraphStorageClient.py @@ -56,6 +56,8 @@ def close(self): def _create_connection(self): storage_addrs = self._meta_cache.get_all_storage_addrs() + if len(storage_addrs) == 0: + raise RuntimeError('Get storage address from meta cache is empty') try: for addr in storage_addrs: conn = GraphStorageConnection(addr, self._time_out, self._meta_cache) diff --git a/nebula2/sclient/ScanResult.py b/nebula2/sclient/ScanResult.py index 2cff9d70..52880098 100644 --- a/nebula2/sclient/ScanResult.py +++ b/nebula2/sclient/ScanResult.py @@ -89,6 +89,8 @@ def has_next(self): def next(self): conns = self._graph_storage_client.get_conns() num = len(conns) + if num == 0: + raise RuntimeError('There is no storage connection') logging.debug('Graph storage client num: {}'.format(num)) exceptions = [] result = [] diff --git a/nebula2/storage/GeneralStorageService-fuzzer b/nebula2/storage/GeneralStorageService-fuzzer index 3ecdc7e5..e7fd4bfe 100755 --- a/nebula2/storage/GeneralStorageService-fuzzer +++ b/nebula2/storage/GeneralStorageService-fuzzer @@ -30,7 +30,7 @@ if (not sys.argv[0].endswith("par") and print("""WARNING You are trying to run *-fuzzer.py which is incorrect as the paths are not set up correctly. - Instead, you should generate your fbthrift file with + Instead, you should generate your thrift file with thrift_library and then run the resulting *-fuzzer.par. For more information, please read @@ -42,4 +42,4 @@ from . import ttypes from . import constants import nebula2.fbthrift.util.fuzzer -nebula2.fbthrift.util.fuzzer.fuzz_service(GeneralStorageService, ttypes, constants) +thrift.util.fuzzer.fuzz_service(GeneralStorageService, ttypes, constants) diff --git a/nebula2/storage/GeneralStorageService-remote b/nebula2/storage/GeneralStorageService-remote index 8d6a7eaa..55abc4ed 100755 --- a/nebula2/storage/GeneralStorageService-remote +++ b/nebula2/storage/GeneralStorageService-remote @@ -28,7 +28,7 @@ if (not sys.argv[0].endswith("par") and print("""WARNING You are trying to run *-remote.py which is incorrect as the paths are not set up correctly. - Instead, you should generate your fbthrift file with + Instead, you should generate your thrift file with thrift_library and then run the resulting *-remote.par. For more information, please read diff --git a/nebula2/storage/GeneralStorageService.py b/nebula2/storage/GeneralStorageService.py index 5171a4b2..4a864d7d 100644 --- a/nebula2/storage/GeneralStorageService.py +++ b/nebula2/storage/GeneralStorageService.py @@ -7,12 +7,13 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException -from .ttypes import * +from .ttypes import UTF8STRINGS, ErrorCode, StatType, OrderDirection, EdgeDirection, ScanType, EngineSignType, PartitionResult, ResponseCommon, StatProp, Expr, EdgeProp, VertexProp, OrderBy, TraverseSpec, GetNeighborsRequest, GetNeighborsResponse, ExecResponse, GetPropRequest, GetPropResponse, NewTag, NewVertex, EdgeKey, NewEdge, AddVerticesRequest, AddEdgesRequest, DeleteVerticesRequest, DeleteEdgesRequest, UpdateResponse, UpdatedProp, UpdateVertexRequest, UpdateEdgeRequest, GetUUIDReq, GetUUIDResp, LookupIndexResp, IndexColumnHint, IndexQueryContext, IndexSpec, LookupIndexRequest, LookupAndTraverseRequest, ScanVertexRequest, ScanVertexResponse, ScanEdgeRequest, ScanEdgeResponse, TaskPara, AddAdminTaskRequest, StopAdminTaskRequest, AdminExecResp, TransLeaderReq, AddPartReq, AddLearnerReq, RemovePartReq, MemberChangeReq, CatchUpDataReq, GetLeaderReq, CreateCPRequest, DropCPRequest, BlockingSignRequest, GetLeaderPartsResp, CheckPeersReq, RebuildIndexRequest, CreateCPResp, PartitionInfoResp, PartitionInfoRequest, KVGetRequest, KVGetResponse, KVPutRequest, KVRemoveRequest, InternalTxnRequest, GetValueRequest, GetValueResponse import nebula2.common.ttypes import nebula2.meta.ttypes @@ -25,16 +26,22 @@ from nebula2.fbthrift.protocol import TCompactProtocol from nebula2.fbthrift.protocol import THeaderProtocol fastproto = None -if not '__pypy__' in sys.builtin_module_names: - try: - from nebula2.fbthrift.protocol import fastproto - except: - pass +try: + from nebula2.fbthrift.protocol import fastproto +except ImportError: + pass all_structs = [] UTF8STRINGS = bool(0) or sys.version_info.major >= 3 -from nebula2.fbthrift.util.Decorators import * +from nebula2.fbthrift.util.Decorators import ( + future_process_main, + future_process_method, + process_main as thrift_process_main, + process_method as thrift_process_method, + should_run_on_thread, + write_results_after_future, +) class Iface: def get(self, req=None): @@ -101,11 +108,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -122,10 +127,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -204,11 +205,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -225,10 +224,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -306,11 +301,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -327,10 +320,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -409,11 +398,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -430,10 +417,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -511,11 +494,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -532,10 +513,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -614,11 +591,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -635,10 +610,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -825,10 +796,10 @@ def onewayMethods(self): l.extend(Processor._onewayMethods) return tuple(l) - @process_main() + @thrift_process_main() def process(self,): pass - @process_method(get_args, oneway=False) + @thrift_process_method(get_args, oneway=False) def process_get(self, args, handler_ctx): result = get_result() try: @@ -836,10 +807,10 @@ def process_get(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'get', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(put_args, oneway=False) + @thrift_process_method(put_args, oneway=False) def process_put(self, args, handler_ctx): result = put_result() try: @@ -847,10 +818,10 @@ def process_put(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'put', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(remove_args, oneway=False) + @thrift_process_method(remove_args, oneway=False) def process_remove(self, args, handler_ctx): result = remove_result() try: @@ -858,7 +829,7 @@ def process_remove(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'remove', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result Iface._processor_type = Processor @@ -883,10 +854,10 @@ def onewayMethods(self): l.extend(ContextProcessor._onewayMethods) return tuple(l) - @process_main() + @thrift_process_main() def process(self,): pass - @process_method(get_args, oneway=False) + @thrift_process_method(get_args, oneway=False) def process_get(self, args, handler_ctx): result = get_result() try: @@ -894,10 +865,10 @@ def process_get(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'get', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(put_args, oneway=False) + @thrift_process_method(put_args, oneway=False) def process_put(self, args, handler_ctx): result = put_result() try: @@ -905,10 +876,10 @@ def process_put(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'put', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(remove_args, oneway=False) + @thrift_process_method(remove_args, oneway=False) def process_remove(self, args, handler_ctx): result = remove_result() try: @@ -916,7 +887,7 @@ def process_remove(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'remove', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result ContextIface._processor_type = ContextProcessor diff --git a/nebula2/storage/GraphStorageService-fuzzer b/nebula2/storage/GraphStorageService-fuzzer index d47897b9..d1dd4e47 100755 --- a/nebula2/storage/GraphStorageService-fuzzer +++ b/nebula2/storage/GraphStorageService-fuzzer @@ -30,7 +30,7 @@ if (not sys.argv[0].endswith("par") and print("""WARNING You are trying to run *-fuzzer.py which is incorrect as the paths are not set up correctly. - Instead, you should generate your fbthrift file with + Instead, you should generate your thrift file with thrift_library and then run the resulting *-fuzzer.par. For more information, please read @@ -42,4 +42,4 @@ from . import ttypes from . import constants import nebula2.fbthrift.util.fuzzer -nebula2.fbthrift.util.fuzzer.fuzz_service(GraphStorageService, ttypes, constants) +thrift.util.fuzzer.fuzz_service(GraphStorageService, ttypes, constants) diff --git a/nebula2/storage/GraphStorageService-remote b/nebula2/storage/GraphStorageService-remote index f060ff2b..1ed36e62 100755 --- a/nebula2/storage/GraphStorageService-remote +++ b/nebula2/storage/GraphStorageService-remote @@ -28,7 +28,7 @@ if (not sys.argv[0].endswith("par") and print("""WARNING You are trying to run *-remote.py which is incorrect as the paths are not set up correctly. - Instead, you should generate your fbthrift file with + Instead, you should generate your thrift file with thrift_library and then run the resulting *-remote.par. For more information, please read diff --git a/nebula2/storage/GraphStorageService.py b/nebula2/storage/GraphStorageService.py index 56e6125b..179dd0c1 100644 --- a/nebula2/storage/GraphStorageService.py +++ b/nebula2/storage/GraphStorageService.py @@ -7,12 +7,13 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException -from .ttypes import * +from .ttypes import UTF8STRINGS, ErrorCode, StatType, OrderDirection, EdgeDirection, ScanType, EngineSignType, PartitionResult, ResponseCommon, StatProp, Expr, EdgeProp, VertexProp, OrderBy, TraverseSpec, GetNeighborsRequest, GetNeighborsResponse, ExecResponse, GetPropRequest, GetPropResponse, NewTag, NewVertex, EdgeKey, NewEdge, AddVerticesRequest, AddEdgesRequest, DeleteVerticesRequest, DeleteEdgesRequest, UpdateResponse, UpdatedProp, UpdateVertexRequest, UpdateEdgeRequest, GetUUIDReq, GetUUIDResp, LookupIndexResp, IndexColumnHint, IndexQueryContext, IndexSpec, LookupIndexRequest, LookupAndTraverseRequest, ScanVertexRequest, ScanVertexResponse, ScanEdgeRequest, ScanEdgeResponse, TaskPara, AddAdminTaskRequest, StopAdminTaskRequest, AdminExecResp, TransLeaderReq, AddPartReq, AddLearnerReq, RemovePartReq, MemberChangeReq, CatchUpDataReq, GetLeaderReq, CreateCPRequest, DropCPRequest, BlockingSignRequest, GetLeaderPartsResp, CheckPeersReq, RebuildIndexRequest, CreateCPResp, PartitionInfoResp, PartitionInfoRequest, KVGetRequest, KVGetResponse, KVPutRequest, KVRemoveRequest, InternalTxnRequest, GetValueRequest, GetValueResponse import nebula2.common.ttypes import nebula2.meta.ttypes @@ -25,16 +26,22 @@ from nebula2.fbthrift.protocol import TCompactProtocol from nebula2.fbthrift.protocol import THeaderProtocol fastproto = None -if not '__pypy__' in sys.builtin_module_names: - try: - from nebula2.fbthrift.protocol import fastproto - except: - pass +try: + from nebula2.fbthrift.protocol import fastproto +except ImportError: + pass all_structs = [] UTF8STRINGS = bool(0) or sys.version_info.major >= 3 -from nebula2.fbthrift.util.Decorators import * +from nebula2.fbthrift.util.Decorators import ( + future_process_main, + future_process_method, + process_main as thrift_process_main, + process_method as thrift_process_method, + should_run_on_thread, + write_results_after_future, +) class Iface: def getNeighbors(self, req=None): @@ -255,11 +262,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -276,10 +281,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -358,11 +359,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -379,10 +378,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -460,11 +455,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -481,10 +474,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -563,11 +552,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -584,10 +571,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -665,11 +648,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -686,10 +667,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -768,11 +745,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -789,10 +764,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -870,11 +841,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -891,10 +860,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -973,11 +938,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -994,10 +957,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1075,11 +1034,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1096,10 +1053,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1178,11 +1131,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1199,10 +1150,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1280,11 +1227,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1301,10 +1246,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1383,11 +1324,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1404,10 +1343,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1485,11 +1420,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1506,10 +1439,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1588,11 +1517,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1609,10 +1536,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1690,11 +1613,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1711,10 +1632,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1793,11 +1710,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1814,10 +1729,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1895,11 +1806,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1916,10 +1825,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1998,11 +1903,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2019,10 +1922,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2100,11 +1999,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2121,10 +2018,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2203,11 +2096,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2224,10 +2115,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2305,11 +2192,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2326,10 +2211,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2408,11 +2289,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2429,10 +2308,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2510,11 +2385,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2531,10 +2404,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2613,11 +2482,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2634,10 +2501,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2715,11 +2578,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2736,10 +2597,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2818,11 +2675,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2839,10 +2694,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2920,11 +2771,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2941,10 +2790,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3023,11 +2868,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3044,10 +2887,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3586,10 +3425,10 @@ def onewayMethods(self): l.extend(Processor._onewayMethods) return tuple(l) - @process_main() + @thrift_process_main() def process(self,): pass - @process_method(getNeighbors_args, oneway=False) + @thrift_process_method(getNeighbors_args, oneway=False) def process_getNeighbors(self, args, handler_ctx): result = getNeighbors_result() try: @@ -3597,10 +3436,10 @@ def process_getNeighbors(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getNeighbors', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getProps_args, oneway=False) + @thrift_process_method(getProps_args, oneway=False) def process_getProps(self, args, handler_ctx): result = getProps_result() try: @@ -3608,10 +3447,10 @@ def process_getProps(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getProps', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addVertices_args, oneway=False) + @thrift_process_method(addVertices_args, oneway=False) def process_addVertices(self, args, handler_ctx): result = addVertices_result() try: @@ -3619,10 +3458,10 @@ def process_addVertices(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addVertices', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addEdges_args, oneway=False) + @thrift_process_method(addEdges_args, oneway=False) def process_addEdges(self, args, handler_ctx): result = addEdges_result() try: @@ -3630,10 +3469,10 @@ def process_addEdges(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addEdges', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(deleteEdges_args, oneway=False) + @thrift_process_method(deleteEdges_args, oneway=False) def process_deleteEdges(self, args, handler_ctx): result = deleteEdges_result() try: @@ -3641,10 +3480,10 @@ def process_deleteEdges(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'deleteEdges', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(deleteVertices_args, oneway=False) + @thrift_process_method(deleteVertices_args, oneway=False) def process_deleteVertices(self, args, handler_ctx): result = deleteVertices_result() try: @@ -3652,10 +3491,10 @@ def process_deleteVertices(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'deleteVertices', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(updateVertex_args, oneway=False) + @thrift_process_method(updateVertex_args, oneway=False) def process_updateVertex(self, args, handler_ctx): result = updateVertex_result() try: @@ -3663,10 +3502,10 @@ def process_updateVertex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'updateVertex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(updateEdge_args, oneway=False) + @thrift_process_method(updateEdge_args, oneway=False) def process_updateEdge(self, args, handler_ctx): result = updateEdge_result() try: @@ -3674,10 +3513,10 @@ def process_updateEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'updateEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(scanVertex_args, oneway=False) + @thrift_process_method(scanVertex_args, oneway=False) def process_scanVertex(self, args, handler_ctx): result = scanVertex_result() try: @@ -3685,10 +3524,10 @@ def process_scanVertex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'scanVertex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(scanEdge_args, oneway=False) + @thrift_process_method(scanEdge_args, oneway=False) def process_scanEdge(self, args, handler_ctx): result = scanEdge_result() try: @@ -3696,10 +3535,10 @@ def process_scanEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'scanEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getUUID_args, oneway=False) + @thrift_process_method(getUUID_args, oneway=False) def process_getUUID(self, args, handler_ctx): result = getUUID_result() try: @@ -3707,10 +3546,10 @@ def process_getUUID(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getUUID', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(lookupIndex_args, oneway=False) + @thrift_process_method(lookupIndex_args, oneway=False) def process_lookupIndex(self, args, handler_ctx): result = lookupIndex_result() try: @@ -3718,10 +3557,10 @@ def process_lookupIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'lookupIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(lookupAndTraverse_args, oneway=False) + @thrift_process_method(lookupAndTraverse_args, oneway=False) def process_lookupAndTraverse(self, args, handler_ctx): result = lookupAndTraverse_result() try: @@ -3729,10 +3568,10 @@ def process_lookupAndTraverse(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'lookupAndTraverse', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addEdgesAtomic_args, oneway=False) + @thrift_process_method(addEdgesAtomic_args, oneway=False) def process_addEdgesAtomic(self, args, handler_ctx): result = addEdgesAtomic_result() try: @@ -3740,7 +3579,7 @@ def process_addEdgesAtomic(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addEdgesAtomic', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result Iface._processor_type = Processor @@ -3787,10 +3626,10 @@ def onewayMethods(self): l.extend(ContextProcessor._onewayMethods) return tuple(l) - @process_main() + @thrift_process_main() def process(self,): pass - @process_method(getNeighbors_args, oneway=False) + @thrift_process_method(getNeighbors_args, oneway=False) def process_getNeighbors(self, args, handler_ctx): result = getNeighbors_result() try: @@ -3798,10 +3637,10 @@ def process_getNeighbors(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getNeighbors', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getProps_args, oneway=False) + @thrift_process_method(getProps_args, oneway=False) def process_getProps(self, args, handler_ctx): result = getProps_result() try: @@ -3809,10 +3648,10 @@ def process_getProps(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getProps', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addVertices_args, oneway=False) + @thrift_process_method(addVertices_args, oneway=False) def process_addVertices(self, args, handler_ctx): result = addVertices_result() try: @@ -3820,10 +3659,10 @@ def process_addVertices(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addVertices', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addEdges_args, oneway=False) + @thrift_process_method(addEdges_args, oneway=False) def process_addEdges(self, args, handler_ctx): result = addEdges_result() try: @@ -3831,10 +3670,10 @@ def process_addEdges(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addEdges', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(deleteEdges_args, oneway=False) + @thrift_process_method(deleteEdges_args, oneway=False) def process_deleteEdges(self, args, handler_ctx): result = deleteEdges_result() try: @@ -3842,10 +3681,10 @@ def process_deleteEdges(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'deleteEdges', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(deleteVertices_args, oneway=False) + @thrift_process_method(deleteVertices_args, oneway=False) def process_deleteVertices(self, args, handler_ctx): result = deleteVertices_result() try: @@ -3853,10 +3692,10 @@ def process_deleteVertices(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'deleteVertices', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(updateVertex_args, oneway=False) + @thrift_process_method(updateVertex_args, oneway=False) def process_updateVertex(self, args, handler_ctx): result = updateVertex_result() try: @@ -3864,10 +3703,10 @@ def process_updateVertex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'updateVertex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(updateEdge_args, oneway=False) + @thrift_process_method(updateEdge_args, oneway=False) def process_updateEdge(self, args, handler_ctx): result = updateEdge_result() try: @@ -3875,10 +3714,10 @@ def process_updateEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'updateEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(scanVertex_args, oneway=False) + @thrift_process_method(scanVertex_args, oneway=False) def process_scanVertex(self, args, handler_ctx): result = scanVertex_result() try: @@ -3886,10 +3725,10 @@ def process_scanVertex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'scanVertex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(scanEdge_args, oneway=False) + @thrift_process_method(scanEdge_args, oneway=False) def process_scanEdge(self, args, handler_ctx): result = scanEdge_result() try: @@ -3897,10 +3736,10 @@ def process_scanEdge(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'scanEdge', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getUUID_args, oneway=False) + @thrift_process_method(getUUID_args, oneway=False) def process_getUUID(self, args, handler_ctx): result = getUUID_result() try: @@ -3908,10 +3747,10 @@ def process_getUUID(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getUUID', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(lookupIndex_args, oneway=False) + @thrift_process_method(lookupIndex_args, oneway=False) def process_lookupIndex(self, args, handler_ctx): result = lookupIndex_result() try: @@ -3919,10 +3758,10 @@ def process_lookupIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'lookupIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(lookupAndTraverse_args, oneway=False) + @thrift_process_method(lookupAndTraverse_args, oneway=False) def process_lookupAndTraverse(self, args, handler_ctx): result = lookupAndTraverse_result() try: @@ -3930,10 +3769,10 @@ def process_lookupAndTraverse(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'lookupAndTraverse', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addEdgesAtomic_args, oneway=False) + @thrift_process_method(addEdgesAtomic_args, oneway=False) def process_addEdgesAtomic(self, args, handler_ctx): result = addEdgesAtomic_result() try: @@ -3941,7 +3780,7 @@ def process_addEdgesAtomic(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addEdgesAtomic', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result ContextIface._processor_type = ContextProcessor diff --git a/nebula2/storage/StorageAdminService-fuzzer b/nebula2/storage/StorageAdminService-fuzzer index c0b7396a..4096544d 100755 --- a/nebula2/storage/StorageAdminService-fuzzer +++ b/nebula2/storage/StorageAdminService-fuzzer @@ -30,7 +30,7 @@ if (not sys.argv[0].endswith("par") and print("""WARNING You are trying to run *-fuzzer.py which is incorrect as the paths are not set up correctly. - Instead, you should generate your fbthrift file with + Instead, you should generate your thrift file with thrift_library and then run the resulting *-fuzzer.par. For more information, please read @@ -42,4 +42,4 @@ from . import ttypes from . import constants import nebula2.fbthrift.util.fuzzer -nebula2.fbthrift.util.fuzzer.fuzz_service(StorageAdminService, ttypes, constants) +thrift.util.fuzzer.fuzz_service(StorageAdminService, ttypes, constants) diff --git a/nebula2/storage/StorageAdminService-remote b/nebula2/storage/StorageAdminService-remote index c17b5672..0a766f13 100755 --- a/nebula2/storage/StorageAdminService-remote +++ b/nebula2/storage/StorageAdminService-remote @@ -28,7 +28,7 @@ if (not sys.argv[0].endswith("par") and print("""WARNING You are trying to run *-remote.py which is incorrect as the paths are not set up correctly. - Instead, you should generate your fbthrift file with + Instead, you should generate your thrift file with thrift_library and then run the resulting *-remote.par. For more information, please read diff --git a/nebula2/storage/StorageAdminService.py b/nebula2/storage/StorageAdminService.py index 01c652de..b5dd2e8c 100644 --- a/nebula2/storage/StorageAdminService.py +++ b/nebula2/storage/StorageAdminService.py @@ -7,12 +7,13 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException -from .ttypes import * +from .ttypes import UTF8STRINGS, ErrorCode, StatType, OrderDirection, EdgeDirection, ScanType, EngineSignType, PartitionResult, ResponseCommon, StatProp, Expr, EdgeProp, VertexProp, OrderBy, TraverseSpec, GetNeighborsRequest, GetNeighborsResponse, ExecResponse, GetPropRequest, GetPropResponse, NewTag, NewVertex, EdgeKey, NewEdge, AddVerticesRequest, AddEdgesRequest, DeleteVerticesRequest, DeleteEdgesRequest, UpdateResponse, UpdatedProp, UpdateVertexRequest, UpdateEdgeRequest, GetUUIDReq, GetUUIDResp, LookupIndexResp, IndexColumnHint, IndexQueryContext, IndexSpec, LookupIndexRequest, LookupAndTraverseRequest, ScanVertexRequest, ScanVertexResponse, ScanEdgeRequest, ScanEdgeResponse, TaskPara, AddAdminTaskRequest, StopAdminTaskRequest, AdminExecResp, TransLeaderReq, AddPartReq, AddLearnerReq, RemovePartReq, MemberChangeReq, CatchUpDataReq, GetLeaderReq, CreateCPRequest, DropCPRequest, BlockingSignRequest, GetLeaderPartsResp, CheckPeersReq, RebuildIndexRequest, CreateCPResp, PartitionInfoResp, PartitionInfoRequest, KVGetRequest, KVGetResponse, KVPutRequest, KVRemoveRequest, InternalTxnRequest, GetValueRequest, GetValueResponse import nebula2.common.ttypes import nebula2.meta.ttypes @@ -25,16 +26,22 @@ from nebula2.fbthrift.protocol import TCompactProtocol from nebula2.fbthrift.protocol import THeaderProtocol fastproto = None -if not '__pypy__' in sys.builtin_module_names: - try: - from nebula2.fbthrift.protocol import fastproto - except: - pass +try: + from nebula2.fbthrift.protocol import fastproto +except ImportError: + pass all_structs = [] UTF8STRINGS = bool(0) or sys.version_info.major >= 3 -from nebula2.fbthrift.util.Decorators import * +from nebula2.fbthrift.util.Decorators import ( + future_process_main, + future_process_method, + process_main as thrift_process_main, + process_method as thrift_process_method, + should_run_on_thread, + write_results_after_future, +) class Iface: def transLeader(self, req=None): @@ -269,11 +276,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -290,10 +295,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -372,11 +373,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -393,10 +392,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -474,11 +469,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -495,10 +488,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -577,11 +566,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -598,10 +585,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -679,11 +662,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -700,10 +681,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -782,11 +759,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -803,10 +778,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -884,11 +855,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -905,10 +874,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -987,11 +952,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1008,10 +971,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1089,11 +1048,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1110,10 +1067,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1192,11 +1145,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1213,10 +1164,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1294,11 +1241,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1315,10 +1260,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1397,11 +1338,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1418,10 +1357,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1499,11 +1434,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1520,10 +1453,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1602,11 +1531,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1623,10 +1550,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1704,11 +1627,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1725,10 +1646,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1807,11 +1724,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1828,10 +1743,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1909,11 +1820,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1930,10 +1839,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2012,11 +1917,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2033,10 +1936,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2114,11 +2013,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2135,10 +2032,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2217,11 +2110,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2238,10 +2129,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2319,11 +2206,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2340,10 +2225,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2422,11 +2303,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2443,10 +2322,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2524,11 +2399,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2545,10 +2418,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2627,11 +2496,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2648,10 +2515,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2729,11 +2592,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2750,10 +2611,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2832,11 +2689,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2853,10 +2708,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2934,11 +2785,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2955,10 +2804,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3037,11 +2882,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3058,10 +2901,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3139,11 +2978,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3160,10 +2997,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3242,11 +3075,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3263,10 +3094,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3837,10 +3664,10 @@ def onewayMethods(self): l.extend(Processor._onewayMethods) return tuple(l) - @process_main() + @thrift_process_main() def process(self,): pass - @process_method(transLeader_args, oneway=False) + @thrift_process_method(transLeader_args, oneway=False) def process_transLeader(self, args, handler_ctx): result = transLeader_result() try: @@ -3848,10 +3675,10 @@ def process_transLeader(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'transLeader', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addPart_args, oneway=False) + @thrift_process_method(addPart_args, oneway=False) def process_addPart(self, args, handler_ctx): result = addPart_result() try: @@ -3859,10 +3686,10 @@ def process_addPart(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addPart', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addLearner_args, oneway=False) + @thrift_process_method(addLearner_args, oneway=False) def process_addLearner(self, args, handler_ctx): result = addLearner_result() try: @@ -3870,10 +3697,10 @@ def process_addLearner(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addLearner', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(removePart_args, oneway=False) + @thrift_process_method(removePart_args, oneway=False) def process_removePart(self, args, handler_ctx): result = removePart_result() try: @@ -3881,10 +3708,10 @@ def process_removePart(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'removePart', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(memberChange_args, oneway=False) + @thrift_process_method(memberChange_args, oneway=False) def process_memberChange(self, args, handler_ctx): result = memberChange_result() try: @@ -3892,10 +3719,10 @@ def process_memberChange(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'memberChange', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(waitingForCatchUpData_args, oneway=False) + @thrift_process_method(waitingForCatchUpData_args, oneway=False) def process_waitingForCatchUpData(self, args, handler_ctx): result = waitingForCatchUpData_result() try: @@ -3903,10 +3730,10 @@ def process_waitingForCatchUpData(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'waitingForCatchUpData', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createCheckpoint_args, oneway=False) + @thrift_process_method(createCheckpoint_args, oneway=False) def process_createCheckpoint(self, args, handler_ctx): result = createCheckpoint_result() try: @@ -3914,10 +3741,10 @@ def process_createCheckpoint(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createCheckpoint', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropCheckpoint_args, oneway=False) + @thrift_process_method(dropCheckpoint_args, oneway=False) def process_dropCheckpoint(self, args, handler_ctx): result = dropCheckpoint_result() try: @@ -3925,10 +3752,10 @@ def process_dropCheckpoint(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropCheckpoint', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(blockingWrites_args, oneway=False) + @thrift_process_method(blockingWrites_args, oneway=False) def process_blockingWrites(self, args, handler_ctx): result = blockingWrites_result() try: @@ -3936,10 +3763,10 @@ def process_blockingWrites(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'blockingWrites', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(rebuildTagIndex_args, oneway=False) + @thrift_process_method(rebuildTagIndex_args, oneway=False) def process_rebuildTagIndex(self, args, handler_ctx): result = rebuildTagIndex_result() try: @@ -3947,10 +3774,10 @@ def process_rebuildTagIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'rebuildTagIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(rebuildEdgeIndex_args, oneway=False) + @thrift_process_method(rebuildEdgeIndex_args, oneway=False) def process_rebuildEdgeIndex(self, args, handler_ctx): result = rebuildEdgeIndex_result() try: @@ -3958,10 +3785,10 @@ def process_rebuildEdgeIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'rebuildEdgeIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getLeaderParts_args, oneway=False) + @thrift_process_method(getLeaderParts_args, oneway=False) def process_getLeaderParts(self, args, handler_ctx): result = getLeaderParts_result() try: @@ -3969,10 +3796,10 @@ def process_getLeaderParts(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getLeaderParts', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(checkPeers_args, oneway=False) + @thrift_process_method(checkPeers_args, oneway=False) def process_checkPeers(self, args, handler_ctx): result = checkPeers_result() try: @@ -3980,10 +3807,10 @@ def process_checkPeers(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'checkPeers', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addAdminTask_args, oneway=False) + @thrift_process_method(addAdminTask_args, oneway=False) def process_addAdminTask(self, args, handler_ctx): result = addAdminTask_result() try: @@ -3991,10 +3818,10 @@ def process_addAdminTask(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addAdminTask', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(stopAdminTask_args, oneway=False) + @thrift_process_method(stopAdminTask_args, oneway=False) def process_stopAdminTask(self, args, handler_ctx): result = stopAdminTask_result() try: @@ -4002,7 +3829,7 @@ def process_stopAdminTask(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'stopAdminTask', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result Iface._processor_type = Processor @@ -4051,10 +3878,10 @@ def onewayMethods(self): l.extend(ContextProcessor._onewayMethods) return tuple(l) - @process_main() + @thrift_process_main() def process(self,): pass - @process_method(transLeader_args, oneway=False) + @thrift_process_method(transLeader_args, oneway=False) def process_transLeader(self, args, handler_ctx): result = transLeader_result() try: @@ -4062,10 +3889,10 @@ def process_transLeader(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'transLeader', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addPart_args, oneway=False) + @thrift_process_method(addPart_args, oneway=False) def process_addPart(self, args, handler_ctx): result = addPart_result() try: @@ -4073,10 +3900,10 @@ def process_addPart(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addPart', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addLearner_args, oneway=False) + @thrift_process_method(addLearner_args, oneway=False) def process_addLearner(self, args, handler_ctx): result = addLearner_result() try: @@ -4084,10 +3911,10 @@ def process_addLearner(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addLearner', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(removePart_args, oneway=False) + @thrift_process_method(removePart_args, oneway=False) def process_removePart(self, args, handler_ctx): result = removePart_result() try: @@ -4095,10 +3922,10 @@ def process_removePart(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'removePart', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(memberChange_args, oneway=False) + @thrift_process_method(memberChange_args, oneway=False) def process_memberChange(self, args, handler_ctx): result = memberChange_result() try: @@ -4106,10 +3933,10 @@ def process_memberChange(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'memberChange', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(waitingForCatchUpData_args, oneway=False) + @thrift_process_method(waitingForCatchUpData_args, oneway=False) def process_waitingForCatchUpData(self, args, handler_ctx): result = waitingForCatchUpData_result() try: @@ -4117,10 +3944,10 @@ def process_waitingForCatchUpData(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'waitingForCatchUpData', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(createCheckpoint_args, oneway=False) + @thrift_process_method(createCheckpoint_args, oneway=False) def process_createCheckpoint(self, args, handler_ctx): result = createCheckpoint_result() try: @@ -4128,10 +3955,10 @@ def process_createCheckpoint(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'createCheckpoint', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(dropCheckpoint_args, oneway=False) + @thrift_process_method(dropCheckpoint_args, oneway=False) def process_dropCheckpoint(self, args, handler_ctx): result = dropCheckpoint_result() try: @@ -4139,10 +3966,10 @@ def process_dropCheckpoint(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'dropCheckpoint', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(blockingWrites_args, oneway=False) + @thrift_process_method(blockingWrites_args, oneway=False) def process_blockingWrites(self, args, handler_ctx): result = blockingWrites_result() try: @@ -4150,10 +3977,10 @@ def process_blockingWrites(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'blockingWrites', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(rebuildTagIndex_args, oneway=False) + @thrift_process_method(rebuildTagIndex_args, oneway=False) def process_rebuildTagIndex(self, args, handler_ctx): result = rebuildTagIndex_result() try: @@ -4161,10 +3988,10 @@ def process_rebuildTagIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'rebuildTagIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(rebuildEdgeIndex_args, oneway=False) + @thrift_process_method(rebuildEdgeIndex_args, oneway=False) def process_rebuildEdgeIndex(self, args, handler_ctx): result = rebuildEdgeIndex_result() try: @@ -4172,10 +3999,10 @@ def process_rebuildEdgeIndex(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'rebuildEdgeIndex', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(getLeaderParts_args, oneway=False) + @thrift_process_method(getLeaderParts_args, oneway=False) def process_getLeaderParts(self, args, handler_ctx): result = getLeaderParts_result() try: @@ -4183,10 +4010,10 @@ def process_getLeaderParts(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'getLeaderParts', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(checkPeers_args, oneway=False) + @thrift_process_method(checkPeers_args, oneway=False) def process_checkPeers(self, args, handler_ctx): result = checkPeers_result() try: @@ -4194,10 +4021,10 @@ def process_checkPeers(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'checkPeers', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(addAdminTask_args, oneway=False) + @thrift_process_method(addAdminTask_args, oneway=False) def process_addAdminTask(self, args, handler_ctx): result = addAdminTask_result() try: @@ -4205,10 +4032,10 @@ def process_addAdminTask(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'addAdminTask', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result - @process_method(stopAdminTask_args, oneway=False) + @thrift_process_method(stopAdminTask_args, oneway=False) def process_stopAdminTask(self, args, handler_ctx): result = stopAdminTask_result() try: @@ -4216,7 +4043,7 @@ def process_stopAdminTask(self, args, handler_ctx): except: ex = sys.exc_info()[1] self._event_handler.handlerError(handler_ctx, 'stopAdminTask', ex) - result = Thrift.TApplicationException(message=str(ex)) + result = Thrift.TApplicationException(message=repr(ex)) return result ContextIface._processor_type = ContextProcessor diff --git a/nebula2/storage/constants.py b/nebula2/storage/constants.py index f162eb6c..b807ef49 100644 --- a/nebula2/storage/constants.py +++ b/nebula2/storage/constants.py @@ -7,8 +7,9 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException @@ -16,5 +17,5 @@ import nebula2.meta.ttypes -from .ttypes import * +from .ttypes import UTF8STRINGS, ErrorCode, StatType, OrderDirection, EdgeDirection, ScanType, EngineSignType, PartitionResult, ResponseCommon, StatProp, Expr, EdgeProp, VertexProp, OrderBy, TraverseSpec, GetNeighborsRequest, GetNeighborsResponse, ExecResponse, GetPropRequest, GetPropResponse, NewTag, NewVertex, EdgeKey, NewEdge, AddVerticesRequest, AddEdgesRequest, DeleteVerticesRequest, DeleteEdgesRequest, UpdateResponse, UpdatedProp, UpdateVertexRequest, UpdateEdgeRequest, GetUUIDReq, GetUUIDResp, LookupIndexResp, IndexColumnHint, IndexQueryContext, IndexSpec, LookupIndexRequest, LookupAndTraverseRequest, ScanVertexRequest, ScanVertexResponse, ScanEdgeRequest, ScanEdgeResponse, TaskPara, AddAdminTaskRequest, StopAdminTaskRequest, AdminExecResp, TransLeaderReq, AddPartReq, AddLearnerReq, RemovePartReq, MemberChangeReq, CatchUpDataReq, GetLeaderReq, CreateCPRequest, DropCPRequest, BlockingSignRequest, GetLeaderPartsResp, CheckPeersReq, RebuildIndexRequest, CreateCPResp, PartitionInfoResp, PartitionInfoRequest, KVGetRequest, KVGetResponse, KVPutRequest, KVRemoveRequest, InternalTxnRequest, GetValueRequest, GetValueResponse diff --git a/nebula2/storage/ttypes.py b/nebula2/storage/ttypes.py index f5a1166b..195f1eaa 100644 --- a/nebula2/storage/ttypes.py +++ b/nebula2/storage/ttypes.py @@ -7,8 +7,9 @@ from __future__ import absolute_import import six +import sys from nebula2.fbthrift.util.Recursive import fix_spec -from nebula2.fbthrift.Thrift import * +from nebula2.fbthrift.Thrift import TType, TMessageType, TPriority, TRequestContext, TProcessorEventHandler, TServerInterface, TProcessor, TException, TApplicationException, UnimplementedTypedef from nebula2.fbthrift.protocol.TProtocol import TProtocolException @@ -24,11 +25,10 @@ from nebula2.fbthrift.protocol import TCompactProtocol from nebula2.fbthrift.protocol import THeaderProtocol fastproto = None -if not '__pypy__' in sys.builtin_module_names: - try: - from nebula2.fbthrift.protocol import fastproto - except: - pass +try: + from nebula2.fbthrift.protocol import fastproto +except ImportError: + pass all_structs = [] UTF8STRINGS = bool(0) or sys.version_info.major >= 3 @@ -284,11 +284,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -315,16 +313,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.code == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'code' was not found in serialized data! Struct: PartitionResult") - - if self.part_id == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'part_id' was not found in serialized data! Struct: PartitionResult") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -397,11 +385,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -434,16 +420,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.failed_parts == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'failed_parts' was not found in serialized data! Struct: ResponseCommon") - - if self.latency_in_us == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'latency_in_us' was not found in serialized data! Struct: ResponseCommon") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -512,11 +488,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -542,10 +516,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -618,11 +588,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -643,10 +611,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -711,11 +675,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -746,10 +708,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -817,11 +775,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -852,10 +808,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -923,11 +875,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -948,10 +898,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1025,11 +971,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1165,10 +1109,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1325,11 +1265,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1407,10 +1345,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1501,11 +1435,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1528,13 +1460,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: GetNeighborsResponse") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1598,11 +1523,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1619,13 +1542,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: ExecResponse") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1689,11 +1605,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -1833,10 +1747,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -1976,11 +1886,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2003,10 +1911,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2071,11 +1975,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2108,10 +2010,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2179,11 +2077,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2217,10 +2113,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2290,11 +2182,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2327,10 +2217,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2411,11 +2297,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2449,10 +2333,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2522,11 +2402,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2625,10 +2503,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2725,11 +2599,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2806,10 +2678,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -2900,11 +2768,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -2961,10 +2827,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3036,11 +2898,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3097,10 +2957,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3172,11 +3028,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3199,13 +3053,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: UpdateResponse") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3270,11 +3117,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3295,16 +3140,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.name == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'name' was not found in serialized data! Struct: UpdatedProp") - - if self.value == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'value' was not found in serialized data! Struct: UpdatedProp") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3375,11 +3210,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3453,13 +3286,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.tag_id == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'tag_id' was not found in serialized data! Struct: UpdateVertexRequest") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3583,11 +3409,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3656,10 +3480,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3771,11 +3591,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3801,10 +3619,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3877,11 +3691,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -3904,13 +3716,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: GetUUIDResp") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -3975,11 +3780,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4002,13 +3805,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: LookupIndexResp") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4075,11 +3871,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4112,10 +3906,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4197,11 +3987,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4239,10 +4027,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4319,11 +4103,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4361,19 +4143,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.contexts == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'contexts' was not found in serialized data! Struct: IndexSpec") - - if self.is_edge == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'is_edge' was not found in serialized data! Struct: IndexSpec") - - if self.tag_or_edge_id == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'tag_or_edge_id' was not found in serialized data! Struct: IndexSpec") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4451,11 +4220,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4507,16 +4274,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.space_id == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'space_id' was not found in serialized data! Struct: LookupIndexRequest") - - if self.parts == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'parts' was not found in serialized data! Struct: LookupIndexRequest") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4605,11 +4362,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4652,16 +4407,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.space_id == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'space_id' was not found in serialized data! Struct: LookupAndTraverseRequest") - - if self.parts == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'parts' was not found in serialized data! Struct: LookupAndTraverseRequest") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4753,11 +4498,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4819,10 +4562,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -4953,11 +4692,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -4990,13 +4727,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: ScanVertexResponse") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5085,11 +4815,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5151,10 +4879,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5285,11 +5009,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5322,13 +5044,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: ScanEdgeResponse") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5410,11 +5125,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5460,10 +5173,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5545,11 +5254,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5586,10 +5293,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5678,11 +5381,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5703,10 +5404,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5771,11 +5468,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5798,13 +5493,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: AdminExecResp") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5870,11 +5558,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -5901,10 +5587,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -5979,11 +5661,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6026,10 +5706,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6114,11 +5790,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6145,10 +5819,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6221,11 +5891,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6246,10 +5914,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6316,11 +5980,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6352,10 +6014,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6437,11 +6095,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6468,10 +6124,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6538,11 +6190,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6553,10 +6203,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6605,11 +6251,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6630,10 +6274,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6698,11 +6338,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6723,10 +6361,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6791,11 +6425,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6816,13 +6448,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.sign == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'sign' was not found in serialized data! Struct: BlockingSignRequest") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -6887,11 +6512,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -6945,13 +6568,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: GetLeaderPartsResp") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7024,11 +6640,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7066,10 +6680,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7146,11 +6756,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7186,10 +6794,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7265,11 +6869,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7291,13 +6893,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: CreateCPResp") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7363,11 +6958,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7395,13 +6988,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: PartitionInfoResp") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7474,11 +7060,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7499,10 +7083,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7568,11 +7148,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7630,10 +7208,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7713,11 +7287,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7751,13 +7323,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: KVGetResponse") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7826,11 +7391,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -7887,10 +7450,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -7962,11 +7521,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8019,10 +7576,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8097,11 +7650,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8167,10 +7718,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8266,11 +7813,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8296,10 +7841,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: @@ -8372,11 +7913,9 @@ def isUnion(): def read(self, iprot): if (isinstance(iprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=0) - self.checkRequired() return if (isinstance(iprot, TCompactProtocol.TCompactProtocolAccelerated) or (isinstance(iprot, THeaderProtocol.THeaderProtocolAccelerate) and iprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_COMPACT_PROTOCOL)) and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastproto is not None: fastproto.decode(self, iprot.trans, [self.__class__, self.thrift_spec, False], utf8strings=UTF8STRINGS, protoid=2) - self.checkRequired() return iprot.readStructBegin() while True: @@ -8398,13 +7937,6 @@ def read(self, iprot): iprot.skip(ftype) iprot.readFieldEnd() iprot.readStructEnd() - self.checkRequired() - - def checkRequired(self): - if self.result == None: - raise TProtocolException(TProtocolException.MISSING_REQUIRED_FIELD, "Required field 'result' was not found in serialized data! Struct: GetValueResponse") - - return def write(self, oprot): if (isinstance(oprot, TBinaryProtocol.TBinaryProtocolAccelerated) or (isinstance(oprot, THeaderProtocol.THeaderProtocolAccelerate) and oprot.get_protocol_id() == THeaderProtocol.THeaderProtocol.T_BINARY_PROTOCOL)) and self.thrift_spec is not None and fastproto is not None: diff --git a/tests/test_data_from_server.py b/tests/test_data_from_server.py index 92ef8e2e..67b12bb8 100644 --- a/tests/test_data_from_server.py +++ b/tests/test_data_from_server.py @@ -229,3 +229,7 @@ def test_path_type(self): 'start_school: 2017-09-10, child_name: "Hello Worl", morning: 07:10:00.000000, ' \ 'friends: 10, first_out_city: 1111, name: "Lily"})' assert expected_str == str(path) + + assert resp.whole_latency() > 100 + + diff --git a/tests/test_data_type.py b/tests/test_data_type.py index 921b1d18..7f1fae89 100644 --- a/tests/test_data_type.py +++ b/tests/test_data_type.py @@ -190,7 +190,7 @@ def get_result_set(self): resp.latency_in_us = 100 resp.data = self.get_data_set() - return ResultSet(resp) + return ResultSet(resp, 100) class TesValueWrapper(TestBaseCase): diff --git a/tests/test_graph_storage_client.py b/tests/test_graph_storage_client.py index 0cbcb847..e990d299 100644 --- a/tests/test_graph_storage_client.py +++ b/tests/test_graph_storage_client.py @@ -51,7 +51,7 @@ def execute_with_retry(conn, session_id, stmt, retry=3): def setup_class(cls): try: conn = Connection() - conn.open('172.28.3.1', 9669, 3000) + conn.open('127.0.0.1', 9671, 3000) session_id = conn.authenticate('root', 'nebula') assert session_id != 0 cls.execute_with_retry(conn,