Skip to content

Implement typed generic wrapper for IBackgroundServiceHealthService #8

@Anders-Toegersen

Description

@Anders-Toegersen

Background:

The current implementation of IBackgroundServiceHealthService uses a string (serviceName) to register and manage the health check state of a background service. As the background services are registered as singletons, we can use the type to make a unique service name.

Proposed Changes:

  1. Implement IBackgroundServiceHealthService<TBackgroundService> that utilizes the type TBackgroundService to create a unique name to call into IBackgroundServiceHealthService.

Impact:

  • Increased ease of use as we reduce the boilerplate of finding the serviceName for each call.
  • Reduced chance of errors as the call can be made more consistent.
  • Added complexity for service registration of IBackgroundServiceHealthService<TBackgroundService>

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions