cds.upb.h 82 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142
  1. /* This file was generated by upbc (the upb compiler) from the input
  2. * file:
  3. *
  4. * envoy/api/v2/cds.proto
  5. *
  6. * Do not edit -- your changes will be discarded when the file is
  7. * regenerated. */
  8. #ifndef ENVOY_API_V2_CDS_PROTO_UPB_H_
  9. #define ENVOY_API_V2_CDS_PROTO_UPB_H_
  10. #include "upb/generated_util.h"
  11. #include "upb/msg.h"
  12. #include "upb/decode.h"
  13. #include "upb/encode.h"
  14. #include "upb/port_def.inc"
  15. #ifdef __cplusplus
  16. extern "C" {
  17. #endif
  18. struct envoy_api_v2_Cluster;
  19. struct envoy_api_v2_Cluster_CustomClusterType;
  20. struct envoy_api_v2_Cluster_EdsClusterConfig;
  21. struct envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry;
  22. struct envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry;
  23. struct envoy_api_v2_Cluster_LbSubsetConfig;
  24. struct envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector;
  25. struct envoy_api_v2_Cluster_LeastRequestLbConfig;
  26. struct envoy_api_v2_Cluster_RingHashLbConfig;
  27. struct envoy_api_v2_Cluster_OriginalDstLbConfig;
  28. struct envoy_api_v2_Cluster_CommonLbConfig;
  29. struct envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig;
  30. struct envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig;
  31. struct envoy_api_v2_UpstreamBindConfig;
  32. struct envoy_api_v2_UpstreamConnectionOptions;
  33. typedef struct envoy_api_v2_Cluster envoy_api_v2_Cluster;
  34. typedef struct envoy_api_v2_Cluster_CustomClusterType envoy_api_v2_Cluster_CustomClusterType;
  35. typedef struct envoy_api_v2_Cluster_EdsClusterConfig envoy_api_v2_Cluster_EdsClusterConfig;
  36. typedef struct envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry;
  37. typedef struct envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry;
  38. typedef struct envoy_api_v2_Cluster_LbSubsetConfig envoy_api_v2_Cluster_LbSubsetConfig;
  39. typedef struct envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector;
  40. typedef struct envoy_api_v2_Cluster_LeastRequestLbConfig envoy_api_v2_Cluster_LeastRequestLbConfig;
  41. typedef struct envoy_api_v2_Cluster_RingHashLbConfig envoy_api_v2_Cluster_RingHashLbConfig;
  42. typedef struct envoy_api_v2_Cluster_OriginalDstLbConfig envoy_api_v2_Cluster_OriginalDstLbConfig;
  43. typedef struct envoy_api_v2_Cluster_CommonLbConfig envoy_api_v2_Cluster_CommonLbConfig;
  44. typedef struct envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig;
  45. typedef struct envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig;
  46. typedef struct envoy_api_v2_UpstreamBindConfig envoy_api_v2_UpstreamBindConfig;
  47. typedef struct envoy_api_v2_UpstreamConnectionOptions envoy_api_v2_UpstreamConnectionOptions;
  48. extern const upb_msglayout envoy_api_v2_Cluster_msginit;
  49. extern const upb_msglayout envoy_api_v2_Cluster_CustomClusterType_msginit;
  50. extern const upb_msglayout envoy_api_v2_Cluster_EdsClusterConfig_msginit;
  51. extern const upb_msglayout envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_msginit;
  52. extern const upb_msglayout envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_msginit;
  53. extern const upb_msglayout envoy_api_v2_Cluster_LbSubsetConfig_msginit;
  54. extern const upb_msglayout envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_msginit;
  55. extern const upb_msglayout envoy_api_v2_Cluster_LeastRequestLbConfig_msginit;
  56. extern const upb_msglayout envoy_api_v2_Cluster_RingHashLbConfig_msginit;
  57. extern const upb_msglayout envoy_api_v2_Cluster_OriginalDstLbConfig_msginit;
  58. extern const upb_msglayout envoy_api_v2_Cluster_CommonLbConfig_msginit;
  59. extern const upb_msglayout envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit;
  60. extern const upb_msglayout envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit;
  61. extern const upb_msglayout envoy_api_v2_UpstreamBindConfig_msginit;
  62. extern const upb_msglayout envoy_api_v2_UpstreamConnectionOptions_msginit;
  63. struct envoy_api_v2_ClusterLoadAssignment;
  64. struct envoy_api_v2_auth_UpstreamTlsContext;
  65. struct envoy_api_v2_cluster_CircuitBreakers;
  66. struct envoy_api_v2_cluster_Filter;
  67. struct envoy_api_v2_cluster_OutlierDetection;
  68. struct envoy_api_v2_core_Address;
  69. struct envoy_api_v2_core_BindConfig;
  70. struct envoy_api_v2_core_ConfigSource;
  71. struct envoy_api_v2_core_HealthCheck;
  72. struct envoy_api_v2_core_Http1ProtocolOptions;
  73. struct envoy_api_v2_core_Http2ProtocolOptions;
  74. struct envoy_api_v2_core_HttpProtocolOptions;
  75. struct envoy_api_v2_core_Metadata;
  76. struct envoy_api_v2_core_TcpKeepalive;
  77. struct envoy_api_v2_core_TransportSocket;
  78. struct envoy_type_Percent;
  79. struct google_protobuf_Any;
  80. struct google_protobuf_Duration;
  81. struct google_protobuf_Struct;
  82. struct google_protobuf_UInt32Value;
  83. struct google_protobuf_UInt64Value;
  84. extern const upb_msglayout envoy_api_v2_ClusterLoadAssignment_msginit;
  85. extern const upb_msglayout envoy_api_v2_auth_UpstreamTlsContext_msginit;
  86. extern const upb_msglayout envoy_api_v2_cluster_CircuitBreakers_msginit;
  87. extern const upb_msglayout envoy_api_v2_cluster_Filter_msginit;
  88. extern const upb_msglayout envoy_api_v2_cluster_OutlierDetection_msginit;
  89. extern const upb_msglayout envoy_api_v2_core_Address_msginit;
  90. extern const upb_msglayout envoy_api_v2_core_BindConfig_msginit;
  91. extern const upb_msglayout envoy_api_v2_core_ConfigSource_msginit;
  92. extern const upb_msglayout envoy_api_v2_core_HealthCheck_msginit;
  93. extern const upb_msglayout envoy_api_v2_core_Http1ProtocolOptions_msginit;
  94. extern const upb_msglayout envoy_api_v2_core_Http2ProtocolOptions_msginit;
  95. extern const upb_msglayout envoy_api_v2_core_HttpProtocolOptions_msginit;
  96. extern const upb_msglayout envoy_api_v2_core_Metadata_msginit;
  97. extern const upb_msglayout envoy_api_v2_core_TcpKeepalive_msginit;
  98. extern const upb_msglayout envoy_api_v2_core_TransportSocket_msginit;
  99. extern const upb_msglayout envoy_type_Percent_msginit;
  100. extern const upb_msglayout google_protobuf_Any_msginit;
  101. extern const upb_msglayout google_protobuf_Duration_msginit;
  102. extern const upb_msglayout google_protobuf_Struct_msginit;
  103. extern const upb_msglayout google_protobuf_UInt32Value_msginit;
  104. extern const upb_msglayout google_protobuf_UInt64Value_msginit;
  105. typedef enum {
  106. envoy_api_v2_Cluster_USE_CONFIGURED_PROTOCOL = 0,
  107. envoy_api_v2_Cluster_USE_DOWNSTREAM_PROTOCOL = 1
  108. } envoy_api_v2_Cluster_ClusterProtocolSelection;
  109. typedef enum {
  110. envoy_api_v2_Cluster_STATIC = 0,
  111. envoy_api_v2_Cluster_STRICT_DNS = 1,
  112. envoy_api_v2_Cluster_LOGICAL_DNS = 2,
  113. envoy_api_v2_Cluster_EDS = 3,
  114. envoy_api_v2_Cluster_ORIGINAL_DST = 4
  115. } envoy_api_v2_Cluster_DiscoveryType;
  116. typedef enum {
  117. envoy_api_v2_Cluster_AUTO = 0,
  118. envoy_api_v2_Cluster_V4_ONLY = 1,
  119. envoy_api_v2_Cluster_V6_ONLY = 2
  120. } envoy_api_v2_Cluster_DnsLookupFamily;
  121. typedef enum {
  122. envoy_api_v2_Cluster_ROUND_ROBIN = 0,
  123. envoy_api_v2_Cluster_LEAST_REQUEST = 1,
  124. envoy_api_v2_Cluster_RING_HASH = 2,
  125. envoy_api_v2_Cluster_RANDOM = 3,
  126. envoy_api_v2_Cluster_ORIGINAL_DST_LB = 4,
  127. envoy_api_v2_Cluster_MAGLEV = 5,
  128. envoy_api_v2_Cluster_CLUSTER_PROVIDED = 6
  129. } envoy_api_v2_Cluster_LbPolicy;
  130. typedef enum {
  131. envoy_api_v2_Cluster_LbSubsetConfig_NO_FALLBACK = 0,
  132. envoy_api_v2_Cluster_LbSubsetConfig_ANY_ENDPOINT = 1,
  133. envoy_api_v2_Cluster_LbSubsetConfig_DEFAULT_SUBSET = 2
  134. } envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetFallbackPolicy;
  135. typedef enum {
  136. envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_NOT_DEFINED = 0,
  137. envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_NO_FALLBACK = 1,
  138. envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_ANY_ENDPOINT = 2,
  139. envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_DEFAULT_SUBSET = 3
  140. } envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_LbSubsetSelectorFallbackPolicy;
  141. typedef enum {
  142. envoy_api_v2_Cluster_RingHashLbConfig_XX_HASH = 0,
  143. envoy_api_v2_Cluster_RingHashLbConfig_MURMUR_HASH_2 = 1
  144. } envoy_api_v2_Cluster_RingHashLbConfig_HashFunction;
  145. /* envoy.api.v2.Cluster */
  146. UPB_INLINE envoy_api_v2_Cluster *envoy_api_v2_Cluster_new(upb_arena *arena) {
  147. return (envoy_api_v2_Cluster *)upb_msg_new(&envoy_api_v2_Cluster_msginit, arena);
  148. }
  149. UPB_INLINE envoy_api_v2_Cluster *envoy_api_v2_Cluster_parse(const char *buf, size_t size,
  150. upb_arena *arena) {
  151. envoy_api_v2_Cluster *ret = envoy_api_v2_Cluster_new(arena);
  152. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_msginit, arena)) ? ret : NULL;
  153. }
  154. UPB_INLINE char *envoy_api_v2_Cluster_serialize(const envoy_api_v2_Cluster *msg, upb_arena *arena, size_t *len) {
  155. return upb_encode(msg, &envoy_api_v2_Cluster_msginit, arena, len);
  156. }
  157. typedef enum {
  158. envoy_api_v2_Cluster_cluster_discovery_type_type = 2,
  159. envoy_api_v2_Cluster_cluster_discovery_type_cluster_type = 38,
  160. envoy_api_v2_Cluster_cluster_discovery_type_NOT_SET = 0
  161. } envoy_api_v2_Cluster_cluster_discovery_type_oneofcases;
  162. UPB_INLINE envoy_api_v2_Cluster_cluster_discovery_type_oneofcases envoy_api_v2_Cluster_cluster_discovery_type_case(const envoy_api_v2_Cluster* msg) { return (envoy_api_v2_Cluster_cluster_discovery_type_oneofcases)UPB_FIELD_AT(msg, int32_t, UPB_SIZE(152, 272)); }
  163. typedef enum {
  164. envoy_api_v2_Cluster_lb_config_ring_hash_lb_config = 23,
  165. envoy_api_v2_Cluster_lb_config_original_dst_lb_config = 34,
  166. envoy_api_v2_Cluster_lb_config_least_request_lb_config = 37,
  167. envoy_api_v2_Cluster_lb_config_NOT_SET = 0
  168. } envoy_api_v2_Cluster_lb_config_oneofcases;
  169. UPB_INLINE envoy_api_v2_Cluster_lb_config_oneofcases envoy_api_v2_Cluster_lb_config_case(const envoy_api_v2_Cluster* msg) { return (envoy_api_v2_Cluster_lb_config_oneofcases)UPB_FIELD_AT(msg, int32_t, UPB_SIZE(160, 288)); }
  170. UPB_INLINE upb_strview envoy_api_v2_Cluster_name(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(28, 32)); }
  171. UPB_INLINE bool envoy_api_v2_Cluster_has_type(const envoy_api_v2_Cluster *msg) { return _upb_has_oneof_field(msg, UPB_SIZE(152, 272), 2); }
  172. UPB_INLINE int32_t envoy_api_v2_Cluster_type(const envoy_api_v2_Cluster *msg) { return UPB_READ_ONEOF(msg, int32_t, UPB_SIZE(144, 264), UPB_SIZE(152, 272), 2, envoy_api_v2_Cluster_STATIC); }
  173. UPB_INLINE const envoy_api_v2_Cluster_EdsClusterConfig* envoy_api_v2_Cluster_eds_cluster_config(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const envoy_api_v2_Cluster_EdsClusterConfig*, UPB_SIZE(44, 64)); }
  174. UPB_INLINE const struct google_protobuf_Duration* envoy_api_v2_Cluster_connect_timeout(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_Duration*, UPB_SIZE(48, 72)); }
  175. UPB_INLINE const struct google_protobuf_UInt32Value* envoy_api_v2_Cluster_per_connection_buffer_limit_bytes(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_UInt32Value*, UPB_SIZE(52, 80)); }
  176. UPB_INLINE int32_t envoy_api_v2_Cluster_lb_policy(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, int32_t, UPB_SIZE(0, 0)); }
  177. UPB_INLINE const struct envoy_api_v2_core_Address* const* envoy_api_v2_Cluster_hosts(const envoy_api_v2_Cluster *msg, size_t *len) { return (const struct envoy_api_v2_core_Address* const*)_upb_array_accessor(msg, UPB_SIZE(120, 216), len); }
  178. UPB_INLINE const struct envoy_api_v2_core_HealthCheck* const* envoy_api_v2_Cluster_health_checks(const envoy_api_v2_Cluster *msg, size_t *len) { return (const struct envoy_api_v2_core_HealthCheck* const*)_upb_array_accessor(msg, UPB_SIZE(124, 224), len); }
  179. UPB_INLINE const struct google_protobuf_UInt32Value* envoy_api_v2_Cluster_max_requests_per_connection(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_UInt32Value*, UPB_SIZE(56, 88)); }
  180. UPB_INLINE const struct envoy_api_v2_cluster_CircuitBreakers* envoy_api_v2_Cluster_circuit_breakers(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_cluster_CircuitBreakers*, UPB_SIZE(60, 96)); }
  181. UPB_INLINE const struct envoy_api_v2_auth_UpstreamTlsContext* envoy_api_v2_Cluster_tls_context(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_auth_UpstreamTlsContext*, UPB_SIZE(64, 104)); }
  182. UPB_INLINE const struct envoy_api_v2_core_Http1ProtocolOptions* envoy_api_v2_Cluster_http_protocol_options(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_core_Http1ProtocolOptions*, UPB_SIZE(68, 112)); }
  183. UPB_INLINE const struct envoy_api_v2_core_Http2ProtocolOptions* envoy_api_v2_Cluster_http2_protocol_options(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_core_Http2ProtocolOptions*, UPB_SIZE(72, 120)); }
  184. UPB_INLINE const struct google_protobuf_Duration* envoy_api_v2_Cluster_dns_refresh_rate(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_Duration*, UPB_SIZE(76, 128)); }
  185. UPB_INLINE int32_t envoy_api_v2_Cluster_dns_lookup_family(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, int32_t, UPB_SIZE(8, 8)); }
  186. UPB_INLINE const struct envoy_api_v2_core_Address* const* envoy_api_v2_Cluster_dns_resolvers(const envoy_api_v2_Cluster *msg, size_t *len) { return (const struct envoy_api_v2_core_Address* const*)_upb_array_accessor(msg, UPB_SIZE(128, 232), len); }
  187. UPB_INLINE const struct envoy_api_v2_cluster_OutlierDetection* envoy_api_v2_Cluster_outlier_detection(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_cluster_OutlierDetection*, UPB_SIZE(80, 136)); }
  188. UPB_INLINE const struct google_protobuf_Duration* envoy_api_v2_Cluster_cleanup_interval(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_Duration*, UPB_SIZE(84, 144)); }
  189. UPB_INLINE const struct envoy_api_v2_core_BindConfig* envoy_api_v2_Cluster_upstream_bind_config(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_core_BindConfig*, UPB_SIZE(88, 152)); }
  190. UPB_INLINE const envoy_api_v2_Cluster_LbSubsetConfig* envoy_api_v2_Cluster_lb_subset_config(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const envoy_api_v2_Cluster_LbSubsetConfig*, UPB_SIZE(92, 160)); }
  191. UPB_INLINE bool envoy_api_v2_Cluster_has_ring_hash_lb_config(const envoy_api_v2_Cluster *msg) { return _upb_has_oneof_field(msg, UPB_SIZE(160, 288), 23); }
  192. UPB_INLINE const envoy_api_v2_Cluster_RingHashLbConfig* envoy_api_v2_Cluster_ring_hash_lb_config(const envoy_api_v2_Cluster *msg) { return UPB_READ_ONEOF(msg, const envoy_api_v2_Cluster_RingHashLbConfig*, UPB_SIZE(156, 280), UPB_SIZE(160, 288), 23, NULL); }
  193. UPB_INLINE const struct envoy_api_v2_core_TransportSocket* envoy_api_v2_Cluster_transport_socket(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_core_TransportSocket*, UPB_SIZE(96, 168)); }
  194. UPB_INLINE const struct envoy_api_v2_core_Metadata* envoy_api_v2_Cluster_metadata(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_core_Metadata*, UPB_SIZE(100, 176)); }
  195. UPB_INLINE int32_t envoy_api_v2_Cluster_protocol_selection(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, int32_t, UPB_SIZE(16, 16)); }
  196. UPB_INLINE const envoy_api_v2_Cluster_CommonLbConfig* envoy_api_v2_Cluster_common_lb_config(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const envoy_api_v2_Cluster_CommonLbConfig*, UPB_SIZE(104, 184)); }
  197. UPB_INLINE upb_strview envoy_api_v2_Cluster_alt_stat_name(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(36, 48)); }
  198. UPB_INLINE const struct envoy_api_v2_core_HttpProtocolOptions* envoy_api_v2_Cluster_common_http_protocol_options(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_core_HttpProtocolOptions*, UPB_SIZE(108, 192)); }
  199. UPB_INLINE const envoy_api_v2_UpstreamConnectionOptions* envoy_api_v2_Cluster_upstream_connection_options(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const envoy_api_v2_UpstreamConnectionOptions*, UPB_SIZE(112, 200)); }
  200. UPB_INLINE bool envoy_api_v2_Cluster_close_connections_on_host_health_failure(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, bool, UPB_SIZE(24, 24)); }
  201. UPB_INLINE bool envoy_api_v2_Cluster_drain_connections_on_host_removal(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, bool, UPB_SIZE(25, 25)); }
  202. UPB_INLINE const struct envoy_api_v2_ClusterLoadAssignment* envoy_api_v2_Cluster_load_assignment(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_ClusterLoadAssignment*, UPB_SIZE(116, 208)); }
  203. UPB_INLINE bool envoy_api_v2_Cluster_has_original_dst_lb_config(const envoy_api_v2_Cluster *msg) { return _upb_has_oneof_field(msg, UPB_SIZE(160, 288), 34); }
  204. UPB_INLINE const envoy_api_v2_Cluster_OriginalDstLbConfig* envoy_api_v2_Cluster_original_dst_lb_config(const envoy_api_v2_Cluster *msg) { return UPB_READ_ONEOF(msg, const envoy_api_v2_Cluster_OriginalDstLbConfig*, UPB_SIZE(156, 280), UPB_SIZE(160, 288), 34, NULL); }
  205. UPB_INLINE const envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry* const* envoy_api_v2_Cluster_extension_protocol_options(const envoy_api_v2_Cluster *msg, size_t *len) { return (const envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry* const*)_upb_array_accessor(msg, UPB_SIZE(132, 240), len); }
  206. UPB_INLINE const envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry* const* envoy_api_v2_Cluster_typed_extension_protocol_options(const envoy_api_v2_Cluster *msg, size_t *len) { return (const envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry* const*)_upb_array_accessor(msg, UPB_SIZE(136, 248), len); }
  207. UPB_INLINE bool envoy_api_v2_Cluster_has_least_request_lb_config(const envoy_api_v2_Cluster *msg) { return _upb_has_oneof_field(msg, UPB_SIZE(160, 288), 37); }
  208. UPB_INLINE const envoy_api_v2_Cluster_LeastRequestLbConfig* envoy_api_v2_Cluster_least_request_lb_config(const envoy_api_v2_Cluster *msg) { return UPB_READ_ONEOF(msg, const envoy_api_v2_Cluster_LeastRequestLbConfig*, UPB_SIZE(156, 280), UPB_SIZE(160, 288), 37, NULL); }
  209. UPB_INLINE bool envoy_api_v2_Cluster_has_cluster_type(const envoy_api_v2_Cluster *msg) { return _upb_has_oneof_field(msg, UPB_SIZE(152, 272), 38); }
  210. UPB_INLINE const envoy_api_v2_Cluster_CustomClusterType* envoy_api_v2_Cluster_cluster_type(const envoy_api_v2_Cluster *msg) { return UPB_READ_ONEOF(msg, const envoy_api_v2_Cluster_CustomClusterType*, UPB_SIZE(144, 264), UPB_SIZE(152, 272), 38, NULL); }
  211. UPB_INLINE bool envoy_api_v2_Cluster_respect_dns_ttl(const envoy_api_v2_Cluster *msg) { return UPB_FIELD_AT(msg, bool, UPB_SIZE(26, 26)); }
  212. UPB_INLINE const struct envoy_api_v2_cluster_Filter* const* envoy_api_v2_Cluster_filters(const envoy_api_v2_Cluster *msg, size_t *len) { return (const struct envoy_api_v2_cluster_Filter* const*)_upb_array_accessor(msg, UPB_SIZE(140, 256), len); }
  213. UPB_INLINE void envoy_api_v2_Cluster_set_name(envoy_api_v2_Cluster *msg, upb_strview value) {
  214. UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(28, 32)) = value;
  215. }
  216. UPB_INLINE void envoy_api_v2_Cluster_set_type(envoy_api_v2_Cluster *msg, int32_t value) {
  217. UPB_WRITE_ONEOF(msg, int32_t, UPB_SIZE(144, 264), value, UPB_SIZE(152, 272), 2);
  218. }
  219. UPB_INLINE void envoy_api_v2_Cluster_set_eds_cluster_config(envoy_api_v2_Cluster *msg, envoy_api_v2_Cluster_EdsClusterConfig* value) {
  220. UPB_FIELD_AT(msg, envoy_api_v2_Cluster_EdsClusterConfig*, UPB_SIZE(44, 64)) = value;
  221. }
  222. UPB_INLINE struct envoy_api_v2_Cluster_EdsClusterConfig* envoy_api_v2_Cluster_mutable_eds_cluster_config(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  223. struct envoy_api_v2_Cluster_EdsClusterConfig* sub = (struct envoy_api_v2_Cluster_EdsClusterConfig*)envoy_api_v2_Cluster_eds_cluster_config(msg);
  224. if (sub == NULL) {
  225. sub = (struct envoy_api_v2_Cluster_EdsClusterConfig*)upb_msg_new(&envoy_api_v2_Cluster_EdsClusterConfig_msginit, arena);
  226. if (!sub) return NULL;
  227. envoy_api_v2_Cluster_set_eds_cluster_config(msg, sub);
  228. }
  229. return sub;
  230. }
  231. UPB_INLINE void envoy_api_v2_Cluster_set_connect_timeout(envoy_api_v2_Cluster *msg, struct google_protobuf_Duration* value) {
  232. UPB_FIELD_AT(msg, struct google_protobuf_Duration*, UPB_SIZE(48, 72)) = value;
  233. }
  234. UPB_INLINE struct google_protobuf_Duration* envoy_api_v2_Cluster_mutable_connect_timeout(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  235. struct google_protobuf_Duration* sub = (struct google_protobuf_Duration*)envoy_api_v2_Cluster_connect_timeout(msg);
  236. if (sub == NULL) {
  237. sub = (struct google_protobuf_Duration*)upb_msg_new(&google_protobuf_Duration_msginit, arena);
  238. if (!sub) return NULL;
  239. envoy_api_v2_Cluster_set_connect_timeout(msg, sub);
  240. }
  241. return sub;
  242. }
  243. UPB_INLINE void envoy_api_v2_Cluster_set_per_connection_buffer_limit_bytes(envoy_api_v2_Cluster *msg, struct google_protobuf_UInt32Value* value) {
  244. UPB_FIELD_AT(msg, struct google_protobuf_UInt32Value*, UPB_SIZE(52, 80)) = value;
  245. }
  246. UPB_INLINE struct google_protobuf_UInt32Value* envoy_api_v2_Cluster_mutable_per_connection_buffer_limit_bytes(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  247. struct google_protobuf_UInt32Value* sub = (struct google_protobuf_UInt32Value*)envoy_api_v2_Cluster_per_connection_buffer_limit_bytes(msg);
  248. if (sub == NULL) {
  249. sub = (struct google_protobuf_UInt32Value*)upb_msg_new(&google_protobuf_UInt32Value_msginit, arena);
  250. if (!sub) return NULL;
  251. envoy_api_v2_Cluster_set_per_connection_buffer_limit_bytes(msg, sub);
  252. }
  253. return sub;
  254. }
  255. UPB_INLINE void envoy_api_v2_Cluster_set_lb_policy(envoy_api_v2_Cluster *msg, int32_t value) {
  256. UPB_FIELD_AT(msg, int32_t, UPB_SIZE(0, 0)) = value;
  257. }
  258. UPB_INLINE struct envoy_api_v2_core_Address** envoy_api_v2_Cluster_mutable_hosts(envoy_api_v2_Cluster *msg, size_t *len) {
  259. return (struct envoy_api_v2_core_Address**)_upb_array_mutable_accessor(msg, UPB_SIZE(120, 216), len);
  260. }
  261. UPB_INLINE struct envoy_api_v2_core_Address** envoy_api_v2_Cluster_resize_hosts(envoy_api_v2_Cluster *msg, size_t len, upb_arena *arena) {
  262. return (struct envoy_api_v2_core_Address**)_upb_array_resize_accessor(msg, UPB_SIZE(120, 216), len, UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, arena);
  263. }
  264. UPB_INLINE struct envoy_api_v2_core_Address* envoy_api_v2_Cluster_add_hosts(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  265. struct envoy_api_v2_core_Address* sub = (struct envoy_api_v2_core_Address*)upb_msg_new(&envoy_api_v2_core_Address_msginit, arena);
  266. bool ok = _upb_array_append_accessor(
  267. msg, UPB_SIZE(120, 216), UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, &sub, arena);
  268. if (!ok) return NULL;
  269. return sub;
  270. }
  271. UPB_INLINE struct envoy_api_v2_core_HealthCheck** envoy_api_v2_Cluster_mutable_health_checks(envoy_api_v2_Cluster *msg, size_t *len) {
  272. return (struct envoy_api_v2_core_HealthCheck**)_upb_array_mutable_accessor(msg, UPB_SIZE(124, 224), len);
  273. }
  274. UPB_INLINE struct envoy_api_v2_core_HealthCheck** envoy_api_v2_Cluster_resize_health_checks(envoy_api_v2_Cluster *msg, size_t len, upb_arena *arena) {
  275. return (struct envoy_api_v2_core_HealthCheck**)_upb_array_resize_accessor(msg, UPB_SIZE(124, 224), len, UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, arena);
  276. }
  277. UPB_INLINE struct envoy_api_v2_core_HealthCheck* envoy_api_v2_Cluster_add_health_checks(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  278. struct envoy_api_v2_core_HealthCheck* sub = (struct envoy_api_v2_core_HealthCheck*)upb_msg_new(&envoy_api_v2_core_HealthCheck_msginit, arena);
  279. bool ok = _upb_array_append_accessor(
  280. msg, UPB_SIZE(124, 224), UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, &sub, arena);
  281. if (!ok) return NULL;
  282. return sub;
  283. }
  284. UPB_INLINE void envoy_api_v2_Cluster_set_max_requests_per_connection(envoy_api_v2_Cluster *msg, struct google_protobuf_UInt32Value* value) {
  285. UPB_FIELD_AT(msg, struct google_protobuf_UInt32Value*, UPB_SIZE(56, 88)) = value;
  286. }
  287. UPB_INLINE struct google_protobuf_UInt32Value* envoy_api_v2_Cluster_mutable_max_requests_per_connection(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  288. struct google_protobuf_UInt32Value* sub = (struct google_protobuf_UInt32Value*)envoy_api_v2_Cluster_max_requests_per_connection(msg);
  289. if (sub == NULL) {
  290. sub = (struct google_protobuf_UInt32Value*)upb_msg_new(&google_protobuf_UInt32Value_msginit, arena);
  291. if (!sub) return NULL;
  292. envoy_api_v2_Cluster_set_max_requests_per_connection(msg, sub);
  293. }
  294. return sub;
  295. }
  296. UPB_INLINE void envoy_api_v2_Cluster_set_circuit_breakers(envoy_api_v2_Cluster *msg, struct envoy_api_v2_cluster_CircuitBreakers* value) {
  297. UPB_FIELD_AT(msg, struct envoy_api_v2_cluster_CircuitBreakers*, UPB_SIZE(60, 96)) = value;
  298. }
  299. UPB_INLINE struct envoy_api_v2_cluster_CircuitBreakers* envoy_api_v2_Cluster_mutable_circuit_breakers(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  300. struct envoy_api_v2_cluster_CircuitBreakers* sub = (struct envoy_api_v2_cluster_CircuitBreakers*)envoy_api_v2_Cluster_circuit_breakers(msg);
  301. if (sub == NULL) {
  302. sub = (struct envoy_api_v2_cluster_CircuitBreakers*)upb_msg_new(&envoy_api_v2_cluster_CircuitBreakers_msginit, arena);
  303. if (!sub) return NULL;
  304. envoy_api_v2_Cluster_set_circuit_breakers(msg, sub);
  305. }
  306. return sub;
  307. }
  308. UPB_INLINE void envoy_api_v2_Cluster_set_tls_context(envoy_api_v2_Cluster *msg, struct envoy_api_v2_auth_UpstreamTlsContext* value) {
  309. UPB_FIELD_AT(msg, struct envoy_api_v2_auth_UpstreamTlsContext*, UPB_SIZE(64, 104)) = value;
  310. }
  311. UPB_INLINE struct envoy_api_v2_auth_UpstreamTlsContext* envoy_api_v2_Cluster_mutable_tls_context(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  312. struct envoy_api_v2_auth_UpstreamTlsContext* sub = (struct envoy_api_v2_auth_UpstreamTlsContext*)envoy_api_v2_Cluster_tls_context(msg);
  313. if (sub == NULL) {
  314. sub = (struct envoy_api_v2_auth_UpstreamTlsContext*)upb_msg_new(&envoy_api_v2_auth_UpstreamTlsContext_msginit, arena);
  315. if (!sub) return NULL;
  316. envoy_api_v2_Cluster_set_tls_context(msg, sub);
  317. }
  318. return sub;
  319. }
  320. UPB_INLINE void envoy_api_v2_Cluster_set_http_protocol_options(envoy_api_v2_Cluster *msg, struct envoy_api_v2_core_Http1ProtocolOptions* value) {
  321. UPB_FIELD_AT(msg, struct envoy_api_v2_core_Http1ProtocolOptions*, UPB_SIZE(68, 112)) = value;
  322. }
  323. UPB_INLINE struct envoy_api_v2_core_Http1ProtocolOptions* envoy_api_v2_Cluster_mutable_http_protocol_options(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  324. struct envoy_api_v2_core_Http1ProtocolOptions* sub = (struct envoy_api_v2_core_Http1ProtocolOptions*)envoy_api_v2_Cluster_http_protocol_options(msg);
  325. if (sub == NULL) {
  326. sub = (struct envoy_api_v2_core_Http1ProtocolOptions*)upb_msg_new(&envoy_api_v2_core_Http1ProtocolOptions_msginit, arena);
  327. if (!sub) return NULL;
  328. envoy_api_v2_Cluster_set_http_protocol_options(msg, sub);
  329. }
  330. return sub;
  331. }
  332. UPB_INLINE void envoy_api_v2_Cluster_set_http2_protocol_options(envoy_api_v2_Cluster *msg, struct envoy_api_v2_core_Http2ProtocolOptions* value) {
  333. UPB_FIELD_AT(msg, struct envoy_api_v2_core_Http2ProtocolOptions*, UPB_SIZE(72, 120)) = value;
  334. }
  335. UPB_INLINE struct envoy_api_v2_core_Http2ProtocolOptions* envoy_api_v2_Cluster_mutable_http2_protocol_options(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  336. struct envoy_api_v2_core_Http2ProtocolOptions* sub = (struct envoy_api_v2_core_Http2ProtocolOptions*)envoy_api_v2_Cluster_http2_protocol_options(msg);
  337. if (sub == NULL) {
  338. sub = (struct envoy_api_v2_core_Http2ProtocolOptions*)upb_msg_new(&envoy_api_v2_core_Http2ProtocolOptions_msginit, arena);
  339. if (!sub) return NULL;
  340. envoy_api_v2_Cluster_set_http2_protocol_options(msg, sub);
  341. }
  342. return sub;
  343. }
  344. UPB_INLINE void envoy_api_v2_Cluster_set_dns_refresh_rate(envoy_api_v2_Cluster *msg, struct google_protobuf_Duration* value) {
  345. UPB_FIELD_AT(msg, struct google_protobuf_Duration*, UPB_SIZE(76, 128)) = value;
  346. }
  347. UPB_INLINE struct google_protobuf_Duration* envoy_api_v2_Cluster_mutable_dns_refresh_rate(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  348. struct google_protobuf_Duration* sub = (struct google_protobuf_Duration*)envoy_api_v2_Cluster_dns_refresh_rate(msg);
  349. if (sub == NULL) {
  350. sub = (struct google_protobuf_Duration*)upb_msg_new(&google_protobuf_Duration_msginit, arena);
  351. if (!sub) return NULL;
  352. envoy_api_v2_Cluster_set_dns_refresh_rate(msg, sub);
  353. }
  354. return sub;
  355. }
  356. UPB_INLINE void envoy_api_v2_Cluster_set_dns_lookup_family(envoy_api_v2_Cluster *msg, int32_t value) {
  357. UPB_FIELD_AT(msg, int32_t, UPB_SIZE(8, 8)) = value;
  358. }
  359. UPB_INLINE struct envoy_api_v2_core_Address** envoy_api_v2_Cluster_mutable_dns_resolvers(envoy_api_v2_Cluster *msg, size_t *len) {
  360. return (struct envoy_api_v2_core_Address**)_upb_array_mutable_accessor(msg, UPB_SIZE(128, 232), len);
  361. }
  362. UPB_INLINE struct envoy_api_v2_core_Address** envoy_api_v2_Cluster_resize_dns_resolvers(envoy_api_v2_Cluster *msg, size_t len, upb_arena *arena) {
  363. return (struct envoy_api_v2_core_Address**)_upb_array_resize_accessor(msg, UPB_SIZE(128, 232), len, UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, arena);
  364. }
  365. UPB_INLINE struct envoy_api_v2_core_Address* envoy_api_v2_Cluster_add_dns_resolvers(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  366. struct envoy_api_v2_core_Address* sub = (struct envoy_api_v2_core_Address*)upb_msg_new(&envoy_api_v2_core_Address_msginit, arena);
  367. bool ok = _upb_array_append_accessor(
  368. msg, UPB_SIZE(128, 232), UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, &sub, arena);
  369. if (!ok) return NULL;
  370. return sub;
  371. }
  372. UPB_INLINE void envoy_api_v2_Cluster_set_outlier_detection(envoy_api_v2_Cluster *msg, struct envoy_api_v2_cluster_OutlierDetection* value) {
  373. UPB_FIELD_AT(msg, struct envoy_api_v2_cluster_OutlierDetection*, UPB_SIZE(80, 136)) = value;
  374. }
  375. UPB_INLINE struct envoy_api_v2_cluster_OutlierDetection* envoy_api_v2_Cluster_mutable_outlier_detection(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  376. struct envoy_api_v2_cluster_OutlierDetection* sub = (struct envoy_api_v2_cluster_OutlierDetection*)envoy_api_v2_Cluster_outlier_detection(msg);
  377. if (sub == NULL) {
  378. sub = (struct envoy_api_v2_cluster_OutlierDetection*)upb_msg_new(&envoy_api_v2_cluster_OutlierDetection_msginit, arena);
  379. if (!sub) return NULL;
  380. envoy_api_v2_Cluster_set_outlier_detection(msg, sub);
  381. }
  382. return sub;
  383. }
  384. UPB_INLINE void envoy_api_v2_Cluster_set_cleanup_interval(envoy_api_v2_Cluster *msg, struct google_protobuf_Duration* value) {
  385. UPB_FIELD_AT(msg, struct google_protobuf_Duration*, UPB_SIZE(84, 144)) = value;
  386. }
  387. UPB_INLINE struct google_protobuf_Duration* envoy_api_v2_Cluster_mutable_cleanup_interval(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  388. struct google_protobuf_Duration* sub = (struct google_protobuf_Duration*)envoy_api_v2_Cluster_cleanup_interval(msg);
  389. if (sub == NULL) {
  390. sub = (struct google_protobuf_Duration*)upb_msg_new(&google_protobuf_Duration_msginit, arena);
  391. if (!sub) return NULL;
  392. envoy_api_v2_Cluster_set_cleanup_interval(msg, sub);
  393. }
  394. return sub;
  395. }
  396. UPB_INLINE void envoy_api_v2_Cluster_set_upstream_bind_config(envoy_api_v2_Cluster *msg, struct envoy_api_v2_core_BindConfig* value) {
  397. UPB_FIELD_AT(msg, struct envoy_api_v2_core_BindConfig*, UPB_SIZE(88, 152)) = value;
  398. }
  399. UPB_INLINE struct envoy_api_v2_core_BindConfig* envoy_api_v2_Cluster_mutable_upstream_bind_config(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  400. struct envoy_api_v2_core_BindConfig* sub = (struct envoy_api_v2_core_BindConfig*)envoy_api_v2_Cluster_upstream_bind_config(msg);
  401. if (sub == NULL) {
  402. sub = (struct envoy_api_v2_core_BindConfig*)upb_msg_new(&envoy_api_v2_core_BindConfig_msginit, arena);
  403. if (!sub) return NULL;
  404. envoy_api_v2_Cluster_set_upstream_bind_config(msg, sub);
  405. }
  406. return sub;
  407. }
  408. UPB_INLINE void envoy_api_v2_Cluster_set_lb_subset_config(envoy_api_v2_Cluster *msg, envoy_api_v2_Cluster_LbSubsetConfig* value) {
  409. UPB_FIELD_AT(msg, envoy_api_v2_Cluster_LbSubsetConfig*, UPB_SIZE(92, 160)) = value;
  410. }
  411. UPB_INLINE struct envoy_api_v2_Cluster_LbSubsetConfig* envoy_api_v2_Cluster_mutable_lb_subset_config(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  412. struct envoy_api_v2_Cluster_LbSubsetConfig* sub = (struct envoy_api_v2_Cluster_LbSubsetConfig*)envoy_api_v2_Cluster_lb_subset_config(msg);
  413. if (sub == NULL) {
  414. sub = (struct envoy_api_v2_Cluster_LbSubsetConfig*)upb_msg_new(&envoy_api_v2_Cluster_LbSubsetConfig_msginit, arena);
  415. if (!sub) return NULL;
  416. envoy_api_v2_Cluster_set_lb_subset_config(msg, sub);
  417. }
  418. return sub;
  419. }
  420. UPB_INLINE void envoy_api_v2_Cluster_set_ring_hash_lb_config(envoy_api_v2_Cluster *msg, envoy_api_v2_Cluster_RingHashLbConfig* value) {
  421. UPB_WRITE_ONEOF(msg, envoy_api_v2_Cluster_RingHashLbConfig*, UPB_SIZE(156, 280), value, UPB_SIZE(160, 288), 23);
  422. }
  423. UPB_INLINE struct envoy_api_v2_Cluster_RingHashLbConfig* envoy_api_v2_Cluster_mutable_ring_hash_lb_config(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  424. struct envoy_api_v2_Cluster_RingHashLbConfig* sub = (struct envoy_api_v2_Cluster_RingHashLbConfig*)envoy_api_v2_Cluster_ring_hash_lb_config(msg);
  425. if (sub == NULL) {
  426. sub = (struct envoy_api_v2_Cluster_RingHashLbConfig*)upb_msg_new(&envoy_api_v2_Cluster_RingHashLbConfig_msginit, arena);
  427. if (!sub) return NULL;
  428. envoy_api_v2_Cluster_set_ring_hash_lb_config(msg, sub);
  429. }
  430. return sub;
  431. }
  432. UPB_INLINE void envoy_api_v2_Cluster_set_transport_socket(envoy_api_v2_Cluster *msg, struct envoy_api_v2_core_TransportSocket* value) {
  433. UPB_FIELD_AT(msg, struct envoy_api_v2_core_TransportSocket*, UPB_SIZE(96, 168)) = value;
  434. }
  435. UPB_INLINE struct envoy_api_v2_core_TransportSocket* envoy_api_v2_Cluster_mutable_transport_socket(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  436. struct envoy_api_v2_core_TransportSocket* sub = (struct envoy_api_v2_core_TransportSocket*)envoy_api_v2_Cluster_transport_socket(msg);
  437. if (sub == NULL) {
  438. sub = (struct envoy_api_v2_core_TransportSocket*)upb_msg_new(&envoy_api_v2_core_TransportSocket_msginit, arena);
  439. if (!sub) return NULL;
  440. envoy_api_v2_Cluster_set_transport_socket(msg, sub);
  441. }
  442. return sub;
  443. }
  444. UPB_INLINE void envoy_api_v2_Cluster_set_metadata(envoy_api_v2_Cluster *msg, struct envoy_api_v2_core_Metadata* value) {
  445. UPB_FIELD_AT(msg, struct envoy_api_v2_core_Metadata*, UPB_SIZE(100, 176)) = value;
  446. }
  447. UPB_INLINE struct envoy_api_v2_core_Metadata* envoy_api_v2_Cluster_mutable_metadata(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  448. struct envoy_api_v2_core_Metadata* sub = (struct envoy_api_v2_core_Metadata*)envoy_api_v2_Cluster_metadata(msg);
  449. if (sub == NULL) {
  450. sub = (struct envoy_api_v2_core_Metadata*)upb_msg_new(&envoy_api_v2_core_Metadata_msginit, arena);
  451. if (!sub) return NULL;
  452. envoy_api_v2_Cluster_set_metadata(msg, sub);
  453. }
  454. return sub;
  455. }
  456. UPB_INLINE void envoy_api_v2_Cluster_set_protocol_selection(envoy_api_v2_Cluster *msg, int32_t value) {
  457. UPB_FIELD_AT(msg, int32_t, UPB_SIZE(16, 16)) = value;
  458. }
  459. UPB_INLINE void envoy_api_v2_Cluster_set_common_lb_config(envoy_api_v2_Cluster *msg, envoy_api_v2_Cluster_CommonLbConfig* value) {
  460. UPB_FIELD_AT(msg, envoy_api_v2_Cluster_CommonLbConfig*, UPB_SIZE(104, 184)) = value;
  461. }
  462. UPB_INLINE struct envoy_api_v2_Cluster_CommonLbConfig* envoy_api_v2_Cluster_mutable_common_lb_config(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  463. struct envoy_api_v2_Cluster_CommonLbConfig* sub = (struct envoy_api_v2_Cluster_CommonLbConfig*)envoy_api_v2_Cluster_common_lb_config(msg);
  464. if (sub == NULL) {
  465. sub = (struct envoy_api_v2_Cluster_CommonLbConfig*)upb_msg_new(&envoy_api_v2_Cluster_CommonLbConfig_msginit, arena);
  466. if (!sub) return NULL;
  467. envoy_api_v2_Cluster_set_common_lb_config(msg, sub);
  468. }
  469. return sub;
  470. }
  471. UPB_INLINE void envoy_api_v2_Cluster_set_alt_stat_name(envoy_api_v2_Cluster *msg, upb_strview value) {
  472. UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(36, 48)) = value;
  473. }
  474. UPB_INLINE void envoy_api_v2_Cluster_set_common_http_protocol_options(envoy_api_v2_Cluster *msg, struct envoy_api_v2_core_HttpProtocolOptions* value) {
  475. UPB_FIELD_AT(msg, struct envoy_api_v2_core_HttpProtocolOptions*, UPB_SIZE(108, 192)) = value;
  476. }
  477. UPB_INLINE struct envoy_api_v2_core_HttpProtocolOptions* envoy_api_v2_Cluster_mutable_common_http_protocol_options(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  478. struct envoy_api_v2_core_HttpProtocolOptions* sub = (struct envoy_api_v2_core_HttpProtocolOptions*)envoy_api_v2_Cluster_common_http_protocol_options(msg);
  479. if (sub == NULL) {
  480. sub = (struct envoy_api_v2_core_HttpProtocolOptions*)upb_msg_new(&envoy_api_v2_core_HttpProtocolOptions_msginit, arena);
  481. if (!sub) return NULL;
  482. envoy_api_v2_Cluster_set_common_http_protocol_options(msg, sub);
  483. }
  484. return sub;
  485. }
  486. UPB_INLINE void envoy_api_v2_Cluster_set_upstream_connection_options(envoy_api_v2_Cluster *msg, envoy_api_v2_UpstreamConnectionOptions* value) {
  487. UPB_FIELD_AT(msg, envoy_api_v2_UpstreamConnectionOptions*, UPB_SIZE(112, 200)) = value;
  488. }
  489. UPB_INLINE struct envoy_api_v2_UpstreamConnectionOptions* envoy_api_v2_Cluster_mutable_upstream_connection_options(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  490. struct envoy_api_v2_UpstreamConnectionOptions* sub = (struct envoy_api_v2_UpstreamConnectionOptions*)envoy_api_v2_Cluster_upstream_connection_options(msg);
  491. if (sub == NULL) {
  492. sub = (struct envoy_api_v2_UpstreamConnectionOptions*)upb_msg_new(&envoy_api_v2_UpstreamConnectionOptions_msginit, arena);
  493. if (!sub) return NULL;
  494. envoy_api_v2_Cluster_set_upstream_connection_options(msg, sub);
  495. }
  496. return sub;
  497. }
  498. UPB_INLINE void envoy_api_v2_Cluster_set_close_connections_on_host_health_failure(envoy_api_v2_Cluster *msg, bool value) {
  499. UPB_FIELD_AT(msg, bool, UPB_SIZE(24, 24)) = value;
  500. }
  501. UPB_INLINE void envoy_api_v2_Cluster_set_drain_connections_on_host_removal(envoy_api_v2_Cluster *msg, bool value) {
  502. UPB_FIELD_AT(msg, bool, UPB_SIZE(25, 25)) = value;
  503. }
  504. UPB_INLINE void envoy_api_v2_Cluster_set_load_assignment(envoy_api_v2_Cluster *msg, struct envoy_api_v2_ClusterLoadAssignment* value) {
  505. UPB_FIELD_AT(msg, struct envoy_api_v2_ClusterLoadAssignment*, UPB_SIZE(116, 208)) = value;
  506. }
  507. UPB_INLINE struct envoy_api_v2_ClusterLoadAssignment* envoy_api_v2_Cluster_mutable_load_assignment(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  508. struct envoy_api_v2_ClusterLoadAssignment* sub = (struct envoy_api_v2_ClusterLoadAssignment*)envoy_api_v2_Cluster_load_assignment(msg);
  509. if (sub == NULL) {
  510. sub = (struct envoy_api_v2_ClusterLoadAssignment*)upb_msg_new(&envoy_api_v2_ClusterLoadAssignment_msginit, arena);
  511. if (!sub) return NULL;
  512. envoy_api_v2_Cluster_set_load_assignment(msg, sub);
  513. }
  514. return sub;
  515. }
  516. UPB_INLINE void envoy_api_v2_Cluster_set_original_dst_lb_config(envoy_api_v2_Cluster *msg, envoy_api_v2_Cluster_OriginalDstLbConfig* value) {
  517. UPB_WRITE_ONEOF(msg, envoy_api_v2_Cluster_OriginalDstLbConfig*, UPB_SIZE(156, 280), value, UPB_SIZE(160, 288), 34);
  518. }
  519. UPB_INLINE struct envoy_api_v2_Cluster_OriginalDstLbConfig* envoy_api_v2_Cluster_mutable_original_dst_lb_config(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  520. struct envoy_api_v2_Cluster_OriginalDstLbConfig* sub = (struct envoy_api_v2_Cluster_OriginalDstLbConfig*)envoy_api_v2_Cluster_original_dst_lb_config(msg);
  521. if (sub == NULL) {
  522. sub = (struct envoy_api_v2_Cluster_OriginalDstLbConfig*)upb_msg_new(&envoy_api_v2_Cluster_OriginalDstLbConfig_msginit, arena);
  523. if (!sub) return NULL;
  524. envoy_api_v2_Cluster_set_original_dst_lb_config(msg, sub);
  525. }
  526. return sub;
  527. }
  528. UPB_INLINE envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry** envoy_api_v2_Cluster_mutable_extension_protocol_options(envoy_api_v2_Cluster *msg, size_t *len) {
  529. return (envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry**)_upb_array_mutable_accessor(msg, UPB_SIZE(132, 240), len);
  530. }
  531. UPB_INLINE envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry** envoy_api_v2_Cluster_resize_extension_protocol_options(envoy_api_v2_Cluster *msg, size_t len, upb_arena *arena) {
  532. return (envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry**)_upb_array_resize_accessor(msg, UPB_SIZE(132, 240), len, UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, arena);
  533. }
  534. UPB_INLINE struct envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry* envoy_api_v2_Cluster_add_extension_protocol_options(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  535. struct envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry* sub = (struct envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry*)upb_msg_new(&envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_msginit, arena);
  536. bool ok = _upb_array_append_accessor(
  537. msg, UPB_SIZE(132, 240), UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, &sub, arena);
  538. if (!ok) return NULL;
  539. return sub;
  540. }
  541. UPB_INLINE envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry** envoy_api_v2_Cluster_mutable_typed_extension_protocol_options(envoy_api_v2_Cluster *msg, size_t *len) {
  542. return (envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry**)_upb_array_mutable_accessor(msg, UPB_SIZE(136, 248), len);
  543. }
  544. UPB_INLINE envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry** envoy_api_v2_Cluster_resize_typed_extension_protocol_options(envoy_api_v2_Cluster *msg, size_t len, upb_arena *arena) {
  545. return (envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry**)_upb_array_resize_accessor(msg, UPB_SIZE(136, 248), len, UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, arena);
  546. }
  547. UPB_INLINE struct envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry* envoy_api_v2_Cluster_add_typed_extension_protocol_options(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  548. struct envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry* sub = (struct envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry*)upb_msg_new(&envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_msginit, arena);
  549. bool ok = _upb_array_append_accessor(
  550. msg, UPB_SIZE(136, 248), UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, &sub, arena);
  551. if (!ok) return NULL;
  552. return sub;
  553. }
  554. UPB_INLINE void envoy_api_v2_Cluster_set_least_request_lb_config(envoy_api_v2_Cluster *msg, envoy_api_v2_Cluster_LeastRequestLbConfig* value) {
  555. UPB_WRITE_ONEOF(msg, envoy_api_v2_Cluster_LeastRequestLbConfig*, UPB_SIZE(156, 280), value, UPB_SIZE(160, 288), 37);
  556. }
  557. UPB_INLINE struct envoy_api_v2_Cluster_LeastRequestLbConfig* envoy_api_v2_Cluster_mutable_least_request_lb_config(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  558. struct envoy_api_v2_Cluster_LeastRequestLbConfig* sub = (struct envoy_api_v2_Cluster_LeastRequestLbConfig*)envoy_api_v2_Cluster_least_request_lb_config(msg);
  559. if (sub == NULL) {
  560. sub = (struct envoy_api_v2_Cluster_LeastRequestLbConfig*)upb_msg_new(&envoy_api_v2_Cluster_LeastRequestLbConfig_msginit, arena);
  561. if (!sub) return NULL;
  562. envoy_api_v2_Cluster_set_least_request_lb_config(msg, sub);
  563. }
  564. return sub;
  565. }
  566. UPB_INLINE void envoy_api_v2_Cluster_set_cluster_type(envoy_api_v2_Cluster *msg, envoy_api_v2_Cluster_CustomClusterType* value) {
  567. UPB_WRITE_ONEOF(msg, envoy_api_v2_Cluster_CustomClusterType*, UPB_SIZE(144, 264), value, UPB_SIZE(152, 272), 38);
  568. }
  569. UPB_INLINE struct envoy_api_v2_Cluster_CustomClusterType* envoy_api_v2_Cluster_mutable_cluster_type(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  570. struct envoy_api_v2_Cluster_CustomClusterType* sub = (struct envoy_api_v2_Cluster_CustomClusterType*)envoy_api_v2_Cluster_cluster_type(msg);
  571. if (sub == NULL) {
  572. sub = (struct envoy_api_v2_Cluster_CustomClusterType*)upb_msg_new(&envoy_api_v2_Cluster_CustomClusterType_msginit, arena);
  573. if (!sub) return NULL;
  574. envoy_api_v2_Cluster_set_cluster_type(msg, sub);
  575. }
  576. return sub;
  577. }
  578. UPB_INLINE void envoy_api_v2_Cluster_set_respect_dns_ttl(envoy_api_v2_Cluster *msg, bool value) {
  579. UPB_FIELD_AT(msg, bool, UPB_SIZE(26, 26)) = value;
  580. }
  581. UPB_INLINE struct envoy_api_v2_cluster_Filter** envoy_api_v2_Cluster_mutable_filters(envoy_api_v2_Cluster *msg, size_t *len) {
  582. return (struct envoy_api_v2_cluster_Filter**)_upb_array_mutable_accessor(msg, UPB_SIZE(140, 256), len);
  583. }
  584. UPB_INLINE struct envoy_api_v2_cluster_Filter** envoy_api_v2_Cluster_resize_filters(envoy_api_v2_Cluster *msg, size_t len, upb_arena *arena) {
  585. return (struct envoy_api_v2_cluster_Filter**)_upb_array_resize_accessor(msg, UPB_SIZE(140, 256), len, UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, arena);
  586. }
  587. UPB_INLINE struct envoy_api_v2_cluster_Filter* envoy_api_v2_Cluster_add_filters(envoy_api_v2_Cluster *msg, upb_arena *arena) {
  588. struct envoy_api_v2_cluster_Filter* sub = (struct envoy_api_v2_cluster_Filter*)upb_msg_new(&envoy_api_v2_cluster_Filter_msginit, arena);
  589. bool ok = _upb_array_append_accessor(
  590. msg, UPB_SIZE(140, 256), UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, &sub, arena);
  591. if (!ok) return NULL;
  592. return sub;
  593. }
  594. /* envoy.api.v2.Cluster.CustomClusterType */
  595. UPB_INLINE envoy_api_v2_Cluster_CustomClusterType *envoy_api_v2_Cluster_CustomClusterType_new(upb_arena *arena) {
  596. return (envoy_api_v2_Cluster_CustomClusterType *)upb_msg_new(&envoy_api_v2_Cluster_CustomClusterType_msginit, arena);
  597. }
  598. UPB_INLINE envoy_api_v2_Cluster_CustomClusterType *envoy_api_v2_Cluster_CustomClusterType_parse(const char *buf, size_t size,
  599. upb_arena *arena) {
  600. envoy_api_v2_Cluster_CustomClusterType *ret = envoy_api_v2_Cluster_CustomClusterType_new(arena);
  601. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_CustomClusterType_msginit, arena)) ? ret : NULL;
  602. }
  603. UPB_INLINE char *envoy_api_v2_Cluster_CustomClusterType_serialize(const envoy_api_v2_Cluster_CustomClusterType *msg, upb_arena *arena, size_t *len) {
  604. return upb_encode(msg, &envoy_api_v2_Cluster_CustomClusterType_msginit, arena, len);
  605. }
  606. UPB_INLINE upb_strview envoy_api_v2_Cluster_CustomClusterType_name(const envoy_api_v2_Cluster_CustomClusterType *msg) { return UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(0, 0)); }
  607. UPB_INLINE const struct google_protobuf_Any* envoy_api_v2_Cluster_CustomClusterType_typed_config(const envoy_api_v2_Cluster_CustomClusterType *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_Any*, UPB_SIZE(8, 16)); }
  608. UPB_INLINE void envoy_api_v2_Cluster_CustomClusterType_set_name(envoy_api_v2_Cluster_CustomClusterType *msg, upb_strview value) {
  609. UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(0, 0)) = value;
  610. }
  611. UPB_INLINE void envoy_api_v2_Cluster_CustomClusterType_set_typed_config(envoy_api_v2_Cluster_CustomClusterType *msg, struct google_protobuf_Any* value) {
  612. UPB_FIELD_AT(msg, struct google_protobuf_Any*, UPB_SIZE(8, 16)) = value;
  613. }
  614. UPB_INLINE struct google_protobuf_Any* envoy_api_v2_Cluster_CustomClusterType_mutable_typed_config(envoy_api_v2_Cluster_CustomClusterType *msg, upb_arena *arena) {
  615. struct google_protobuf_Any* sub = (struct google_protobuf_Any*)envoy_api_v2_Cluster_CustomClusterType_typed_config(msg);
  616. if (sub == NULL) {
  617. sub = (struct google_protobuf_Any*)upb_msg_new(&google_protobuf_Any_msginit, arena);
  618. if (!sub) return NULL;
  619. envoy_api_v2_Cluster_CustomClusterType_set_typed_config(msg, sub);
  620. }
  621. return sub;
  622. }
  623. /* envoy.api.v2.Cluster.EdsClusterConfig */
  624. UPB_INLINE envoy_api_v2_Cluster_EdsClusterConfig *envoy_api_v2_Cluster_EdsClusterConfig_new(upb_arena *arena) {
  625. return (envoy_api_v2_Cluster_EdsClusterConfig *)upb_msg_new(&envoy_api_v2_Cluster_EdsClusterConfig_msginit, arena);
  626. }
  627. UPB_INLINE envoy_api_v2_Cluster_EdsClusterConfig *envoy_api_v2_Cluster_EdsClusterConfig_parse(const char *buf, size_t size,
  628. upb_arena *arena) {
  629. envoy_api_v2_Cluster_EdsClusterConfig *ret = envoy_api_v2_Cluster_EdsClusterConfig_new(arena);
  630. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_EdsClusterConfig_msginit, arena)) ? ret : NULL;
  631. }
  632. UPB_INLINE char *envoy_api_v2_Cluster_EdsClusterConfig_serialize(const envoy_api_v2_Cluster_EdsClusterConfig *msg, upb_arena *arena, size_t *len) {
  633. return upb_encode(msg, &envoy_api_v2_Cluster_EdsClusterConfig_msginit, arena, len);
  634. }
  635. UPB_INLINE const struct envoy_api_v2_core_ConfigSource* envoy_api_v2_Cluster_EdsClusterConfig_eds_config(const envoy_api_v2_Cluster_EdsClusterConfig *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_core_ConfigSource*, UPB_SIZE(8, 16)); }
  636. UPB_INLINE upb_strview envoy_api_v2_Cluster_EdsClusterConfig_service_name(const envoy_api_v2_Cluster_EdsClusterConfig *msg) { return UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(0, 0)); }
  637. UPB_INLINE void envoy_api_v2_Cluster_EdsClusterConfig_set_eds_config(envoy_api_v2_Cluster_EdsClusterConfig *msg, struct envoy_api_v2_core_ConfigSource* value) {
  638. UPB_FIELD_AT(msg, struct envoy_api_v2_core_ConfigSource*, UPB_SIZE(8, 16)) = value;
  639. }
  640. UPB_INLINE struct envoy_api_v2_core_ConfigSource* envoy_api_v2_Cluster_EdsClusterConfig_mutable_eds_config(envoy_api_v2_Cluster_EdsClusterConfig *msg, upb_arena *arena) {
  641. struct envoy_api_v2_core_ConfigSource* sub = (struct envoy_api_v2_core_ConfigSource*)envoy_api_v2_Cluster_EdsClusterConfig_eds_config(msg);
  642. if (sub == NULL) {
  643. sub = (struct envoy_api_v2_core_ConfigSource*)upb_msg_new(&envoy_api_v2_core_ConfigSource_msginit, arena);
  644. if (!sub) return NULL;
  645. envoy_api_v2_Cluster_EdsClusterConfig_set_eds_config(msg, sub);
  646. }
  647. return sub;
  648. }
  649. UPB_INLINE void envoy_api_v2_Cluster_EdsClusterConfig_set_service_name(envoy_api_v2_Cluster_EdsClusterConfig *msg, upb_strview value) {
  650. UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(0, 0)) = value;
  651. }
  652. /* envoy.api.v2.Cluster.ExtensionProtocolOptionsEntry */
  653. UPB_INLINE envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry *envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_new(upb_arena *arena) {
  654. return (envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry *)upb_msg_new(&envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_msginit, arena);
  655. }
  656. UPB_INLINE envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry *envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_parse(const char *buf, size_t size,
  657. upb_arena *arena) {
  658. envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry *ret = envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_new(arena);
  659. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_msginit, arena)) ? ret : NULL;
  660. }
  661. UPB_INLINE char *envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_serialize(const envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry *msg, upb_arena *arena, size_t *len) {
  662. return upb_encode(msg, &envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_msginit, arena, len);
  663. }
  664. UPB_INLINE upb_strview envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_key(const envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry *msg) { return UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(0, 0)); }
  665. UPB_INLINE const struct google_protobuf_Struct* envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_value(const envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_Struct*, UPB_SIZE(8, 16)); }
  666. UPB_INLINE void envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_set_key(envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry *msg, upb_strview value) {
  667. UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(0, 0)) = value;
  668. }
  669. UPB_INLINE void envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_set_value(envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry *msg, struct google_protobuf_Struct* value) {
  670. UPB_FIELD_AT(msg, struct google_protobuf_Struct*, UPB_SIZE(8, 16)) = value;
  671. }
  672. UPB_INLINE struct google_protobuf_Struct* envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_mutable_value(envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry *msg, upb_arena *arena) {
  673. struct google_protobuf_Struct* sub = (struct google_protobuf_Struct*)envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_value(msg);
  674. if (sub == NULL) {
  675. sub = (struct google_protobuf_Struct*)upb_msg_new(&google_protobuf_Struct_msginit, arena);
  676. if (!sub) return NULL;
  677. envoy_api_v2_Cluster_ExtensionProtocolOptionsEntry_set_value(msg, sub);
  678. }
  679. return sub;
  680. }
  681. /* envoy.api.v2.Cluster.TypedExtensionProtocolOptionsEntry */
  682. UPB_INLINE envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry *envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_new(upb_arena *arena) {
  683. return (envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry *)upb_msg_new(&envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_msginit, arena);
  684. }
  685. UPB_INLINE envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry *envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_parse(const char *buf, size_t size,
  686. upb_arena *arena) {
  687. envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry *ret = envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_new(arena);
  688. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_msginit, arena)) ? ret : NULL;
  689. }
  690. UPB_INLINE char *envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_serialize(const envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry *msg, upb_arena *arena, size_t *len) {
  691. return upb_encode(msg, &envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_msginit, arena, len);
  692. }
  693. UPB_INLINE upb_strview envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_key(const envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry *msg) { return UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(0, 0)); }
  694. UPB_INLINE const struct google_protobuf_Any* envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_value(const envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_Any*, UPB_SIZE(8, 16)); }
  695. UPB_INLINE void envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_set_key(envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry *msg, upb_strview value) {
  696. UPB_FIELD_AT(msg, upb_strview, UPB_SIZE(0, 0)) = value;
  697. }
  698. UPB_INLINE void envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_set_value(envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry *msg, struct google_protobuf_Any* value) {
  699. UPB_FIELD_AT(msg, struct google_protobuf_Any*, UPB_SIZE(8, 16)) = value;
  700. }
  701. UPB_INLINE struct google_protobuf_Any* envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_mutable_value(envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry *msg, upb_arena *arena) {
  702. struct google_protobuf_Any* sub = (struct google_protobuf_Any*)envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_value(msg);
  703. if (sub == NULL) {
  704. sub = (struct google_protobuf_Any*)upb_msg_new(&google_protobuf_Any_msginit, arena);
  705. if (!sub) return NULL;
  706. envoy_api_v2_Cluster_TypedExtensionProtocolOptionsEntry_set_value(msg, sub);
  707. }
  708. return sub;
  709. }
  710. /* envoy.api.v2.Cluster.LbSubsetConfig */
  711. UPB_INLINE envoy_api_v2_Cluster_LbSubsetConfig *envoy_api_v2_Cluster_LbSubsetConfig_new(upb_arena *arena) {
  712. return (envoy_api_v2_Cluster_LbSubsetConfig *)upb_msg_new(&envoy_api_v2_Cluster_LbSubsetConfig_msginit, arena);
  713. }
  714. UPB_INLINE envoy_api_v2_Cluster_LbSubsetConfig *envoy_api_v2_Cluster_LbSubsetConfig_parse(const char *buf, size_t size,
  715. upb_arena *arena) {
  716. envoy_api_v2_Cluster_LbSubsetConfig *ret = envoy_api_v2_Cluster_LbSubsetConfig_new(arena);
  717. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_LbSubsetConfig_msginit, arena)) ? ret : NULL;
  718. }
  719. UPB_INLINE char *envoy_api_v2_Cluster_LbSubsetConfig_serialize(const envoy_api_v2_Cluster_LbSubsetConfig *msg, upb_arena *arena, size_t *len) {
  720. return upb_encode(msg, &envoy_api_v2_Cluster_LbSubsetConfig_msginit, arena, len);
  721. }
  722. UPB_INLINE int32_t envoy_api_v2_Cluster_LbSubsetConfig_fallback_policy(const envoy_api_v2_Cluster_LbSubsetConfig *msg) { return UPB_FIELD_AT(msg, int32_t, UPB_SIZE(0, 0)); }
  723. UPB_INLINE const struct google_protobuf_Struct* envoy_api_v2_Cluster_LbSubsetConfig_default_subset(const envoy_api_v2_Cluster_LbSubsetConfig *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_Struct*, UPB_SIZE(12, 16)); }
  724. UPB_INLINE const envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector* const* envoy_api_v2_Cluster_LbSubsetConfig_subset_selectors(const envoy_api_v2_Cluster_LbSubsetConfig *msg, size_t *len) { return (const envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector* const*)_upb_array_accessor(msg, UPB_SIZE(16, 24), len); }
  725. UPB_INLINE bool envoy_api_v2_Cluster_LbSubsetConfig_locality_weight_aware(const envoy_api_v2_Cluster_LbSubsetConfig *msg) { return UPB_FIELD_AT(msg, bool, UPB_SIZE(8, 8)); }
  726. UPB_INLINE bool envoy_api_v2_Cluster_LbSubsetConfig_scale_locality_weight(const envoy_api_v2_Cluster_LbSubsetConfig *msg) { return UPB_FIELD_AT(msg, bool, UPB_SIZE(9, 9)); }
  727. UPB_INLINE bool envoy_api_v2_Cluster_LbSubsetConfig_panic_mode_any(const envoy_api_v2_Cluster_LbSubsetConfig *msg) { return UPB_FIELD_AT(msg, bool, UPB_SIZE(10, 10)); }
  728. UPB_INLINE bool envoy_api_v2_Cluster_LbSubsetConfig_list_as_any(const envoy_api_v2_Cluster_LbSubsetConfig *msg) { return UPB_FIELD_AT(msg, bool, UPB_SIZE(11, 11)); }
  729. UPB_INLINE void envoy_api_v2_Cluster_LbSubsetConfig_set_fallback_policy(envoy_api_v2_Cluster_LbSubsetConfig *msg, int32_t value) {
  730. UPB_FIELD_AT(msg, int32_t, UPB_SIZE(0, 0)) = value;
  731. }
  732. UPB_INLINE void envoy_api_v2_Cluster_LbSubsetConfig_set_default_subset(envoy_api_v2_Cluster_LbSubsetConfig *msg, struct google_protobuf_Struct* value) {
  733. UPB_FIELD_AT(msg, struct google_protobuf_Struct*, UPB_SIZE(12, 16)) = value;
  734. }
  735. UPB_INLINE struct google_protobuf_Struct* envoy_api_v2_Cluster_LbSubsetConfig_mutable_default_subset(envoy_api_v2_Cluster_LbSubsetConfig *msg, upb_arena *arena) {
  736. struct google_protobuf_Struct* sub = (struct google_protobuf_Struct*)envoy_api_v2_Cluster_LbSubsetConfig_default_subset(msg);
  737. if (sub == NULL) {
  738. sub = (struct google_protobuf_Struct*)upb_msg_new(&google_protobuf_Struct_msginit, arena);
  739. if (!sub) return NULL;
  740. envoy_api_v2_Cluster_LbSubsetConfig_set_default_subset(msg, sub);
  741. }
  742. return sub;
  743. }
  744. UPB_INLINE envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector** envoy_api_v2_Cluster_LbSubsetConfig_mutable_subset_selectors(envoy_api_v2_Cluster_LbSubsetConfig *msg, size_t *len) {
  745. return (envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector**)_upb_array_mutable_accessor(msg, UPB_SIZE(16, 24), len);
  746. }
  747. UPB_INLINE envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector** envoy_api_v2_Cluster_LbSubsetConfig_resize_subset_selectors(envoy_api_v2_Cluster_LbSubsetConfig *msg, size_t len, upb_arena *arena) {
  748. return (envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector**)_upb_array_resize_accessor(msg, UPB_SIZE(16, 24), len, UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, arena);
  749. }
  750. UPB_INLINE struct envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector* envoy_api_v2_Cluster_LbSubsetConfig_add_subset_selectors(envoy_api_v2_Cluster_LbSubsetConfig *msg, upb_arena *arena) {
  751. struct envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector* sub = (struct envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector*)upb_msg_new(&envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_msginit, arena);
  752. bool ok = _upb_array_append_accessor(
  753. msg, UPB_SIZE(16, 24), UPB_SIZE(4, 8), UPB_TYPE_MESSAGE, &sub, arena);
  754. if (!ok) return NULL;
  755. return sub;
  756. }
  757. UPB_INLINE void envoy_api_v2_Cluster_LbSubsetConfig_set_locality_weight_aware(envoy_api_v2_Cluster_LbSubsetConfig *msg, bool value) {
  758. UPB_FIELD_AT(msg, bool, UPB_SIZE(8, 8)) = value;
  759. }
  760. UPB_INLINE void envoy_api_v2_Cluster_LbSubsetConfig_set_scale_locality_weight(envoy_api_v2_Cluster_LbSubsetConfig *msg, bool value) {
  761. UPB_FIELD_AT(msg, bool, UPB_SIZE(9, 9)) = value;
  762. }
  763. UPB_INLINE void envoy_api_v2_Cluster_LbSubsetConfig_set_panic_mode_any(envoy_api_v2_Cluster_LbSubsetConfig *msg, bool value) {
  764. UPB_FIELD_AT(msg, bool, UPB_SIZE(10, 10)) = value;
  765. }
  766. UPB_INLINE void envoy_api_v2_Cluster_LbSubsetConfig_set_list_as_any(envoy_api_v2_Cluster_LbSubsetConfig *msg, bool value) {
  767. UPB_FIELD_AT(msg, bool, UPB_SIZE(11, 11)) = value;
  768. }
  769. /* envoy.api.v2.Cluster.LbSubsetConfig.LbSubsetSelector */
  770. UPB_INLINE envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_new(upb_arena *arena) {
  771. return (envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *)upb_msg_new(&envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_msginit, arena);
  772. }
  773. UPB_INLINE envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_parse(const char *buf, size_t size,
  774. upb_arena *arena) {
  775. envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *ret = envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_new(arena);
  776. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_msginit, arena)) ? ret : NULL;
  777. }
  778. UPB_INLINE char *envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_serialize(const envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *msg, upb_arena *arena, size_t *len) {
  779. return upb_encode(msg, &envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_msginit, arena, len);
  780. }
  781. UPB_INLINE upb_strview const* envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_keys(const envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(8, 8), len); }
  782. UPB_INLINE int32_t envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_fallback_policy(const envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *msg) { return UPB_FIELD_AT(msg, int32_t, UPB_SIZE(0, 0)); }
  783. UPB_INLINE upb_strview* envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_mutable_keys(envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *msg, size_t *len) {
  784. return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(8, 8), len);
  785. }
  786. UPB_INLINE upb_strview* envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_resize_keys(envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *msg, size_t len, upb_arena *arena) {
  787. return (upb_strview*)_upb_array_resize_accessor(msg, UPB_SIZE(8, 8), len, UPB_SIZE(8, 16), UPB_TYPE_STRING, arena);
  788. }
  789. UPB_INLINE bool envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_add_keys(envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *msg, upb_strview val, upb_arena *arena) {
  790. return _upb_array_append_accessor(
  791. msg, UPB_SIZE(8, 8), UPB_SIZE(8, 16), UPB_TYPE_STRING, &val, arena);
  792. }
  793. UPB_INLINE void envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector_set_fallback_policy(envoy_api_v2_Cluster_LbSubsetConfig_LbSubsetSelector *msg, int32_t value) {
  794. UPB_FIELD_AT(msg, int32_t, UPB_SIZE(0, 0)) = value;
  795. }
  796. /* envoy.api.v2.Cluster.LeastRequestLbConfig */
  797. UPB_INLINE envoy_api_v2_Cluster_LeastRequestLbConfig *envoy_api_v2_Cluster_LeastRequestLbConfig_new(upb_arena *arena) {
  798. return (envoy_api_v2_Cluster_LeastRequestLbConfig *)upb_msg_new(&envoy_api_v2_Cluster_LeastRequestLbConfig_msginit, arena);
  799. }
  800. UPB_INLINE envoy_api_v2_Cluster_LeastRequestLbConfig *envoy_api_v2_Cluster_LeastRequestLbConfig_parse(const char *buf, size_t size,
  801. upb_arena *arena) {
  802. envoy_api_v2_Cluster_LeastRequestLbConfig *ret = envoy_api_v2_Cluster_LeastRequestLbConfig_new(arena);
  803. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_LeastRequestLbConfig_msginit, arena)) ? ret : NULL;
  804. }
  805. UPB_INLINE char *envoy_api_v2_Cluster_LeastRequestLbConfig_serialize(const envoy_api_v2_Cluster_LeastRequestLbConfig *msg, upb_arena *arena, size_t *len) {
  806. return upb_encode(msg, &envoy_api_v2_Cluster_LeastRequestLbConfig_msginit, arena, len);
  807. }
  808. UPB_INLINE const struct google_protobuf_UInt32Value* envoy_api_v2_Cluster_LeastRequestLbConfig_choice_count(const envoy_api_v2_Cluster_LeastRequestLbConfig *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_UInt32Value*, UPB_SIZE(0, 0)); }
  809. UPB_INLINE void envoy_api_v2_Cluster_LeastRequestLbConfig_set_choice_count(envoy_api_v2_Cluster_LeastRequestLbConfig *msg, struct google_protobuf_UInt32Value* value) {
  810. UPB_FIELD_AT(msg, struct google_protobuf_UInt32Value*, UPB_SIZE(0, 0)) = value;
  811. }
  812. UPB_INLINE struct google_protobuf_UInt32Value* envoy_api_v2_Cluster_LeastRequestLbConfig_mutable_choice_count(envoy_api_v2_Cluster_LeastRequestLbConfig *msg, upb_arena *arena) {
  813. struct google_protobuf_UInt32Value* sub = (struct google_protobuf_UInt32Value*)envoy_api_v2_Cluster_LeastRequestLbConfig_choice_count(msg);
  814. if (sub == NULL) {
  815. sub = (struct google_protobuf_UInt32Value*)upb_msg_new(&google_protobuf_UInt32Value_msginit, arena);
  816. if (!sub) return NULL;
  817. envoy_api_v2_Cluster_LeastRequestLbConfig_set_choice_count(msg, sub);
  818. }
  819. return sub;
  820. }
  821. /* envoy.api.v2.Cluster.RingHashLbConfig */
  822. UPB_INLINE envoy_api_v2_Cluster_RingHashLbConfig *envoy_api_v2_Cluster_RingHashLbConfig_new(upb_arena *arena) {
  823. return (envoy_api_v2_Cluster_RingHashLbConfig *)upb_msg_new(&envoy_api_v2_Cluster_RingHashLbConfig_msginit, arena);
  824. }
  825. UPB_INLINE envoy_api_v2_Cluster_RingHashLbConfig *envoy_api_v2_Cluster_RingHashLbConfig_parse(const char *buf, size_t size,
  826. upb_arena *arena) {
  827. envoy_api_v2_Cluster_RingHashLbConfig *ret = envoy_api_v2_Cluster_RingHashLbConfig_new(arena);
  828. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_RingHashLbConfig_msginit, arena)) ? ret : NULL;
  829. }
  830. UPB_INLINE char *envoy_api_v2_Cluster_RingHashLbConfig_serialize(const envoy_api_v2_Cluster_RingHashLbConfig *msg, upb_arena *arena, size_t *len) {
  831. return upb_encode(msg, &envoy_api_v2_Cluster_RingHashLbConfig_msginit, arena, len);
  832. }
  833. UPB_INLINE const struct google_protobuf_UInt64Value* envoy_api_v2_Cluster_RingHashLbConfig_minimum_ring_size(const envoy_api_v2_Cluster_RingHashLbConfig *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_UInt64Value*, UPB_SIZE(8, 8)); }
  834. UPB_INLINE int32_t envoy_api_v2_Cluster_RingHashLbConfig_hash_function(const envoy_api_v2_Cluster_RingHashLbConfig *msg) { return UPB_FIELD_AT(msg, int32_t, UPB_SIZE(0, 0)); }
  835. UPB_INLINE const struct google_protobuf_UInt64Value* envoy_api_v2_Cluster_RingHashLbConfig_maximum_ring_size(const envoy_api_v2_Cluster_RingHashLbConfig *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_UInt64Value*, UPB_SIZE(12, 16)); }
  836. UPB_INLINE void envoy_api_v2_Cluster_RingHashLbConfig_set_minimum_ring_size(envoy_api_v2_Cluster_RingHashLbConfig *msg, struct google_protobuf_UInt64Value* value) {
  837. UPB_FIELD_AT(msg, struct google_protobuf_UInt64Value*, UPB_SIZE(8, 8)) = value;
  838. }
  839. UPB_INLINE struct google_protobuf_UInt64Value* envoy_api_v2_Cluster_RingHashLbConfig_mutable_minimum_ring_size(envoy_api_v2_Cluster_RingHashLbConfig *msg, upb_arena *arena) {
  840. struct google_protobuf_UInt64Value* sub = (struct google_protobuf_UInt64Value*)envoy_api_v2_Cluster_RingHashLbConfig_minimum_ring_size(msg);
  841. if (sub == NULL) {
  842. sub = (struct google_protobuf_UInt64Value*)upb_msg_new(&google_protobuf_UInt64Value_msginit, arena);
  843. if (!sub) return NULL;
  844. envoy_api_v2_Cluster_RingHashLbConfig_set_minimum_ring_size(msg, sub);
  845. }
  846. return sub;
  847. }
  848. UPB_INLINE void envoy_api_v2_Cluster_RingHashLbConfig_set_hash_function(envoy_api_v2_Cluster_RingHashLbConfig *msg, int32_t value) {
  849. UPB_FIELD_AT(msg, int32_t, UPB_SIZE(0, 0)) = value;
  850. }
  851. UPB_INLINE void envoy_api_v2_Cluster_RingHashLbConfig_set_maximum_ring_size(envoy_api_v2_Cluster_RingHashLbConfig *msg, struct google_protobuf_UInt64Value* value) {
  852. UPB_FIELD_AT(msg, struct google_protobuf_UInt64Value*, UPB_SIZE(12, 16)) = value;
  853. }
  854. UPB_INLINE struct google_protobuf_UInt64Value* envoy_api_v2_Cluster_RingHashLbConfig_mutable_maximum_ring_size(envoy_api_v2_Cluster_RingHashLbConfig *msg, upb_arena *arena) {
  855. struct google_protobuf_UInt64Value* sub = (struct google_protobuf_UInt64Value*)envoy_api_v2_Cluster_RingHashLbConfig_maximum_ring_size(msg);
  856. if (sub == NULL) {
  857. sub = (struct google_protobuf_UInt64Value*)upb_msg_new(&google_protobuf_UInt64Value_msginit, arena);
  858. if (!sub) return NULL;
  859. envoy_api_v2_Cluster_RingHashLbConfig_set_maximum_ring_size(msg, sub);
  860. }
  861. return sub;
  862. }
  863. /* envoy.api.v2.Cluster.OriginalDstLbConfig */
  864. UPB_INLINE envoy_api_v2_Cluster_OriginalDstLbConfig *envoy_api_v2_Cluster_OriginalDstLbConfig_new(upb_arena *arena) {
  865. return (envoy_api_v2_Cluster_OriginalDstLbConfig *)upb_msg_new(&envoy_api_v2_Cluster_OriginalDstLbConfig_msginit, arena);
  866. }
  867. UPB_INLINE envoy_api_v2_Cluster_OriginalDstLbConfig *envoy_api_v2_Cluster_OriginalDstLbConfig_parse(const char *buf, size_t size,
  868. upb_arena *arena) {
  869. envoy_api_v2_Cluster_OriginalDstLbConfig *ret = envoy_api_v2_Cluster_OriginalDstLbConfig_new(arena);
  870. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_OriginalDstLbConfig_msginit, arena)) ? ret : NULL;
  871. }
  872. UPB_INLINE char *envoy_api_v2_Cluster_OriginalDstLbConfig_serialize(const envoy_api_v2_Cluster_OriginalDstLbConfig *msg, upb_arena *arena, size_t *len) {
  873. return upb_encode(msg, &envoy_api_v2_Cluster_OriginalDstLbConfig_msginit, arena, len);
  874. }
  875. UPB_INLINE bool envoy_api_v2_Cluster_OriginalDstLbConfig_use_http_header(const envoy_api_v2_Cluster_OriginalDstLbConfig *msg) { return UPB_FIELD_AT(msg, bool, UPB_SIZE(0, 0)); }
  876. UPB_INLINE void envoy_api_v2_Cluster_OriginalDstLbConfig_set_use_http_header(envoy_api_v2_Cluster_OriginalDstLbConfig *msg, bool value) {
  877. UPB_FIELD_AT(msg, bool, UPB_SIZE(0, 0)) = value;
  878. }
  879. /* envoy.api.v2.Cluster.CommonLbConfig */
  880. UPB_INLINE envoy_api_v2_Cluster_CommonLbConfig *envoy_api_v2_Cluster_CommonLbConfig_new(upb_arena *arena) {
  881. return (envoy_api_v2_Cluster_CommonLbConfig *)upb_msg_new(&envoy_api_v2_Cluster_CommonLbConfig_msginit, arena);
  882. }
  883. UPB_INLINE envoy_api_v2_Cluster_CommonLbConfig *envoy_api_v2_Cluster_CommonLbConfig_parse(const char *buf, size_t size,
  884. upb_arena *arena) {
  885. envoy_api_v2_Cluster_CommonLbConfig *ret = envoy_api_v2_Cluster_CommonLbConfig_new(arena);
  886. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_CommonLbConfig_msginit, arena)) ? ret : NULL;
  887. }
  888. UPB_INLINE char *envoy_api_v2_Cluster_CommonLbConfig_serialize(const envoy_api_v2_Cluster_CommonLbConfig *msg, upb_arena *arena, size_t *len) {
  889. return upb_encode(msg, &envoy_api_v2_Cluster_CommonLbConfig_msginit, arena, len);
  890. }
  891. typedef enum {
  892. envoy_api_v2_Cluster_CommonLbConfig_locality_config_specifier_zone_aware_lb_config = 2,
  893. envoy_api_v2_Cluster_CommonLbConfig_locality_config_specifier_locality_weighted_lb_config = 3,
  894. envoy_api_v2_Cluster_CommonLbConfig_locality_config_specifier_NOT_SET = 0
  895. } envoy_api_v2_Cluster_CommonLbConfig_locality_config_specifier_oneofcases;
  896. UPB_INLINE envoy_api_v2_Cluster_CommonLbConfig_locality_config_specifier_oneofcases envoy_api_v2_Cluster_CommonLbConfig_locality_config_specifier_case(const envoy_api_v2_Cluster_CommonLbConfig* msg) { return (envoy_api_v2_Cluster_CommonLbConfig_locality_config_specifier_oneofcases)UPB_FIELD_AT(msg, int32_t, UPB_SIZE(16, 32)); }
  897. UPB_INLINE const struct envoy_type_Percent* envoy_api_v2_Cluster_CommonLbConfig_healthy_panic_threshold(const envoy_api_v2_Cluster_CommonLbConfig *msg) { return UPB_FIELD_AT(msg, const struct envoy_type_Percent*, UPB_SIZE(4, 8)); }
  898. UPB_INLINE bool envoy_api_v2_Cluster_CommonLbConfig_has_zone_aware_lb_config(const envoy_api_v2_Cluster_CommonLbConfig *msg) { return _upb_has_oneof_field(msg, UPB_SIZE(16, 32), 2); }
  899. UPB_INLINE const envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig* envoy_api_v2_Cluster_CommonLbConfig_zone_aware_lb_config(const envoy_api_v2_Cluster_CommonLbConfig *msg) { return UPB_READ_ONEOF(msg, const envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig*, UPB_SIZE(12, 24), UPB_SIZE(16, 32), 2, NULL); }
  900. UPB_INLINE bool envoy_api_v2_Cluster_CommonLbConfig_has_locality_weighted_lb_config(const envoy_api_v2_Cluster_CommonLbConfig *msg) { return _upb_has_oneof_field(msg, UPB_SIZE(16, 32), 3); }
  901. UPB_INLINE const envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig* envoy_api_v2_Cluster_CommonLbConfig_locality_weighted_lb_config(const envoy_api_v2_Cluster_CommonLbConfig *msg) { return UPB_READ_ONEOF(msg, const envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig*, UPB_SIZE(12, 24), UPB_SIZE(16, 32), 3, NULL); }
  902. UPB_INLINE const struct google_protobuf_Duration* envoy_api_v2_Cluster_CommonLbConfig_update_merge_window(const envoy_api_v2_Cluster_CommonLbConfig *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_Duration*, UPB_SIZE(8, 16)); }
  903. UPB_INLINE bool envoy_api_v2_Cluster_CommonLbConfig_ignore_new_hosts_until_first_hc(const envoy_api_v2_Cluster_CommonLbConfig *msg) { return UPB_FIELD_AT(msg, bool, UPB_SIZE(0, 0)); }
  904. UPB_INLINE bool envoy_api_v2_Cluster_CommonLbConfig_close_connections_on_host_set_change(const envoy_api_v2_Cluster_CommonLbConfig *msg) { return UPB_FIELD_AT(msg, bool, UPB_SIZE(1, 1)); }
  905. UPB_INLINE void envoy_api_v2_Cluster_CommonLbConfig_set_healthy_panic_threshold(envoy_api_v2_Cluster_CommonLbConfig *msg, struct envoy_type_Percent* value) {
  906. UPB_FIELD_AT(msg, struct envoy_type_Percent*, UPB_SIZE(4, 8)) = value;
  907. }
  908. UPB_INLINE struct envoy_type_Percent* envoy_api_v2_Cluster_CommonLbConfig_mutable_healthy_panic_threshold(envoy_api_v2_Cluster_CommonLbConfig *msg, upb_arena *arena) {
  909. struct envoy_type_Percent* sub = (struct envoy_type_Percent*)envoy_api_v2_Cluster_CommonLbConfig_healthy_panic_threshold(msg);
  910. if (sub == NULL) {
  911. sub = (struct envoy_type_Percent*)upb_msg_new(&envoy_type_Percent_msginit, arena);
  912. if (!sub) return NULL;
  913. envoy_api_v2_Cluster_CommonLbConfig_set_healthy_panic_threshold(msg, sub);
  914. }
  915. return sub;
  916. }
  917. UPB_INLINE void envoy_api_v2_Cluster_CommonLbConfig_set_zone_aware_lb_config(envoy_api_v2_Cluster_CommonLbConfig *msg, envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig* value) {
  918. UPB_WRITE_ONEOF(msg, envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig*, UPB_SIZE(12, 24), value, UPB_SIZE(16, 32), 2);
  919. }
  920. UPB_INLINE struct envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig* envoy_api_v2_Cluster_CommonLbConfig_mutable_zone_aware_lb_config(envoy_api_v2_Cluster_CommonLbConfig *msg, upb_arena *arena) {
  921. struct envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig* sub = (struct envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig*)envoy_api_v2_Cluster_CommonLbConfig_zone_aware_lb_config(msg);
  922. if (sub == NULL) {
  923. sub = (struct envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig*)upb_msg_new(&envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit, arena);
  924. if (!sub) return NULL;
  925. envoy_api_v2_Cluster_CommonLbConfig_set_zone_aware_lb_config(msg, sub);
  926. }
  927. return sub;
  928. }
  929. UPB_INLINE void envoy_api_v2_Cluster_CommonLbConfig_set_locality_weighted_lb_config(envoy_api_v2_Cluster_CommonLbConfig *msg, envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig* value) {
  930. UPB_WRITE_ONEOF(msg, envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig*, UPB_SIZE(12, 24), value, UPB_SIZE(16, 32), 3);
  931. }
  932. UPB_INLINE struct envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig* envoy_api_v2_Cluster_CommonLbConfig_mutable_locality_weighted_lb_config(envoy_api_v2_Cluster_CommonLbConfig *msg, upb_arena *arena) {
  933. struct envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig* sub = (struct envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig*)envoy_api_v2_Cluster_CommonLbConfig_locality_weighted_lb_config(msg);
  934. if (sub == NULL) {
  935. sub = (struct envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig*)upb_msg_new(&envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit, arena);
  936. if (!sub) return NULL;
  937. envoy_api_v2_Cluster_CommonLbConfig_set_locality_weighted_lb_config(msg, sub);
  938. }
  939. return sub;
  940. }
  941. UPB_INLINE void envoy_api_v2_Cluster_CommonLbConfig_set_update_merge_window(envoy_api_v2_Cluster_CommonLbConfig *msg, struct google_protobuf_Duration* value) {
  942. UPB_FIELD_AT(msg, struct google_protobuf_Duration*, UPB_SIZE(8, 16)) = value;
  943. }
  944. UPB_INLINE struct google_protobuf_Duration* envoy_api_v2_Cluster_CommonLbConfig_mutable_update_merge_window(envoy_api_v2_Cluster_CommonLbConfig *msg, upb_arena *arena) {
  945. struct google_protobuf_Duration* sub = (struct google_protobuf_Duration*)envoy_api_v2_Cluster_CommonLbConfig_update_merge_window(msg);
  946. if (sub == NULL) {
  947. sub = (struct google_protobuf_Duration*)upb_msg_new(&google_protobuf_Duration_msginit, arena);
  948. if (!sub) return NULL;
  949. envoy_api_v2_Cluster_CommonLbConfig_set_update_merge_window(msg, sub);
  950. }
  951. return sub;
  952. }
  953. UPB_INLINE void envoy_api_v2_Cluster_CommonLbConfig_set_ignore_new_hosts_until_first_hc(envoy_api_v2_Cluster_CommonLbConfig *msg, bool value) {
  954. UPB_FIELD_AT(msg, bool, UPB_SIZE(0, 0)) = value;
  955. }
  956. UPB_INLINE void envoy_api_v2_Cluster_CommonLbConfig_set_close_connections_on_host_set_change(envoy_api_v2_Cluster_CommonLbConfig *msg, bool value) {
  957. UPB_FIELD_AT(msg, bool, UPB_SIZE(1, 1)) = value;
  958. }
  959. /* envoy.api.v2.Cluster.CommonLbConfig.ZoneAwareLbConfig */
  960. UPB_INLINE envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_new(upb_arena *arena) {
  961. return (envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *)upb_msg_new(&envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit, arena);
  962. }
  963. UPB_INLINE envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_parse(const char *buf, size_t size,
  964. upb_arena *arena) {
  965. envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *ret = envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_new(arena);
  966. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit, arena)) ? ret : NULL;
  967. }
  968. UPB_INLINE char *envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_serialize(const envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *msg, upb_arena *arena, size_t *len) {
  969. return upb_encode(msg, &envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_msginit, arena, len);
  970. }
  971. UPB_INLINE const struct envoy_type_Percent* envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_routing_enabled(const envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *msg) { return UPB_FIELD_AT(msg, const struct envoy_type_Percent*, UPB_SIZE(0, 0)); }
  972. UPB_INLINE const struct google_protobuf_UInt64Value* envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_min_cluster_size(const envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *msg) { return UPB_FIELD_AT(msg, const struct google_protobuf_UInt64Value*, UPB_SIZE(4, 8)); }
  973. UPB_INLINE void envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_set_routing_enabled(envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *msg, struct envoy_type_Percent* value) {
  974. UPB_FIELD_AT(msg, struct envoy_type_Percent*, UPB_SIZE(0, 0)) = value;
  975. }
  976. UPB_INLINE struct envoy_type_Percent* envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_mutable_routing_enabled(envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *msg, upb_arena *arena) {
  977. struct envoy_type_Percent* sub = (struct envoy_type_Percent*)envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_routing_enabled(msg);
  978. if (sub == NULL) {
  979. sub = (struct envoy_type_Percent*)upb_msg_new(&envoy_type_Percent_msginit, arena);
  980. if (!sub) return NULL;
  981. envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_set_routing_enabled(msg, sub);
  982. }
  983. return sub;
  984. }
  985. UPB_INLINE void envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_set_min_cluster_size(envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *msg, struct google_protobuf_UInt64Value* value) {
  986. UPB_FIELD_AT(msg, struct google_protobuf_UInt64Value*, UPB_SIZE(4, 8)) = value;
  987. }
  988. UPB_INLINE struct google_protobuf_UInt64Value* envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_mutable_min_cluster_size(envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig *msg, upb_arena *arena) {
  989. struct google_protobuf_UInt64Value* sub = (struct google_protobuf_UInt64Value*)envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_min_cluster_size(msg);
  990. if (sub == NULL) {
  991. sub = (struct google_protobuf_UInt64Value*)upb_msg_new(&google_protobuf_UInt64Value_msginit, arena);
  992. if (!sub) return NULL;
  993. envoy_api_v2_Cluster_CommonLbConfig_ZoneAwareLbConfig_set_min_cluster_size(msg, sub);
  994. }
  995. return sub;
  996. }
  997. /* envoy.api.v2.Cluster.CommonLbConfig.LocalityWeightedLbConfig */
  998. UPB_INLINE envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig *envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig_new(upb_arena *arena) {
  999. return (envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig *)upb_msg_new(&envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit, arena);
  1000. }
  1001. UPB_INLINE envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig *envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig_parse(const char *buf, size_t size,
  1002. upb_arena *arena) {
  1003. envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig *ret = envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig_new(arena);
  1004. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit, arena)) ? ret : NULL;
  1005. }
  1006. UPB_INLINE char *envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig_serialize(const envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig *msg, upb_arena *arena, size_t *len) {
  1007. return upb_encode(msg, &envoy_api_v2_Cluster_CommonLbConfig_LocalityWeightedLbConfig_msginit, arena, len);
  1008. }
  1009. /* envoy.api.v2.UpstreamBindConfig */
  1010. UPB_INLINE envoy_api_v2_UpstreamBindConfig *envoy_api_v2_UpstreamBindConfig_new(upb_arena *arena) {
  1011. return (envoy_api_v2_UpstreamBindConfig *)upb_msg_new(&envoy_api_v2_UpstreamBindConfig_msginit, arena);
  1012. }
  1013. UPB_INLINE envoy_api_v2_UpstreamBindConfig *envoy_api_v2_UpstreamBindConfig_parse(const char *buf, size_t size,
  1014. upb_arena *arena) {
  1015. envoy_api_v2_UpstreamBindConfig *ret = envoy_api_v2_UpstreamBindConfig_new(arena);
  1016. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_UpstreamBindConfig_msginit, arena)) ? ret : NULL;
  1017. }
  1018. UPB_INLINE char *envoy_api_v2_UpstreamBindConfig_serialize(const envoy_api_v2_UpstreamBindConfig *msg, upb_arena *arena, size_t *len) {
  1019. return upb_encode(msg, &envoy_api_v2_UpstreamBindConfig_msginit, arena, len);
  1020. }
  1021. UPB_INLINE const struct envoy_api_v2_core_Address* envoy_api_v2_UpstreamBindConfig_source_address(const envoy_api_v2_UpstreamBindConfig *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_core_Address*, UPB_SIZE(0, 0)); }
  1022. UPB_INLINE void envoy_api_v2_UpstreamBindConfig_set_source_address(envoy_api_v2_UpstreamBindConfig *msg, struct envoy_api_v2_core_Address* value) {
  1023. UPB_FIELD_AT(msg, struct envoy_api_v2_core_Address*, UPB_SIZE(0, 0)) = value;
  1024. }
  1025. UPB_INLINE struct envoy_api_v2_core_Address* envoy_api_v2_UpstreamBindConfig_mutable_source_address(envoy_api_v2_UpstreamBindConfig *msg, upb_arena *arena) {
  1026. struct envoy_api_v2_core_Address* sub = (struct envoy_api_v2_core_Address*)envoy_api_v2_UpstreamBindConfig_source_address(msg);
  1027. if (sub == NULL) {
  1028. sub = (struct envoy_api_v2_core_Address*)upb_msg_new(&envoy_api_v2_core_Address_msginit, arena);
  1029. if (!sub) return NULL;
  1030. envoy_api_v2_UpstreamBindConfig_set_source_address(msg, sub);
  1031. }
  1032. return sub;
  1033. }
  1034. /* envoy.api.v2.UpstreamConnectionOptions */
  1035. UPB_INLINE envoy_api_v2_UpstreamConnectionOptions *envoy_api_v2_UpstreamConnectionOptions_new(upb_arena *arena) {
  1036. return (envoy_api_v2_UpstreamConnectionOptions *)upb_msg_new(&envoy_api_v2_UpstreamConnectionOptions_msginit, arena);
  1037. }
  1038. UPB_INLINE envoy_api_v2_UpstreamConnectionOptions *envoy_api_v2_UpstreamConnectionOptions_parse(const char *buf, size_t size,
  1039. upb_arena *arena) {
  1040. envoy_api_v2_UpstreamConnectionOptions *ret = envoy_api_v2_UpstreamConnectionOptions_new(arena);
  1041. return (ret && upb_decode(buf, size, ret, &envoy_api_v2_UpstreamConnectionOptions_msginit, arena)) ? ret : NULL;
  1042. }
  1043. UPB_INLINE char *envoy_api_v2_UpstreamConnectionOptions_serialize(const envoy_api_v2_UpstreamConnectionOptions *msg, upb_arena *arena, size_t *len) {
  1044. return upb_encode(msg, &envoy_api_v2_UpstreamConnectionOptions_msginit, arena, len);
  1045. }
  1046. UPB_INLINE const struct envoy_api_v2_core_TcpKeepalive* envoy_api_v2_UpstreamConnectionOptions_tcp_keepalive(const envoy_api_v2_UpstreamConnectionOptions *msg) { return UPB_FIELD_AT(msg, const struct envoy_api_v2_core_TcpKeepalive*, UPB_SIZE(0, 0)); }
  1047. UPB_INLINE void envoy_api_v2_UpstreamConnectionOptions_set_tcp_keepalive(envoy_api_v2_UpstreamConnectionOptions *msg, struct envoy_api_v2_core_TcpKeepalive* value) {
  1048. UPB_FIELD_AT(msg, struct envoy_api_v2_core_TcpKeepalive*, UPB_SIZE(0, 0)) = value;
  1049. }
  1050. UPB_INLINE struct envoy_api_v2_core_TcpKeepalive* envoy_api_v2_UpstreamConnectionOptions_mutable_tcp_keepalive(envoy_api_v2_UpstreamConnectionOptions *msg, upb_arena *arena) {
  1051. struct envoy_api_v2_core_TcpKeepalive* sub = (struct envoy_api_v2_core_TcpKeepalive*)envoy_api_v2_UpstreamConnectionOptions_tcp_keepalive(msg);
  1052. if (sub == NULL) {
  1053. sub = (struct envoy_api_v2_core_TcpKeepalive*)upb_msg_new(&envoy_api_v2_core_TcpKeepalive_msginit, arena);
  1054. if (!sub) return NULL;
  1055. envoy_api_v2_UpstreamConnectionOptions_set_tcp_keepalive(msg, sub);
  1056. }
  1057. return sub;
  1058. }
  1059. #ifdef __cplusplus
  1060. } /* extern "C" */
  1061. #endif
  1062. #include "upb/port_undef.inc"
  1063. #endif /* ENVOY_API_V2_CDS_PROTO_UPB_H_ */