Dependent healthchecks #2651
-
I added a RabbitMQ dependency to the apiservice project:
Then stopped the container for RabbitMQ in Docker and went to the /health endpoint of apiservice hoping it would now report Unhealthy. But it still returned Healthy. My question: is there a way to configure .NET Aspire for nested healthchecks like this? (You could go with your own healthcheck package/code but I'm curious what .NET Aspire has to offer.) |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
If you use the Aspire Component for RabbitMQ and add the RabbitMQ client using the method provided by it, you should get a health check added for it. See https://learn.microsoft.com/dotnet/aspire/messaging/rabbitmq-client-component?tabs=dotnet-cli#health-checks for more details. |
Beta Was this translation helpful? Give feedback.
If you use the Aspire Component for RabbitMQ and add the RabbitMQ client using the method provided by it, you should get a health check added for it. See https://learn.microsoft.com/dotnet/aspire/messaging/rabbitmq-client-component?tabs=dotnet-cli#health-checks for more details.