Skip to content
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

Ensure we don't add duplicate Health Checks #707

Merged
merged 1 commit into from
Nov 6, 2023
Merged

Ensure we don't add duplicate Health Checks #707

merged 1 commit into from
Nov 6, 2023

Conversation

eerhardt
Copy link
Member

@eerhardt eerhardt commented Nov 6, 2023

When adding Health Checks, we need to ensure we don't add the same health check twice. ASP.NET will throw an exception if 2 health checks have the same name.

Use the HostApplicationBuilder Properties to ensure an Aspire Component doesn't add the same health check twice.

Fix #705

When adding Health Checks, we need to ensure we don't add the same health check twice. ASP.NET will throw an exception if 2 health checks have the same name.

Use the HostApplicationBuilder Properties to ensure an Aspire Component doesn't add the same health check twice.

Fix #705
@davidfowl
Copy link
Member

I like it.

@eerhardt eerhardt merged commit 5f7beb2 into main Nov 6, 2023
5 checks passed
@eerhardt eerhardt deleted the Fix705 branch November 6, 2023 22:36
eerhardt added a commit that referenced this pull request Nov 6, 2023
When adding Health Checks, we need to ensure we don't add the same health check twice. ASP.NET will throw an exception if 2 health checks have the same name.

Use the HostApplicationBuilder Properties to ensure an Aspire Component doesn't add the same health check twice.

Fix #705
eerhardt added a commit that referenced this pull request Nov 6, 2023
When adding Health Checks, we need to ensure we don't add the same health check twice. ASP.NET will throw an exception if 2 health checks have the same name.

Use the HostApplicationBuilder Properties to ensure an Aspire Component doesn't add the same health check twice.

Fix #705
@danmoseley danmoseley added the area-integrations Issues pertaining to Aspire Integrations packages label Nov 16, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Apr 30, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-integrations Issues pertaining to Aspire Integrations packages
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Multiple calls to component registeration methods fail with duplicate health check registrations
3 participants