All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints Maven / Gradle / Ivy

// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: envoy/config/endpoint/v3/endpoint_components.proto

package io.envoyproxy.envoy.config.endpoint.v3;

/**
 * 
 * A group of endpoints belonging to a Locality.
 * One can have multiple LocalityLbEndpoints for a locality, but only if
 * they have different priorities.
 * [#next-free-field: 9]
 * 
* * Protobuf type {@code envoy.config.endpoint.v3.LocalityLbEndpoints} */ public final class LocalityLbEndpoints extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:envoy.config.endpoint.v3.LocalityLbEndpoints) LocalityLbEndpointsOrBuilder { private static final long serialVersionUID = 0L; // Use LocalityLbEndpoints.newBuilder() to construct. private LocalityLbEndpoints(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private LocalityLbEndpoints() { lbEndpoints_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new LocalityLbEndpoints(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private LocalityLbEndpoints( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { io.envoyproxy.envoy.config.core.v3.Locality.Builder subBuilder = null; if (locality_ != null) { subBuilder = locality_.toBuilder(); } locality_ = input.readMessage(io.envoyproxy.envoy.config.core.v3.Locality.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(locality_); locality_ = subBuilder.buildPartial(); } break; } case 18: { if (!((mutable_bitField0_ & 0x00000001) != 0)) { lbEndpoints_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } lbEndpoints_.add( input.readMessage(io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.parser(), extensionRegistry)); break; } case 26: { com.google.protobuf.UInt32Value.Builder subBuilder = null; if (loadBalancingWeight_ != null) { subBuilder = loadBalancingWeight_.toBuilder(); } loadBalancingWeight_ = input.readMessage(com.google.protobuf.UInt32Value.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(loadBalancingWeight_); loadBalancingWeight_ = subBuilder.buildPartial(); } break; } case 40: { priority_ = input.readUInt32(); break; } case 50: { com.google.protobuf.UInt32Value.Builder subBuilder = null; if (proximity_ != null) { subBuilder = proximity_.toBuilder(); } proximity_ = input.readMessage(com.google.protobuf.UInt32Value.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(proximity_); proximity_ = subBuilder.buildPartial(); } break; } case 58: { io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.Builder subBuilder = null; if (lbConfigCase_ == 7) { subBuilder = ((io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) lbConfig_).toBuilder(); } lbConfig_ = input.readMessage(io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom((io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) lbConfig_); lbConfig_ = subBuilder.buildPartial(); } lbConfigCase_ = 7; break; } case 66: { io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.Builder subBuilder = null; if (lbConfigCase_ == 8) { subBuilder = ((io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig) lbConfig_).toBuilder(); } lbConfig_ = input.readMessage(io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom((io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig) lbConfig_); lbConfig_ = subBuilder.buildPartial(); } lbConfigCase_ = 8; break; } default: { if (!parseUnknownField( input, unknownFields, extensionRegistry, tag)) { done = true; } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { if (((mutable_bitField0_ & 0x00000001) != 0)) { lbEndpoints_ = java.util.Collections.unmodifiableList(lbEndpoints_); } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.envoyproxy.envoy.config.endpoint.v3.EndpointComponentsProto.internal_static_envoy_config_endpoint_v3_LocalityLbEndpoints_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.envoyproxy.envoy.config.endpoint.v3.EndpointComponentsProto.internal_static_envoy_config_endpoint_v3_LocalityLbEndpoints_fieldAccessorTable .ensureFieldAccessorsInitialized( io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.class, io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.Builder.class); } public interface LbEndpointListOrBuilder extends // @@protoc_insertion_point(interface_extends:envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) com.google.protobuf.MessageOrBuilder { /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ java.util.List getLbEndpointsList(); /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint getLbEndpoints(int index); /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ int getLbEndpointsCount(); /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ java.util.List getLbEndpointsOrBuilderList(); /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder getLbEndpointsOrBuilder( int index); } /** *
   * [#not-implemented-hide:]
   * A list of endpoints of a specific locality.
   * 
* * Protobuf type {@code envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList} */ public static final class LbEndpointList extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) LbEndpointListOrBuilder { private static final long serialVersionUID = 0L; // Use LbEndpointList.newBuilder() to construct. private LbEndpointList(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private LbEndpointList() { lbEndpoints_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new LbEndpointList(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private LbEndpointList( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { if (!((mutable_bitField0_ & 0x00000001) != 0)) { lbEndpoints_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } lbEndpoints_.add( input.readMessage(io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.parser(), extensionRegistry)); break; } default: { if (!parseUnknownField( input, unknownFields, extensionRegistry, tag)) { done = true; } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { if (((mutable_bitField0_ & 0x00000001) != 0)) { lbEndpoints_ = java.util.Collections.unmodifiableList(lbEndpoints_); } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.envoyproxy.envoy.config.endpoint.v3.EndpointComponentsProto.internal_static_envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.envoyproxy.envoy.config.endpoint.v3.EndpointComponentsProto.internal_static_envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_fieldAccessorTable .ensureFieldAccessorsInitialized( io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.class, io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.Builder.class); } public static final int LB_ENDPOINTS_FIELD_NUMBER = 1; private java.util.List lbEndpoints_; /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ @java.lang.Override public java.util.List getLbEndpointsList() { return lbEndpoints_; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ @java.lang.Override public java.util.List getLbEndpointsOrBuilderList() { return lbEndpoints_; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ @java.lang.Override public int getLbEndpointsCount() { return lbEndpoints_.size(); } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint getLbEndpoints(int index) { return lbEndpoints_.get(index); } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder getLbEndpointsOrBuilder( int index) { return lbEndpoints_.get(index); } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { for (int i = 0; i < lbEndpoints_.size(); i++) { output.writeMessage(1, lbEndpoints_.get(i)); } unknownFields.writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; for (int i = 0; i < lbEndpoints_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(1, lbEndpoints_.get(i)); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList)) { return super.equals(obj); } io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList other = (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) obj; if (!getLbEndpointsList() .equals(other.getLbEndpointsList())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); if (getLbEndpointsCount() > 0) { hash = (37 * hash) + LB_ENDPOINTS_FIELD_NUMBER; hash = (53 * hash) + getLbEndpointsList().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** *
     * [#not-implemented-hide:]
     * A list of endpoints of a specific locality.
     * 
* * Protobuf type {@code envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointListOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.envoyproxy.envoy.config.endpoint.v3.EndpointComponentsProto.internal_static_envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.envoyproxy.envoy.config.endpoint.v3.EndpointComponentsProto.internal_static_envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_fieldAccessorTable .ensureFieldAccessorsInitialized( io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.class, io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.Builder.class); } // Construct using io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { getLbEndpointsFieldBuilder(); } } @java.lang.Override public Builder clear() { super.clear(); if (lbEndpointsBuilder_ == null) { lbEndpoints_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); } else { lbEndpointsBuilder_.clear(); } return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return io.envoyproxy.envoy.config.endpoint.v3.EndpointComponentsProto.internal_static_envoy_config_endpoint_v3_LocalityLbEndpoints_LbEndpointList_descriptor; } @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList getDefaultInstanceForType() { return io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.getDefaultInstance(); } @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList build() { io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList buildPartial() { io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList result = new io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList(this); int from_bitField0_ = bitField0_; if (lbEndpointsBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0)) { lbEndpoints_ = java.util.Collections.unmodifiableList(lbEndpoints_); bitField0_ = (bitField0_ & ~0x00000001); } result.lbEndpoints_ = lbEndpoints_; } else { result.lbEndpoints_ = lbEndpointsBuilder_.build(); } onBuilt(); return result; } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) { return mergeFrom((io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList other) { if (other == io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.getDefaultInstance()) return this; if (lbEndpointsBuilder_ == null) { if (!other.lbEndpoints_.isEmpty()) { if (lbEndpoints_.isEmpty()) { lbEndpoints_ = other.lbEndpoints_; bitField0_ = (bitField0_ & ~0x00000001); } else { ensureLbEndpointsIsMutable(); lbEndpoints_.addAll(other.lbEndpoints_); } onChanged(); } } else { if (!other.lbEndpoints_.isEmpty()) { if (lbEndpointsBuilder_.isEmpty()) { lbEndpointsBuilder_.dispose(); lbEndpointsBuilder_ = null; lbEndpoints_ = other.lbEndpoints_; bitField0_ = (bitField0_ & ~0x00000001); lbEndpointsBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getLbEndpointsFieldBuilder() : null; } else { lbEndpointsBuilder_.addAllMessages(other.lbEndpoints_); } } } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int bitField0_; private java.util.List lbEndpoints_ = java.util.Collections.emptyList(); private void ensureLbEndpointsIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { lbEndpoints_ = new java.util.ArrayList(lbEndpoints_); bitField0_ |= 0x00000001; } } private com.google.protobuf.RepeatedFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder, io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder> lbEndpointsBuilder_; /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public java.util.List getLbEndpointsList() { if (lbEndpointsBuilder_ == null) { return java.util.Collections.unmodifiableList(lbEndpoints_); } else { return lbEndpointsBuilder_.getMessageList(); } } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public int getLbEndpointsCount() { if (lbEndpointsBuilder_ == null) { return lbEndpoints_.size(); } else { return lbEndpointsBuilder_.getCount(); } } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint getLbEndpoints(int index) { if (lbEndpointsBuilder_ == null) { return lbEndpoints_.get(index); } else { return lbEndpointsBuilder_.getMessage(index); } } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public Builder setLbEndpoints( int index, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint value) { if (lbEndpointsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureLbEndpointsIsMutable(); lbEndpoints_.set(index, value); onChanged(); } else { lbEndpointsBuilder_.setMessage(index, value); } return this; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public Builder setLbEndpoints( int index, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder builderForValue) { if (lbEndpointsBuilder_ == null) { ensureLbEndpointsIsMutable(); lbEndpoints_.set(index, builderForValue.build()); onChanged(); } else { lbEndpointsBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public Builder addLbEndpoints(io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint value) { if (lbEndpointsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureLbEndpointsIsMutable(); lbEndpoints_.add(value); onChanged(); } else { lbEndpointsBuilder_.addMessage(value); } return this; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public Builder addLbEndpoints( int index, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint value) { if (lbEndpointsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureLbEndpointsIsMutable(); lbEndpoints_.add(index, value); onChanged(); } else { lbEndpointsBuilder_.addMessage(index, value); } return this; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public Builder addLbEndpoints( io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder builderForValue) { if (lbEndpointsBuilder_ == null) { ensureLbEndpointsIsMutable(); lbEndpoints_.add(builderForValue.build()); onChanged(); } else { lbEndpointsBuilder_.addMessage(builderForValue.build()); } return this; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public Builder addLbEndpoints( int index, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder builderForValue) { if (lbEndpointsBuilder_ == null) { ensureLbEndpointsIsMutable(); lbEndpoints_.add(index, builderForValue.build()); onChanged(); } else { lbEndpointsBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public Builder addAllLbEndpoints( java.lang.Iterable values) { if (lbEndpointsBuilder_ == null) { ensureLbEndpointsIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, lbEndpoints_); onChanged(); } else { lbEndpointsBuilder_.addAllMessages(values); } return this; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public Builder clearLbEndpoints() { if (lbEndpointsBuilder_ == null) { lbEndpoints_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); } else { lbEndpointsBuilder_.clear(); } return this; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public Builder removeLbEndpoints(int index) { if (lbEndpointsBuilder_ == null) { ensureLbEndpointsIsMutable(); lbEndpoints_.remove(index); onChanged(); } else { lbEndpointsBuilder_.remove(index); } return this; } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder getLbEndpointsBuilder( int index) { return getLbEndpointsFieldBuilder().getBuilder(index); } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder getLbEndpointsOrBuilder( int index) { if (lbEndpointsBuilder_ == null) { return lbEndpoints_.get(index); } else { return lbEndpointsBuilder_.getMessageOrBuilder(index); } } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public java.util.List getLbEndpointsOrBuilderList() { if (lbEndpointsBuilder_ != null) { return lbEndpointsBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(lbEndpoints_); } } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder addLbEndpointsBuilder() { return getLbEndpointsFieldBuilder().addBuilder( io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.getDefaultInstance()); } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder addLbEndpointsBuilder( int index) { return getLbEndpointsFieldBuilder().addBuilder( index, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.getDefaultInstance()); } /** * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 1; */ public java.util.List getLbEndpointsBuilderList() { return getLbEndpointsFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder, io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder> getLbEndpointsFieldBuilder() { if (lbEndpointsBuilder_ == null) { lbEndpointsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder, io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder>( lbEndpoints_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); lbEndpoints_ = null; } return lbEndpointsBuilder_; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) } // @@protoc_insertion_point(class_scope:envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) private static final io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList(); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public LbEndpointList parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new LbEndpointList(input, extensionRegistry); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } private int lbConfigCase_ = 0; private java.lang.Object lbConfig_; public enum LbConfigCase implements com.google.protobuf.Internal.EnumLite, com.google.protobuf.AbstractMessage.InternalOneOfEnum { LOAD_BALANCER_ENDPOINTS(7), LEDS_CLUSTER_LOCALITY_CONFIG(8), LBCONFIG_NOT_SET(0); private final int value; private LbConfigCase(int value) { this.value = value; } /** * @param value The number of the enum to look for. * @return The enum associated with the given number. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static LbConfigCase valueOf(int value) { return forNumber(value); } public static LbConfigCase forNumber(int value) { switch (value) { case 7: return LOAD_BALANCER_ENDPOINTS; case 8: return LEDS_CLUSTER_LOCALITY_CONFIG; case 0: return LBCONFIG_NOT_SET; default: return null; } } public int getNumber() { return this.value; } }; public LbConfigCase getLbConfigCase() { return LbConfigCase.forNumber( lbConfigCase_); } public static final int LOCALITY_FIELD_NUMBER = 1; private io.envoyproxy.envoy.config.core.v3.Locality locality_; /** *
   * Identifies location of where the upstream hosts run.
   * 
* * .envoy.config.core.v3.Locality locality = 1; * @return Whether the locality field is set. */ @java.lang.Override public boolean hasLocality() { return locality_ != null; } /** *
   * Identifies location of where the upstream hosts run.
   * 
* * .envoy.config.core.v3.Locality locality = 1; * @return The locality. */ @java.lang.Override public io.envoyproxy.envoy.config.core.v3.Locality getLocality() { return locality_ == null ? io.envoyproxy.envoy.config.core.v3.Locality.getDefaultInstance() : locality_; } /** *
   * Identifies location of where the upstream hosts run.
   * 
* * .envoy.config.core.v3.Locality locality = 1; */ @java.lang.Override public io.envoyproxy.envoy.config.core.v3.LocalityOrBuilder getLocalityOrBuilder() { return getLocality(); } public static final int LB_ENDPOINTS_FIELD_NUMBER = 2; private java.util.List lbEndpoints_; /** *
   * The group of endpoints belonging to the locality specified.
   * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
   * deprecated and replaced by ``load_balancer_endpoints``.]
   * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ @java.lang.Override public java.util.List getLbEndpointsList() { return lbEndpoints_; } /** *
   * The group of endpoints belonging to the locality specified.
   * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
   * deprecated and replaced by ``load_balancer_endpoints``.]
   * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ @java.lang.Override public java.util.List getLbEndpointsOrBuilderList() { return lbEndpoints_; } /** *
   * The group of endpoints belonging to the locality specified.
   * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
   * deprecated and replaced by ``load_balancer_endpoints``.]
   * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ @java.lang.Override public int getLbEndpointsCount() { return lbEndpoints_.size(); } /** *
   * The group of endpoints belonging to the locality specified.
   * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
   * deprecated and replaced by ``load_balancer_endpoints``.]
   * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint getLbEndpoints(int index) { return lbEndpoints_.get(index); } /** *
   * The group of endpoints belonging to the locality specified.
   * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
   * deprecated and replaced by ``load_balancer_endpoints``.]
   * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder getLbEndpointsOrBuilder( int index) { return lbEndpoints_.get(index); } public static final int LOAD_BALANCER_ENDPOINTS_FIELD_NUMBER = 7; /** *
   * The group of endpoints belonging to the locality.
   * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
   * needs to be deprecated.]
   * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; * @return Whether the loadBalancerEndpoints field is set. */ @java.lang.Override public boolean hasLoadBalancerEndpoints() { return lbConfigCase_ == 7; } /** *
   * The group of endpoints belonging to the locality.
   * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
   * needs to be deprecated.]
   * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; * @return The loadBalancerEndpoints. */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList getLoadBalancerEndpoints() { if (lbConfigCase_ == 7) { return (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) lbConfig_; } return io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.getDefaultInstance(); } /** *
   * The group of endpoints belonging to the locality.
   * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
   * needs to be deprecated.]
   * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointListOrBuilder getLoadBalancerEndpointsOrBuilder() { if (lbConfigCase_ == 7) { return (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) lbConfig_; } return io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.getDefaultInstance(); } public static final int LEDS_CLUSTER_LOCALITY_CONFIG_FIELD_NUMBER = 8; /** *
   * LEDS Configuration for the current locality.
   * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; * @return Whether the ledsClusterLocalityConfig field is set. */ @java.lang.Override public boolean hasLedsClusterLocalityConfig() { return lbConfigCase_ == 8; } /** *
   * LEDS Configuration for the current locality.
   * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; * @return The ledsClusterLocalityConfig. */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig getLedsClusterLocalityConfig() { if (lbConfigCase_ == 8) { return (io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig) lbConfig_; } return io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.getDefaultInstance(); } /** *
   * LEDS Configuration for the current locality.
   * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfigOrBuilder getLedsClusterLocalityConfigOrBuilder() { if (lbConfigCase_ == 8) { return (io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig) lbConfig_; } return io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.getDefaultInstance(); } public static final int LOAD_BALANCING_WEIGHT_FIELD_NUMBER = 3; private com.google.protobuf.UInt32Value loadBalancingWeight_; /** *
   * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
   * balancing weight for a locality is divided by the sum of the weights of all
   * localities  at the same priority level to produce the effective percentage
   * of traffic for the locality. The sum of the weights of all localities at
   * the same priority level must not exceed uint32_t maximal value (4294967295).
   * Locality weights are only considered when :ref:`locality weighted load
   * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
   * configured. These weights are ignored otherwise. If no weights are
   * specified when locality weighted load balancing is enabled, the locality is
   * assigned no load.
   * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } * @return Whether the loadBalancingWeight field is set. */ @java.lang.Override public boolean hasLoadBalancingWeight() { return loadBalancingWeight_ != null; } /** *
   * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
   * balancing weight for a locality is divided by the sum of the weights of all
   * localities  at the same priority level to produce the effective percentage
   * of traffic for the locality. The sum of the weights of all localities at
   * the same priority level must not exceed uint32_t maximal value (4294967295).
   * Locality weights are only considered when :ref:`locality weighted load
   * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
   * configured. These weights are ignored otherwise. If no weights are
   * specified when locality weighted load balancing is enabled, the locality is
   * assigned no load.
   * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } * @return The loadBalancingWeight. */ @java.lang.Override public com.google.protobuf.UInt32Value getLoadBalancingWeight() { return loadBalancingWeight_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : loadBalancingWeight_; } /** *
   * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
   * balancing weight for a locality is divided by the sum of the weights of all
   * localities  at the same priority level to produce the effective percentage
   * of traffic for the locality. The sum of the weights of all localities at
   * the same priority level must not exceed uint32_t maximal value (4294967295).
   * Locality weights are only considered when :ref:`locality weighted load
   * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
   * configured. These weights are ignored otherwise. If no weights are
   * specified when locality weighted load balancing is enabled, the locality is
   * assigned no load.
   * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } */ @java.lang.Override public com.google.protobuf.UInt32ValueOrBuilder getLoadBalancingWeightOrBuilder() { return getLoadBalancingWeight(); } public static final int PRIORITY_FIELD_NUMBER = 5; private int priority_; /** *
   * Optional: the priority for this LocalityLbEndpoints. If unspecified this will
   * default to the highest priority (0).
   * Under usual circumstances, Envoy will only select endpoints for the highest
   * priority (0). In the event that enough endpoints for a particular priority are
   * unavailable/unhealthy, Envoy will fail over to selecting endpoints for the
   * next highest priority group. Read more at :ref:`priority levels <arch_overview_load_balancing_priority_levels>`.
   * Priorities should range from 0 (highest) to N (lowest) without skipping.
   * 
* * uint32 priority = 5 [(.validate.rules) = { ... } * @return The priority. */ @java.lang.Override public int getPriority() { return priority_; } public static final int PROXIMITY_FIELD_NUMBER = 6; private com.google.protobuf.UInt32Value proximity_; /** *
   * Optional: Per locality proximity value which indicates how close this
   * locality is from the source locality. This value only provides ordering
   * information (lower the value, closer it is to the source locality).
   * This will be consumed by load balancing schemes that need proximity order
   * to determine where to route the requests.
   * [#not-implemented-hide:]
   * 
* * .google.protobuf.UInt32Value proximity = 6; * @return Whether the proximity field is set. */ @java.lang.Override public boolean hasProximity() { return proximity_ != null; } /** *
   * Optional: Per locality proximity value which indicates how close this
   * locality is from the source locality. This value only provides ordering
   * information (lower the value, closer it is to the source locality).
   * This will be consumed by load balancing schemes that need proximity order
   * to determine where to route the requests.
   * [#not-implemented-hide:]
   * 
* * .google.protobuf.UInt32Value proximity = 6; * @return The proximity. */ @java.lang.Override public com.google.protobuf.UInt32Value getProximity() { return proximity_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : proximity_; } /** *
   * Optional: Per locality proximity value which indicates how close this
   * locality is from the source locality. This value only provides ordering
   * information (lower the value, closer it is to the source locality).
   * This will be consumed by load balancing schemes that need proximity order
   * to determine where to route the requests.
   * [#not-implemented-hide:]
   * 
* * .google.protobuf.UInt32Value proximity = 6; */ @java.lang.Override public com.google.protobuf.UInt32ValueOrBuilder getProximityOrBuilder() { return getProximity(); } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (locality_ != null) { output.writeMessage(1, getLocality()); } for (int i = 0; i < lbEndpoints_.size(); i++) { output.writeMessage(2, lbEndpoints_.get(i)); } if (loadBalancingWeight_ != null) { output.writeMessage(3, getLoadBalancingWeight()); } if (priority_ != 0) { output.writeUInt32(5, priority_); } if (proximity_ != null) { output.writeMessage(6, getProximity()); } if (lbConfigCase_ == 7) { output.writeMessage(7, (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) lbConfig_); } if (lbConfigCase_ == 8) { output.writeMessage(8, (io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig) lbConfig_); } unknownFields.writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (locality_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(1, getLocality()); } for (int i = 0; i < lbEndpoints_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(2, lbEndpoints_.get(i)); } if (loadBalancingWeight_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(3, getLoadBalancingWeight()); } if (priority_ != 0) { size += com.google.protobuf.CodedOutputStream .computeUInt32Size(5, priority_); } if (proximity_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(6, getProximity()); } if (lbConfigCase_ == 7) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(7, (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) lbConfig_); } if (lbConfigCase_ == 8) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(8, (io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig) lbConfig_); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints)) { return super.equals(obj); } io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints other = (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints) obj; if (hasLocality() != other.hasLocality()) return false; if (hasLocality()) { if (!getLocality() .equals(other.getLocality())) return false; } if (!getLbEndpointsList() .equals(other.getLbEndpointsList())) return false; if (hasLoadBalancingWeight() != other.hasLoadBalancingWeight()) return false; if (hasLoadBalancingWeight()) { if (!getLoadBalancingWeight() .equals(other.getLoadBalancingWeight())) return false; } if (getPriority() != other.getPriority()) return false; if (hasProximity() != other.hasProximity()) return false; if (hasProximity()) { if (!getProximity() .equals(other.getProximity())) return false; } if (!getLbConfigCase().equals(other.getLbConfigCase())) return false; switch (lbConfigCase_) { case 7: if (!getLoadBalancerEndpoints() .equals(other.getLoadBalancerEndpoints())) return false; break; case 8: if (!getLedsClusterLocalityConfig() .equals(other.getLedsClusterLocalityConfig())) return false; break; case 0: default: } if (!unknownFields.equals(other.unknownFields)) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); if (hasLocality()) { hash = (37 * hash) + LOCALITY_FIELD_NUMBER; hash = (53 * hash) + getLocality().hashCode(); } if (getLbEndpointsCount() > 0) { hash = (37 * hash) + LB_ENDPOINTS_FIELD_NUMBER; hash = (53 * hash) + getLbEndpointsList().hashCode(); } if (hasLoadBalancingWeight()) { hash = (37 * hash) + LOAD_BALANCING_WEIGHT_FIELD_NUMBER; hash = (53 * hash) + getLoadBalancingWeight().hashCode(); } hash = (37 * hash) + PRIORITY_FIELD_NUMBER; hash = (53 * hash) + getPriority(); if (hasProximity()) { hash = (37 * hash) + PROXIMITY_FIELD_NUMBER; hash = (53 * hash) + getProximity().hashCode(); } switch (lbConfigCase_) { case 7: hash = (37 * hash) + LOAD_BALANCER_ENDPOINTS_FIELD_NUMBER; hash = (53 * hash) + getLoadBalancerEndpoints().hashCode(); break; case 8: hash = (37 * hash) + LEDS_CLUSTER_LOCALITY_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getLedsClusterLocalityConfig().hashCode(); break; case 0: default: } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input, extensionRegistry); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** *
   * A group of endpoints belonging to a Locality.
   * One can have multiple LocalityLbEndpoints for a locality, but only if
   * they have different priorities.
   * [#next-free-field: 9]
   * 
* * Protobuf type {@code envoy.config.endpoint.v3.LocalityLbEndpoints} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:envoy.config.endpoint.v3.LocalityLbEndpoints) io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpointsOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.envoyproxy.envoy.config.endpoint.v3.EndpointComponentsProto.internal_static_envoy_config_endpoint_v3_LocalityLbEndpoints_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.envoyproxy.envoy.config.endpoint.v3.EndpointComponentsProto.internal_static_envoy_config_endpoint_v3_LocalityLbEndpoints_fieldAccessorTable .ensureFieldAccessorsInitialized( io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.class, io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.Builder.class); } // Construct using io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { getLbEndpointsFieldBuilder(); } } @java.lang.Override public Builder clear() { super.clear(); if (localityBuilder_ == null) { locality_ = null; } else { locality_ = null; localityBuilder_ = null; } if (lbEndpointsBuilder_ == null) { lbEndpoints_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); } else { lbEndpointsBuilder_.clear(); } if (loadBalancingWeightBuilder_ == null) { loadBalancingWeight_ = null; } else { loadBalancingWeight_ = null; loadBalancingWeightBuilder_ = null; } priority_ = 0; if (proximityBuilder_ == null) { proximity_ = null; } else { proximity_ = null; proximityBuilder_ = null; } lbConfigCase_ = 0; lbConfig_ = null; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return io.envoyproxy.envoy.config.endpoint.v3.EndpointComponentsProto.internal_static_envoy_config_endpoint_v3_LocalityLbEndpoints_descriptor; } @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints getDefaultInstanceForType() { return io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.getDefaultInstance(); } @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints build() { io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints buildPartial() { io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints result = new io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints(this); int from_bitField0_ = bitField0_; if (localityBuilder_ == null) { result.locality_ = locality_; } else { result.locality_ = localityBuilder_.build(); } if (lbEndpointsBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0)) { lbEndpoints_ = java.util.Collections.unmodifiableList(lbEndpoints_); bitField0_ = (bitField0_ & ~0x00000001); } result.lbEndpoints_ = lbEndpoints_; } else { result.lbEndpoints_ = lbEndpointsBuilder_.build(); } if (lbConfigCase_ == 7) { if (loadBalancerEndpointsBuilder_ == null) { result.lbConfig_ = lbConfig_; } else { result.lbConfig_ = loadBalancerEndpointsBuilder_.build(); } } if (lbConfigCase_ == 8) { if (ledsClusterLocalityConfigBuilder_ == null) { result.lbConfig_ = lbConfig_; } else { result.lbConfig_ = ledsClusterLocalityConfigBuilder_.build(); } } if (loadBalancingWeightBuilder_ == null) { result.loadBalancingWeight_ = loadBalancingWeight_; } else { result.loadBalancingWeight_ = loadBalancingWeightBuilder_.build(); } result.priority_ = priority_; if (proximityBuilder_ == null) { result.proximity_ = proximity_; } else { result.proximity_ = proximityBuilder_.build(); } result.lbConfigCase_ = lbConfigCase_; onBuilt(); return result; } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField( com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof( com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints) { return mergeFrom((io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints other) { if (other == io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.getDefaultInstance()) return this; if (other.hasLocality()) { mergeLocality(other.getLocality()); } if (lbEndpointsBuilder_ == null) { if (!other.lbEndpoints_.isEmpty()) { if (lbEndpoints_.isEmpty()) { lbEndpoints_ = other.lbEndpoints_; bitField0_ = (bitField0_ & ~0x00000001); } else { ensureLbEndpointsIsMutable(); lbEndpoints_.addAll(other.lbEndpoints_); } onChanged(); } } else { if (!other.lbEndpoints_.isEmpty()) { if (lbEndpointsBuilder_.isEmpty()) { lbEndpointsBuilder_.dispose(); lbEndpointsBuilder_ = null; lbEndpoints_ = other.lbEndpoints_; bitField0_ = (bitField0_ & ~0x00000001); lbEndpointsBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getLbEndpointsFieldBuilder() : null; } else { lbEndpointsBuilder_.addAllMessages(other.lbEndpoints_); } } } if (other.hasLoadBalancingWeight()) { mergeLoadBalancingWeight(other.getLoadBalancingWeight()); } if (other.getPriority() != 0) { setPriority(other.getPriority()); } if (other.hasProximity()) { mergeProximity(other.getProximity()); } switch (other.getLbConfigCase()) { case LOAD_BALANCER_ENDPOINTS: { mergeLoadBalancerEndpoints(other.getLoadBalancerEndpoints()); break; } case LEDS_CLUSTER_LOCALITY_CONFIG: { mergeLedsClusterLocalityConfig(other.getLedsClusterLocalityConfig()); break; } case LBCONFIG_NOT_SET: { break; } } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int lbConfigCase_ = 0; private java.lang.Object lbConfig_; public LbConfigCase getLbConfigCase() { return LbConfigCase.forNumber( lbConfigCase_); } public Builder clearLbConfig() { lbConfigCase_ = 0; lbConfig_ = null; onChanged(); return this; } private int bitField0_; private io.envoyproxy.envoy.config.core.v3.Locality locality_; private com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.core.v3.Locality, io.envoyproxy.envoy.config.core.v3.Locality.Builder, io.envoyproxy.envoy.config.core.v3.LocalityOrBuilder> localityBuilder_; /** *
     * Identifies location of where the upstream hosts run.
     * 
