dotnet / dotnet/SqlClient

Feature: SqlAuthenticationProvider API change proposal

Open
#3,728 1 comment 2 reactions 0 assignees View on GitHub
Breaking Change :hammer:
Dominant language
C#
Stars
989
Forks
340
Avg merge
4d 18h
Merged PRs (30d)
69

Description

Below are proposals to revamp SQL Authentication Provider APIs, captured from PR #3680 by @paulmedynski

Provider registration APIs:
- Make `GetProvider()` and `SetProvider()` public on `SqlAuthenticationProviderManager`. These are the actual implementation of provider management.
- Deprecate `GetProvider()` and `SetProvider()` on `SqlAuthenticationProvider`. These are management functions that don't belong on the base abstract class used to implement providers.
- Point to the `SqlAuthenticationProviderManager` methods as the replacement. Removing these methods will eliminate fragile runtime reflection from the MDS.Abstractions package.

Authentication Timeout APIs:
- Add an `AuthenticationTimeout` property to `SqlAuthenticationParameter`. This is a more accurate name than the existing `ConnectionTimeout` property.
- Deprecate `SqlAuthenticationParameter`'s `ConnectionTimeout` property. Implement it in terms of `AuthenticationTimeout`.
- Direct callers to `AuthenticationTimeout` property.
- Rename `SqlAuthenticationParameter`'s `ConnectionTimeout` constructor argument. We can't actually do this since C# doesn't provide a mechanism to maintain backwards compatibility with callers that are supplying the timeout value by name 🙁
- Document the intention of the connectionTimeout argument as clearly as possible.

Designers: @saurabh500 and @paulmedynski

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.