Are there any JavaScript (Angular) equivalents of the .net Polly library
Asked Answered
A

2

7

I recently discovered the .net library Polly . From the GitHub page..

Polly is a .NET resilience and transient-fault-handling library that allows developers to express policies such as Retry, Circuit Breaker, Timeout, Bulkhead Isolation, and Fallback.

It looks very powerful and extremely easy to use, however I am after the same sort of thing for my Angular applications (Polly is only for .net). Perhaps I should see if the Polly team may consider a JS port.

I know Rxjs has retry, timeout etc (which I currently use), but was wondering if there was some package that perhaps wrapped this similar to the way you can with the Polly policies, and also include features such as the caching?

I've done a fair bit of searching, and not found anything yet.

Thanks in advance!

Absorbing answered 21/1, 2018 at 6:35 Comment(0)
A
4

For for anyone else. As well as polly-js I have since also come across cockatiel which actually seems to have a lot more in it (more like the .net version)

Its a pity the name makes it hard to find.

Absorbing answered 14/6, 2023 at 22:54 Comment(0)
K
8

There is polly-js authored by @maurice. I am aware this covers retry policies; the authors of that library could comment further.

I don't (as the maintainer of Polly for .Net) have bandwidth at ths time to undertake a Javascript port. However, I would be happy to support (or advise, eg about concepts) anybody who wants to develop a Javascript/Angular equivalent.

Karinakarine answered 21/1, 2018 at 10:51 Comment(1)
Thanks for that. Yes i did find the polly-js, and saw it only had the retry (would certianly like the cache and bulkhead as well). Perhaps some of the other policies are on a roadmapAbsorbing
A
4

For for anyone else. As well as polly-js I have since also come across cockatiel which actually seems to have a lot more in it (more like the .net version)

Its a pity the name makes it hard to find.

Absorbing answered 14/6, 2023 at 22:54 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.