Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: envoy/data/cluster/v2alpha/outlier_detection_event.proto
package io.envoyproxy.envoy.data.cluster.v2alpha;
/**
*
* [#next-free-field: 12]
*
*
* Protobuf type {@code envoy.data.cluster.v2alpha.OutlierDetectionEvent}
*/
public final class OutlierDetectionEvent extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.data.cluster.v2alpha.OutlierDetectionEvent)
OutlierDetectionEventOrBuilder {
private static final long serialVersionUID = 0L;
// Use OutlierDetectionEvent.newBuilder() to construct.
private OutlierDetectionEvent(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private OutlierDetectionEvent() {
type_ = 0;
clusterName_ = "";
upstreamUrl_ = "";
action_ = 0;
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new OutlierDetectionEvent();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private OutlierDetectionEvent(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
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 8: {
int rawValue = input.readEnum();
type_ = rawValue;
break;
}
case 18: {
com.google.protobuf.Timestamp.Builder subBuilder = null;
if (timestamp_ != null) {
subBuilder = timestamp_.toBuilder();
}
timestamp_ = input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(timestamp_);
timestamp_ = subBuilder.buildPartial();
}
break;
}
case 26: {
com.google.protobuf.UInt64Value.Builder subBuilder = null;
if (secsSinceLastAction_ != null) {
subBuilder = secsSinceLastAction_.toBuilder();
}
secsSinceLastAction_ = input.readMessage(com.google.protobuf.UInt64Value.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(secsSinceLastAction_);
secsSinceLastAction_ = subBuilder.buildPartial();
}
break;
}
case 34: {
java.lang.String s = input.readStringRequireUtf8();
clusterName_ = s;
break;
}
case 42: {
java.lang.String s = input.readStringRequireUtf8();
upstreamUrl_ = s;
break;
}
case 48: {
int rawValue = input.readEnum();
action_ = rawValue;
break;
}
case 56: {
numEjections_ = input.readUInt32();
break;
}
case 64: {
enforced_ = input.readBool();
break;
}
case 74: {
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate.Builder subBuilder = null;
if (eventCase_ == 9) {
subBuilder = ((io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate) event_).toBuilder();
}
event_ =
input.readMessage(io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom((io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate) event_);
event_ = subBuilder.buildPartial();
}
eventCase_ = 9;
break;
}
case 82: {
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive.Builder subBuilder = null;
if (eventCase_ == 10) {
subBuilder = ((io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive) event_).toBuilder();
}
event_ =
input.readMessage(io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom((io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive) event_);
event_ = subBuilder.buildPartial();
}
eventCase_ = 10;
break;
}
case 90: {
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage.Builder subBuilder = null;
if (eventCase_ == 11) {
subBuilder = ((io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage) event_).toBuilder();
}
event_ =
input.readMessage(io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom((io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage) event_);
event_ = subBuilder.buildPartial();
}
eventCase_ = 11;
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 {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEventProto.internal_static_envoy_data_cluster_v2alpha_OutlierDetectionEvent_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEventProto.internal_static_envoy_data_cluster_v2alpha_OutlierDetectionEvent_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent.class, io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent.Builder.class);
}
private int eventCase_ = 0;
private java.lang.Object event_;
public enum EventCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
EJECT_SUCCESS_RATE_EVENT(9),
EJECT_CONSECUTIVE_EVENT(10),
EJECT_FAILURE_PERCENTAGE_EVENT(11),
EVENT_NOT_SET(0);
private final int value;
private EventCase(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 EventCase valueOf(int value) {
return forNumber(value);
}
public static EventCase forNumber(int value) {
switch (value) {
case 9: return EJECT_SUCCESS_RATE_EVENT;
case 10: return EJECT_CONSECUTIVE_EVENT;
case 11: return EJECT_FAILURE_PERCENTAGE_EVENT;
case 0: return EVENT_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public EventCase
getEventCase() {
return EventCase.forNumber(
eventCase_);
}
public static final int TYPE_FIELD_NUMBER = 1;
private int type_;
/**
*
* In case of eject represents type of ejection that took place.
*
*
* .envoy.data.cluster.v2alpha.OutlierEjectionType type = 1 [(.validate.rules) = { ... }
* @return The enum numeric value on the wire for type.
*/
@java.lang.Override public int getTypeValue() {
return type_;
}
/**
*
* In case of eject represents type of ejection that took place.
*
*
* .envoy.data.cluster.v2alpha.OutlierEjectionType type = 1 [(.validate.rules) = { ... }
* @return The type.
*/
@java.lang.Override public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType getType() {
@SuppressWarnings("deprecation")
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType result = io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType.valueOf(type_);
return result == null ? io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType.UNRECOGNIZED : result;
}
public static final int TIMESTAMP_FIELD_NUMBER = 2;
private com.google.protobuf.Timestamp timestamp_;
/**
*
* Timestamp for event.
*
*
* .google.protobuf.Timestamp timestamp = 2;
* @return Whether the timestamp field is set.
*/
@java.lang.Override
public boolean hasTimestamp() {
return timestamp_ != null;
}
/**
*
* The URL of the ejected host. E.g., ``tcp://1.2.3.4:80``.
*
*
* string upstream_url = 5 [(.validate.rules) = { ... }
* @return The bytes for upstreamUrl.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getUpstreamUrlBytes() {
java.lang.Object ref = upstreamUrl_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
upstreamUrl_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int ACTION_FIELD_NUMBER = 6;
private int action_;
/**
*
* The action that took place.
*
*
* .envoy.data.cluster.v2alpha.Action action = 6 [(.validate.rules) = { ... }
* @return The enum numeric value on the wire for action.
*/
@java.lang.Override public int getActionValue() {
return action_;
}
/**
*
* The action that took place.
*
*
* .envoy.data.cluster.v2alpha.Action action = 6 [(.validate.rules) = { ... }
* @return The action.
*/
@java.lang.Override public io.envoyproxy.envoy.data.cluster.v2alpha.Action getAction() {
@SuppressWarnings("deprecation")
io.envoyproxy.envoy.data.cluster.v2alpha.Action result = io.envoyproxy.envoy.data.cluster.v2alpha.Action.valueOf(action_);
return result == null ? io.envoyproxy.envoy.data.cluster.v2alpha.Action.UNRECOGNIZED : result;
}
public static final int NUM_EJECTIONS_FIELD_NUMBER = 7;
private int numEjections_;
/**
*
* If ``action`` is ``eject``, specifies the number of times the host has been ejected (local to
* that Envoy and gets reset if the host gets removed from the upstream cluster for any reason and
* then re-added).
*
*
* uint32 num_ejections = 7;
* @return The numEjections.
*/
@java.lang.Override
public int getNumEjections() {
return numEjections_;
}
public static final int ENFORCED_FIELD_NUMBER = 8;
private boolean enforced_;
/**
*
* If ``action`` is ``eject``, specifies if the ejection was enforced. ``true`` means the host was
* ejected. ``false`` means the event was logged but the host was not actually ejected.
*
*
* bool enforced = 8;
* @return The enforced.
*/
@java.lang.Override
public boolean getEnforced() {
return enforced_;
}
public static final int EJECT_SUCCESS_RATE_EVENT_FIELD_NUMBER = 9;
/**
* .envoy.data.cluster.v2alpha.OutlierEjectSuccessRate eject_success_rate_event = 9;
* @return Whether the ejectSuccessRateEvent field is set.
*/
@java.lang.Override
public boolean hasEjectSuccessRateEvent() {
return eventCase_ == 9;
}
/**
* .envoy.data.cluster.v2alpha.OutlierEjectSuccessRate eject_success_rate_event = 9;
* @return The ejectSuccessRateEvent.
*/
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate getEjectSuccessRateEvent() {
if (eventCase_ == 9) {
return (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate) event_;
}
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate.getDefaultInstance();
}
/**
* .envoy.data.cluster.v2alpha.OutlierEjectSuccessRate eject_success_rate_event = 9;
*/
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRateOrBuilder getEjectSuccessRateEventOrBuilder() {
if (eventCase_ == 9) {
return (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate) event_;
}
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate.getDefaultInstance();
}
public static final int EJECT_CONSECUTIVE_EVENT_FIELD_NUMBER = 10;
/**
* .envoy.data.cluster.v2alpha.OutlierEjectConsecutive eject_consecutive_event = 10;
* @return Whether the ejectConsecutiveEvent field is set.
*/
@java.lang.Override
public boolean hasEjectConsecutiveEvent() {
return eventCase_ == 10;
}
/**
* .envoy.data.cluster.v2alpha.OutlierEjectConsecutive eject_consecutive_event = 10;
* @return The ejectConsecutiveEvent.
*/
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive getEjectConsecutiveEvent() {
if (eventCase_ == 10) {
return (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive) event_;
}
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive.getDefaultInstance();
}
/**
* .envoy.data.cluster.v2alpha.OutlierEjectConsecutive eject_consecutive_event = 10;
*/
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutiveOrBuilder getEjectConsecutiveEventOrBuilder() {
if (eventCase_ == 10) {
return (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive) event_;
}
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive.getDefaultInstance();
}
public static final int EJECT_FAILURE_PERCENTAGE_EVENT_FIELD_NUMBER = 11;
/**
* .envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage eject_failure_percentage_event = 11;
* @return Whether the ejectFailurePercentageEvent field is set.
*/
@java.lang.Override
public boolean hasEjectFailurePercentageEvent() {
return eventCase_ == 11;
}
/**
* .envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage eject_failure_percentage_event = 11;
* @return The ejectFailurePercentageEvent.
*/
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage getEjectFailurePercentageEvent() {
if (eventCase_ == 11) {
return (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage) event_;
}
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage.getDefaultInstance();
}
/**
* .envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage eject_failure_percentage_event = 11;
*/
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentageOrBuilder getEjectFailurePercentageEventOrBuilder() {
if (eventCase_ == 11) {
return (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage) event_;
}
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage.getDefaultInstance();
}
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 (type_ != io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType.CONSECUTIVE_5XX.getNumber()) {
output.writeEnum(1, type_);
}
if (timestamp_ != null) {
output.writeMessage(2, getTimestamp());
}
if (secsSinceLastAction_ != null) {
output.writeMessage(3, getSecsSinceLastAction());
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(clusterName_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 4, clusterName_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(upstreamUrl_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 5, upstreamUrl_);
}
if (action_ != io.envoyproxy.envoy.data.cluster.v2alpha.Action.EJECT.getNumber()) {
output.writeEnum(6, action_);
}
if (numEjections_ != 0) {
output.writeUInt32(7, numEjections_);
}
if (enforced_ != false) {
output.writeBool(8, enforced_);
}
if (eventCase_ == 9) {
output.writeMessage(9, (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate) event_);
}
if (eventCase_ == 10) {
output.writeMessage(10, (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive) event_);
}
if (eventCase_ == 11) {
output.writeMessage(11, (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage) event_);
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (type_ != io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType.CONSECUTIVE_5XX.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, type_);
}
if (timestamp_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getTimestamp());
}
if (secsSinceLastAction_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getSecsSinceLastAction());
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(clusterName_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, clusterName_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(upstreamUrl_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, upstreamUrl_);
}
if (action_ != io.envoyproxy.envoy.data.cluster.v2alpha.Action.EJECT.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(6, action_);
}
if (numEjections_ != 0) {
size += com.google.protobuf.CodedOutputStream
.computeUInt32Size(7, numEjections_);
}
if (enforced_ != false) {
size += com.google.protobuf.CodedOutputStream
.computeBoolSize(8, enforced_);
}
if (eventCase_ == 9) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(9, (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectSuccessRate) event_);
}
if (eventCase_ == 10) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(10, (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectConsecutive) event_);
}
if (eventCase_ == 11) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(11, (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectFailurePercentage) event_);
}
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.data.cluster.v2alpha.OutlierDetectionEvent)) {
return super.equals(obj);
}
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent other = (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent) obj;
if (type_ != other.type_) return false;
if (hasTimestamp() != other.hasTimestamp()) return false;
if (hasTimestamp()) {
if (!getTimestamp()
.equals(other.getTimestamp())) return false;
}
if (hasSecsSinceLastAction() != other.hasSecsSinceLastAction()) return false;
if (hasSecsSinceLastAction()) {
if (!getSecsSinceLastAction()
.equals(other.getSecsSinceLastAction())) return false;
}
if (!getClusterName()
.equals(other.getClusterName())) return false;
if (!getUpstreamUrl()
.equals(other.getUpstreamUrl())) return false;
if (action_ != other.action_) return false;
if (getNumEjections()
!= other.getNumEjections()) return false;
if (getEnforced()
!= other.getEnforced()) return false;
if (!getEventCase().equals(other.getEventCase())) return false;
switch (eventCase_) {
case 9:
if (!getEjectSuccessRateEvent()
.equals(other.getEjectSuccessRateEvent())) return false;
break;
case 10:
if (!getEjectConsecutiveEvent()
.equals(other.getEjectConsecutiveEvent())) return false;
break;
case 11:
if (!getEjectFailurePercentageEvent()
.equals(other.getEjectFailurePercentageEvent())) 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();
hash = (37 * hash) + TYPE_FIELD_NUMBER;
hash = (53 * hash) + type_;
if (hasTimestamp()) {
hash = (37 * hash) + TIMESTAMP_FIELD_NUMBER;
hash = (53 * hash) + getTimestamp().hashCode();
}
if (hasSecsSinceLastAction()) {
hash = (37 * hash) + SECS_SINCE_LAST_ACTION_FIELD_NUMBER;
hash = (53 * hash) + getSecsSinceLastAction().hashCode();
}
hash = (37 * hash) + CLUSTER_NAME_FIELD_NUMBER;
hash = (53 * hash) + getClusterName().hashCode();
hash = (37 * hash) + UPSTREAM_URL_FIELD_NUMBER;
hash = (53 * hash) + getUpstreamUrl().hashCode();
hash = (37 * hash) + ACTION_FIELD_NUMBER;
hash = (53 * hash) + action_;
hash = (37 * hash) + NUM_EJECTIONS_FIELD_NUMBER;
hash = (53 * hash) + getNumEjections();
hash = (37 * hash) + ENFORCED_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
getEnforced());
switch (eventCase_) {
case 9:
hash = (37 * hash) + EJECT_SUCCESS_RATE_EVENT_FIELD_NUMBER;
hash = (53 * hash) + getEjectSuccessRateEvent().hashCode();
break;
case 10:
hash = (37 * hash) + EJECT_CONSECUTIVE_EVENT_FIELD_NUMBER;
hash = (53 * hash) + getEjectConsecutiveEvent().hashCode();
break;
case 11:
hash = (37 * hash) + EJECT_FAILURE_PERCENTAGE_EVENT_FIELD_NUMBER;
hash = (53 * hash) + getEjectFailurePercentageEvent().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent 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.data.cluster.v2alpha.OutlierDetectionEvent parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent 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.data.cluster.v2alpha.OutlierDetectionEvent parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent 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.data.cluster.v2alpha.OutlierDetectionEvent parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent 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.data.cluster.v2alpha.OutlierDetectionEvent parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent 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.data.cluster.v2alpha.OutlierDetectionEvent 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;
}
/**
*
* [#next-free-field: 12]
*
*
* Protobuf type {@code envoy.data.cluster.v2alpha.OutlierDetectionEvent}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.data.cluster.v2alpha.OutlierDetectionEvent)
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEventOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEventProto.internal_static_envoy_data_cluster_v2alpha_OutlierDetectionEvent_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEventProto.internal_static_envoy_data_cluster_v2alpha_OutlierDetectionEvent_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent.class, io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent.Builder.class);
}
// Construct using io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
type_ = 0;
if (timestampBuilder_ == null) {
timestamp_ = null;
} else {
timestamp_ = null;
timestampBuilder_ = null;
}
if (secsSinceLastActionBuilder_ == null) {
secsSinceLastAction_ = null;
} else {
secsSinceLastAction_ = null;
secsSinceLastActionBuilder_ = null;
}
clusterName_ = "";
upstreamUrl_ = "";
action_ = 0;
numEjections_ = 0;
enforced_ = false;
eventCase_ = 0;
event_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEventProto.internal_static_envoy_data_cluster_v2alpha_OutlierDetectionEvent_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent getDefaultInstanceForType() {
return io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent build() {
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent buildPartial() {
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent result = new io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent(this);
result.type_ = type_;
if (timestampBuilder_ == null) {
result.timestamp_ = timestamp_;
} else {
result.timestamp_ = timestampBuilder_.build();
}
if (secsSinceLastActionBuilder_ == null) {
result.secsSinceLastAction_ = secsSinceLastAction_;
} else {
result.secsSinceLastAction_ = secsSinceLastActionBuilder_.build();
}
result.clusterName_ = clusterName_;
result.upstreamUrl_ = upstreamUrl_;
result.action_ = action_;
result.numEjections_ = numEjections_;
result.enforced_ = enforced_;
if (eventCase_ == 9) {
if (ejectSuccessRateEventBuilder_ == null) {
result.event_ = event_;
} else {
result.event_ = ejectSuccessRateEventBuilder_.build();
}
}
if (eventCase_ == 10) {
if (ejectConsecutiveEventBuilder_ == null) {
result.event_ = event_;
} else {
result.event_ = ejectConsecutiveEventBuilder_.build();
}
}
if (eventCase_ == 11) {
if (ejectFailurePercentageEventBuilder_ == null) {
result.event_ = event_;
} else {
result.event_ = ejectFailurePercentageEventBuilder_.build();
}
}
result.eventCase_ = eventCase_;
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.data.cluster.v2alpha.OutlierDetectionEvent) {
return mergeFrom((io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent other) {
if (other == io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent.getDefaultInstance()) return this;
if (other.type_ != 0) {
setTypeValue(other.getTypeValue());
}
if (other.hasTimestamp()) {
mergeTimestamp(other.getTimestamp());
}
if (other.hasSecsSinceLastAction()) {
mergeSecsSinceLastAction(other.getSecsSinceLastAction());
}
if (!other.getClusterName().isEmpty()) {
clusterName_ = other.clusterName_;
onChanged();
}
if (!other.getUpstreamUrl().isEmpty()) {
upstreamUrl_ = other.upstreamUrl_;
onChanged();
}
if (other.action_ != 0) {
setActionValue(other.getActionValue());
}
if (other.getNumEjections() != 0) {
setNumEjections(other.getNumEjections());
}
if (other.getEnforced() != false) {
setEnforced(other.getEnforced());
}
switch (other.getEventCase()) {
case EJECT_SUCCESS_RATE_EVENT: {
mergeEjectSuccessRateEvent(other.getEjectSuccessRateEvent());
break;
}
case EJECT_CONSECUTIVE_EVENT: {
mergeEjectConsecutiveEvent(other.getEjectConsecutiveEvent());
break;
}
case EJECT_FAILURE_PERCENTAGE_EVENT: {
mergeEjectFailurePercentageEvent(other.getEjectFailurePercentageEvent());
break;
}
case EVENT_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.data.cluster.v2alpha.OutlierDetectionEvent parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (io.envoyproxy.envoy.data.cluster.v2alpha.OutlierDetectionEvent) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int eventCase_ = 0;
private java.lang.Object event_;
public EventCase
getEventCase() {
return EventCase.forNumber(
eventCase_);
}
public Builder clearEvent() {
eventCase_ = 0;
event_ = null;
onChanged();
return this;
}
private int type_ = 0;
/**
*
* In case of eject represents type of ejection that took place.
*
*
* .envoy.data.cluster.v2alpha.OutlierEjectionType type = 1 [(.validate.rules) = { ... }
* @return The enum numeric value on the wire for type.
*/
@java.lang.Override public int getTypeValue() {
return type_;
}
/**
*
* In case of eject represents type of ejection that took place.
*
*
* .envoy.data.cluster.v2alpha.OutlierEjectionType type = 1 [(.validate.rules) = { ... }
* @param value The enum numeric value on the wire for type to set.
* @return This builder for chaining.
*/
public Builder setTypeValue(int value) {
type_ = value;
onChanged();
return this;
}
/**
*
* In case of eject represents type of ejection that took place.
*
*
* .envoy.data.cluster.v2alpha.OutlierEjectionType type = 1 [(.validate.rules) = { ... }
* @return The type.
*/
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType getType() {
@SuppressWarnings("deprecation")
io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType result = io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType.valueOf(type_);
return result == null ? io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType.UNRECOGNIZED : result;
}
/**
*
* In case of eject represents type of ejection that took place.
*
*
* .envoy.data.cluster.v2alpha.OutlierEjectionType type = 1 [(.validate.rules) = { ... }
* @param value The type to set.
* @return This builder for chaining.
*/
public Builder setType(io.envoyproxy.envoy.data.cluster.v2alpha.OutlierEjectionType value) {
if (value == null) {
throw new NullPointerException();
}
type_ = value.getNumber();
onChanged();
return this;
}
/**
*
* In case of eject represents type of ejection that took place.
*
*
* .envoy.data.cluster.v2alpha.OutlierEjectionType type = 1 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearType() {
type_ = 0;
onChanged();
return this;
}
private com.google.protobuf.Timestamp timestamp_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> timestampBuilder_;
/**
*
* Timestamp for event.
*
*
* .google.protobuf.Timestamp timestamp = 2;
* @return Whether the timestamp field is set.
*/
public boolean hasTimestamp() {
return timestampBuilder_ != null || timestamp_ != null;
}
/**
*
* The URL of the ejected host. E.g., ``tcp://1.2.3.4:80``.
*
*
* string upstream_url = 5 [(.validate.rules) = { ... }
* @param value The bytes for upstreamUrl to set.
* @return This builder for chaining.
*/
public Builder setUpstreamUrlBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
upstreamUrl_ = value;
onChanged();
return this;
}
private int action_ = 0;
/**
*
* The action that took place.
*
*
* .envoy.data.cluster.v2alpha.Action action = 6 [(.validate.rules) = { ... }
* @return The enum numeric value on the wire for action.
*/
@java.lang.Override public int getActionValue() {
return action_;
}
/**
*
* The action that took place.
*
*
* .envoy.data.cluster.v2alpha.Action action = 6 [(.validate.rules) = { ... }
* @param value The enum numeric value on the wire for action to set.
* @return This builder for chaining.
*/
public Builder setActionValue(int value) {
action_ = value;
onChanged();
return this;
}
/**
*
* The action that took place.
*
*
* .envoy.data.cluster.v2alpha.Action action = 6 [(.validate.rules) = { ... }
* @return The action.
*/
@java.lang.Override
public io.envoyproxy.envoy.data.cluster.v2alpha.Action getAction() {
@SuppressWarnings("deprecation")
io.envoyproxy.envoy.data.cluster.v2alpha.Action result = io.envoyproxy.envoy.data.cluster.v2alpha.Action.valueOf(action_);
return result == null ? io.envoyproxy.envoy.data.cluster.v2alpha.Action.UNRECOGNIZED : result;
}
/**
*
* The action that took place.
*
*
* .envoy.data.cluster.v2alpha.Action action = 6 [(.validate.rules) = { ... }
* @param value The action to set.
* @return This builder for chaining.
*/
public Builder setAction(io.envoyproxy.envoy.data.cluster.v2alpha.Action value) {
if (value == null) {
throw new NullPointerException();
}
action_ = value.getNumber();
onChanged();
return this;
}
/**
*
* The action that took place.
*
*
* .envoy.data.cluster.v2alpha.Action action = 6 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearAction() {
action_ = 0;
onChanged();
return this;
}
private int numEjections_ ;
/**
*
* If ``action`` is ``eject``, specifies the number of times the host has been ejected (local to
* that Envoy and gets reset if the host gets removed from the upstream cluster for any reason and
* then re-added).
*
*
* uint32 num_ejections = 7;
* @return The numEjections.
*/
@java.lang.Override
public int getNumEjections() {
return numEjections_;
}
/**
*
* If ``action`` is ``eject``, specifies the number of times the host has been ejected (local to
* that Envoy and gets reset if the host gets removed from the upstream cluster for any reason and
* then re-added).
*
*
* uint32 num_ejections = 7;
* @param value The numEjections to set.
* @return This builder for chaining.
*/
public Builder setNumEjections(int value) {
numEjections_ = value;
onChanged();
return this;
}
/**
*
* If ``action`` is ``eject``, specifies the number of times the host has been ejected (local to
* that Envoy and gets reset if the host gets removed from the upstream cluster for any reason and
* then re-added).
*
*
* uint32 num_ejections = 7;
* @return This builder for chaining.
*/
public Builder clearNumEjections() {
numEjections_ = 0;
onChanged();
return this;
}
private boolean enforced_ ;
/**
*
* If ``action`` is ``eject``, specifies if the ejection was enforced. ``true`` means the host was
* ejected. ``false`` means the event was logged but the host was not actually ejected.
*
* If ``action`` is ``eject``, specifies if the ejection was enforced. ``true`` means the host was
* ejected. ``false`` means the event was logged but the host was not actually ejected.
*
*
* bool enforced = 8;
* @param value The enforced to set.
* @return This builder for chaining.
*/
public Builder setEnforced(boolean value) {
enforced_ = value;
onChanged();
return this;
}
/**
*
* If ``action`` is ``eject``, specifies if the ejection was enforced. ``true`` means the host was
* ejected. ``false`` means the event was logged but the host was not actually ejected.
*