- Updates for alpha.9 by @martincostello in App-vNext#1526
- Finalize the API review by @martintmk in App-vNext#1528
- Disposing pipeline should not dispose external inner pipeline by @martintmk in App-vNext#1529
- Clean duplications around disposing the pipelines by @martintmk in App-vNext#1530
- Updates for alpha.8 by @martincostello in App-vNext#1465
- Fix unstable build by @martintmk in App-vNext#1466
- Improve samples by @martintmk in App-vNext#1467
- Specify DebuggerDisplay for ReactiveResilienceStrategyBridge by @martintmk in App-vNext#1468
- Drop the
Extensions
fromPolly.Extensions
namespace by @martintmk in App-vNext#1469 - Remove Moq by @martincostello in App-vNext#1472
- Add new metering tests to cover uncovered lines by @martintmk in App-vNext#1474
- Default names for individual resilience strategies by @martintmk in App-vNext#1475
- Introduce
NonReactiveResilienceStrategy
by @martintmk in App-vNext#1476 - Drop
TelemetryResilienceStrategy
by @martintmk in App-vNext#1482 - API Review feedback (1) by @martintmk in App-vNext#1484
- Rename ResilienceStrategy to ResiliencePipeline by @martintmk in App-vNext#1483
- API Review Feedback (2) by @martintmk in App-vNext#1485
- Introduce TelemetryListener by @martintmk in App-vNext#1486
- Improve documentation by @martintmk in App-vNext#1487
- Fix metering tests by @martintmk in App-vNext#1488
- Hide validation APIs by @martintmk in App-vNext#1490
- Logging improvements by @martintmk in App-vNext#1489
- Hide/drop some unused APIs by @martintmk in App-vNext#1491
- Cleanup internals by @martintmk in App-vNext#1492
- ResilienceContextPool improvements by @martintmk in App-vNext#1493
- Hide IsSynchronous property by @martintmk in App-vNext#1494
- Drop unused ResiliencePipelineRegistry APIs by @martintmk in App-vNext#1495
ResiliencePipelineRegistry
is now disposable by @martintmk in App-vNext#1496- Move pipeline-related internals into
Pipeline
folder by @martintmk in App-vNext#1497 - Update benchmarks by @martintmk in App-vNext#1503
- Minor ResiliencePipelineRegistry cleanup of internals by @martintmk in App-vNext#1505
- API Review Feedback by @martintmk in App-vNext#1506
- Minor API cleanup by @martintmk in App-vNext#1508
- Clenaup rate limiter API by @martintmk in App-vNext#1509
- Cleanup ResiliencePipelineRegistry internals by @martintmk in App-vNext#1510
- Allow to dispose linked resources on pipeline disposal by @martintmk in App-vNext#1511
- Simplify and enhance the pipeline reloads by @martintmk in App-vNext#1512
- Drop
OutcomeArguments
struct by @martintmk in App-vNext#1513 - API Review Feedback by @martintmk in App-vNext#1520
- Got rid of some warnings in the Polly project by @IgorIgorevich94 in App-vNext#1514
- API Review Feedback by @martintmk in App-vNext#1521
- Cleanup Outcome internals and drop unused hedging and fallbacks APIs by @martintmk in App-vNext#1523
- Improve debugging experience for
ResilienceProperties
by @martintmk in App-vNext#1524 - Protect against retry delay overflows by @martintmk in App-vNext#1522
- Fix DelayAsync extension by @martintmk in App-vNext#1525
- Updates for 8.0.0-alpha.7 by @martincostello in App-vNext#1433
- Improve logging messages by @martintmk in App-vNext#1436
- Rename
BuilderName
toName
by @martintmk in App-vNext#1437 - Do not record null tags to meter by @martintmk in App-vNext#1438
- Fix telemetry test failures by @martintmk in App-vNext#1439
- Simplify OutcomeResilienceStrategy by @martintmk in App-vNext#1440
- Drop simple circuit breaker by @martintmk in App-vNext#1444
- Allow jitter for all backoff types by @martintmk in App-vNext#1445
- Rename
Attempt
toAttemptNumber
by @martintmk in App-vNext#1447 - Hide
CircuitBreakerStateProvider.LastHandledOutcome
by @martintmk in App-vNext#1446 - Rename
ResilienceStrategyBuilder
toCompositeStrategyBuilder
by @martintmk in App-vNext#1448 - Added
readonly
modifier to private fields which are never changed by @Lehonti in App-vNext#1451 - Reduced nesting levels through block-scoped
using
s and the inversion of anif
block. by @Lehonti in App-vNext#1453 - Simplify file names by @martintmk in App-vNext#1455
- Improve
MultipleStrategiesBenchmark
by @martintmk in App-vNext#1457 - Elaborate about synchronous vs asynchronous executions by @martintmk in App-vNext#1456
- Fix some typos in XML docs by @martintmk in App-vNext#1458
- Make
ReactiveResilienceStrategy
public by @martintmk in App-vNext#1460 - Make the
ReactiveResilienceStrategy
type-safe by @martintmk in App-vNext#1462 - Use
StrategyHelper
for safe executions and drop redundant methods by @martintmk in App-vNext#1463 - Drop unnecessary allocation in circuit breaker by @martintmk in App-vNext#1464
- Introduce ResilienceStrategyBuilder.Validator by @martintmk in App-vNext#1412
- Update docs by @martintmk in App-vNext#1413
- Annotate the library with trimming attributes by @martintmk in App-vNext#1414
- Update trimming justifications by @martincostello in App-vNext#1415
- Fix condition by @martincostello in App-vNext#1416
- API Review Feedback (1) by @martintmk in App-vNext#1420
- Introduce ResilienceContextPool (ApiReview) by @martintmk in App-vNext#1421
- Convert records to classes by @martintmk in App-vNext#1422
- Rename ExecuteCoreAsync to ExecuteCore by @martintmk in App-vNext#1424
- Benchmark for strategy creation by @martintmk in App-vNext#1426
- Fix README.md example syntax errors by @Sensational-Code in App-vNext#1427
- Improve usability of ResilienceStrategy<T> by @martintmk in App-vNext#1428
- Cleanup OutcomeResilienceStrategy by @martintmk in App-vNext#1430
- Drop the ResilienceStrategyBuilder.IsGenericBuilder property by @martintmk in App-vNext#1431
- Allow isolate CircuitBreakerManualControl using constructor by @martintmk in App-vNext#1432
- Update docs by @martincostello in App-vNext#1382
- Add support for
PartitionedRateLimiter
by @martintmk in App-vNext#1383 - Fix debugger proxies by @martintmk in App-vNext#1384
- Allow adding generic strategies to generic builder by @martintmk in App-vNext#1386
- Add new issue that demonstrates how to use PartitionedRateLimiter by @martintmk in App-vNext#1385
- Introduce
TelemetryOptions.OnTelemetryEvent
by @martintmk in App-vNext#1387 ResilienceStrategyRegistry
API improvements by @martintmk in App-vNext#1388- Simplify condition by @martincostello in App-vNext#1391
- Introduce
ResilienceStrategyBuilder.InstanceName
and use it in telemetry by @martintmk in App-vNext#1392 - Introduce
Polly.Testing
package by @martintmk in App-vNext#1394 - Kill mutant by @martintmk in App-vNext#1395
- Fix unstable test by @martintmk in App-vNext#1396
- Rename AddResilienceStrategy to AddResilienceStrategyRegistry by @martintmk in App-vNext#1397
- Update README.md for Polly.Extensions with telemetry info by @martintmk in App-vNext#1401
- Kill mutant by @martintmk in App-vNext#1407
- Assertion failed when running tests in Visual Studio by @martintmk in App-vNext#1408
- Include PublicApiAnalyzers by @martintmk in App-vNext#1400
- Kill mutant by @martintmk in App-vNext#1409
- Demonstrate how to create dynamic strategies with complex keys by @martintmk in App-vNext#1366
- Skip mutation tests for tagged builds by @martincostello in App-vNext#1354
- Update CHANGELOG by @martincostello in App-vNext#1353
- Drop TimeProvider.Delay by @martintmk in App-vNext#1355
- Fix race conditions in tests by @martintmk in App-vNext#1358
- Simplify the logging by @martintmk in App-vNext#1359
- Prepare for .NET 8 by @martincostello in App-vNext#1360
- Introduce ResilienceEventSeverity by @martintmk in App-vNext#1361
- Upload coverage reports by @martincostello in App-vNext#1363
- Kill mutant by @martintmk in App-vNext#1368
- Accelerate build in VS by @martintmk in App-vNext#1369
- Simplify handling of reloads by @martintmk in App-vNext#1374
- Allow reusing CircuitBreakerManualControl across multiple CBs by @martintmk in App-vNext#1375
- PR and issue automation by @martincostello in App-vNext#1370
- Exclude some labels from stale by @martincostello in App-vNext#1378
- Debugger proxies for resilience strategies by @martintmk in App-vNext#1379
- Introduce
ResilienceContext.OperationKey
by @martintmk in App-vNext#1380
- Rename FakeTimeProvider by @martincostello in App-vNext#1349
- Adopt FakeTimeProvider by @martincostello in App-vNext#1350
- Drop custom validation attributes by @martintmk in App-vNext#1351
- Drop TimeProvider.CancelAfter by @martintmk in App-vNext#1352
- Update README.md with v8 Alpha v2 release announcement by @joelhulen in App-vNext#1337
- Adopt Alpha 2 in samples by @martintmk in App-vNext#1338
- Add net6.0 and net7.0 to Polly by @martincostello in App-vNext#1336
- Sync TimeProvider and cleanup by @martintmk in App-vNext#1339
- Fix hedging being cancelled too early by @martintmk in App-vNext#1340
- Fix logging of execution attempt by @martintmk in App-vNext#1341
- Bump github/codeql-action from 2.20.0 to 2.20.1 by @dependabot in App-vNext#1344
- Bump martincostello/update-dotnet-sdk from 2.2.2 to 2.2.3 by @dependabot in App-vNext#1345
- Bump StyleCop.Analyzers from 1.2.0-beta.435 to 1.2.0-beta.507 by @dependabot in App-vNext#1342
- Bump SonarAnalyzer.CSharp from 9.3.0.71466 to 9.4.0.72892 by @dependabot in App-vNext#1343
- Expose Randomizer property and use it in retry strategy by @martintmk in App-vNext#1346
- Drop redundant validation of resilience strategy options by @martintmk in App-vNext#1299
- Add NuGet configuration file by @martincostello in App-vNext#1305
- Log unhealthy executions with warning level by @martintmk in App-vNext#1306
- Add hedging to package tags by @martincostello in App-vNext#1307
- Bump github/codeql-action from 2.3.6 to 2.20.0 by @dependabot in App-vNext#1310
- Bump actions/checkout from 3.5.2 to 3.5.3 by @dependabot in App-vNext#1309
- Introduce
samples
folder by @martintmk in App-vNext#1295 - Update telemetry benchmark by @martintmk in App-vNext#1311
- Enhance
OnHedgingArguments
by @martintmk in App-vNext#1314 - The options that handle outcomes now have sensible defaults by @martintmk in App-vNext#1316
- Update README.md with v8 alpha announcement by @joelhulen in App-vNext#1317
- The deafult RateLimiterStrategyOptions instance is now valid by @martintmk in App-vNext#1315
- Rename
TelemetryResilienceStrategyOptions
toTelemetryOptions
by @martintmk in App-vNext#1318 - Alpha fixes and improvements by @martintmk in App-vNext#1319
- Fix OnHedging not being called by @martintmk in App-vNext#1320
- Reduce allocations in telemetry by @martintmk in App-vNext#1321
- Add new issue test that demonstrates library scenario by @martintmk in App-vNext#1322
- Fix relative links by @martincostello in App-vNext#1325
- API feedback by @martintmk in App-vNext#1327
- Introduce ExecutionAttemptArguments by @martintmk in App-vNext#1326
- Introduce OutcomeResilienceStrategy and drop some internals by @martintmk in App-vNext#1330
- Introduce Outcome by @martintmk in App-vNext#1331
- Validate NuGet package signatures by @martincostello in App-vNext#1335
- Allow implicit conversion of
PredicateBuilder
to delegates by @martintmk in App-vNext#1332
- The first public preview of Polly v8 with our new high-performance core API and extensions. Feel free to check out the samples to see the new and improved Polly V8 in action.
- The first release of the new NuGet packages:
Polly.Core
- This package contains the new Polly V8 API.Polly.Extensions
- This package is designed to integrate Polly with dependency injection and enable telemetry.Polly.RateLimiting
- This package provides an integration between Polly andSystem.Threading.RateLimiting
.
Thanks to:
- @adamnova
- @andrey-noskov
- @joelhulen
- @juraj-blazek
- @geeknoid
- @laura-mi
- @martincostello
- @martintmk
- @SimonCropp
- @tekian
- @terrajobst
- Fixed an incorrect exception argument - Thanks to @FoxTes
- Upgrade FluentAssertions - Thanks to @dotnetspark
- Upgrade Cake - Thanks to @eugeneogongo
- Fixed possible NullReferenceException - Thanks to @FoxTes
- Migrate build to GitHub Actions - Thanks to @martincostello
- Authenticode sign the assembly and NuGet package - Thanks to @martincostello and the .NET Foundation
- Add RateLimit policy - Thanks to @reisenberger
- Various codebase health updates - Thanks to @SimonCropp
- Add benchmarks project - Thanks to @martincostello
- Fix broken README image - Thanks to @GitHubPang
- Recursively search all
AggregateException
inner exceptions for predicate matches when usingHandleInner()
(#818) - Thanks to @sideproject - Polly now builds deterministically - Thanks to @304NotModified
- Bug fix: the
timeoutStrategy
parameter was not being used by theTimeoutAsync(Func<TimeSpan>, TimeoutStrategy, Func<Context, TimeSpan, Task, Task>)
method - Thanks to @martincostello - Bug fix: the solution can now be built with the .NET 5.0 SDK - Thanks to @martincostello
- Upgrade SourceLink to RTM v1 (fixes building from source for latest .NET Core 3.1.x)
- Bug fix: rare circuit-breaker race condition causing NullReferenceException when circuit throws BrokenCircuitException.
- Add test target for netcoreapp3.0.
- Extend PolicyRegistry with concurrent method support, TryAdd, TryRemove, TryUpdate, GetOrAdd, AddOrUpdate; new interface IConcurrentPolicyRegistry
- Improve .NET Framework support: Add explicit targets for .NET Framework 4.6.1 and 4.7.2.
- TimeoutPolicy: if timeout occurs while a user exception is being marshalled (edge case race condition), do not mask user exception (fix issue 620)
- Enhance debugging/stacktrace experience for some contexts: Include pdb symbols in package again.
- Bug fix: ensure async retry policies honor continueOnCapturedContext setting (affected v7.1.0 only).
- Remove deprecated cake add-in from build
- Add SourceLink debugger support.
- Bug fix: PolicyRegistry with .NET Core services.AddPolicyRegistry() overload (affected Polly v7.0.1-3 only)
- Rationalise solution layout
- Add explicit .NET framework 4.6.2 and 4.7.2 test runs
- Bug fix for AdvancedCircuitBreakerAsync (issue affecting v7.0.1-2 only)
- Bug fix for PolicyRegistry (issue affecting v7.0.1 only)
- Clarify separation of sync and async policies (breaking change)
- Enable extensibility by custom policies hosted external to Polly
- Enable collection initialization syntax for PolicyRegistry
- Enable cache policies to cache default(TResult) (breaking change)
- Restore Exception binary serialization for .Net Standard 2.0
- Bug Fix: Async continuation control for async executions (issue 540, affected only v6.1.1)
- Bug Fix: Context.PolicyKey behaviour in PolicyWrap (issue 510)
- Bug Fix: Context.PolicyKey behaviour in PolicyWrap (issue 463)
- Bug Fix: CachePolicy behaviour with non-nullable types (issues 472, 475)
- Enhancement: WaitAnd/RetryForever overloads where onRetry takes the retry number as a parameter (issue 451)
- Enhancement: Overloads where onTimeout takes thrown exception as a parameter (issue 338)
- Enhancement: Improved cache error message (issue 455)
- Version 6 RTM, for integration to ASPNET Core 2.1 IHttpClientFactory
- Publish as strong-named package only (discontinue non-strong-named versions)
- Add .NetStandard 2.0 tfm
- Provide .NET4.5 support via .NetStandard 1.1 tfm
- Discontinue .NET4.0 support
- Remove methods marked as deprecated in v5.9.0
- Allow Timeout.InfiniteTimeSpan (no timeout) for TimeoutPolicy.
- Add .AsPolicy<TResult> and .AsAsyncPolicy<TResult> methods for converting non-generic policies to generic policies.
- Per Semver, indicates deprecation of overloads and properties intended to be removed or renamed in Polly v6.
- Add a new onBreak overload that provides the prior state on a transition to an open state
- Bug fix: RelativeTtl in CachePolicy now always returns a ttl relative to time item is cached
- Minor cache fixes
- Add ability to calculate cache Ttl based on item to cache
- Allow user-created custom policies
- Extend PolicyWrap syntax with interfaces
- Add ability to handle inner exceptions natively: .HandleInner<TEx>()
- Allow WaitAndRetry policies to calculate wait based on the handled fault
- Add the ability to access the policies within an IPolicyWrap
- Allow PolicyWrap to configure policies expressed as interfaces
- Bug fix: set context keys for generic execute methods with PolicyWrap
- Bug fix: generic TResult method with non-generic fallback policy
- Performance improvements
- Multiple build speed improvements
- Bug fix: non-generic CachePolicy with PolicyWrap
- Add Cache interfaces
- Add CachePolicy: cache-aside pattern, with interfaces for pluggable cache providers and serializers.
- Bug fix: Sync TimeoutPolicy in pessimistic mode no longer interposes AggregateException.
- Provide public factory methods for PolicyResult, to support testing.
- Fallback delegates can now take handled fault as input parameter.
- Make ISyncPolicy public
- (Upgrade solution to msbuild15)
- Fix ExecuteAndCapture() usage with PolicyWrap
- Allow Fallback delegates to take execution Context
- Provide IReadOnlyPolicyRegistry interface
- Add PolicyRegistry for storing and retrieving policies.
- Add interfaces by policy type and execution type.
- Change .NetStandard minimum support to NetStandard1.1.
- Allow different parts of a policy execution to exchange data via a mutable Context travelling with each execution.
- Update NETStandard.Library dependency to latest 1.6.1 for .NetStandard1.0 target. Resolves compatibility for some Xamarin targets.
- Bug fix: Prevent request stampede during half-open state of CircuitBreaker and AdvancedCircuitBreaker. Enforce only one new trial call per break duration, during half-open state.
- Bug fix: Prevent duplicate raising of the onBreak delegate, if executions started when a circuit was closed, return faults when a circuit has already opened.
- Optimisation: Optimise hotpaths for Circuit-Breaker, Retry and Fallback policies.
- Minor behavioural change: For a circuit which has not handled any faults since initialisation or last reset, make
LastException
property return null rather than a fake exception. - Add NoOpPolicy: NoOpPolicy executes delegates without intervention; for eg stubbing out Polly in unit testing.
- Fix Microsoft.Bcl and Nito.AsyncEx dependencies for Polly.Net40Async.
- Refine implementation of cancellable synchronous WaitAndRetry
- Minor breaking change: Where a user delegate does not observe cancellation, Polly will now honour the delegate's outcome rather than throw for the unobserved cancellation (issue 188).
- .NETStandard1.0 target: Correctly state dependencies.
- .NETStandard1.0 target: Fix SemVer stamping of Polly.dll.
- PCL259 project and target: Remove, in favour of .NETStandard1.0 target. PCL259 is supported via .NETStandard1.0 target, going forward.
- Mark Polly.dll as CLSCompliant.
- Tidy build around GitVersionTask and ReferenceGenerator.
- Update FluentAssertions dependency.
- Added Polly.Net40Async specs project.
- Fix issue 179: Make Net4.0 async implementation for Bulkhead truly async.
- Add .NET Standard 1.0 project and target.
A major release, adding significant new resilience policies:
- Timeout policy: allows timing out any execution. Thanks to @reisenberger.
- Bulkhead isolation policy: limits the resources consumable by governed actions, such that a faulting channel cannot cause cascading failures. Thanks to @reisenberger and contributions from @brunolauze.
- Fallback policy: provides for a fallback execution or value, in case of overall failure. Thanks to @reisenberger
- PolicyWrap: allows flexibly combining Policy instances of any type, to form an overall resilience strategy. Thanks to @reisenberger
Other changes include:
- Add PolicyKeys and context to all policy executions, for logging and to support later introduction of policy events and metrics. Thanks to @reisenberger
- Add CancellationToken support to synchronous executions. Thanks to @brunolauze and @reisenberger
- Add some missing ExecuteAndCapture/Async overloads. Thanks to @reisenberger
- Remove invalid ExecuteAsync overloads taking (but not making use of) a CancellationToken
- Provide .NET4.0 support uniquely through Polly.NET40Async package
- Retire ContextualPolicy (not part of documented API; support now in Policy base class)
- Discontinue .NET3.5 support
- Added ability for policies to handle returned results. Optimised circuit-breaker hot path. Fixed circuit-breaker threshold bug. Thanks to @reisenberger, @christopherbahr and @Finity respectively.
- Added overloads to WaitAndRetry and WaitAndRetryAsync methods that accept an onRetry delegate which includes the attempt count. Thanks to @SteveCote
- Updated the Polly.Net40Async NuGet package to enable async via the SUPPORTSASYNC constant. Cleaned up the build scripts in order to ensure unnecessary DLL references are not included within each of the framework targets. Thanks to @reisenberger and @joelhulen
- Add new Polly.Net40Async project/package supporting async for .NET40 via Microsoft.Bcl.Async. Thanks to @Lumirris
- Allowed async onRetry delegates to async retry policies. Thanks to @reisenberger
- Add AdvancedCircuitBreaker. Thanks to @reisenberger and @kristianhald
- Fixed an issue with the onReset delegate of the CircuitBreaker.
- Add ExecuteAndCapture support with arbitrary context data - Thanks to @reisenberger
- Add Wait and retry forever policy - Thanks to @nedstoyanov
- Remove time-limit on CircuitBreaker state-change delegates - Thanks to @reisenberger
- Add async support and circuit-breaker support for ContextualPolicy
- Add manual control of circuit-breaker (reset and manual circuit isolation)
- Add public reporting of circuit-breaker state, for health/performance monitoring
- Add delegates on changes of circuit state
- Thanks to @reisenberger
- Add cancellation support for all async Policy execution - Thanks to @reisenberger
- Fixes an issue where continueOnCapturedContext needed to be specified in two places (on action execution and Policy configuration), when wanting to flow async action execution on the captured context - Thanks to @reisenberger
- Fixes excess line ending issues
- Async sleep fix, plus added continueOnCapturedContext parameter on async methods to control whether continuation and retry will run on captured synchronization context - Thanks to @yevhen
- Policies with a retry count of zero are now allowed - Thanks to @nelsonghezzi
- Add .NET Core support
- Fix PCL implementation of
SystemClock.Reset
- Added ability to capture the results of executing a policy via
ExecuteAndCapture
- Thanks to @ThomasMentzel
- Added extra
NotOnCapturedContext
call to prevent potential deadlocks when blocking on asynchronous calls - Thanks to Hacko
- Replaced non-blocking sleep implementation with a blocking one for PCL
- Added Async Support (PCL)
- PCL Profile updated from Profile78 -> Profile 259
- Added missing WaitAndRetryAsync overload
- Added Async Support (.NET Framework 4.5 Only) - Massive thanks to @mauricedb for the implementation
- Added Portable Class Library (Issue #4) - Thanks to @ghuntley for the implementation
- The
Polly
NuGet package is now no longer strongly named. The strongly named NuGet package is nowPolly-Signed
(Issue #5)
- Added additional overloads to Retry
- Allow arbitrary data to be passed to policy execution (Issue #1)