Microsoft.Data.SqlClient 4.0 Preview 1 has been released. This release contains improvements and updates to the Microsoft.Data.SqlClient data provider for SQL Server.
Our plan is to provide GA releases twice a year with two preview releases in between. This cadence should provide time for feedback and allow us to deliver features and fixes in a timely manner. This first 4.0 preview includes many fixes and changes over the previous 3.0 GA release.
Notable changes include:
Encrypt default value set to true
The default value of theEncryptconnection setting has been changed fromfalsetotrue. With the growing use of cloud databases and the need to ensure those connections are secure, it's time for this backwards-compatibility-breaking change.
Ensure connections fail when encryption is required
In scenarios where client encryption libraries were disabled or unavailable, it was possible for unencrypted connections to be made when Encrypt was set to true or the server required encryption.
App Context Switch for using System default protocols
TLS 1.3 is not supported by the driver; therefore, it has been removed from the supported protocols list by default. Users can switch back to forcing use of Operating System's client protocols, by enabling the App Context switch below:
Microsoft.Data.SqlClient introduces newSqlCommandAPI,EnableOptimizedParameterBindingto improve performance of queries with large number of parameters. This property is disabled by default. When set totrue, parameter names will not be sent to the SQL server when the command is executed.
We appreciate the time and effort you spend checking out our previews. It makes the final product that much better. If you encounter any issues or have any feedback, head over to the SqlClient GitHub repository and submit an issue.