Class PostgresServiceCollectionExtensions
- Namespace
- Steeltoe.CloudFoundry.Connector.PostgreSql
- Assembly
- Steeltoe.CloudFoundry.ConnectorCore.dll
public static class PostgresServiceCollectionExtensions
- Inheritance
-
PostgresServiceCollectionExtensions
- Inherited Members
Methods
AddPostgresHealthContributor(IServiceCollection, IConfiguration, ServiceLifetime, ILoggerFactory)
Add an IHealthContributor to a ServiceCollection for PostgreSQL
public static IServiceCollection AddPostgresHealthContributor(this IServiceCollection services, IConfiguration config, ServiceLifetime contextLifetime = ServiceLifetime.Singleton, ILoggerFactory logFactory = null)
Parameters
servicesIServiceCollectionService collection to add to
configIConfigurationApp configuration
contextLifetimeServiceLifetimeLifetime of the service to inject
logFactoryILoggerFactorylogger factory
Returns
- IServiceCollection
IServiceCollection for chaining
AddPostgresHealthContributor(IServiceCollection, IConfiguration, string, ServiceLifetime, ILoggerFactory)
Add an IHealthContributor to a ServiceCollection for PostgreSQL
public static IServiceCollection AddPostgresHealthContributor(this IServiceCollection services, IConfiguration config, string serviceName, ServiceLifetime contextLifetime = ServiceLifetime.Singleton, ILoggerFactory logFactory = null)
Parameters
servicesIServiceCollectionService collection to add to
configIConfigurationApp configuration
serviceNamestringcloud foundry service name binding
contextLifetimeServiceLifetimeLifetime of the service to inject
logFactoryILoggerFactorylogger factory
Returns
- IServiceCollection
IServiceCollection for chaining