...

Text file src/github.com/emissary-ingress/emissary/v3/api/envoy/data/cluster/v2alpha/outlier_detection_event.proto

Documentation: github.com/emissary-ingress/emissary/v3/api/envoy/data/cluster/v2alpha

     1syntax = "proto3";
     2
     3package envoy.data.cluster.v2alpha;
     4
     5import "google/protobuf/timestamp.proto";
     6import "google/protobuf/wrappers.proto";
     7
     8import "udpa/annotations/migrate.proto";
     9import "udpa/annotations/status.proto";
    10import "validate/validate.proto";
    11
    12option java_package = "io.envoyproxy.envoy.data.cluster.v2alpha";
    13option java_outer_classname = "OutlierDetectionEventProto";
    14option java_multiple_files = true;
    15option go_package = "github.com/envoyproxy/go-control-plane/envoy/data/cluster/v2alpha";
    16option (udpa.annotations.file_migrate).move_to_package = "envoy.data.cluster.v3";
    17option (udpa.annotations.file_status).package_version_status = FROZEN;
    18
    19// [#protodoc-title: Outlier detection logging events]
    20// :ref:`Outlier detection logging <arch_overview_outlier_detection_logging>`.
    21
    22// Type of ejection that took place
    23enum OutlierEjectionType {
    24  // In case upstream host returns certain number of consecutive 5xx.
    25  // If
    26  // :ref:`outlier_detection.split_external_local_origin_errors<envoy_api_field_cluster.OutlierDetection.split_external_local_origin_errors>`
    27  // is *false*, all type of errors are treated as HTTP 5xx errors.
    28  // See :ref:`Cluster outlier detection <arch_overview_outlier_detection>` documentation for
    29  // details.
    30  CONSECUTIVE_5XX = 0;
    31
    32  // In case upstream host returns certain number of consecutive gateway errors
    33  CONSECUTIVE_GATEWAY_FAILURE = 1;
    34
    35  // Runs over aggregated success rate statistics from every host in cluster
    36  // and selects hosts for which ratio of successful replies deviates from other hosts
    37  // in the cluster.
    38  // If
    39  // :ref:`outlier_detection.split_external_local_origin_errors<envoy_api_field_cluster.OutlierDetection.split_external_local_origin_errors>`
    40  // is *false*, all errors (externally and locally generated) are used to calculate success rate
    41  // statistics. See :ref:`Cluster outlier detection <arch_overview_outlier_detection>`
    42  // documentation for details.
    43  SUCCESS_RATE = 2;
    44
    45  // Consecutive local origin failures: Connection failures, resets, timeouts, etc
    46  // This type of ejection happens only when
    47  // :ref:`outlier_detection.split_external_local_origin_errors<envoy_api_field_cluster.OutlierDetection.split_external_local_origin_errors>`
    48  // is set to *true*.
    49  // See :ref:`Cluster outlier detection <arch_overview_outlier_detection>` documentation for
    50  CONSECUTIVE_LOCAL_ORIGIN_FAILURE = 3;
    51
    52  // Runs over aggregated success rate statistics for local origin failures
    53  // for all hosts in the cluster and selects hosts for which success rate deviates from other
    54  // hosts in the cluster. This type of ejection happens only when
    55  // :ref:`outlier_detection.split_external_local_origin_errors<envoy_api_field_cluster.OutlierDetection.split_external_local_origin_errors>`
    56  // is set to *true*.
    57  // See :ref:`Cluster outlier detection <arch_overview_outlier_detection>` documentation for
    58  SUCCESS_RATE_LOCAL_ORIGIN = 4;
    59
    60  // Runs over aggregated success rate statistics from every host in cluster and selects hosts for
    61  // which ratio of failed replies is above configured value.
    62  FAILURE_PERCENTAGE = 5;
    63
    64  // Runs over aggregated success rate statistics for local origin failures from every host in
    65  // cluster and selects hosts for which ratio of failed replies is above configured value.
    66  FAILURE_PERCENTAGE_LOCAL_ORIGIN = 6;
    67}
    68
    69// Represents possible action applied to upstream host
    70enum Action {
    71  // In case host was excluded from service
    72  EJECT = 0;
    73
    74  // In case host was brought back into service
    75  UNEJECT = 1;
    76}
    77
    78// [#next-free-field: 12]
    79message OutlierDetectionEvent {
    80  // In case of eject represents type of ejection that took place.
    81  OutlierEjectionType type = 1 [(validate.rules).enum = {defined_only: true}];
    82
    83  // Timestamp for event.
    84  google.protobuf.Timestamp timestamp = 2;
    85
    86  // The time in seconds since the last action (either an ejection or unejection) took place.
    87  google.protobuf.UInt64Value secs_since_last_action = 3;
    88
    89  // The :ref:`cluster <envoy_api_msg_Cluster>` that owns the ejected host.
    90  string cluster_name = 4 [(validate.rules).string = {min_bytes: 1}];
    91
    92  // The URL of the ejected host. E.g., ``tcp://1.2.3.4:80``.
    93  string upstream_url = 5 [(validate.rules).string = {min_bytes: 1}];
    94
    95  // The action that took place.
    96  Action action = 6 [(validate.rules).enum = {defined_only: true}];
    97
    98  // If ``action`` is ``eject``, specifies the number of times the host has been ejected (local to
    99  // that Envoy and gets reset if the host gets removed from the upstream cluster for any reason and
   100  // then re-added).
   101  uint32 num_ejections = 7;
   102
   103  // If ``action`` is ``eject``, specifies if the ejection was enforced. ``true`` means the host was
   104  // ejected. ``false`` means the event was logged but the host was not actually ejected.
   105  bool enforced = 8;
   106
   107  oneof event {
   108    option (validate.required) = true;
   109
   110    OutlierEjectSuccessRate eject_success_rate_event = 9;
   111
   112    OutlierEjectConsecutive eject_consecutive_event = 10;
   113
   114    OutlierEjectFailurePercentage eject_failure_percentage_event = 11;
   115  }
   116}
   117
   118message OutlierEjectSuccessRate {
   119  // Host’s success rate at the time of the ejection event on a 0-100 range.
   120  uint32 host_success_rate = 1 [(validate.rules).uint32 = {lte: 100}];
   121
   122  // Average success rate of the hosts in the cluster at the time of the ejection event on a 0-100
   123  // range.
   124  uint32 cluster_average_success_rate = 2 [(validate.rules).uint32 = {lte: 100}];
   125
   126  // Success rate ejection threshold at the time of the ejection event.
   127  uint32 cluster_success_rate_ejection_threshold = 3 [(validate.rules).uint32 = {lte: 100}];
   128}
   129
   130message OutlierEjectConsecutive {
   131}
   132
   133message OutlierEjectFailurePercentage {
   134  // Host's success rate at the time of the ejection event on a 0-100 range.
   135  uint32 host_success_rate = 1 [(validate.rules).uint32 = {lte: 100}];
   136}

View as plain text