{
  "description": "KongIngress is the Schema for the kongingresses API.\nDeprecated: Use annotations and KongUpstreamPolicy instead. See https://developer.konghq.com/kubernetes-ingress-controller/migrate/kongingress/",
  "properties": {
    "apiVersion": {
      "description": "APIVersion defines the versioned schema of this representation of an object.\nServers should convert recognized schemas to the latest internal value, and\nmay reject unrecognized values.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources",
      "type": "string"
    },
    "kind": {
      "description": "Kind is a string value representing the REST resource this object represents.\nServers may infer this from the endpoint the client submits requests to.\nCannot be updated.\nIn CamelCase.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
      "type": "string"
    },
    "metadata": {
      "type": "object"
    },
    "proxy": {
      "description": "Proxy defines additional connection options for the routes to be configured in the\nKong Gateway, e.g. `connection_timeout`, `retries`, etc.",
      "properties": {
        "connect_timeout": {
          "description": "The timeout in milliseconds for\testablishing a connection to the upstream server.\nDeprecated: use Service's \"konghq.com/connect-timeout\" annotation instead.",
          "minimum": 0,
          "type": "integer"
        },
        "path": {
          "description": "(optional) The path to be used in requests to the upstream server.\nDeprecated: use Service's \"konghq.com/path\" annotation instead.",
          "pattern": "^/.*$",
          "type": "string"
        },
        "protocol": {
          "description": "The protocol used to communicate with the upstream.\nDeprecated: use Service's \"konghq.com/protocol\" annotation instead.",
          "enum": [
            "http",
            "https",
            "grpc",
            "grpcs",
            "tcp",
            "tls",
            "udp"
          ],
          "type": "string"
        },
        "read_timeout": {
          "description": "The timeout in milliseconds between two successive read operations\nfor transmitting a request to the upstream server.\nDeprecated: use Service's \"konghq.com/read-timeout\" annotation instead.",
          "minimum": 0,
          "type": "integer"
        },
        "retries": {
          "description": "The number of retries to execute upon failure to proxy.\nDeprecated: use Service's \"konghq.com/retries\" annotation instead.",
          "minimum": 0,
          "type": "integer"
        },
        "write_timeout": {
          "description": "The timeout in milliseconds between two successive write operations\nfor transmitting a request to the upstream server.\nDeprecated: use Service's \"konghq.com/write-timeout\" annotation instead.",
          "minimum": 0,
          "type": "integer"
        }
      },
      "type": "object",
      "additionalProperties": false
    },
    "route": {
      "description": "Route define rules to match client requests.\nEach Route is associated with a Service,\nand a Service may have multiple Routes associated to it.",
      "properties": {
        "headers": {
          "additionalProperties": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "description": "Headers contains one or more lists of values indexed by header name\nthat will cause this Route to match if present in the request.\nThe Host header cannot be used with this attribute.\nDeprecated: use Ingress' \"konghq.com/headers\" annotation instead.",
          "type": "object"
        },
        "https_redirect_status_code": {
          "description": "HTTPSRedirectStatusCode is the status code Kong responds with\nwhen all properties of a Route match except the protocol.\nDeprecated: use Ingress' \"ingress.kubernetes.io/force-ssl-redirect\" or\n\"konghq.com/https-redirect-status-code\" annotations instead.",
          "type": "integer"
        },
        "methods": {
          "description": "Methods is a list of HTTP methods that match this Route.\nDeprecated: use Ingress' \"konghq.com/methods\" annotation instead.",
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "path_handling": {
          "description": "PathHandling controls how the Service path, Route path and requested path\nare combined when sending a request to the upstream.\nDeprecated: use Ingress' \"konghq.com/path-handling\" annotation instead.",
          "enum": [
            "v0",
            "v1"
          ],
          "type": "string"
        },
        "preserve_host": {
          "description": "PreserveHost sets When matching a Route via one of the hosts domain names,\nuse the request Host header in the upstream request headers.\nIf set to false, the upstream Host header will be that of the Service\u2019s host.\nDeprecated: use Ingress' \"konghq.com/preserve-host\" annotation instead.",
          "type": "boolean"
        },
        "protocols": {
          "description": "Protocols is an array of the protocols this Route should allow.\nDeprecated: use Ingress' \"konghq.com/protocols\" annotation instead.",
          "items": {
            "description": "KongProtocol is a valid Kong protocol.\nThis alias is necessary to deal with https://github.com/kubernetes-sigs/controller-tools/issues/342",
            "enum": [
              "http",
              "https",
              "grpc",
              "grpcs",
              "tcp",
              "tls",
              "udp"
            ],
            "type": "string"
          },
          "type": "array"
        },
        "regex_priority": {
          "description": "RegexPriority is a number used to choose which route resolves a given request\nwhen several routes match it using regexes simultaneously.\nDeprecated: use Ingress' \"konghq.com/regex-priority\" annotation instead.",
          "type": "integer"
        },
        "request_buffering": {
          "description": "RequestBuffering sets whether to enable request body buffering or not.\nDeprecated: use Ingress' \"konghq.com/request-buffering\" annotation instead.",
          "type": "boolean"
        },
        "response_buffering": {
          "description": "ResponseBuffering sets whether to enable response body buffering or not.\nDeprecated: use Ingress' \"konghq.com/response-buffering\" annotation instead.",
          "type": "boolean"
        },
        "snis": {
          "description": "SNIs is a list of SNIs that match this Route when using stream routing.\nDeprecated: use Ingress' \"konghq.com/snis\" annotation instead.",
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "strip_path": {
          "description": "StripPath sets When matching a Route via one of the paths\nstrip the matching prefix from the upstream request URL.\nDeprecated: use Ingress' \"konghq.com/strip-path\" annotation instead.",
          "type": "boolean"
        }
      },
      "type": "object",
      "additionalProperties": false
    },
    "upstream": {
      "description": "Upstream represents a virtual hostname and can be used to loadbalance\nincoming requests over multiple targets (e.g. Kubernetes `Services` can\nbe a target, OR `Endpoints` can be targets).",
      "properties": {
        "algorithm": {
          "description": "Algorithm is the load balancing algorithm to use.\nAccepted values are: \"round-robin\", \"consistent-hashing\", \"least-connections\", \"latency\".",
          "enum": [
            "round-robin",
            "consistent-hashing",
            "least-connections",
            "latency"
          ],
          "type": "string"
        },
        "hash_fallback": {
          "description": "HashFallback defines What to use as hashing input\nif the primary hash_on does not return a hash.\nAccepted values are: \"none\", \"consumer\", \"ip\", \"header\", \"cookie\".",
          "type": "string"
        },
        "hash_fallback_header": {
          "description": "HashFallbackHeader is the header name to take the value from as hash input.\nOnly required when \"hash_fallback\" is set to \"header\".",
          "type": "string"
        },
        "hash_fallback_query_arg": {
          "description": "HashFallbackQueryArg is the \"hash_fallback\" version of HashOnQueryArg.",
          "type": "string"
        },
        "hash_fallback_uri_capture": {
          "description": "HashFallbackURICapture is the \"hash_fallback\" version of HashOnURICapture.",
          "type": "string"
        },
        "hash_on": {
          "description": "HashOn defines what to use as hashing input.\nAccepted values are: \"none\", \"consumer\", \"ip\", \"header\", \"cookie\", \"path\", \"query_arg\", \"uri_capture\".",
          "type": "string"
        },
        "hash_on_cookie": {
          "description": "The cookie name to take the value from as hash input.\nOnly required when \"hash_on\" or \"hash_fallback\" is set to \"cookie\".",
          "type": "string"
        },
        "hash_on_cookie_path": {
          "description": "The cookie path to set in the response headers.\nOnly required when \"hash_on\" or \"hash_fallback\" is set to \"cookie\".",
          "type": "string"
        },
        "hash_on_header": {
          "description": "HashOnHeader defines the header name to take the value from as hash input.\nOnly required when \"hash_on\" is set to \"header\".",
          "type": "string"
        },
        "hash_on_query_arg": {
          "description": "HashOnQueryArg is the query string parameter whose value is the hash input when \"hash_on\" is set to \"query_arg\".",
          "type": "string"
        },
        "hash_on_uri_capture": {
          "description": "HashOnURICapture is the name of the capture group whose value is the hash input when \"hash_on\" is set to\n\"uri_capture\".",
          "type": "string"
        },
        "healthchecks": {
          "description": "Healthchecks defines the health check configurations in Kong.",
          "properties": {
            "active": {
              "description": "ActiveHealthcheck configures active health check probing.",
              "properties": {
                "concurrency": {
                  "minimum": 1,
                  "type": "integer"
                },
                "headers": {
                  "additionalProperties": {
                    "items": {
                      "type": "string"
                    },
                    "type": "array"
                  },
                  "type": "object"
                },
                "healthy": {
                  "description": "Healthy configures thresholds and HTTP status codes\nto mark targets healthy for an upstream.",
                  "properties": {
                    "http_statuses": {
                      "items": {
                        "type": "integer"
                      },
                      "type": "array"
                    },
                    "interval": {
                      "minimum": 0,
                      "type": "integer"
                    },
                    "successes": {
                      "minimum": 0,
                      "type": "integer"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                },
                "http_path": {
                  "pattern": "^/.*$",
                  "type": "string"
                },
                "https_sni": {
                  "type": "string"
                },
                "https_verify_certificate": {
                  "type": "boolean"
                },
                "timeout": {
                  "minimum": 0,
                  "type": "integer"
                },
                "type": {
                  "type": "string"
                },
                "unhealthy": {
                  "description": "Unhealthy configures thresholds and HTTP status codes\nto mark targets unhealthy.",
                  "properties": {
                    "http_failures": {
                      "minimum": 0,
                      "type": "integer"
                    },
                    "http_statuses": {
                      "items": {
                        "type": "integer"
                      },
                      "type": "array"
                    },
                    "interval": {
                      "minimum": 0,
                      "type": "integer"
                    },
                    "tcp_failures": {
                      "minimum": 0,
                      "type": "integer"
                    },
                    "timeouts": {
                      "minimum": 0,
                      "type": "integer"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                }
              },
              "type": "object",
              "additionalProperties": false
            },
            "passive": {
              "description": "PassiveHealthcheck configures passive checks around\npassive health checks.",
              "properties": {
                "healthy": {
                  "description": "Healthy configures thresholds and HTTP status codes\nto mark targets healthy for an upstream.",
                  "properties": {
                    "http_statuses": {
                      "items": {
                        "type": "integer"
                      },
                      "type": "array"
                    },
                    "interval": {
                      "minimum": 0,
                      "type": "integer"
                    },
                    "successes": {
                      "minimum": 0,
                      "type": "integer"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                },
                "type": {
                  "type": "string"
                },
                "unhealthy": {
                  "description": "Unhealthy configures thresholds and HTTP status codes\nto mark targets unhealthy.",
                  "properties": {
                    "http_failures": {
                      "minimum": 0,
                      "type": "integer"
                    },
                    "http_statuses": {
                      "items": {
                        "type": "integer"
                      },
                      "type": "array"
                    },
                    "interval": {
                      "minimum": 0,
                      "type": "integer"
                    },
                    "tcp_failures": {
                      "minimum": 0,
                      "type": "integer"
                    },
                    "timeouts": {
                      "minimum": 0,
                      "type": "integer"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                }
              },
              "type": "object",
              "additionalProperties": false
            },
            "threshold": {
              "type": "number"
            }
          },
          "type": "object",
          "additionalProperties": false
        },
        "host_header": {
          "description": "HostHeader is The hostname to be used as Host header\nwhen proxying requests through Kong.",
          "type": "string"
        },
        "slots": {
          "description": "Slots is the number of slots in the load balancer algorithm.",
          "minimum": 10,
          "type": "integer"
        }
      },
      "type": "object",
      "additionalProperties": false
    }
  },
  "type": "object",
  "x-kubernetes-validations": [
    {
      "message": "'proxy' field is no longer supported, use Service's annotations instead",
      "rule": "!has(self.proxy)"
    },
    {
      "message": "'route' field is no longer supported, use Ingress' annotations instead",
      "rule": "!has(self.route)"
    }
  ]
}
