-
-
Notifications
You must be signed in to change notification settings - Fork 390
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
Drop ConnectionLeaseTimeout #703
Comments
Specific objects from which
|
Sorry for being a little late here, but we actually use this pretty extensively in alot of projects that needs to multi-target .NET Framework + .NET Standard 2.0 + .NET 5+ (API clients/SDKs mostly), and found that Flurl handles this very conveniently without having to figure out/remember all the gritty details with Servicepoint, SocketHttpHandler and lack of built-in solution for some targets. So I guess we actually use it for the intended reasons and like the fact that it just works across all targets, since we need to support these "older" platforms for the foreseeable future (maybe not netstandard, but it's going to take along time to get rid of .NET Framework in the enterprise segment). So I hope you will reconsider and thereby not remove it 🙏😀 |
@KorsG You won't like this answer but I've only become more convinced that 4.0 is the right time to drop this. Understand that Flurl's I don't like to force anyone to make the same decisions with their libraries that I've made with mine, but have you considered taking a similar position? That is, upgrade Flurl in the next major version(s) of your libraries and recommend that your users still on full framework either not upgrade or add the necessary |
Totally forgot to respond - sorry about that! But I understand you reasoning and we will basically just skip supporting netstandard 2.0 (as we really dont use it anymore) and just support .NET Framework and .NET 6+, by using Looking forward to try out the new version and thanks for all your hard work 👍 |
I'm in the process of updating a .NET Framework 4.x solution to Flurl v4. One advantage of Flurl's Is there a way to globally run some code when a new Flurl client is created and where I also can access the base URL? I tried it in |
@cremor I think you now have 2 reasons to not upgrade Flurl in your .NET Framework app. ;) |
I've created a |
@cremor How about an extension method on |
Good idea, I'll do that (once #845 is solved), thanks! |
Flurl.Http 2.0 introduced the
ConnectionLeaseTimeout
setting for platforms that don't supportServicePoint
, in order to deal with this infamous DNS problem. A lot changed since them, most notably the introduction ofSocketsHttpHandler
in .NET Core 2.1, which more elegantly solved the problem, is far superior to Flurl's solution, and is now the default handler out of the box withHttpClient
. Flurl kept its setting around and improved upon it, primarily to cover gaps in platforms that supported neitherServicePoint
norSocketsHttpHandler
.Those platforms that support neither? .NET Core 1.x, which has been out of support for 3 years and isn't usable with Flurl anymore anyway.
So Flurl's
ConnectionLeaseTimeout
setting will be dropped in the next 4.0 prerelease. I don't expect much protest, but it's possible those on platforms that don't supportSocketsHttpHandler
(full framework and Core 2.0) might find Flurl'sConnectionLeaseTimeout
setting nicer to use thanServicePoint
. I'm open to hearing that argument if it's out there, but I just have a hunch not many are using it, and major version upgrades are always a good opportunity to trim some fat.The text was updated successfully, but these errors were encountered: