Finbuckle / Finbuckle.MultiTenant

Finbuckle.MultiTenant is an open-source multitenancy middleware library for .NET. It enables tenant resolution, per-tenant app behavior, and per-tenant data isolation.
https://www.finbuckle.com/multitenant
Apache License 2.0
1.3k stars 265 forks source link

.NET Standard 2 support dropped #223

Closed markgould closed 4 years ago

markgould commented 4 years ago

Is there a reason .NET Standard support was dropped in 5.0.1? (A major breaking change)

I have some sites that have to integrate with some full framework dlls, so they're .NET 4.7.2 ASP.NET Core projects which supports .NET Standard 2.0.

AndrewTriesToCode commented 4 years ago

hi @markgould

You are correct, in 5.0.1 when adding ASP.NET Core 3.1.1 support I also changed how the ASP.NET Core 2 support works by targeting netcoreapp2.1 instead of netstandard2.0. I did this mainly for consistency and easier maintenance. I intended to do it as part of 5.0 alongside other breaking changes. The January .NET Core updates came out very shortly after the 5.0 release so I took the opportunity to include this change. I think I will update the changeling to reflect this. .NET Framework compatibility hasn't been a priority, but maybe I should reconsider.

However I also tried to factor out anything needing ASP.NET Core from Finbuckle.MultiTenant.Core so that it could still target netstandard2.0. That gives you stores, strategies, and other basics. It lacks the strategies other items that are ASP.NET Core specific because those are in Finbuckle.MultiTenant.AspNetCore (i.e. anything that relies on HttpContext). This also includes the middleware which normally ties the strategy and stores together in an application.

It should be entirely possible to just reference Finbuckle.MultiTenant.Core from .NET Framework and use the basics. You might have to use the strategy and stores "manually" in doing so.

As an aside I also plan to support non-web scenarios in the next release via the new Host mechanism in .NET Core. I'm not sure if .NET Framework supports that or not--I'll have to check.

Some general background for anyone reading this:

markgould commented 4 years ago

Hi @achandlerwhite - thanks for the quick response, as always.

I'm planning on abstracting the pieces that rely on the full framework into a gRPC server, that way I can make the web project .NET Core 3 and keep current. So hopefully this shouldn't end up being an issue.

Appreciate the explanation!

stale[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.