Open arschles opened 3 years ago
Looks good; one question - How would HTTPIgnoreRule be tied back to the relevant HTTPScaledObject?
@vitarkah it may not tie back to just one specific HTTPScaledObject
but the intersection point between the two is the Host. If there were an HTTPScaledObject
issued for host: mysite.com
and an HTTPIgnoreRule
issued similar to this:
kind: HTTPIgnoreRule
apiVersion: http.keda.sh/v1alpha1
metadata:
name: healthz-path
spec:
hosts:
- *site.com
Then the ignore would apply to that HTTPScaledObject
and others ending in site.com
(like host: myothersite.com
)
Perfect! Thanks and look forward to this feature.
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:
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 aspec.hosts
field so thatHTTPIgnoreRule
s have a many-to-many relationship toHTTPScaledObject
s.There should also be a
spec.headers
field that contains matching rules for incoming request headers:This rule would match all incoming requests that have an
X-Custom-Value
header that starts withabc
and ends withxyz
.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.