diff --git a/shared/protos/_generated/tunnelbroker.pb.h b/shared/protos/_generated/tunnelbroker.pb.h --- a/shared/protos/_generated/tunnelbroker.pb.h +++ b/shared/protos/_generated/tunnelbroker.pb.h @@ -1227,6 +1227,7 @@ enum : int { kSessionIDFieldNumber = 1, + kNewNotifyTokenFieldNumber = 2, }; // string sessionID = 1; void clear_sessionid(); @@ -1244,6 +1245,26 @@ std::string* _internal_mutable_sessionid(); public: + // string newNotifyToken = 2; + bool has_newnotifytoken() const; + private: + bool _internal_has_newnotifytoken() const; + public: + void clear_newnotifytoken(); + const std::string& newnotifytoken() const; + void set_newnotifytoken(const std::string& value); + void set_newnotifytoken(std::string&& value); + void set_newnotifytoken(const char* value); + void set_newnotifytoken(const char* value, size_t size); + std::string* mutable_newnotifytoken(); + std::string* release_newnotifytoken(); + void set_allocated_newnotifytoken(std::string* newnotifytoken); + private: + const std::string& _internal_newnotifytoken() const; + void _internal_set_newnotifytoken(const std::string& value); + std::string* _internal_mutable_newnotifytoken(); + public: + // @@protoc_insertion_point(class_scope:tunnelbroker.GetRequest) private: class _Internal; @@ -1251,8 +1272,10 @@ template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; typedef void InternalArenaConstructable_; typedef void DestructorSkippable_; - ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr sessionid_; + ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr sessionid_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr newnotifytoken_; friend struct ::TableStruct_tunnelbroker_2eproto; }; // ------------------------------------------------------------------- @@ -4377,6 +4400,79 @@ // @@protoc_insertion_point(field_set_allocated:tunnelbroker.GetRequest.sessionID) } +// string newNotifyToken = 2; +inline bool GetRequest::_internal_has_newnotifytoken() const { + bool value = (_has_bits_[0] & 0x00000001u) != 0; + return value; +} +inline bool GetRequest::has_newnotifytoken() const { + return _internal_has_newnotifytoken(); +} +inline void GetRequest::clear_newnotifytoken() { + newnotifytoken_.ClearToEmpty(); + _has_bits_[0] &= ~0x00000001u; +} +inline const std::string& GetRequest::newnotifytoken() const { + // @@protoc_insertion_point(field_get:tunnelbroker.GetRequest.newNotifyToken) + return _internal_newnotifytoken(); +} +inline void GetRequest::set_newnotifytoken(const std::string& value) { + _internal_set_newnotifytoken(value); + // @@protoc_insertion_point(field_set:tunnelbroker.GetRequest.newNotifyToken) +} +inline std::string* GetRequest::mutable_newnotifytoken() { + // @@protoc_insertion_point(field_mutable:tunnelbroker.GetRequest.newNotifyToken) + return _internal_mutable_newnotifytoken(); +} +inline const std::string& GetRequest::_internal_newnotifytoken() const { + return newnotifytoken_.Get(); +} +inline void GetRequest::_internal_set_newnotifytoken(const std::string& value) { + _has_bits_[0] |= 0x00000001u; + newnotifytoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, value, GetArena()); +} +inline void GetRequest::set_newnotifytoken(std::string&& value) { + _has_bits_[0] |= 0x00000001u; + newnotifytoken_.Set( + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::move(value), GetArena()); + // @@protoc_insertion_point(field_set_rvalue:tunnelbroker.GetRequest.newNotifyToken) +} +inline void GetRequest::set_newnotifytoken(const char* value) { + GOOGLE_DCHECK(value != nullptr); + _has_bits_[0] |= 0x00000001u; + newnotifytoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string(value), GetArena()); + // @@protoc_insertion_point(field_set_char:tunnelbroker.GetRequest.newNotifyToken) +} +inline void GetRequest::set_newnotifytoken(const char* value, + size_t size) { + _has_bits_[0] |= 0x00000001u; + newnotifytoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, ::std::string( + reinterpret_cast(value), size), GetArena()); + // @@protoc_insertion_point(field_set_pointer:tunnelbroker.GetRequest.newNotifyToken) +} +inline std::string* GetRequest::_internal_mutable_newnotifytoken() { + _has_bits_[0] |= 0x00000001u; + return newnotifytoken_.Mutable(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, GetArena()); +} +inline std::string* GetRequest::release_newnotifytoken() { + // @@protoc_insertion_point(field_release:tunnelbroker.GetRequest.newNotifyToken) + if (!_internal_has_newnotifytoken()) { + return nullptr; + } + _has_bits_[0] &= ~0x00000001u; + return newnotifytoken_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); +} +inline void GetRequest::set_allocated_newnotifytoken(std::string* newnotifytoken) { + if (newnotifytoken != nullptr) { + _has_bits_[0] |= 0x00000001u; + } else { + _has_bits_[0] &= ~0x00000001u; + } + newnotifytoken_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), newnotifytoken, + GetArena()); + // @@protoc_insertion_point(field_set_allocated:tunnelbroker.GetRequest.newNotifyToken) +} + // ------------------------------------------------------------------- // GetResponse diff --git a/shared/protos/_generated/tunnelbroker.pb.cc b/shared/protos/_generated/tunnelbroker.pb.cc --- a/shared/protos/_generated/tunnelbroker.pb.cc +++ b/shared/protos/_generated/tunnelbroker.pb.cc @@ -89,7 +89,8 @@ PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT SendRequestDefaultTypeInternal _SendRequest_default_instance_; constexpr GetRequest::GetRequest( ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized) - : sessionid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){} + : sessionid_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string) + , newnotifytoken_(&::PROTOBUF_NAMESPACE_ID::internal::fixed_address_empty_string){} struct GetRequestDefaultTypeInternal { constexpr GetRequestDefaultTypeInternal() : _instance(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized{}) {} @@ -320,12 +321,15 @@ PROTOBUF_FIELD_OFFSET(::tunnelbroker::SendRequest, todeviceid_), PROTOBUF_FIELD_OFFSET(::tunnelbroker::SendRequest, payload_), PROTOBUF_FIELD_OFFSET(::tunnelbroker::SendRequest, blobhashes_), - ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::tunnelbroker::GetRequest, _has_bits_), PROTOBUF_FIELD_OFFSET(::tunnelbroker::GetRequest, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ ~0u, // no _weak_field_map_ PROTOBUF_FIELD_OFFSET(::tunnelbroker::GetRequest, sessionid_), + PROTOBUF_FIELD_OFFSET(::tunnelbroker::GetRequest, newnotifytoken_), + ~0u, + 0, ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::tunnelbroker::GetResponse, _internal_metadata_), ~0u, // no _extensions_ @@ -427,20 +431,20 @@ { 12, 24, sizeof(::tunnelbroker::NewSessionRequest)}, { 31, -1, sizeof(::tunnelbroker::NewSessionResponse)}, { 37, -1, sizeof(::tunnelbroker::SendRequest)}, - { 46, -1, sizeof(::tunnelbroker::GetRequest)}, - { 52, -1, sizeof(::tunnelbroker::GetResponse)}, - { 60, -1, sizeof(::tunnelbroker::ProcessedMessages)}, - { 66, -1, sizeof(::tunnelbroker::MessageToTunnelbrokerStruct)}, - { 75, -1, sizeof(::tunnelbroker::MessagesToSend)}, - { 81, -1, sizeof(::tunnelbroker::MessageToTunnelbroker)}, - { 90, -1, sizeof(::tunnelbroker::MessageToClientStruct)}, - { 99, -1, sizeof(::tunnelbroker::MessagesToDeliver)}, - { 105, -1, sizeof(::tunnelbroker::MessageToClient)}, - { 113, -1, sizeof(::tunnelbroker::CheckRequest)}, - { 120, -1, sizeof(::tunnelbroker::CheckResponse)}, - { 126, -1, sizeof(::tunnelbroker::NewPrimaryRequest)}, - { 133, -1, sizeof(::tunnelbroker::NewPrimaryResponse)}, - { 139, -1, sizeof(::tunnelbroker::PongRequest)}, + { 46, 53, sizeof(::tunnelbroker::GetRequest)}, + { 55, -1, sizeof(::tunnelbroker::GetResponse)}, + { 63, -1, sizeof(::tunnelbroker::ProcessedMessages)}, + { 69, -1, sizeof(::tunnelbroker::MessageToTunnelbrokerStruct)}, + { 78, -1, sizeof(::tunnelbroker::MessagesToSend)}, + { 84, -1, sizeof(::tunnelbroker::MessageToTunnelbroker)}, + { 93, -1, sizeof(::tunnelbroker::MessageToClientStruct)}, + { 102, -1, sizeof(::tunnelbroker::MessagesToDeliver)}, + { 108, -1, sizeof(::tunnelbroker::MessageToClient)}, + { 116, -1, sizeof(::tunnelbroker::CheckRequest)}, + { 123, -1, sizeof(::tunnelbroker::CheckResponse)}, + { 129, -1, sizeof(::tunnelbroker::NewPrimaryRequest)}, + { 136, -1, sizeof(::tunnelbroker::NewPrimaryResponse)}, + { 142, -1, sizeof(::tunnelbroker::PongRequest)}, }; static ::PROTOBUF_NAMESPACE_ID::Message const * const file_default_instances[] = { @@ -480,61 +484,62 @@ "essionResponse\022\021\n\tsessionID\030\001 \001(\t\"Y\n\013Sen" "dRequest\022\021\n\tsessionID\030\001 \001(\t\022\022\n\ntoDeviceI" "D\030\002 \001(\t\022\017\n\007payload\030\003 \001(\014\022\022\n\nblobHashes\030\004" - " \003(\t\"\037\n\nGetRequest\022\021\n\tsessionID\030\001 \001(\t\"H\n" - "\013GetResponse\022\024\n\014fromDeviceID\030\001 \001(\t\022\017\n\007pa" - "yload\030\002 \001(\014\022\022\n\nblobHashes\030\003 \003(\t\"&\n\021Proce" - "ssedMessages\022\021\n\tmessageID\030\001 \003(\t\"i\n\033Messa" - "geToTunnelbrokerStruct\022\021\n\tmessageID\030\001 \001(" - "\t\022\022\n\ntoDeviceID\030\002 \001(\t\022\017\n\007payload\030\003 \001(\t\022\022" - "\n\nblobHashes\030\004 \003(\t\"M\n\016MessagesToSend\022;\n\010" - "messages\030\001 \003(\0132).tunnelbroker.MessageToT" - "unnelbrokerStruct\"\250\001\n\025MessageToTunnelbro" - "ker\022\021\n\tsessionID\030\001 \001(\t\0226\n\016messagesToSend" - "\030\002 \001(\0132\034.tunnelbroker.MessagesToSendH\000\022<" - "\n\021processedMessages\030\003 \001(\0132\037.tunnelbroker" - ".ProcessedMessagesH\000B\006\n\004data\"e\n\025MessageT" - "oClientStruct\022\021\n\tmessageID\030\001 \001(\t\022\024\n\014from" - "DeviceID\030\002 \001(\t\022\017\n\007payload\030\003 \001(\t\022\022\n\nblobH" - "ashes\030\004 \003(\t\"J\n\021MessagesToDeliver\0225\n\010mess" - "ages\030\001 \003(\0132#.tunnelbroker.MessageToClien" - "tStruct\"\225\001\n\017MessageToClient\022<\n\021messagesT" - "oDeliver\030\001 \001(\0132\037.tunnelbroker.MessagesTo" - "DeliverH\000\022<\n\021processedMessages\030\002 \001(\0132\037.t" - "unnelbroker.ProcessedMessagesH\000B\006\n\004data\"" - "3\n\014CheckRequest\022\016\n\006userId\030\001 \001(\t\022\023\n\013devic" - "eToken\030\002 \001(\t\"K\n\rCheckResponse\022:\n\021checkRe" - "sponseType\030\001 \001(\0162\037.tunnelbroker.CheckRes" - "ponseType\"8\n\021NewPrimaryRequest\022\016\n\006userId" - "\030\001 \001(\t\022\023\n\013deviceToken\030\002 \001(\t\"%\n\022NewPrimar" - "yResponse\022\017\n\007success\030\001 \001(\010\"2\n\013PongReques" - "t\022\016\n\006userId\030\001 \001(\t\022\023\n\013deviceToken\030\002 \001(\t*n" - "\n\021CheckResponseType\022\030\n\024PRIMARY_DOESNT_EX" - "IST\020\000\022\022\n\016PRIMARY_ONLINE\020\001\022\023\n\017PRIMARY_OFF" - "LINE\020\002\022\026\n\022CURRENT_IS_PRIMARY\020\0032\237\005\n\023Tunne" - "lbrokerService\022W\n\032CheckIfPrimaryDeviceOn" - "line\022\032.tunnelbroker.CheckRequest\032\033.tunne" - "lbroker.CheckResponse\"\000\022]\n\026BecomeNewPrim" - "aryDevice\022\037.tunnelbroker.NewPrimaryReque" - "st\032 .tunnelbroker.NewPrimaryResponse\"\000\022\?" - "\n\010SendPong\022\031.tunnelbroker.PongRequest\032\026." - "google.protobuf.Empty\"\000\022c\n\020SessionSignat" - "ure\022%.tunnelbroker.SessionSignatureReque" - "st\032&.tunnelbroker.SessionSignatureRespon" - "se\"\000\022Q\n\nNewSession\022\037.tunnelbroker.NewSes" - "sionRequest\032 .tunnelbroker.NewSessionRes" - "ponse\"\000\022;\n\004Send\022\031.tunnelbroker.SendReque" - "st\032\026.google.protobuf.Empty\"\000\022>\n\003Get\022\030.tu" - "nnelbroker.GetRequest\032\031.tunnelbroker.Get" - "Response\"\0000\001\022Z\n\016MessagesStream\022#.tunnelb" - "roker.MessageToTunnelbroker\032\035.tunnelbrok" - "er.MessageToClient\"\000(\0010\001b\006proto3" + " \003(\t\"O\n\nGetRequest\022\021\n\tsessionID\030\001 \001(\t\022\033\n" + "\016newNotifyToken\030\002 \001(\tH\000\210\001\001B\021\n\017_newNotify" + "Token\"H\n\013GetResponse\022\024\n\014fromDeviceID\030\001 \001" + "(\t\022\017\n\007payload\030\002 \001(\014\022\022\n\nblobHashes\030\003 \003(\t\"" + "&\n\021ProcessedMessages\022\021\n\tmessageID\030\001 \003(\t\"" + "i\n\033MessageToTunnelbrokerStruct\022\021\n\tmessag" + "eID\030\001 \001(\t\022\022\n\ntoDeviceID\030\002 \001(\t\022\017\n\007payload" + "\030\003 \001(\t\022\022\n\nblobHashes\030\004 \003(\t\"M\n\016MessagesTo" + "Send\022;\n\010messages\030\001 \003(\0132).tunnelbroker.Me" + "ssageToTunnelbrokerStruct\"\250\001\n\025MessageToT" + "unnelbroker\022\021\n\tsessionID\030\001 \001(\t\0226\n\016messag" + "esToSend\030\002 \001(\0132\034.tunnelbroker.MessagesTo" + "SendH\000\022<\n\021processedMessages\030\003 \001(\0132\037.tunn" + "elbroker.ProcessedMessagesH\000B\006\n\004data\"e\n\025" + "MessageToClientStruct\022\021\n\tmessageID\030\001 \001(\t" + "\022\024\n\014fromDeviceID\030\002 \001(\t\022\017\n\007payload\030\003 \001(\t\022" + "\022\n\nblobHashes\030\004 \003(\t\"J\n\021MessagesToDeliver" + "\0225\n\010messages\030\001 \003(\0132#.tunnelbroker.Messag" + "eToClientStruct\"\225\001\n\017MessageToClient\022<\n\021m" + "essagesToDeliver\030\001 \001(\0132\037.tunnelbroker.Me" + "ssagesToDeliverH\000\022<\n\021processedMessages\030\002" + " \001(\0132\037.tunnelbroker.ProcessedMessagesH\000B" + "\006\n\004data\"3\n\014CheckRequest\022\016\n\006userId\030\001 \001(\t\022" + "\023\n\013deviceToken\030\002 \001(\t\"K\n\rCheckResponse\022:\n" + "\021checkResponseType\030\001 \001(\0162\037.tunnelbroker." + "CheckResponseType\"8\n\021NewPrimaryRequest\022\016" + "\n\006userId\030\001 \001(\t\022\023\n\013deviceToken\030\002 \001(\t\"%\n\022N" + "ewPrimaryResponse\022\017\n\007success\030\001 \001(\010\"2\n\013Po" + "ngRequest\022\016\n\006userId\030\001 \001(\t\022\023\n\013deviceToken" + "\030\002 \001(\t*n\n\021CheckResponseType\022\030\n\024PRIMARY_D" + "OESNT_EXIST\020\000\022\022\n\016PRIMARY_ONLINE\020\001\022\023\n\017PRI" + "MARY_OFFLINE\020\002\022\026\n\022CURRENT_IS_PRIMARY\020\0032\237" + "\005\n\023TunnelbrokerService\022W\n\032CheckIfPrimary" + "DeviceOnline\022\032.tunnelbroker.CheckRequest" + "\032\033.tunnelbroker.CheckResponse\"\000\022]\n\026Becom" + "eNewPrimaryDevice\022\037.tunnelbroker.NewPrim" + "aryRequest\032 .tunnelbroker.NewPrimaryResp" + "onse\"\000\022\?\n\010SendPong\022\031.tunnelbroker.PongRe" + "quest\032\026.google.protobuf.Empty\"\000\022c\n\020Sessi" + "onSignature\022%.tunnelbroker.SessionSignat" + "ureRequest\032&.tunnelbroker.SessionSignatu" + "reResponse\"\000\022Q\n\nNewSession\022\037.tunnelbroke" + "r.NewSessionRequest\032 .tunnelbroker.NewSe" + "ssionResponse\"\000\022;\n\004Send\022\031.tunnelbroker.S" + "endRequest\032\026.google.protobuf.Empty\"\000\022>\n\003" + "Get\022\030.tunnelbroker.GetRequest\032\031.tunnelbr" + "oker.GetResponse\"\0000\001\022Z\n\016MessagesStream\022#" + ".tunnelbroker.MessageToTunnelbroker\032\035.tu" + "nnelbroker.MessageToClient\"\000(\0010\001b\006proto3" ; static const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable*const descriptor_table_tunnelbroker_2eproto_deps[1] = { &::descriptor_table_google_2fprotobuf_2fempty_2eproto, }; static ::PROTOBUF_NAMESPACE_ID::internal::once_flag descriptor_table_tunnelbroker_2eproto_once; const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_tunnelbroker_2eproto = { - false, false, 2472, descriptor_table_protodef_tunnelbroker_2eproto, "tunnelbroker.proto", + false, false, 2520, descriptor_table_protodef_tunnelbroker_2eproto, "tunnelbroker.proto", &descriptor_table_tunnelbroker_2eproto_once, descriptor_table_tunnelbroker_2eproto_deps, 1, 19, schemas, file_default_instances, TableStruct_tunnelbroker_2eproto::offsets, file_level_metadata_tunnelbroker_2eproto, file_level_enum_descriptors_tunnelbroker_2eproto, file_level_service_descriptors_tunnelbroker_2eproto, @@ -1931,6 +1936,10 @@ class GetRequest::_Internal { public: + using HasBits = decltype(std::declval()._has_bits_); + static void set_has_newnotifytoken(HasBits* has_bits) { + (*has_bits)[0] |= 1u; + } }; GetRequest::GetRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena) @@ -1940,18 +1949,25 @@ // @@protoc_insertion_point(arena_constructor:tunnelbroker.GetRequest) } GetRequest::GetRequest(const GetRequest& from) - : ::PROTOBUF_NAMESPACE_ID::Message() { + : ::PROTOBUF_NAMESPACE_ID::Message(), + _has_bits_(from._has_bits_) { _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); sessionid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); if (!from._internal_sessionid().empty()) { sessionid_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_sessionid(), GetArena()); } + newnotifytoken_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); + if (from._internal_has_newnotifytoken()) { + newnotifytoken_.Set(::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::EmptyDefault{}, from._internal_newnotifytoken(), + GetArena()); + } // @@protoc_insertion_point(copy_constructor:tunnelbroker.GetRequest) } void GetRequest::SharedCtor() { sessionid_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); +newnotifytoken_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } GetRequest::~GetRequest() { @@ -1963,6 +1979,7 @@ void GetRequest::SharedDtor() { GOOGLE_DCHECK(GetArena() == nullptr); sessionid_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); + newnotifytoken_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); } void GetRequest::ArenaDtor(void* object) { @@ -1982,11 +1999,17 @@ (void) cached_has_bits; sessionid_.ClearToEmpty(); + cached_has_bits = _has_bits_[0]; + if (cached_has_bits & 0x00000001u) { + newnotifytoken_.ClearNonDefaultToEmpty(); + } + _has_bits_.Clear(); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } const char* GetRequest::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure + _Internal::HasBits has_bits{}; while (!ctx->Done(&ptr)) { ::PROTOBUF_NAMESPACE_ID::uint32 tag; ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); @@ -2001,6 +2024,15 @@ CHK_(ptr); } else goto handle_unusual; continue; + // string newNotifyToken = 2; + case 2: + if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) { + auto str = _internal_mutable_newnotifytoken(); + ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(str, ptr, ctx); + CHK_(::PROTOBUF_NAMESPACE_ID::internal::VerifyUTF8(str, "tunnelbroker.GetRequest.newNotifyToken")); + CHK_(ptr); + } else goto handle_unusual; + continue; default: { handle_unusual: if ((tag & 7) == 4 || tag == 0) { @@ -2016,6 +2048,7 @@ } // switch } // while success: + _has_bits_.Or(has_bits); return ptr; failure: ptr = nullptr; @@ -2039,6 +2072,16 @@ 1, this->_internal_sessionid(), target); } + // string newNotifyToken = 2; + if (_internal_has_newnotifytoken()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_newnotifytoken().data(), static_cast(this->_internal_newnotifytoken().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "tunnelbroker.GetRequest.newNotifyToken"); + target = stream->WriteStringMaybeAliased( + 2, this->_internal_newnotifytoken(), target); + } + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::InternalSerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); @@ -2062,6 +2105,14 @@ this->_internal_sessionid()); } + // string newNotifyToken = 2; + cached_has_bits = _has_bits_[0]; + if (cached_has_bits & 0x00000001u) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_newnotifytoken()); + } + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { return ::PROTOBUF_NAMESPACE_ID::internal::ComputeUnknownFieldsSize( _internal_metadata_, total_size, &_cached_size_); @@ -2096,6 +2147,9 @@ if (from.sessionid().size() > 0) { _internal_set_sessionid(from._internal_sessionid()); } + if (from._internal_has_newnotifytoken()) { + _internal_set_newnotifytoken(from._internal_newnotifytoken()); + } } void GetRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { @@ -2119,7 +2173,9 @@ void GetRequest::InternalSwap(GetRequest* other) { using std::swap; _internal_metadata_.Swap<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(&other->_internal_metadata_); + swap(_has_bits_[0], other->_has_bits_[0]); sessionid_.Swap(&other->sessionid_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); + newnotifytoken_.Swap(&other->newnotifytoken_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); } ::PROTOBUF_NAMESPACE_ID::Metadata GetRequest::GetMetadata() const { diff --git a/shared/protos/tunnelbroker.proto b/shared/protos/tunnelbroker.proto --- a/shared/protos/tunnelbroker.proto +++ b/shared/protos/tunnelbroker.proto @@ -68,6 +68,7 @@ message GetRequest { string sessionID = 1; + optional string newNotifyToken = 2; } message GetResponse {