본문으로 바로가기 본문 바로가기
WIKI 기술 지식 베이스

메시 서킷브레이커 정책 설정 레퍼런스

원문 보기 위키 갱신

메시 서킷브레이커 정책 설정 레퍼런스 (MeshCircuitBreakers Policy Configuration Reference)

이 문서는 Kong Mesh에서 서킷브레이커 동작을 제어하는 MeshCircuitBreaker 정책 리소스의 설정 스키마를 정리한 레퍼런스예요. 어떤 클라이언트 트래픽에 규칙을 적용할지 정하는 from 구조부터, maxConnections·maxPendingRequests·maxRetries 같은 연결 제한 항목까지 하나씩 짚어봐요. 또한 장애가 있는 호스트를 건강한 로드밸런싱 대상에서 자동으로 빼내는 outlier detection 설정도 함께 다뤄요. 서비스 간 트래픽이 불안정할 때 서킷브레이커로 장애 확산을 막고 싶다면 이 문서를 참고하면 돼요

출처: 문서

본문

구성

{
  "description": "Spec is the specification of the Kuma MeshCircuitBreaker resource.",
  "properties": {
    "from": {
      "description": "From list makes a match between clients and corresponding configurations",
      "items": {
        "properties": {
          "default": {
            "description": "Default is a configuration specific to the group of destinations\nreferenced in 'targetRef'",
            "properties": {
              "connectionLimits": {
                "description": "ConnectionLimits contains configuration of each circuit breaking limit,\nwhich when exceeded makes the circuit breaker to become open (no traffic\nis allowed like no current is allowed in the circuits when physical\ncircuit breaker ir open)",
                "properties": {
                  "maxConnectionPools": {
                    "description": "The maximum number of connection pools per cluster that are concurrently\nsupported at once. Set this for clusters which create a large number of\nconnection pools.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxConnections": {
                    "description": "The maximum number of connections allowed to be made to the upstream\ncluster.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxPendingRequests": {
                    "description": "The maximum number of pending requests that are allowed to the upstream\ncluster. This limit is applied as a connection limit for non-HTTP\ntraffic.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxRequests": {
                    "description": "The maximum number of parallel requests that are allowed to be made\nto the upstream cluster. This limit does not apply to non-HTTP traffic.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxRetries": {
                    "description": "The maximum number of parallel retries that will be allowed to\nthe upstream cluster.",
                    "format": "int32",
                    "type": "integer"
                  }
                },
                "type": "object"
              },
              "outlierDetection": {
                "description": "OutlierDetection contains the configuration of the process of dynamically\ndetermining whether some number of hosts in an upstream cluster are\nperforming unlike the others and removing them from the healthy load\nbalancing set. Performance might be along different axes such as\nconsecutive failures, temporal success rate, temporal latency, etc.\nOutlier detection is a form of passive health checking.",
                "properties": {
                  "baseEjectionTime": {
                    "description": "The base time that a host is ejected for. The real time is equal to\nthe base time multiplied by the number of times the host has been\nejected.",
                    "type": "string"
                  },
                  "detectors": {
                    "description": "Contains configuration for supported outlier detectors",
                    "properties": {
                      "failurePercentage": {
                        "description": "Failure Percentage based outlier detection functions similarly to success\nrate detection, in that it relies on success rate data from each host in\na cluster. However, rather than compare those values to the mean success\nrate of the cluster as a whole, they are compared to a flat\nuser-configured threshold. This threshold is configured via the\noutlierDetection.failurePercentageThreshold field.\nThe other configuration fields for failure percentage based detection are\nsimilar to the fields for success rate detection. As with success rate\ndetection, detection will not be performed for a host if its request\nvolume over the aggregation interval is less than the\noutlierDetection.detectors.failurePercentage.requestVolume value.\nDetection also will not be performed for a cluster if the number of hosts\nwith the minimum required request volume in an interval is less than the\noutlierDetection.detectors.failurePercentage.minimumHosts value.",
                        "properties": {
                          "minimumHosts": {
                            "description": "The minimum number of hosts in a cluster in order to perform failure\npercentage-based ejection. If the total number of hosts in the cluster is\nless than this value, failure percentage-based ejection will not be\nperformed.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "requestVolume": {
                            "description": "The minimum number of total requests that must be collected in one\ninterval (as defined by the interval duration above) to perform failure\npercentage-based ejection for this host. If the volume is lower than this\nsetting, failure percentage-based ejection will not be performed for this\nhost.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "threshold": {
                            "description": "The failure percentage to use when determining failure percentage-based\noutlier detection. If the failure percentage of a given host is greater\nthan or equal to this value, it will be ejected.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "gatewayFailures": {
                        "description": "In the default mode (outlierDetection.splitExternalLocalOriginErrors is\nfalse) this detection type takes into account a subset of 5xx errors,\ncalled \"gateway errors\" (502, 503 or 504 status code) and local origin\nfailures, such as timeout, TCP reset etc.\nIn split mode (outlierDetection.splitExternalLocalOriginErrors is true)\nthis detection type takes into account a subset of 5xx errors, called\n\"gateway errors\" (502, 503 or 504 status code) and is supported only by\nthe http router.",
                        "properties": {
                          "consecutive": {
                            "description": "The number of consecutive gateway failures (502, 503, 504 status codes)\nbefore a consecutive gateway failure ejection occurs.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "localOriginFailures": {
                        "description": "This detection type is enabled only when\noutlierDetection.splitExternalLocalOriginErrors is true and takes into\naccount only locally originated errors (timeout, reset, etc).\nIf Envoy repeatedly cannot connect to an upstream host or communication\nwith the upstream host is repeatedly interrupted, it will be ejected.\nVarious locally originated problems are detected: timeout, TCP reset,\nICMP errors, etc. This detection type is supported by http router and\ntcp proxy.",
                        "properties": {
                          "consecutive": {
                            "description": "The number of consecutive locally originated failures before ejection\noccurs. Parameter takes effect only when splitExternalAndLocalErrors\nis set to true.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "successRate": {
                        "description": "Success Rate based outlier detection aggregates success rate data from\nevery host in a cluster. Then at given intervals ejects hosts based on\nstatistical outlier detection. Success Rate outlier detection will not be\ncalculated for a host if its request volume over the aggregation interval\nis less than the outlierDetection.detectors.successRate.requestVolume\nvalue.\nMoreover, detection will not be performed for a cluster if the number of\nhosts with the minimum required request volume in an interval is less\nthan the outlierDetection.detectors.successRate.minimumHosts value.\nIn the default configuration mode\n(outlierDetection.splitExternalLocalOriginErrors is false) this detection\ntype takes into account all types of errors: locally and externally\noriginated.\nIn split mode (outlierDetection.splitExternalLocalOriginErrors is true),\nlocally originated errors and externally originated (transaction) errors\nare counted and treated separately.",
                        "properties": {
                          "minimumHosts": {
                            "description": "The number of hosts in a cluster that must have enough request volume to\ndetect success rate outliers. If the number of hosts is less than this\nsetting, outlier detection via success rate statistics is not performed\nfor any host in the cluster.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "requestVolume": {
                            "description": "The minimum number of total requests that must be collected in one\ninterval (as defined by the interval duration configured in\noutlierDetection section) to include this host in success rate based\noutlier detection. If the volume is lower than this setting, outlier\ndetection via success rate statistics is not performed for that host.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "standardDeviationFactor": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "string"
                              }
                            ],
                            "description": "This factor is used to determine the ejection threshold for success rate\noutlier ejection. The ejection threshold is the difference between\nthe mean success rate, and the product of this factor and the standard\ndeviation of the mean success rate: mean - (standard_deviation *\nsuccess_rate_standard_deviation_factor).\nEither int or decimal represented as string.",
                            "x-kubernetes-int-or-string": true
                          }
                        },
                        "type": "object"
                      },
                      "totalFailures": {
                        "description": "In the default mode (outlierDetection.splitExternalAndLocalErrors is\nfalse) this detection type takes into account all generated errors:\nlocally originated and externally originated (transaction) errors.\nIn split mode (outlierDetection.splitExternalLocalOriginErrors is true)\nthis detection type takes into account only externally originated\n(transaction) errors, ignoring locally originated errors.\nIf an upstream host is an HTTP-server, only 5xx types of error are taken\ninto account (see Consecutive Gateway Failure for exceptions).\nProperly formatted responses, even when they carry an operational error\n(like index not found, access denied) are not taken into account.",
                        "properties": {
                          "consecutive": {
                            "description": "The number of consecutive server-side error responses (for HTTP traffic,\n5xx responses; for TCP traffic, connection failures; for Redis, failure\nto respond PONG; etc.) before a consecutive total failure ejection\noccurs.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      }
                    },
                    "type": "object"
                  },
                  "disabled": {
                    "description": "When set to true, outlierDetection configuration won't take any effect",
                    "type": "boolean"
                  },
                  "healthyPanicThreshold": {
                    "anyOf": [
                      {
                        "type": "integer"
                      },
                      {
                        "type": "string"
                      }
                    ],
                    "description": "Allows to configure panic threshold for Envoy cluster. If not specified,\nthe default is 50%. To disable panic mode, set to 0%.\nEither int or decimal represented as string.",
                    "x-kubernetes-int-or-string": true
                  },
                  "interval": {
                    "description": "The time interval between ejection analysis sweeps. This can result in\nboth new ejections and hosts being returned to service.",
                    "type": "string"
                  },
                  "maxEjectionPercent": {
                    "description": "The maximum % of an upstream cluster that can be ejected due to outlier\ndetection. Defaults to 10% but will eject at least one host regardless of\nthe value.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "splitExternalAndLocalErrors": {
                    "description": "Determines whether to distinguish local origin failures from external\nerrors. If set to true the following configuration parameters are taken\ninto account: detectors.localOriginFailures.consecutive",
                    "type": "boolean"
                  }
                },
                "type": "object"
              }
            },
            "type": "object"
          },
          "targetRef": {
            "description": "TargetRef is a reference to the resource that represents a group of\ndestinations.",
            "properties": {
              "kind": {
                "description": "Kind of the referenced resource",
                "enum": [
                  "Mesh",
                  "MeshSubset",
                  "MeshGateway",
                  "MeshService",
                  "MeshExternalService",
                  "MeshMultiZoneService",
                  "MeshServiceSubset",
                  "MeshHTTPRoute",
                  "Dataplane"
                ],
                "type": "string"
              },
              "labels": {
                "additionalProperties": {
                  "type": "string"
                },
                "description": "Labels are used to select group of MeshServices that match labels. Either Labels or\nName and Namespace can be used.",
                "type": "object"
              },
              "mesh": {
                "description": "Mesh is reserved for future use to identify cross mesh resources.",
                "type": "string"
              },
              "name": {
                "description": "Name of the referenced resource. Can only be used with kinds: `MeshService`,\n`MeshServiceSubset` and `MeshGatewayRoute`",
                "type": "string"
              },
              "namespace": {
                "description": "Namespace specifies the namespace of target resource. If empty only resources in policy namespace\nwill be targeted.",
                "type": "string"
              },
              "proxyTypes": {
                "description": "ProxyTypes specifies the data plane types that are subject to the policy. When not specified,\nall data plane types are targeted by the policy.",
                "items": {
                  "enum": [
                    "Sidecar",
                    "Gateway"
                  ],
                  "type": "string"
                },
                "type": "array"
              },
              "sectionName": {
                "description": "SectionName is used to target specific section of resource.\nFor example, you can target port from MeshService.ports[] by its name. Only traffic to this port will be affected.",
                "type": "string"
              },
              "tags": {
                "additionalProperties": {
                  "type": "string"
                },
                "description": "Tags used to select a subset of proxies by tags. Can only be used with kinds\n`MeshSubset` and `MeshServiceSubset`",
                "type": "object"
              }
            },
            "required": [
              "kind"
            ],
            "type": "object"
          }
        },
        "required": [
          "targetRef"
        ],
        "type": "object"
      },
      "type": "array"
    },
    "rules": {
      "description": "Rules defines inbound circuit breaker configurations. Currently limited to\nselecting all inbound traffic, as L7 matching is not yet implemented.",
      "items": {
        "properties": {
          "default": {
            "description": "Default contains configuration of the inbound circuit breaker",
            "properties": {
              "connectionLimits": {
                "description": "ConnectionLimits contains configuration of each circuit breaking limit,\nwhich when exceeded makes the circuit breaker to become open (no traffic\nis allowed like no current is allowed in the circuits when physical\ncircuit breaker ir open)",
                "properties": {
                  "maxConnectionPools": {
                    "description": "The maximum number of connection pools per cluster that are concurrently\nsupported at once. Set this for clusters which create a large number of\nconnection pools.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxConnections": {
                    "description": "The maximum number of connections allowed to be made to the upstream\ncluster.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxPendingRequests": {
                    "description": "The maximum number of pending requests that are allowed to the upstream\ncluster. This limit is applied as a connection limit for non-HTTP\ntraffic.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxRequests": {
                    "description": "The maximum number of parallel requests that are allowed to be made\nto the upstream cluster. This limit does not apply to non-HTTP traffic.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxRetries": {
                    "description": "The maximum number of parallel retries that will be allowed to\nthe upstream cluster.",
                    "format": "int32",
                    "type": "integer"
                  }
                },
                "type": "object"
              },
              "outlierDetection": {
                "description": "OutlierDetection contains the configuration of the process of dynamically\ndetermining whether some number of hosts in an upstream cluster are\nperforming unlike the others and removing them from the healthy load\nbalancing set. Performance might be along different axes such as\nconsecutive failures, temporal success rate, temporal latency, etc.\nOutlier detection is a form of passive health checking.",
                "properties": {
                  "baseEjectionTime": {
                    "description": "The base time that a host is ejected for. The real time is equal to\nthe base time multiplied by the number of times the host has been\nejected.",
                    "type": "string"
                  },
                  "detectors": {
                    "description": "Contains configuration for supported outlier detectors",
                    "properties": {
                      "failurePercentage": {
                        "description": "Failure Percentage based outlier detection functions similarly to success\nrate detection, in that it relies on success rate data from each host in\na cluster. However, rather than compare those values to the mean success\nrate of the cluster as a whole, they are compared to a flat\nuser-configured threshold. This threshold is configured via the\noutlierDetection.failurePercentageThreshold field.\nThe other configuration fields for failure percentage based detection are\nsimilar to the fields for success rate detection. As with success rate\ndetection, detection will not be performed for a host if its request\nvolume over the aggregation interval is less than the\noutlierDetection.detectors.failurePercentage.requestVolume value.\nDetection also will not be performed for a cluster if the number of hosts\nwith the minimum required request volume in an interval is less than the\noutlierDetection.detectors.failurePercentage.minimumHosts value.",
                        "properties": {
                          "minimumHosts": {
                            "description": "The minimum number of hosts in a cluster in order to perform failure\npercentage-based ejection. If the total number of hosts in the cluster is\nless than this value, failure percentage-based ejection will not be\nperformed.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "requestVolume": {
                            "description": "The minimum number of total requests that must be collected in one\ninterval (as defined by the interval duration above) to perform failure\npercentage-based ejection for this host. If the volume is lower than this\nsetting, failure percentage-based ejection will not be performed for this\nhost.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "threshold": {
                            "description": "The failure percentage to use when determining failure percentage-based\noutlier detection. If the failure percentage of a given host is greater\nthan or equal to this value, it will be ejected.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "gatewayFailures": {
                        "description": "In the default mode (outlierDetection.splitExternalLocalOriginErrors is\nfalse) this detection type takes into account a subset of 5xx errors,\ncalled \"gateway errors\" (502, 503 or 504 status code) and local origin\nfailures, such as timeout, TCP reset etc.\nIn split mode (outlierDetection.splitExternalLocalOriginErrors is true)\nthis detection type takes into account a subset of 5xx errors, called\n\"gateway errors\" (502, 503 or 504 status code) and is supported only by\nthe http router.",
                        "properties": {
                          "consecutive": {
                            "description": "The number of consecutive gateway failures (502, 503, 504 status codes)\nbefore a consecutive gateway failure ejection occurs.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "localOriginFailures": {
                        "description": "This detection type is enabled only when\noutlierDetection.splitExternalLocalOriginErrors is true and takes into\naccount only locally originated errors (timeout, reset, etc).\nIf Envoy repeatedly cannot connect to an upstream host or communication\nwith the upstream host is repeatedly interrupted, it will be ejected.\nVarious locally originated problems are detected: timeout, TCP reset,\nICMP errors, etc. This detection type is supported by http router and\ntcp proxy.",
                        "properties": {
                          "consecutive": {
                            "description": "The number of consecutive locally originated failures before ejection\noccurs. Parameter takes effect only when splitExternalAndLocalErrors\nis set to true.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "successRate": {
                        "description": "Success Rate based outlier detection aggregates success rate data from\nevery host in a cluster. Then at given intervals ejects hosts based on\nstatistical outlier detection. Success Rate outlier detection will not be\ncalculated for a host if its request volume over the aggregation interval\nis less than the outlierDetection.detectors.successRate.requestVolume\nvalue.\nMoreover, detection will not be performed for a cluster if the number of\nhosts with the minimum required request volume in an interval is less\nthan the outlierDetection.detectors.successRate.minimumHosts value.\nIn the default configuration mode\n(outlierDetection.splitExternalLocalOriginErrors is false) this detection\ntype takes into account all types of errors: locally and externally\noriginated.\nIn split mode (outlierDetection.splitExternalLocalOriginErrors is true),\nlocally originated errors and externally originated (transaction) errors\nare counted and treated separately.",
                        "properties": {
                          "minimumHosts": {
                            "description": "The number of hosts in a cluster that must have enough request volume to\ndetect success rate outliers. If the number of hosts is less than this\nsetting, outlier detection via success rate statistics is not performed\nfor any host in the cluster.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "requestVolume": {
                            "description": "The minimum number of total requests that must be collected in one\ninterval (as defined by the interval duration configured in\noutlierDetection section) to include this host in success rate based\noutlier detection. If the volume is lower than this setting, outlier\ndetection via success rate statistics is not performed for that host.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "standardDeviationFactor": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "string"
                              }
                            ],
                            "description": "This factor is used to determine the ejection threshold for success rate\noutlier ejection. The ejection threshold is the difference between\nthe mean success rate, and the product of this factor and the standard\ndeviation of the mean success rate: mean - (standard_deviation *\nsuccess_rate_standard_deviation_factor).\nEither int or decimal represented as string.",
                            "x-kubernetes-int-or-string": true
                          }
                        },
                        "type": "object"
                      },
                      "totalFailures": {
                        "description": "In the default mode (outlierDetection.splitExternalAndLocalErrors is\nfalse) this detection type takes into account all generated errors:\nlocally originated and externally originated (transaction) errors.\nIn split mode (outlierDetection.splitExternalLocalOriginErrors is true)\nthis detection type takes into account only externally originated\n(transaction) errors, ignoring locally originated errors.\nIf an upstream host is an HTTP-server, only 5xx types of error are taken\ninto account (see Consecutive Gateway Failure for exceptions).\nProperly formatted responses, even when they carry an operational error\n(like index not found, access denied) are not taken into account.",
                        "properties": {
                          "consecutive": {
                            "description": "The number of consecutive server-side error responses (for HTTP traffic,\n5xx responses; for TCP traffic, connection failures; for Redis, failure\nto respond PONG; etc.) before a consecutive total failure ejection\noccurs.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      }
                    },
                    "type": "object"
                  },
                  "disabled": {
                    "description": "When set to true, outlierDetection configuration won't take any effect",
                    "type": "boolean"
                  },
                  "healthyPanicThreshold": {
                    "anyOf": [
                      {
                        "type": "integer"
                      },
                      {
                        "type": "string"
                      }
                    ],
                    "description": "Allows to configure panic threshold for Envoy cluster. If not specified,\nthe default is 50%. To disable panic mode, set to 0%.\nEither int or decimal represented as string.",
                    "x-kubernetes-int-or-string": true
                  },
                  "interval": {
                    "description": "The time interval between ejection analysis sweeps. This can result in\nboth new ejections and hosts being returned to service.",
                    "type": "string"
                  },
                  "maxEjectionPercent": {
                    "description": "The maximum % of an upstream cluster that can be ejected due to outlier\ndetection. Defaults to 10% but will eject at least one host regardless of\nthe value.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "splitExternalAndLocalErrors": {
                    "description": "Determines whether to distinguish local origin failures from external\nerrors. If set to true the following configuration parameters are taken\ninto account: detectors.localOriginFailures.consecutive",
                    "type": "boolean"
                  }
                },
                "type": "object"
              }
            },
            "type": "object"
          }
        },
        "type": "object"
      },
      "type": "array"
    },
    "targetRef": {
      "description": "TargetRef is a reference to the resource the policy takes an effect on.\nThe resource could be either a real store object or virtual resource\ndefined in place.",
      "properties": {
        "kind": {
          "description": "Kind of the referenced resource",
          "enum": [
            "Mesh",
            "MeshSubset",
            "MeshGateway",
            "MeshService",
            "MeshExternalService",
            "MeshMultiZoneService",
            "MeshServiceSubset",
            "MeshHTTPRoute",
            "Dataplane"
          ],
          "type": "string"
        },
        "labels": {
          "additionalProperties": {
            "type": "string"
          },
          "description": "Labels are used to select group of MeshServices that match labels. Either Labels or\nName and Namespace can be used.",
          "type": "object"
        },
        "mesh": {
          "description": "Mesh is reserved for future use to identify cross mesh resources.",
          "type": "string"
        },
        "name": {
          "description": "Name of the referenced resource. Can only be used with kinds: `MeshService`,\n`MeshServiceSubset` and `MeshGatewayRoute`",
          "type": "string"
        },
        "namespace": {
          "description": "Namespace specifies the namespace of target resource. If empty only resources in policy namespace\nwill be targeted.",
          "type": "string"
        },
        "proxyTypes": {
          "description": "ProxyTypes specifies the data plane types that are subject to the policy. When not specified,\nall data plane types are targeted by the policy.",
          "items": {
            "enum": [
              "Sidecar",
              "Gateway"
            ],
            "type": "string"
          },
          "type": "array"
        },
        "sectionName": {
          "description": "SectionName is used to target specific section of resource.\nFor example, you can target port from MeshService.ports[] by its name. Only traffic to this port will be affected.",
          "type": "string"
        },
        "tags": {
          "additionalProperties": {
            "type": "string"
          },
          "description": "Tags used to select a subset of proxies by tags. Can only be used with kinds\n`MeshSubset` and `MeshServiceSubset`",
          "type": "object"
        }
      },
      "required": [
        "kind"
      ],
      "type": "object"
    },
    "to": {
      "description": "To list makes a match between the consumed services and corresponding\nconfigurations",
      "items": {
        "properties": {
          "default": {
            "description": "Default is a configuration specific to the group of destinations\nreferenced in 'targetRef'",
            "properties": {
              "connectionLimits": {
                "description": "ConnectionLimits contains configuration of each circuit breaking limit,\nwhich when exceeded makes the circuit breaker to become open (no traffic\nis allowed like no current is allowed in the circuits when physical\ncircuit breaker ir open)",
                "properties": {
                  "maxConnectionPools": {
                    "description": "The maximum number of connection pools per cluster that are concurrently\nsupported at once. Set this for clusters which create a large number of\nconnection pools.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxConnections": {
                    "description": "The maximum number of connections allowed to be made to the upstream\ncluster.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxPendingRequests": {
                    "description": "The maximum number of pending requests that are allowed to the upstream\ncluster. This limit is applied as a connection limit for non-HTTP\ntraffic.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxRequests": {
                    "description": "The maximum number of parallel requests that are allowed to be made\nto the upstream cluster. This limit does not apply to non-HTTP traffic.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "maxRetries": {
                    "description": "The maximum number of parallel retries that will be allowed to\nthe upstream cluster.",
                    "format": "int32",
                    "type": "integer"
                  }
                },
                "type": "object"
              },
              "outlierDetection": {
                "description": "OutlierDetection contains the configuration of the process of dynamically\ndetermining whether some number of hosts in an upstream cluster are\nperforming unlike the others and removing them from the healthy load\nbalancing set. Performance might be along different axes such as\nconsecutive failures, temporal success rate, temporal latency, etc.\nOutlier detection is a form of passive health checking.",
                "properties": {
                  "baseEjectionTime": {
                    "description": "The base time that a host is ejected for. The real time is equal to\nthe base time multiplied by the number of times the host has been\nejected.",
                    "type": "string"
                  },
                  "detectors": {
                    "description": "Contains configuration for supported outlier detectors",
                    "properties": {
                      "failurePercentage": {
                        "description": "Failure Percentage based outlier detection functions similarly to success\nrate detection, in that it relies on success rate data from each host in\na cluster. However, rather than compare those values to the mean success\nrate of the cluster as a whole, they are compared to a flat\nuser-configured threshold. This threshold is configured via the\noutlierDetection.failurePercentageThreshold field.\nThe other configuration fields for failure percentage based detection are\nsimilar to the fields for success rate detection. As with success rate\ndetection, detection will not be performed for a host if its request\nvolume over the aggregation interval is less than the\noutlierDetection.detectors.failurePercentage.requestVolume value.\nDetection also will not be performed for a cluster if the number of hosts\nwith the minimum required request volume in an interval is less than the\noutlierDetection.detectors.failurePercentage.minimumHosts value.",
                        "properties": {
                          "minimumHosts": {
                            "description": "The minimum number of hosts in a cluster in order to perform failure\npercentage-based ejection. If the total number of hosts in the cluster is\nless than this value, failure percentage-based ejection will not be\nperformed.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "requestVolume": {
                            "description": "The minimum number of total requests that must be collected in one\ninterval (as defined by the interval duration above) to perform failure\npercentage-based ejection for this host. If the volume is lower than this\nsetting, failure percentage-based ejection will not be performed for this\nhost.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "threshold": {
                            "description": "The failure percentage to use when determining failure percentage-based\noutlier detection. If the failure percentage of a given host is greater\nthan or equal to this value, it will be ejected.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "gatewayFailures": {
                        "description": "In the default mode (outlierDetection.splitExternalLocalOriginErrors is\nfalse) this detection type takes into account a subset of 5xx errors,\ncalled \"gateway errors\" (502, 503 or 504 status code) and local origin\nfailures, such as timeout, TCP reset etc.\nIn split mode (outlierDetection.splitExternalLocalOriginErrors is true)\nthis detection type takes into account a subset of 5xx errors, called\n\"gateway errors\" (502, 503 or 504 status code) and is supported only by\nthe http router.",
                        "properties": {
                          "consecutive": {
                            "description": "The number of consecutive gateway failures (502, 503, 504 status codes)\nbefore a consecutive gateway failure ejection occurs.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "localOriginFailures": {
                        "description": "This detection type is enabled only when\noutlierDetection.splitExternalLocalOriginErrors is true and takes into\naccount only locally originated errors (timeout, reset, etc).\nIf Envoy repeatedly cannot connect to an upstream host or communication\nwith the upstream host is repeatedly interrupted, it will be ejected.\nVarious locally originated problems are detected: timeout, TCP reset,\nICMP errors, etc. This detection type is supported by http router and\ntcp proxy.",
                        "properties": {
                          "consecutive": {
                            "description": "The number of consecutive locally originated failures before ejection\noccurs. Parameter takes effect only when splitExternalAndLocalErrors\nis set to true.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "successRate": {
                        "description": "Success Rate based outlier detection aggregates success rate data from\nevery host in a cluster. Then at given intervals ejects hosts based on\nstatistical outlier detection. Success Rate outlier detection will not be\ncalculated for a host if its request volume over the aggregation interval\nis less than the outlierDetection.detectors.successRate.requestVolume\nvalue.\nMoreover, detection will not be performed for a cluster if the number of\nhosts with the minimum required request volume in an interval is less\nthan the outlierDetection.detectors.successRate.minimumHosts value.\nIn the default configuration mode\n(outlierDetection.splitExternalLocalOriginErrors is false) this detection\ntype takes into account all types of errors: locally and externally\noriginated.\nIn split mode (outlierDetection.splitExternalLocalOriginErrors is true),\nlocally originated errors and externally originated (transaction) errors\nare counted and treated separately.",
                        "properties": {
                          "minimumHosts": {
                            "description": "The number of hosts in a cluster that must have enough request volume to\ndetect success rate outliers. If the number of hosts is less than this\nsetting, outlier detection via success rate statistics is not performed\nfor any host in the cluster.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "requestVolume": {
                            "description": "The minimum number of total requests that must be collected in one\ninterval (as defined by the interval duration configured in\noutlierDetection section) to include this host in success rate based\noutlier detection. If the volume is lower than this setting, outlier\ndetection via success rate statistics is not performed for that host.",
                            "format": "int32",
                            "type": "integer"
                          },
                          "standardDeviationFactor": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "string"
                              }
                            ],
                            "description": "This factor is used to determine the ejection threshold for success rate\noutlier ejection. The ejection threshold is the difference between\nthe mean success rate, and the product of this factor and the standard\ndeviation of the mean success rate: mean - (standard_deviation *\nsuccess_rate_standard_deviation_factor).\nEither int or decimal represented as string.",
                            "x-kubernetes-int-or-string": true
                          }
                        },
                        "type": "object"
                      },
                      "totalFailures": {
                        "description": "In the default mode (outlierDetection.splitExternalAndLocalErrors is\nfalse) this detection type takes into account all generated errors:\nlocally originated and externally originated (transaction) errors.\nIn split mode (outlierDetection.splitExternalLocalOriginErrors is true)\nthis detection type takes into account only externally originated\n(transaction) errors, ignoring locally originated errors.\nIf an upstream host is an HTTP-server, only 5xx types of error are taken\ninto account (see Consecutive Gateway Failure for exceptions).\nProperly formatted responses, even when they carry an operational error\n(like index not found, access denied) are not taken into account.",
                        "properties": {
                          "consecutive": {
                            "description": "The number of consecutive server-side error responses (for HTTP traffic,\n5xx responses; for TCP traffic, connection failures; for Redis, failure\nto respond PONG; etc.) before a consecutive total failure ejection\noccurs.",
                            "format": "int32",
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      }
                    },
                    "type": "object"
                  },
                  "disabled": {
                    "description": "When set to true, outlierDetection configuration won't take any effect",
                    "type": "boolean"
                  },
                  "healthyPanicThreshold": {
                    "anyOf": [
                      {
                        "type": "integer"
                      },
                      {
                        "type": "string"
                      }
                    ],
                    "description": "Allows to configure panic threshold for Envoy cluster. If not specified,\nthe default is 50%. To disable panic mode, set to 0%.\nEither int or decimal represented as string.",
                    "x-kubernetes-int-or-string": true
                  },
                  "interval": {
                    "description": "The time interval between ejection analysis sweeps. This can result in\nboth new ejections and hosts being returned to service.",
                    "type": "string"
                  },
                  "maxEjectionPercent": {
                    "description": "The maximum % of an upstream cluster that can be ejected due to outlier\ndetection. Defaults to 10% but will eject at least one host regardless of\nthe value.",
                    "format": "int32",
                    "type": "integer"
                  },
                  "splitExternalAndLocalErrors": {
                    "description": "Determines whether to distinguish local origin failures from external\nerrors. If set to true the following configuration parameters are taken\ninto account: detectors.localOriginFailures.consecutive",
                    "type": "boolean"
                  }
                },
                "type": "object"
              }
            },
            "type": "object"
          },
          "targetRef": {
            "description": "TargetRef is a reference to the resource that represents a group of\ndestinations.",
            "properties": {
              "kind": {
                "description": "Kind of the referenced resource",
                "enum": [
                  "Mesh",
                  "MeshSubset",
                  "MeshGateway",
                  "MeshService",
                  "MeshExternalService",
                  "MeshMultiZoneService",
                  "MeshServiceSubset",
                  "MeshHTTPRoute",
                  "Dataplane"
                ],
                "type": "string"
              },
              "labels": {
                "additionalProperties": {
                  "type": "string"
                },
                "description": "Labels are used to select group of MeshServices that match labels. Either Labels or\nName and Namespace can be used.",
                "type": "object"
              },
              "mesh": {
                "description": "Mesh is reserved for future use to identify cross mesh resources.",
                "type": "string"
              },
              "name": {
                "description": "Name of the referenced resource. Can only be used with kinds: `MeshService`,\n`MeshServiceSubset` and `MeshGatewayRoute`",
                "type": "string"
              },
              "namespace": {
                "description": "Namespace specifies the namespace of target resource. If empty only resources in policy namespace\nwill be targeted.",
                "type": "string"
              },
              "proxyTypes": {
                "description": "ProxyTypes specifies the data plane types that are subject to the policy. When not specified,\nall data plane types are targeted by the policy.",
                "items": {
                  "enum": [
                    "Sidecar",
                    "Gateway"
                  ],
                  "type": "string"
                },
                "type": "array"
              },
              "sectionName": {
                "description": "SectionName is used to target specific section of resource.\nFor example, you can target port from MeshService.ports[] by its name. Only traffic to this port will be affected.",
                "type": "string"
              },
              "tags": {
                "additionalProperties": {
                  "type": "string"
                },
                "description": "Tags used to select a subset of proxies by tags. Can only be used with kinds\n`MeshSubset` and `MeshServiceSubset`",
                "type": "object"
              }
            },
            "required": [
              "kind"
            ],
            "type": "object"
          }
        },
        "required": [
          "targetRef"
        ],
        "type": "object"
      },
      "type": "array"
    }
  },
  "type": "object"
}

더 알아보기 (Learn more)

이 문서에는 원문에서 추출한 별도의 관련 문서 링크가 없어요.