-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Probing Dapr's /healthz endpoint throws sidecar error #8472
Comments
After discussion, we should recommend that folks no longer add a health probe on application start-up that hits the Dapr As part of this we need to:
|
My takeaway was slightly different, so this might be worth hashing out once more next week. What I took from the discussion is that the health endpoint isn't really intended for SDKs to use and instead intended for load balancer and K8s health probes instead. So the SDK itself shouldn't expose this method to developers to use (marking them as obsolete) and that even the SDK itself shouldn't bother doing a check because if the port is open to send the request to Daprd, the runtime is listening to requests and that it'll block requests until it's ready, then start responding to each. Thus, no health check needed. |
"we should recommend that folks no longer add a health probe on application start-up that hits the Dapr healthz endpoint" Yes, even prior to 1.15 it seems pretty crazy that people were doing this, and demonstrates a lack of understanding. However, I'm not clear how OPs original issue raised has anything to do with the |
In what area(s)?
/area runtime
What version of Dapr?
CLI version: 1.15.0-rc.5
Runtime version: 1.15.0-rc.10
Expected Behavior
In a dotnet application we are using Dapr's /healthz endpoint as a startup probe to check if the sidecar was ready before the app became functional.
Sample code:
Prior to 1.15, this worked well, but testing it on 1.15.0-rc.10, a particular workflow sidecar logs show:
level=error msg="Failed to receive scheduler hosts: rpc error: code = Canceled desc = context canceled" app_id=order-processor-workflow instance=order-processor-workflow-7f898f88d6-l48qc scope=dapr.runtime.scheduler type=log ver=1.15.0-rc.10
and
Removing that startup probe fixes the issue and the app works as expected.
It's important to note that other applications that are not workflows have the same startup probe and work properly.
Steps to Reproduce the Problem
A simple workflow application with a startup probe that points to the dapr healthz endpoint should throw this error.
The text was updated successfully, but these errors were encountered: