OpenWithNewClientSecret

This method opens a new connection using a new Microsoft Entra ID client secret.

Declaration

// C#
public static void OpenWithNewClientSecret(this OracleConnection @this, SecureString clientSecret)

Parameters

clientSecret - new client secret SecureString object reference

Exceptions

Description

ODP.NET uses the new client secret value to open a new connection. If the new connection opens successfully, then this new client secret is cached with the connection pool. If the new connection fails to open successfully, then an exception is thrown and the new client secret is ignored.

Remarks

This method is recommended only for when the current Azure client secret expires or opening a connection with a different client secret.

ODP.NET does not check whether the new client secret is the same value or reference as the existing cached client secret in the connection pool.

This method should successfully open an entirely new connection and connection pool even if there is no existing connection pool associated.

See Also: