microsoft / microsoft/aspire

Support tags for Health Checks added by Components

Open
#2,138 5 comments 4 reactions 0 assignees View on GitHub
area-integrations
Dominant language
C#
Stars
6.3k
Forks
991
Avg merge
2d 15h
Merged PRs (30d)
196

Description

When components add health checks today, they don't set tags at all. For example:

https://github.com/dotnet/aspire/blob/f2d158bf2b02e370a6c0714313823e5a612ab962/src/Components/Aspire.StackExchange.Redis/AspireRedisExtensions.cs#L120-L129

If someone wanted to segregate their health checks so they could be run in different groupings, they would want to be able to specify the tag values for each health check added by components. This would be similar to how we do the default health check endpoints using tags:

https://github.com/dotnet/aspire/blob/f2d158bf2b02e370a6c0714313823e5a612ab962/src/Aspire.ProjectTemplates/templates/aspire-servicedefaults/Extensions.cs#L104-L111

Should we support an `IList HealthCheckTags` property on the `XXXSettings` objects that support HealthChecks? That way people could configure the tag values per component and can design how they want their health checks to be run.

cc @davidfowl @DamianEdwards @sebastienros @radical

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.