Description
I'd like to be able to configure the interceptor to prevent specific incoming requests from triggering a scaling event. Examples of these types of requests would be health checks or requests for metrics.
Use-Case
My interceptor fleet is fronted by a load balancer that makes periodic health check requests to the /healthz
path. In this situation, I want these requests to check if the interceptors are healthy, not necessarily the backend application. Therefore, the backend application should not scale.
Specification
There should be optional configuration to instruct the interceptor to ignore certain classes of requests. I believe this should be a different CRD, as ignore configuration should be orthogonal to scaling configuration. Such a CRD might look similar to the below:
kind: HTTPIgnoreRule
apiVersion: http.keda.sh/v1alpha1
metadata:
name: healthz-path
spec:
paths:
- /healthz*
This rule would ignore all paths that match the pattern (perhaps one that matches the one defined in filepath.Match
) across all requests. Importantly, this ignore rule would match all requests across all hosts. The CRD should support specification of hosts or host patterns via a spec.hosts
field so that HTTPIgnoreRule
s have a many-to-many relationship to HTTPScaledObject
s.
There should also be a spec.headers
field that contains matching rules for incoming request headers:
kind: HTTPIgnoreRule
apiVersion: http.keda.sh/v1alpha1
metadata:
name: custom-value-header
spec:
headers:
- X-Custom-Value: abc*xyz
This rule would match all incoming requests that have an X-Custom-Value
header that starts with abc
and ends with xyz
.
If both of these rules were submitted to the cluster at once, only requests that match the union of these two rules would be ignored. In other words, for any given host, all applicable rules are AND
ed together to match against requests.
Metadata
Metadata
Assignees
Type
Projects
Status