NuGet dependency on System.Data.SqlClient

Posts   
 
    
acl
User
Posts: 94
Joined: 28-Mar-2012
# Posted on: 22-Dec-2022 15:01:45   

Hi,

I started porting library projects to .NET Standard in order to use them in .NET FW and .NET 6 applications.

There are some issues, which I won't get into just now. But there is one thing I don't understand though.

In the version 5.6.0 NuGet Package of the ORMSupportClasses library there is a dependency on System.Data.SqlClient >= 4.4.0 (see https://www.nuget.org/packages/SD.LLBLGen.Pro.ORMSupportClasses/5.6.0) when targeting .NET Standard. I don't understand why, since it's the one library supposed to be database independent. This dependency was removed in 5.6.1, why?

The DQE.SqlServer NuGet, on the contrary (see eg. https://www.nuget.org/packages/SD.LLBLGen.Pro.DQE.SqlServer/5.6.1) does not have any reference to System.Data.SqlClient whatsoever. Even though it's not part of the .NET Standard API set (see https://apisof.net/catalog/5acbc47c-b7c2-b3e3-bf4b-2ba958153403). So what are you using to do the database requests?

Thanks,

andreas

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39760
Joined: 17-Aug-2003
# Posted on: 23-Dec-2022 10:41:29   

Change Runtime Libraries 5.6 5.6.1 20-Sep-2019 The dependency on SqlClient in ORMSupportClasses has been removed through refactoring of the transient recovery class causing the dependency.

We reworked the code a bit so for the transient error recovery (for sql azure ) there's no need for the dependency anymore as it should never have had that dependency in the first place.

Frans Bouma | Lead developer LLBLGen Pro
acl
User
Posts: 94
Joined: 28-Mar-2012
# Posted on: 23-Dec-2022 10:51:36   

Ok thanks, but what are you using for connecting to SQL Server in the DQE.SqlServer NuGet under .NET Standard 2.0?

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39760
Joined: 17-Aug-2003
# Posted on: 23-Dec-2022 14:03:32   

acl wrote:

Ok thanks, but what are you using for connecting to SQL Server in the DQE.SqlServer NuGet under .NET Standard 2.0?

The factory you pass in to the RuntimeConfiguration simple_smile So we don't have any dependencies on any ADO.NET provider in the runtime

Frans Bouma | Lead developer LLBLGen Pro
acl
User
Posts: 94
Joined: 28-Mar-2012
# Posted on: 29-Dec-2022 14:02:35   

Ok so am I right in assuming that the DQE.SqlServer DLL is referencing the base classes that exist in the System.Data.Common namespace and that are thus available in .NET Standard as well (https://apisof.net/catalog/d5746002d88e1f13d7d2c5aee7b1becf).

Walaa avatar
Walaa
Support Team
Posts: 14986
Joined: 21-Aug-2005
# Posted on: 29-Dec-2022 19:52:27   

Fair assumption simple_smile