Do Bulkheads support using ExecuteOutcomeAsync to avoid throwing exceptions? #2685
-
I am currently using BulkheadPolicy which throws BulkheadRejectedException. This incurs a performance penalty and can be avoided if Polly can return a response with the exception embedded in it. Polly 8 already seems to be supporting that based on this : https://www.pollydocs.org/advanced/performance.html#execute-callbacks-without-throwing-exceptions Wondering if bulkhead policies can also leverage the above behavior? Also if there is any workaround when using Bulkheads to not throw BulkheadRejectedExceptions, please let me know? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
The v8 codebase introduces the new concept of resilience strategies instead of policies that have been designed to be more performant in terms of runtime and memory usage. If you would like to benefit from these changes then you should migrate to using the new APIs in your application, as we won't be duplicating these improvements into the older API surface. The bulkhead policy is replaced in the new APIs by the rate limiter strategy as that can be used to enforce throughput. |
Beta Was this translation helpful? Give feedback.
The v8 codebase introduces the new concept of resilience strategies instead of policies that have been designed to be more performant in terms of runtime and memory usage.
If you would like to benefit from these changes then you should migrate to using the new APIs in your application, as we won't be duplicating these improvements into the older API surface.
The bulkhead policy is replaced in the new APIs by the rate limiter strategy as that can be used to enforce throughput.