Readiness probes fail if the path contains a querystring #14267
Labels
kind/bug
Categorizes issue or PR as related to a bug.
triage/accepted
Issues which should be fixed (post-triage)
Milestone
What version of Knative?
1.10.1
Expected Behavior
We are trying to run ApolloServer in Knative. ApolloServer recommends the following healthcheck
https://your.server/graphql?query=%7B__typename%7D
We expect that ApolloServer should start when using the recommended healthcheck.
Actual Behavior
The QueueProxy fails to establish that the ApolloServer app is healthy. We observe that the healthchecks fail and the Knative app never becomes available.
Observing the pod resource we can see that the healthcheck is the following:
When we observe the app’s logs we can see that the healthcheck that is being made is:
/%3Fquery={__typename}
The above URL 404s.
Steps to Reproduce the Problem
Rather than recreating an example with Apollo, we’ve reduced the problem.
kn service update hello --image docker.io/library/nginx --port 80 --probe-readiness "http:localhost:80:/?foo=bar"
Note the following log lines:
user-container 127.0.0.1 - - [16/Aug/2023:10:35:20 +0000] "GET /%3Ffoo=bar HTTP/1.1" 404 153 "-" "kube-probe//" "-"
We’d expect to see the following:
user-container 127.0.0.1 - - [16/Aug/2023:10:35:20 +0000] "GET /?foo=bar HTTP/1.1" 200 153 "-" "kube-probe//" "-"
The text was updated successfully, but these errors were encountered: