ServiceCollectionExtensions
- Namespace:
PPDS.Dataverse.DependencyInjection - Assembly:
PPDS.Dataverse - Kind: Class
Summary
Extension methods for configuring Dataverse services in an Microsoft.Extensions.DependencyInjection.IServiceCollection.
Members
Methods
AddDataverseConnectionPool
IServiceCollection AddDataverseConnectionPool(IServiceCollection services, Action<DataverseOptions> configure)
Adds Dataverse connection pooling services with a configuration action.
-
Param
services: The service collection. -
Param
configure: Action to configure options. -
Returns: The service collection for chaining.
AddDataverseConnectionPool
IServiceCollection AddDataverseConnectionPool(IServiceCollection services, IConfiguration configuration, string environment, string sectionName)
Adds Dataverse connection pooling services from configuration.
-
Param
services: The service collection. -
Param
configuration: The configuration root. -
Param
environment: Optional environment name. When specified, uses the connections from that named environment (Environments dictionary) instead of root-level Connections. When not specified but Environments are defined, uses DefaultEnvironment or the first environment. -
Param
sectionName: The configuration section name. Default: "Dataverse" -
Returns: The service collection for chaining.
RegisterDataverseServices
IServiceCollection RegisterDataverseServices(IServiceCollection services)
Registers core Dataverse services including throttle tracking and pool-consuming services. Called by both library registration and CLI ProfileServiceFactory.
-
Param
services: The service collection. -
Returns: The service collection for chaining.