* * .envoy.config.core.v3.Locality locality = 1; * @return Whether the locality field is set. */ public boolean hasLocality() { return localityBuilder_ != null || locality_ != null; } /** *
     * Identifies location of where the upstream hosts run.
     * 
* * .envoy.config.core.v3.Locality locality = 1; * @return The locality. */ public io.envoyproxy.envoy.config.core.v3.Locality getLocality() { if (localityBuilder_ == null) { return locality_ == null ? io.envoyproxy.envoy.config.core.v3.Locality.getDefaultInstance() : locality_; } else { return localityBuilder_.getMessage(); } } /** *
     * Identifies location of where the upstream hosts run.
     * 
* * .envoy.config.core.v3.Locality locality = 1; */ public Builder setLocality(io.envoyproxy.envoy.config.core.v3.Locality value) { if (localityBuilder_ == null) { if (value == null) { throw new NullPointerException(); } locality_ = value; onChanged(); } else { localityBuilder_.setMessage(value); } return this; } /** *
     * Identifies location of where the upstream hosts run.
     * 
* * .envoy.config.core.v3.Locality locality = 1; */ public Builder setLocality( io.envoyproxy.envoy.config.core.v3.Locality.Builder builderForValue) { if (localityBuilder_ == null) { locality_ = builderForValue.build(); onChanged(); } else { localityBuilder_.setMessage(builderForValue.build()); } return this; } /** *
     * Identifies location of where the upstream hosts run.
     * 
* * .envoy.config.core.v3.Locality locality = 1; */ public Builder mergeLocality(io.envoyproxy.envoy.config.core.v3.Locality value) { if (localityBuilder_ == null) { if (locality_ != null) { locality_ = io.envoyproxy.envoy.config.core.v3.Locality.newBuilder(locality_).mergeFrom(value).buildPartial(); } else { locality_ = value; } onChanged(); } else { localityBuilder_.mergeFrom(value); } return this; } /** *
     * Identifies location of where the upstream hosts run.
     * 
* * .envoy.config.core.v3.Locality locality = 1; */ public Builder clearLocality() { if (localityBuilder_ == null) { locality_ = null; onChanged(); } else { locality_ = null; localityBuilder_ = null; } return this; } /** *
     * Identifies location of where the upstream hosts run.
     * 
* * .envoy.config.core.v3.Locality locality = 1; */ public io.envoyproxy.envoy.config.core.v3.Locality.Builder getLocalityBuilder() { onChanged(); return getLocalityFieldBuilder().getBuilder(); } /** *
     * Identifies location of where the upstream hosts run.
     * 
* * .envoy.config.core.v3.Locality locality = 1; */ public io.envoyproxy.envoy.config.core.v3.LocalityOrBuilder getLocalityOrBuilder() { if (localityBuilder_ != null) { return localityBuilder_.getMessageOrBuilder(); } else { return locality_ == null ? io.envoyproxy.envoy.config.core.v3.Locality.getDefaultInstance() : locality_; } } /** *
     * Identifies location of where the upstream hosts run.
     * 
* * .envoy.config.core.v3.Locality locality = 1; */ private com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.core.v3.Locality, io.envoyproxy.envoy.config.core.v3.Locality.Builder, io.envoyproxy.envoy.config.core.v3.LocalityOrBuilder> getLocalityFieldBuilder() { if (localityBuilder_ == null) { localityBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.core.v3.Locality, io.envoyproxy.envoy.config.core.v3.Locality.Builder, io.envoyproxy.envoy.config.core.v3.LocalityOrBuilder>( getLocality(), getParentForChildren(), isClean()); locality_ = null; } return localityBuilder_; } private java.util.List lbEndpoints_ = java.util.Collections.emptyList(); private void ensureLbEndpointsIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { lbEndpoints_ = new java.util.ArrayList(lbEndpoints_); bitField0_ |= 0x00000001; } } private com.google.protobuf.RepeatedFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder, io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder> lbEndpointsBuilder_; /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public java.util.List getLbEndpointsList() { if (lbEndpointsBuilder_ == null) { return java.util.Collections.unmodifiableList(lbEndpoints_); } else { return lbEndpointsBuilder_.getMessageList(); } } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public int getLbEndpointsCount() { if (lbEndpointsBuilder_ == null) { return lbEndpoints_.size(); } else { return lbEndpointsBuilder_.getCount(); } } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint getLbEndpoints(int index) { if (lbEndpointsBuilder_ == null) { return lbEndpoints_.get(index); } else { return lbEndpointsBuilder_.getMessage(index); } } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public Builder setLbEndpoints( int index, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint value) { if (lbEndpointsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureLbEndpointsIsMutable(); lbEndpoints_.set(index, value); onChanged(); } else { lbEndpointsBuilder_.setMessage(index, value); } return this; } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public Builder setLbEndpoints( int index, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder builderForValue) { if (lbEndpointsBuilder_ == null) { ensureLbEndpointsIsMutable(); lbEndpoints_.set(index, builderForValue.build()); onChanged(); } else { lbEndpointsBuilder_.setMessage(index, builderForValue.build()); } return this; } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public Builder addLbEndpoints(io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint value) { if (lbEndpointsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureLbEndpointsIsMutable(); lbEndpoints_.add(value); onChanged(); } else { lbEndpointsBuilder_.addMessage(value); } return this; } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public Builder addLbEndpoints( int index, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint value) { if (lbEndpointsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureLbEndpointsIsMutable(); lbEndpoints_.add(index, value); onChanged(); } else { lbEndpointsBuilder_.addMessage(index, value); } return this; } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public Builder addLbEndpoints( io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder builderForValue) { if (lbEndpointsBuilder_ == null) { ensureLbEndpointsIsMutable(); lbEndpoints_.add(builderForValue.build()); onChanged(); } else { lbEndpointsBuilder_.addMessage(builderForValue.build()); } return this; } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public Builder addLbEndpoints( int index, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder builderForValue) { if (lbEndpointsBuilder_ == null) { ensureLbEndpointsIsMutable(); lbEndpoints_.add(index, builderForValue.build()); onChanged(); } else { lbEndpointsBuilder_.addMessage(index, builderForValue.build()); } return this; } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public Builder addAllLbEndpoints( java.lang.Iterable values) { if (lbEndpointsBuilder_ == null) { ensureLbEndpointsIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, lbEndpoints_); onChanged(); } else { lbEndpointsBuilder_.addAllMessages(values); } return this; } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public Builder clearLbEndpoints() { if (lbEndpointsBuilder_ == null) { lbEndpoints_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); } else { lbEndpointsBuilder_.clear(); } return this; } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public Builder removeLbEndpoints(int index) { if (lbEndpointsBuilder_ == null) { ensureLbEndpointsIsMutable(); lbEndpoints_.remove(index); onChanged(); } else { lbEndpointsBuilder_.remove(index); } return this; } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder getLbEndpointsBuilder( int index) { return getLbEndpointsFieldBuilder().getBuilder(index); } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder getLbEndpointsOrBuilder( int index) { if (lbEndpointsBuilder_ == null) { return lbEndpoints_.get(index); } else { return lbEndpointsBuilder_.getMessageOrBuilder(index); } } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public java.util.List getLbEndpointsOrBuilderList() { if (lbEndpointsBuilder_ != null) { return lbEndpointsBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(lbEndpoints_); } } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder addLbEndpointsBuilder() { return getLbEndpointsFieldBuilder().addBuilder( io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.getDefaultInstance()); } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder addLbEndpointsBuilder( int index) { return getLbEndpointsFieldBuilder().addBuilder( index, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.getDefaultInstance()); } /** *
     * The group of endpoints belonging to the locality specified.
     * [#comment:TODO(adisuissa): Once LEDS is implemented this field needs to be
     * deprecated and replaced by ``load_balancer_endpoints``.]
     * 
* * repeated .envoy.config.endpoint.v3.LbEndpoint lb_endpoints = 2; */ public java.util.List getLbEndpointsBuilderList() { return getLbEndpointsFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder, io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder> getLbEndpointsFieldBuilder() { if (lbEndpointsBuilder_ == null) { lbEndpointsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint, io.envoyproxy.envoy.config.endpoint.v3.LbEndpoint.Builder, io.envoyproxy.envoy.config.endpoint.v3.LbEndpointOrBuilder>( lbEndpoints_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); lbEndpoints_ = null; } return lbEndpointsBuilder_; } private com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList, io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.Builder, io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointListOrBuilder> loadBalancerEndpointsBuilder_; /** *
     * The group of endpoints belonging to the locality.
     * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
     * needs to be deprecated.]
     * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; * @return Whether the loadBalancerEndpoints field is set. */ @java.lang.Override public boolean hasLoadBalancerEndpoints() { return lbConfigCase_ == 7; } /** *
     * The group of endpoints belonging to the locality.
     * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
     * needs to be deprecated.]
     * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; * @return The loadBalancerEndpoints. */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList getLoadBalancerEndpoints() { if (loadBalancerEndpointsBuilder_ == null) { if (lbConfigCase_ == 7) { return (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) lbConfig_; } return io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.getDefaultInstance(); } else { if (lbConfigCase_ == 7) { return loadBalancerEndpointsBuilder_.getMessage(); } return io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.getDefaultInstance(); } } /** *
     * The group of endpoints belonging to the locality.
     * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
     * needs to be deprecated.]
     * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; */ public Builder setLoadBalancerEndpoints(io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList value) { if (loadBalancerEndpointsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } lbConfig_ = value; onChanged(); } else { loadBalancerEndpointsBuilder_.setMessage(value); } lbConfigCase_ = 7; return this; } /** *
     * The group of endpoints belonging to the locality.
     * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
     * needs to be deprecated.]
     * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; */ public Builder setLoadBalancerEndpoints( io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.Builder builderForValue) { if (loadBalancerEndpointsBuilder_ == null) { lbConfig_ = builderForValue.build(); onChanged(); } else { loadBalancerEndpointsBuilder_.setMessage(builderForValue.build()); } lbConfigCase_ = 7; return this; } /** *
     * The group of endpoints belonging to the locality.
     * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
     * needs to be deprecated.]
     * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; */ public Builder mergeLoadBalancerEndpoints(io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList value) { if (loadBalancerEndpointsBuilder_ == null) { if (lbConfigCase_ == 7 && lbConfig_ != io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.getDefaultInstance()) { lbConfig_ = io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.newBuilder((io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) lbConfig_) .mergeFrom(value).buildPartial(); } else { lbConfig_ = value; } onChanged(); } else { if (lbConfigCase_ == 7) { loadBalancerEndpointsBuilder_.mergeFrom(value); } else { loadBalancerEndpointsBuilder_.setMessage(value); } } lbConfigCase_ = 7; return this; } /** *
     * The group of endpoints belonging to the locality.
     * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
     * needs to be deprecated.]
     * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; */ public Builder clearLoadBalancerEndpoints() { if (loadBalancerEndpointsBuilder_ == null) { if (lbConfigCase_ == 7) { lbConfigCase_ = 0; lbConfig_ = null; onChanged(); } } else { if (lbConfigCase_ == 7) { lbConfigCase_ = 0; lbConfig_ = null; } loadBalancerEndpointsBuilder_.clear(); } return this; } /** *
     * The group of endpoints belonging to the locality.
     * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
     * needs to be deprecated.]
     * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; */ public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.Builder getLoadBalancerEndpointsBuilder() { return getLoadBalancerEndpointsFieldBuilder().getBuilder(); } /** *
     * The group of endpoints belonging to the locality.
     * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
     * needs to be deprecated.]
     * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointListOrBuilder getLoadBalancerEndpointsOrBuilder() { if ((lbConfigCase_ == 7) && (loadBalancerEndpointsBuilder_ != null)) { return loadBalancerEndpointsBuilder_.getMessageOrBuilder(); } else { if (lbConfigCase_ == 7) { return (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) lbConfig_; } return io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.getDefaultInstance(); } } /** *
     * The group of endpoints belonging to the locality.
     * [#comment:TODO(adisuissa): Once LEDS is implemented the ``lb_endpoints`` field
     * needs to be deprecated.]
     * 
* * .envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList load_balancer_endpoints = 7; */ private com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList, io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.Builder, io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointListOrBuilder> getLoadBalancerEndpointsFieldBuilder() { if (loadBalancerEndpointsBuilder_ == null) { if (!(lbConfigCase_ == 7)) { lbConfig_ = io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.getDefaultInstance(); } loadBalancerEndpointsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList, io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList.Builder, io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointListOrBuilder>( (io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints.LbEndpointList) lbConfig_, getParentForChildren(), isClean()); lbConfig_ = null; } lbConfigCase_ = 7; onChanged();; return loadBalancerEndpointsBuilder_; } private com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig, io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.Builder, io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfigOrBuilder> ledsClusterLocalityConfigBuilder_; /** *
     * LEDS Configuration for the current locality.
     * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; * @return Whether the ledsClusterLocalityConfig field is set. */ @java.lang.Override public boolean hasLedsClusterLocalityConfig() { return lbConfigCase_ == 8; } /** *
     * LEDS Configuration for the current locality.
     * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; * @return The ledsClusterLocalityConfig. */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig getLedsClusterLocalityConfig() { if (ledsClusterLocalityConfigBuilder_ == null) { if (lbConfigCase_ == 8) { return (io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig) lbConfig_; } return io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.getDefaultInstance(); } else { if (lbConfigCase_ == 8) { return ledsClusterLocalityConfigBuilder_.getMessage(); } return io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.getDefaultInstance(); } } /** *
     * LEDS Configuration for the current locality.
     * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; */ public Builder setLedsClusterLocalityConfig(io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig value) { if (ledsClusterLocalityConfigBuilder_ == null) { if (value == null) { throw new NullPointerException(); } lbConfig_ = value; onChanged(); } else { ledsClusterLocalityConfigBuilder_.setMessage(value); } lbConfigCase_ = 8; return this; } /** *
     * LEDS Configuration for the current locality.
     * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; */ public Builder setLedsClusterLocalityConfig( io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.Builder builderForValue) { if (ledsClusterLocalityConfigBuilder_ == null) { lbConfig_ = builderForValue.build(); onChanged(); } else { ledsClusterLocalityConfigBuilder_.setMessage(builderForValue.build()); } lbConfigCase_ = 8; return this; } /** *
     * LEDS Configuration for the current locality.
     * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; */ public Builder mergeLedsClusterLocalityConfig(io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig value) { if (ledsClusterLocalityConfigBuilder_ == null) { if (lbConfigCase_ == 8 && lbConfig_ != io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.getDefaultInstance()) { lbConfig_ = io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.newBuilder((io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig) lbConfig_) .mergeFrom(value).buildPartial(); } else { lbConfig_ = value; } onChanged(); } else { if (lbConfigCase_ == 8) { ledsClusterLocalityConfigBuilder_.mergeFrom(value); } else { ledsClusterLocalityConfigBuilder_.setMessage(value); } } lbConfigCase_ = 8; return this; } /** *
     * LEDS Configuration for the current locality.
     * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; */ public Builder clearLedsClusterLocalityConfig() { if (ledsClusterLocalityConfigBuilder_ == null) { if (lbConfigCase_ == 8) { lbConfigCase_ = 0; lbConfig_ = null; onChanged(); } } else { if (lbConfigCase_ == 8) { lbConfigCase_ = 0; lbConfig_ = null; } ledsClusterLocalityConfigBuilder_.clear(); } return this; } /** *
     * LEDS Configuration for the current locality.
     * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; */ public io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.Builder getLedsClusterLocalityConfigBuilder() { return getLedsClusterLocalityConfigFieldBuilder().getBuilder(); } /** *
     * LEDS Configuration for the current locality.
     * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; */ @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfigOrBuilder getLedsClusterLocalityConfigOrBuilder() { if ((lbConfigCase_ == 8) && (ledsClusterLocalityConfigBuilder_ != null)) { return ledsClusterLocalityConfigBuilder_.getMessageOrBuilder(); } else { if (lbConfigCase_ == 8) { return (io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig) lbConfig_; } return io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.getDefaultInstance(); } } /** *
     * LEDS Configuration for the current locality.
     * 
* * .envoy.config.endpoint.v3.LedsClusterLocalityConfig leds_cluster_locality_config = 8; */ private com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig, io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.Builder, io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfigOrBuilder> getLedsClusterLocalityConfigFieldBuilder() { if (ledsClusterLocalityConfigBuilder_ == null) { if (!(lbConfigCase_ == 8)) { lbConfig_ = io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.getDefaultInstance(); } ledsClusterLocalityConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig, io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig.Builder, io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfigOrBuilder>( (io.envoyproxy.envoy.config.endpoint.v3.LedsClusterLocalityConfig) lbConfig_, getParentForChildren(), isClean()); lbConfig_ = null; } lbConfigCase_ = 8; onChanged();; return ledsClusterLocalityConfigBuilder_; } private com.google.protobuf.UInt32Value loadBalancingWeight_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder> loadBalancingWeightBuilder_; /** *
     * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
     * balancing weight for a locality is divided by the sum of the weights of all
     * localities  at the same priority level to produce the effective percentage
     * of traffic for the locality. The sum of the weights of all localities at
     * the same priority level must not exceed uint32_t maximal value (4294967295).
     * Locality weights are only considered when :ref:`locality weighted load
     * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
     * configured. These weights are ignored otherwise. If no weights are
     * specified when locality weighted load balancing is enabled, the locality is
     * assigned no load.
     * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } * @return Whether the loadBalancingWeight field is set. */ public boolean hasLoadBalancingWeight() { return loadBalancingWeightBuilder_ != null || loadBalancingWeight_ != null; } /** *
     * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
     * balancing weight for a locality is divided by the sum of the weights of all
     * localities  at the same priority level to produce the effective percentage
     * of traffic for the locality. The sum of the weights of all localities at
     * the same priority level must not exceed uint32_t maximal value (4294967295).
     * Locality weights are only considered when :ref:`locality weighted load
     * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
     * configured. These weights are ignored otherwise. If no weights are
     * specified when locality weighted load balancing is enabled, the locality is
     * assigned no load.
     * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } * @return The loadBalancingWeight. */ public com.google.protobuf.UInt32Value getLoadBalancingWeight() { if (loadBalancingWeightBuilder_ == null) { return loadBalancingWeight_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : loadBalancingWeight_; } else { return loadBalancingWeightBuilder_.getMessage(); } } /** *
     * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
     * balancing weight for a locality is divided by the sum of the weights of all
     * localities  at the same priority level to produce the effective percentage
     * of traffic for the locality. The sum of the weights of all localities at
     * the same priority level must not exceed uint32_t maximal value (4294967295).
     * Locality weights are only considered when :ref:`locality weighted load
     * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
     * configured. These weights are ignored otherwise. If no weights are
     * specified when locality weighted load balancing is enabled, the locality is
     * assigned no load.
     * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } */ public Builder setLoadBalancingWeight(com.google.protobuf.UInt32Value value) { if (loadBalancingWeightBuilder_ == null) { if (value == null) { throw new NullPointerException(); } loadBalancingWeight_ = value; onChanged(); } else { loadBalancingWeightBuilder_.setMessage(value); } return this; } /** *
     * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
     * balancing weight for a locality is divided by the sum of the weights of all
     * localities  at the same priority level to produce the effective percentage
     * of traffic for the locality. The sum of the weights of all localities at
     * the same priority level must not exceed uint32_t maximal value (4294967295).
     * Locality weights are only considered when :ref:`locality weighted load
     * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
     * configured. These weights are ignored otherwise. If no weights are
     * specified when locality weighted load balancing is enabled, the locality is
     * assigned no load.
     * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } */ public Builder setLoadBalancingWeight( com.google.protobuf.UInt32Value.Builder builderForValue) { if (loadBalancingWeightBuilder_ == null) { loadBalancingWeight_ = builderForValue.build(); onChanged(); } else { loadBalancingWeightBuilder_.setMessage(builderForValue.build()); } return this; } /** *
     * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
     * balancing weight for a locality is divided by the sum of the weights of all
     * localities  at the same priority level to produce the effective percentage
     * of traffic for the locality. The sum of the weights of all localities at
     * the same priority level must not exceed uint32_t maximal value (4294967295).
     * Locality weights are only considered when :ref:`locality weighted load
     * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
     * configured. These weights are ignored otherwise. If no weights are
     * specified when locality weighted load balancing is enabled, the locality is
     * assigned no load.
     * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } */ public Builder mergeLoadBalancingWeight(com.google.protobuf.UInt32Value value) { if (loadBalancingWeightBuilder_ == null) { if (loadBalancingWeight_ != null) { loadBalancingWeight_ = com.google.protobuf.UInt32Value.newBuilder(loadBalancingWeight_).mergeFrom(value).buildPartial(); } else { loadBalancingWeight_ = value; } onChanged(); } else { loadBalancingWeightBuilder_.mergeFrom(value); } return this; } /** *
     * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
     * balancing weight for a locality is divided by the sum of the weights of all
     * localities  at the same priority level to produce the effective percentage
     * of traffic for the locality. The sum of the weights of all localities at
     * the same priority level must not exceed uint32_t maximal value (4294967295).
     * Locality weights are only considered when :ref:`locality weighted load
     * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
     * configured. These weights are ignored otherwise. If no weights are
     * specified when locality weighted load balancing is enabled, the locality is
     * assigned no load.
     * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } */ public Builder clearLoadBalancingWeight() { if (loadBalancingWeightBuilder_ == null) { loadBalancingWeight_ = null; onChanged(); } else { loadBalancingWeight_ = null; loadBalancingWeightBuilder_ = null; } return this; } /** *
     * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
     * balancing weight for a locality is divided by the sum of the weights of all
     * localities  at the same priority level to produce the effective percentage
     * of traffic for the locality. The sum of the weights of all localities at
     * the same priority level must not exceed uint32_t maximal value (4294967295).
     * Locality weights are only considered when :ref:`locality weighted load
     * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
     * configured. These weights are ignored otherwise. If no weights are
     * specified when locality weighted load balancing is enabled, the locality is
     * assigned no load.
     * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } */ public com.google.protobuf.UInt32Value.Builder getLoadBalancingWeightBuilder() { onChanged(); return getLoadBalancingWeightFieldBuilder().getBuilder(); } /** *
     * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
     * balancing weight for a locality is divided by the sum of the weights of all
     * localities  at the same priority level to produce the effective percentage
     * of traffic for the locality. The sum of the weights of all localities at
     * the same priority level must not exceed uint32_t maximal value (4294967295).
     * Locality weights are only considered when :ref:`locality weighted load
     * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
     * configured. These weights are ignored otherwise. If no weights are
     * specified when locality weighted load balancing is enabled, the locality is
     * assigned no load.
     * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } */ public com.google.protobuf.UInt32ValueOrBuilder getLoadBalancingWeightOrBuilder() { if (loadBalancingWeightBuilder_ != null) { return loadBalancingWeightBuilder_.getMessageOrBuilder(); } else { return loadBalancingWeight_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : loadBalancingWeight_; } } /** *
     * Optional: Per priority/region/zone/sub_zone weight; at least 1. The load
     * balancing weight for a locality is divided by the sum of the weights of all
     * localities  at the same priority level to produce the effective percentage
     * of traffic for the locality. The sum of the weights of all localities at
     * the same priority level must not exceed uint32_t maximal value (4294967295).
     * Locality weights are only considered when :ref:`locality weighted load
     * balancing <arch_overview_load_balancing_locality_weighted_lb>` is
     * configured. These weights are ignored otherwise. If no weights are
     * specified when locality weighted load balancing is enabled, the locality is
     * assigned no load.
     * 
* * .google.protobuf.UInt32Value load_balancing_weight = 3 [(.validate.rules) = { ... } */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder> getLoadBalancingWeightFieldBuilder() { if (loadBalancingWeightBuilder_ == null) { loadBalancingWeightBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>( getLoadBalancingWeight(), getParentForChildren(), isClean()); loadBalancingWeight_ = null; } return loadBalancingWeightBuilder_; } private int priority_ ; /** *
     * Optional: the priority for this LocalityLbEndpoints. If unspecified this will
     * default to the highest priority (0).
     * Under usual circumstances, Envoy will only select endpoints for the highest
     * priority (0). In the event that enough endpoints for a particular priority are
     * unavailable/unhealthy, Envoy will fail over to selecting endpoints for the
     * next highest priority group. Read more at :ref:`priority levels <arch_overview_load_balancing_priority_levels>`.
     * Priorities should range from 0 (highest) to N (lowest) without skipping.
     * 
* * uint32 priority = 5 [(.validate.rules) = { ... } * @return The priority. */ @java.lang.Override public int getPriority() { return priority_; } /** *
     * Optional: the priority for this LocalityLbEndpoints. If unspecified this will
     * default to the highest priority (0).
     * Under usual circumstances, Envoy will only select endpoints for the highest
     * priority (0). In the event that enough endpoints for a particular priority are
     * unavailable/unhealthy, Envoy will fail over to selecting endpoints for the
     * next highest priority group. Read more at :ref:`priority levels <arch_overview_load_balancing_priority_levels>`.
     * Priorities should range from 0 (highest) to N (lowest) without skipping.
     * 
* * uint32 priority = 5 [(.validate.rules) = { ... } * @param value The priority to set. * @return This builder for chaining. */ public Builder setPriority(int value) { priority_ = value; onChanged(); return this; } /** *
     * Optional: the priority for this LocalityLbEndpoints. If unspecified this will
     * default to the highest priority (0).
     * Under usual circumstances, Envoy will only select endpoints for the highest
     * priority (0). In the event that enough endpoints for a particular priority are
     * unavailable/unhealthy, Envoy will fail over to selecting endpoints for the
     * next highest priority group. Read more at :ref:`priority levels <arch_overview_load_balancing_priority_levels>`.
     * Priorities should range from 0 (highest) to N (lowest) without skipping.
     * 
* * uint32 priority = 5 [(.validate.rules) = { ... } * @return This builder for chaining. */ public Builder clearPriority() { priority_ = 0; onChanged(); return this; } private com.google.protobuf.UInt32Value proximity_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder> proximityBuilder_; /** *
     * Optional: Per locality proximity value which indicates how close this
     * locality is from the source locality. This value only provides ordering
     * information (lower the value, closer it is to the source locality).
     * This will be consumed by load balancing schemes that need proximity order
     * to determine where to route the requests.
     * [#not-implemented-hide:]
     * 
* * .google.protobuf.UInt32Value proximity = 6; * @return Whether the proximity field is set. */ public boolean hasProximity() { return proximityBuilder_ != null || proximity_ != null; } /** *
     * Optional: Per locality proximity value which indicates how close this
     * locality is from the source locality. This value only provides ordering
     * information (lower the value, closer it is to the source locality).
     * This will be consumed by load balancing schemes that need proximity order
     * to determine where to route the requests.
     * [#not-implemented-hide:]
     * 
* * .google.protobuf.UInt32Value proximity = 6; * @return The proximity. */ public com.google.protobuf.UInt32Value getProximity() { if (proximityBuilder_ == null) { return proximity_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : proximity_; } else { return proximityBuilder_.getMessage(); } } /** *
     * Optional: Per locality proximity value which indicates how close this
     * locality is from the source locality. This value only provides ordering
     * information (lower the value, closer it is to the source locality).
     * This will be consumed by load balancing schemes that need proximity order
     * to determine where to route the requests.
     * [#not-implemented-hide:]
     * 
* * .google.protobuf.UInt32Value proximity = 6; */ public Builder setProximity(com.google.protobuf.UInt32Value value) { if (proximityBuilder_ == null) { if (value == null) { throw new NullPointerException(); } proximity_ = value; onChanged(); } else { proximityBuilder_.setMessage(value); } return this; } /** *
     * Optional: Per locality proximity value which indicates how close this
     * locality is from the source locality. This value only provides ordering
     * information (lower the value, closer it is to the source locality).
     * This will be consumed by load balancing schemes that need proximity order
     * to determine where to route the requests.
     * [#not-implemented-hide:]
     * 
* * .google.protobuf.UInt32Value proximity = 6; */ public Builder setProximity( com.google.protobuf.UInt32Value.Builder builderForValue) { if (proximityBuilder_ == null) { proximity_ = builderForValue.build(); onChanged(); } else { proximityBuilder_.setMessage(builderForValue.build()); } return this; } /** *
     * Optional: Per locality proximity value which indicates how close this
     * locality is from the source locality. This value only provides ordering
     * information (lower the value, closer it is to the source locality).
     * This will be consumed by load balancing schemes that need proximity order
     * to determine where to route the requests.
     * [#not-implemented-hide:]
     * 
* * .google.protobuf.UInt32Value proximity = 6; */ public Builder mergeProximity(com.google.protobuf.UInt32Value value) { if (proximityBuilder_ == null) { if (proximity_ != null) { proximity_ = com.google.protobuf.UInt32Value.newBuilder(proximity_).mergeFrom(value).buildPartial(); } else { proximity_ = value; } onChanged(); } else { proximityBuilder_.mergeFrom(value); } return this; } /** *
     * Optional: Per locality proximity value which indicates how close this
     * locality is from the source locality. This value only provides ordering
     * information (lower the value, closer it is to the source locality).
     * This will be consumed by load balancing schemes that need proximity order
     * to determine where to route the requests.
     * [#not-implemented-hide:]
     * 
* * .google.protobuf.UInt32Value proximity = 6; */ public Builder clearProximity() { if (proximityBuilder_ == null) { proximity_ = null; onChanged(); } else { proximity_ = null; proximityBuilder_ = null; } return this; } /** *
     * Optional: Per locality proximity value which indicates how close this
     * locality is from the source locality. This value only provides ordering
     * information (lower the value, closer it is to the source locality).
     * This will be consumed by load balancing schemes that need proximity order
     * to determine where to route the requests.
     * [#not-implemented-hide:]
     * 
* * .google.protobuf.UInt32Value proximity = 6; */ public com.google.protobuf.UInt32Value.Builder getProximityBuilder() { onChanged(); return getProximityFieldBuilder().getBuilder(); } /** *
     * Optional: Per locality proximity value which indicates how close this
     * locality is from the source locality. This value only provides ordering
     * information (lower the value, closer it is to the source locality).
     * This will be consumed by load balancing schemes that need proximity order
     * to determine where to route the requests.
     * [#not-implemented-hide:]
     * 
* * .google.protobuf.UInt32Value proximity = 6; */ public com.google.protobuf.UInt32ValueOrBuilder getProximityOrBuilder() { if (proximityBuilder_ != null) { return proximityBuilder_.getMessageOrBuilder(); } else { return proximity_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : proximity_; } } /** *
     * Optional: Per locality proximity value which indicates how close this
     * locality is from the source locality. This value only provides ordering
     * information (lower the value, closer it is to the source locality).
     * This will be consumed by load balancing schemes that need proximity order
     * to determine where to route the requests.
     * [#not-implemented-hide:]
     * 
* * .google.protobuf.UInt32Value proximity = 6; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder> getProximityFieldBuilder() { if (proximityBuilder_ == null) { proximityBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>( getProximity(), getParentForChildren(), isClean()); proximity_ = null; } return proximityBuilder_; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:envoy.config.endpoint.v3.LocalityLbEndpoints) } // @@protoc_insertion_point(class_scope:envoy.config.endpoint.v3.LocalityLbEndpoints) private static final io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints(); } public static io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public LocalityLbEndpoints parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new LocalityLbEndpoints(input, extensionRegistry); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public io.envoyproxy.envoy.config.endpoint.v3.LocalityLbEndpoints getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy