12

I want to introduce transient fault handling in our .net application. I saw two nu-get packages are available as of now. One is Polly framework and the other one is Microsoft transient fault handling application block.

We investigated and saw both support asynchronous functions and different retry strategies. Polly framework also supports circuit breaker additionally. Could someone suggest which framework to use with some solid reasons. Also, it would be really helpful if pros and cons of both the frameworks along with support on internet community and scope for future extension and support can be highlighted. Thanks in advance.

Thomas Schreiter
  • 770
  • 2
  • 10
  • 25
Demon Hunter
  • 233
  • 1
  • 3
  • 15
  • I would go with Polly - it's lighter weight and easier to work with - lower friction. disclaimer: I have not worked with the application block solution. – tom redfern Apr 06 '16 at 09:58
  • Additionally, the MSTFHAB (as I will call it from now on) appears to be designed for use only for Azure hosted application, though it can be made to work on premise too. – tom redfern Apr 06 '16 at 10:16
  • Thanks for your replies. Yes Microsoft's solutions also works with the in house application that throws transient errors. One important thing which i noticed on MSDN blog is : This is already part of Azure package and should be used from there itself directly and on msdn is is marked as obsolete as well in few articles. – Demon Hunter Apr 06 '16 at 10:58

1 Answers1

19

Answering as [disclosure] the lead dev on Polly under the App-vNext umbrella, I'll confine myself to factual answers to your question about support from the internet community and future prospects for the library:

The Polly team will welcome any community feedback from the SO community!

Pang
  • 9,564
  • 146
  • 81
  • 122
mountain traveller
  • 7,591
  • 33
  • 38
  • The story is like Newtonsoft Json.Net which is now recommended by MS (de)serializer for JSON. The competition of alternatives is good, but focusing on de facto winner is great. – SerG Mar 29 '18 at 10:06
  • 2
    I've changed my mind and now I look for a simple alternative to Polly. It's just too sophisticated for real use. P.S. It is worth noting Json.Net was fired from .Net and is replaced by System.Text.Json now – SerG Aug 16 '20 at 23:10
  • So what is the microsoft library for? – CodeMonkey Dec 03 '20 at 09:08
  • @YonatanNir It is [deprecated, not maintained anymore](https://github.com/microsoftarchive/transient-fault-handling-application-block), just forget that library – Peter Csala Jul 27 '22 at 10:05
  • @PeterCsala Is there a retry library from MS? – CodeMonkey Jul 28 '22 at 07:29
  • 1
    @YonatanNir Even though polly did not start its career as MS library, now it is a valuable member of the .NET foundation. Please also note that the integration between polly and httpclient is now owned by the asp.net team (microsoft.extensions.http.polly package). – Peter Csala Jul 28 '22 at 10:53