Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
adamsitnik authored Sep 19, 2023
1 parent 05bf740 commit b9ebfc4
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion build/versions.props
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
<HealthCheckInfluxDB>7.0.0</HealthCheckInfluxDB>
<HealthCheckIoTHub>7.0.0</HealthCheckIoTHub>
<HealthCheckKafka>7.0.0</HealthCheckKafka>
<HealthCheckKeyVault>7.0.1</HealthCheckKeyVault>
<HealthCheckKeyVault>7.0.0</HealthCheckKeyVault>
<HealthCheckKubernetes>7.0.0</HealthCheckKubernetes>
<HealthCheckMongoDB>7.0.0</HealthCheckMongoDB>
<HealthCheckMySql>7.0.0</HealthCheckMySql>
Expand Down
1 change: 0 additions & 1 deletion src/HealthChecks.Azure.Messaging.EventHubs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ void Configure(IHealthChecksBuilder builder)
}
```


### Breaking changes

In the prior releases, `AzureEventHubHealthCheck` was a part of `HealthChecks.AzureServiceBus` package. It had a dependency on not just `Azure.Messaging.EventHubs`, but also `Azure.Messaging.ServiceBus`. The packages have been split to avoid bringing unnecessary dependencies. Moreover, `AzureEventHubHealthCheck` was letting the users specify how `EventHubProducerClient` should be created (from raw connection string or from fully qualified namespace and managed identity credentials), at a cost of maintaining an internal, static client instances cache. Now the type does not create client instances nor maintain an internal cache and **it's the caller responsibility to provide the instance of `EventHubProducerClient`** (please see [#2040](https://github.com/Xabaril/AspNetCore.Diagnostics.HealthChecks/issues/2040) for more details). Since Azure SDK recommends treating clients as singletons <see href="https://devblogs.microsoft.com/azure-sdk/lifetime-management-and-thread-safety-guarantees-of-azure-sdk-net-clients/"/> and client instances can be expensive to create, it's recommended to register a singleton factory method for Azure SDK clients. So the clients are created only when needed and once per whole application lifetime.

0 comments on commit b9ebfc4

Please sign in to comment.