Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.NETStandard 2.1 and .NET 4.7.2 migration - switching over to new Sql… #29

Closed
wants to merge 1 commit into from

Conversation

alesebi91
Copy link

Hi,
I've made the following changes to meet my needs on a project developed with .NetCore 3.1:

  1. projects migration to .NETStandard 2.1 and .NET 4.7.2
  2. Switched over to new SqlClient package (related to issue: Consider switching over to new SqlClient package #25 (comment))

Copy link
Owner

@madelson madelson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @alesebi91 thanks for your interest in the library. I’d like to understand your issue better. Some questions:

  1. What caused you to need the new SQL client vs the old one?
  2. I had thought that users of the new client could use it by passing in a DbConnection to the constructor. Did that work for you?
  3. Are there any issues using the new and old providers side by side?
  4. I don’t understand the need to switch to netstandard2.1 and netframework472. We already support net45 and netstandard1.3, so you should be able to install in .net core 3 or .net framework 472 projects just fine. Did you run into any issues with that?

Thanks in advance for your help!

@alesebi91
Copy link
Author

Hi @madelson ,
I answer you by points:

  1. I need it because I am migrating my project to Asp.Net Core 3.1 in order to run it into docker linux container. The old SqlClient are windows platform dependent and will no more mantained by Microsoft.
  2. I haven't tried it. I migrated to the new package without codebase modification.
  3. New and old SqlClient share the same namespaces so they cannot be used side by side
  4. I migrated them to align the library with the latest frameworks versions and because the new Microsoft.Data.SqlClient supports .NetFramework 4.6+, netstandard 2+ and netcore 2.1+. If you want I can also add compatibility to netstandard 2 and .NetFramework 4.6

Let me know if you need further implementations.

Thanks and enjoy the weekend!

@madelson
Copy link
Owner

Thanks @alesebi91 that context is helpful. In particular I wasn't aware that System.Data.SqlClient did not work at all on Linux.

I'm working on a new version of the library now that will incorporate this client as the default for .NET Standard 2.0 and newer (until I release a major version bump I plan to retain compatibility with the older frameworks). If I publish a prerelease version of this to NuGet.org in the next few days, would you be able to test it in your environment?

@alesebi91
Copy link
Author

Thanks @madelson, It sonds good!
Let me know when prerelease will be available so I can test it in my environment

@madelson
Copy link
Owner

madelson commented Jan 28, 2020

@alesebi91 Prerelease is up on Nuget.org here: https://www.nuget.org/packages/DistributedLock/1.5.0-beta01

Let me know how it goes!

@alesebi91
Copy link
Author

@madelson I just ran some tests with the new prerelease package and found no problems.

Thank you!

@madelson
Copy link
Owner

Thanks @alesebi91 I appreciate it. I've now released official v1.5 on NuGet. I'm going to close this PR since I found it simpler in this case to copy pieces over (due to maintaining the old frameworks). Thanks again for your help with this.

@madelson madelson closed this Jan 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants