-
-
Couldn't load subscription status.
- Fork 1.3k
Polly V8: Public API Review #1233
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
Closed
Changes from all commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
bb8aee2
Update with latest API
martintmk 05cc3c8
Update with latest API
martintmk 020e1e9
Update with latest API.
martintmk a787e99
Update with latest API
martintmk aa2ec83
Update with latest API
martintmk c1d94b8
Update with latest API
martintmk b64d0b5
Update with latest API
martintmk a564d51
Update with latest API
martintmk b6fba09
Update with the latest API
martintmk c154731
Update with latest API
martintmk fd77cd5
Update with latest API
martintmk ac0d9a8
Update with latest API
martintmk ea73276
Update with latest API
martintmk d5654ed
Update with latest API
martintmk 06979ae
Cleanup the output
martintmk a42c4f3
Update with latest API
martintmk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| System.Collections | ||
| System.Collections.Concurrent | ||
| System.ComponentModel.Annotations | ||
| System.Linq | ||
| System.Private.CoreLib | ||
| System.Private.Uri | ||
| System.Runtime | ||
| System.Runtime.CompilerServices.Unsafe | ||
| System.Runtime.InteropServices | ||
| System.Threading |
14 changes: 14 additions & 0 deletions
14
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/BrokenCircuitException.TResult.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.Runtime.CompilerServices; | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public class BrokenCircuitException<TResult> : BrokenCircuitException | ||
| { | ||
| public TResult Result { get; } | ||
| public BrokenCircuitException(TResult result); | ||
| public BrokenCircuitException(string message, TResult result); | ||
| public BrokenCircuitException(string message, Exception inner, TResult result); | ||
| } |
12 changes: 12 additions & 0 deletions
12
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/BrokenCircuitException.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public class BrokenCircuitException : ExecutionRejectedException | ||
| { | ||
| public BrokenCircuitException(); | ||
| public BrokenCircuitException(string message); | ||
| public BrokenCircuitException(string message, Exception inner); | ||
| } |
19 changes: 19 additions & 0 deletions
19
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/CircuitBreakerManualControl.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.Collections.Generic; | ||
| using System.Diagnostics; | ||
| using System.Runtime.CompilerServices; | ||
| using System.Threading; | ||
| using System.Threading.Tasks; | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public sealed class CircuitBreakerManualControl : IDisposable | ||
| { | ||
| public CircuitBreakerManualControl(); | ||
| public CircuitBreakerManualControl(bool isIsolated); | ||
| public Task IsolateAsync(CancellationToken cancellationToken = default(CancellationToken)); | ||
| public Task CloseAsync(CancellationToken cancellationToken = default(CancellationToken)); | ||
| public void Dispose(); | ||
| } | ||
10 changes: 10 additions & 0 deletions
10
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/CircuitBreakerPredicateArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System.Runtime.InteropServices; | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| [StructLayout(LayoutKind.Sequential, Size = 1)] | ||
| public readonly struct CircuitBreakerPredicateArguments | ||
| { | ||
| } |
11 changes: 11 additions & 0 deletions
11
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/CircuitBreakerStateProvider.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public sealed class CircuitBreakerStateProvider | ||
| { | ||
| public CircuitState CircuitState { get; } | ||
| public CircuitBreakerStateProvider(); | ||
| } |
28 changes: 28 additions & 0 deletions
28
...eview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/CircuitBreakerStrategyOptions.TResult.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.ComponentModel.DataAnnotations; | ||
| using System.Runtime.CompilerServices; | ||
| using System.Threading.Tasks; | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public class CircuitBreakerStrategyOptions<TResult> : ResilienceStrategyOptions | ||
| { | ||
| [Range(0.0, 1.0)] | ||
| public double FailureRatio { get; set; } | ||
| [Range(2, int.MaxValue)] | ||
| public int MinimumThroughput { get; set; } | ||
| [Range(typeof(TimeSpan), "00:00:00.500", "1.00:00:00")] | ||
| public TimeSpan SamplingDuration { get; set; } | ||
| [Range(typeof(TimeSpan), "00:00:00.500", "1.00:00:00")] | ||
| public TimeSpan BreakDuration { get; set; } | ||
| [Required] | ||
| public Func<OutcomeArguments<TResult, CircuitBreakerPredicateArguments>, ValueTask<bool>> ShouldHandle { get; set; } | ||
| public Func<OutcomeArguments<TResult, OnCircuitClosedArguments>, ValueTask>? OnClosed { get; set; } | ||
| public Func<OutcomeArguments<TResult, OnCircuitOpenedArguments>, ValueTask>? OnOpened { get; set; } | ||
| public Func<OnCircuitHalfOpenedArguments, ValueTask>? OnHalfOpened { get; set; } | ||
| public CircuitBreakerManualControl? ManualControl { get; set; } | ||
| public CircuitBreakerStateProvider? StateProvider { get; set; } | ||
| public CircuitBreakerStrategyOptions(); | ||
| } |
8 changes: 8 additions & 0 deletions
8
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/CircuitBreakerStrategyOptions.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public class CircuitBreakerStrategyOptions : CircuitBreakerStrategyOptions<object> | ||
| { | ||
| public CircuitBreakerStrategyOptions(); | ||
| } | ||
martintmk marked this conversation as resolved.
Show resolved
Hide resolved
|
||
11 changes: 11 additions & 0 deletions
11
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/CircuitState.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public enum CircuitState | ||
| { | ||
| Closed = 0, | ||
| Open = 1, | ||
| HalfOpen = 2, | ||
| Isolated = 3 | ||
| } |
12 changes: 12 additions & 0 deletions
12
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/IsolatedCircuitException.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public class IsolatedCircuitException : BrokenCircuitException | ||
| { | ||
| public IsolatedCircuitException(); | ||
| public IsolatedCircuitException(string message); | ||
| public IsolatedCircuitException(string message, Exception innerException); | ||
| } |
11 changes: 11 additions & 0 deletions
11
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/OnCircuitClosedArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System.Runtime.CompilerServices; | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public readonly struct OnCircuitClosedArguments | ||
| { | ||
| public bool IsManual { get; } | ||
| public OnCircuitClosedArguments(bool isManual); | ||
| } |
11 changes: 11 additions & 0 deletions
11
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/OnCircuitHalfOpenedArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System.Runtime.CompilerServices; | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public readonly struct OnCircuitHalfOpenedArguments | ||
| { | ||
| public ResilienceContext Context { get; } | ||
| public OnCircuitHalfOpenedArguments(ResilienceContext context); | ||
| } |
13 changes: 13 additions & 0 deletions
13
ApiReview/API.Polly.Core/NoDocs/Polly.CircuitBreaker/OnCircuitOpenedArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.Runtime.CompilerServices; | ||
|
|
||
| namespace Polly.CircuitBreaker; | ||
|
|
||
| public readonly struct OnCircuitOpenedArguments | ||
| { | ||
| public TimeSpan BreakDuration { get; } | ||
| public bool IsManual { get; } | ||
| public OnCircuitOpenedArguments(TimeSpan breakDuration, bool isManual); | ||
| } |
10 changes: 10 additions & 0 deletions
10
ApiReview/API.Polly.Core/NoDocs/Polly.Fallback/FallbackPredicateArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System.Runtime.InteropServices; | ||
|
|
||
| namespace Polly.Fallback; | ||
|
|
||
| [StructLayout(LayoutKind.Sequential, Size = 1)] | ||
| public readonly struct FallbackPredicateArguments | ||
| { | ||
| } |
18 changes: 18 additions & 0 deletions
18
ApiReview/API.Polly.Core/NoDocs/Polly.Fallback/FallbackStrategyOptions.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.ComponentModel.DataAnnotations; | ||
| using System.Runtime.CompilerServices; | ||
| using System.Threading.Tasks; | ||
|
|
||
| namespace Polly.Fallback; | ||
|
|
||
| public class FallbackStrategyOptions<TResult> : ResilienceStrategyOptions | ||
| { | ||
| [Required] | ||
| public Func<OutcomeArguments<TResult, FallbackPredicateArguments>, ValueTask<bool>> ShouldHandle { get; set; } | ||
| [Required] | ||
| public Func<OutcomeArguments<TResult, FallbackPredicateArguments>, ValueTask<Outcome<TResult>>>? FallbackAction { get; set; } | ||
| public Func<OutcomeArguments<TResult, OnFallbackArguments>, ValueTask>? OnFallback { get; set; } | ||
| public FallbackStrategyOptions(); | ||
| } |
10 changes: 10 additions & 0 deletions
10
ApiReview/API.Polly.Core/NoDocs/Polly.Fallback/OnFallbackArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System.Runtime.InteropServices; | ||
|
|
||
| namespace Polly.Fallback; | ||
|
|
||
| [StructLayout(LayoutKind.Sequential, Size = 1)] | ||
| public readonly struct OnFallbackArguments | ||
| { | ||
| } |
16 changes: 16 additions & 0 deletions
16
ApiReview/API.Polly.Core/NoDocs/Polly.Hedging/HedgingActionGeneratorArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.Runtime.CompilerServices; | ||
| using System.Threading.Tasks; | ||
|
|
||
| namespace Polly.Hedging; | ||
|
|
||
| public readonly struct HedgingActionGeneratorArguments<TResult> | ||
| { | ||
| public ResilienceContext PrimaryContext { get; } | ||
| public ResilienceContext ActionContext { get; } | ||
| public int AttemptNumber { get; } | ||
| public Func<ResilienceContext, ValueTask<Outcome<TResult>>> Callback { get; } | ||
martintmk marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| public HedgingActionGeneratorArguments(ResilienceContext primaryContext, ResilienceContext actionContext, int attemptNumber, Func<ResilienceContext, ValueTask<Outcome<TResult>>> callback); | ||
| } | ||
12 changes: 12 additions & 0 deletions
12
ApiReview/API.Polly.Core/NoDocs/Polly.Hedging/HedgingDelayArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System.Runtime.CompilerServices; | ||
|
|
||
| namespace Polly.Hedging; | ||
|
|
||
| public readonly struct HedgingDelayArguments | ||
| { | ||
| public ResilienceContext Context { get; } | ||
| public int AttemptNumber { get; } | ||
| public HedgingDelayArguments(ResilienceContext context, int attemptNumber); | ||
| } |
10 changes: 10 additions & 0 deletions
10
ApiReview/API.Polly.Core/NoDocs/Polly.Hedging/HedgingPredicateArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System.Runtime.InteropServices; | ||
|
|
||
| namespace Polly.Hedging; | ||
|
|
||
| [StructLayout(LayoutKind.Sequential, Size = 1)] | ||
| public readonly struct HedgingPredicateArguments | ||
| { | ||
| } |
22 changes: 22 additions & 0 deletions
22
ApiReview/API.Polly.Core/NoDocs/Polly.Hedging/HedgingStrategyOptions.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.ComponentModel.DataAnnotations; | ||
| using System.Runtime.CompilerServices; | ||
| using System.Threading.Tasks; | ||
|
|
||
| namespace Polly.Hedging; | ||
|
|
||
| public class HedgingStrategyOptions<TResult> : ResilienceStrategyOptions | ||
| { | ||
| public TimeSpan HedgingDelay { get; set; } | ||
| [Range(2, 10)] | ||
| public int MaxHedgedAttempts { get; set; } | ||
| [Required] | ||
| public Func<OutcomeArguments<TResult, HedgingPredicateArguments>, ValueTask<bool>> ShouldHandle { get; set; } | ||
| [Required] | ||
| public Func<HedgingActionGeneratorArguments<TResult>, Func<ValueTask<Outcome<TResult>>>?> HedgingActionGenerator { get; set; } | ||
| public Func<HedgingDelayArguments, ValueTask<TimeSpan>>? HedgingDelayGenerator { get; set; } | ||
| public Func<OutcomeArguments<TResult, OnHedgingArguments>, ValueTask>? OnHedging { get; set; } | ||
| public HedgingStrategyOptions(); | ||
| } |
14 changes: 14 additions & 0 deletions
14
ApiReview/API.Polly.Core/NoDocs/Polly.Hedging/OnHedgingArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.Runtime.CompilerServices; | ||
|
|
||
| namespace Polly.Hedging; | ||
|
|
||
| public readonly struct OnHedgingArguments | ||
| { | ||
| public int AttemptNumber { get; } | ||
| public bool HasOutcome { get; } | ||
| public TimeSpan Duration { get; } | ||
| public OnHedgingArguments(int attemptNumber, bool hasOutcome, TimeSpan duration); | ||
| } |
15 changes: 15 additions & 0 deletions
15
ApiReview/API.Polly.Core/NoDocs/Polly.Registry/ConfigureBuilderContext.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.ComponentModel; | ||
| using System.Runtime.CompilerServices; | ||
| using System.Threading; | ||
|
|
||
| namespace Polly.Registry; | ||
|
|
||
| public class ConfigureBuilderContext<TKey> where TKey : notnull | ||
| { | ||
| public TKey PipelineKey { get; } | ||
| [EditorBrowsable(EditorBrowsableState.Never)] | ||
| public void EnableReloads(Func<Func<CancellationToken>> tokenProducerFactory); | ||
| } |
14 changes: 14 additions & 0 deletions
14
ApiReview/API.Polly.Core/NoDocs/Polly.Registry/ResiliencePipelineProvider.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System.Diagnostics.CodeAnalysis; | ||
|
|
||
| namespace Polly.Registry; | ||
|
|
||
| public abstract class ResiliencePipelineProvider<TKey> where TKey : notnull | ||
| { | ||
| public virtual ResiliencePipeline GetPipeline(TKey key); | ||
| public virtual ResiliencePipeline<TResult> GetPipeline<TResult>(TKey key); | ||
| public abstract bool TryGetPipeline(TKey key, [NotNullWhen(true)] out ResiliencePipeline? pipeline); | ||
| public abstract bool TryGetPipeline<TResult>(TKey key, [NotNullWhen(true)] out ResiliencePipeline<TResult>? pipeline); | ||
| protected ResiliencePipelineProvider(); | ||
| } |
23 changes: 23 additions & 0 deletions
23
ApiReview/API.Polly.Core/NoDocs/Polly.Registry/ResiliencePipelineRegistry.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,23 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.Collections.Concurrent; | ||
| using System.Collections.Generic; | ||
| using System.Diagnostics.CodeAnalysis; | ||
| using Polly.Utils; | ||
|
|
||
| namespace Polly.Registry; | ||
|
|
||
| public sealed class ResiliencePipelineRegistry<TKey> : ResiliencePipelineProvider<TKey> where TKey : notnull | ||
| { | ||
| public ResiliencePipelineRegistry(); | ||
| public ResiliencePipelineRegistry(ResiliencePipelineRegistryOptions<TKey> options); | ||
| public override bool TryGetPipeline<TResult>(TKey key, [NotNullWhen(true)] out ResiliencePipeline<TResult>? pipeline); | ||
| public override bool TryGetPipeline(TKey key, [NotNullWhen(true)] out ResiliencePipeline? pipeline); | ||
| public ResiliencePipeline GetOrAddPipeline(TKey key, Action<ResiliencePipelineBuilder> configure); | ||
| public ResiliencePipeline GetOrAddPipeline(TKey key, Action<ResiliencePipelineBuilder, ConfigureBuilderContext<TKey>> configure); | ||
| public ResiliencePipeline<TResult> GetOrAddPipeline<TResult>(TKey key, Action<ResiliencePipelineBuilder<TResult>> configure); | ||
| public ResiliencePipeline<TResult> GetOrAddPipeline<TResult>(TKey key, Action<ResiliencePipelineBuilder<TResult>, ConfigureBuilderContext<TKey>> configure); | ||
| public bool TryAddBuilder(TKey key, Action<ResiliencePipelineBuilder, ConfigureBuilderContext<TKey>> configure); | ||
| public bool TryAddBuilder<TResult>(TKey key, Action<ResiliencePipelineBuilder<TResult>, ConfigureBuilderContext<TKey>> configure); | ||
| } |
22 changes: 22 additions & 0 deletions
22
ApiReview/API.Polly.Core/NoDocs/Polly.Registry/ResiliencePipelineRegistryOptions.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.Collections.Generic; | ||
| using System.ComponentModel.DataAnnotations; | ||
| using System.Runtime.CompilerServices; | ||
|
|
||
| namespace Polly.Registry; | ||
|
|
||
| public class ResiliencePipelineRegistryOptions<TKey> | ||
| { | ||
| [Required] | ||
| public Func<ResiliencePipelineBuilder> BuilderFactory { get; set; } | ||
| [Required] | ||
| public IEqualityComparer<TKey> PipelineComparer { get; set; } | ||
| [Required] | ||
| public IEqualityComparer<TKey> BuilderComparer { get; set; } | ||
| public Func<TKey, string>? InstanceNameFormatter { get; set; } | ||
| [Required] | ||
| public Func<TKey, string> BuilderNameFormatter { get; set; } | ||
| public ResiliencePipelineRegistryOptions(); | ||
| } |
14 changes: 14 additions & 0 deletions
14
ApiReview/API.Polly.Core/NoDocs/Polly.Retry/OnRetryArguments.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| // Assembly 'Polly.Core' | ||
|
|
||
| using System; | ||
| using System.Runtime.CompilerServices; | ||
|
|
||
| namespace Polly.Retry; | ||
|
|
||
| public readonly struct OnRetryArguments | ||
| { | ||
| public int AttemptNumber { get; } | ||
| public TimeSpan RetryDelay { get; } | ||
| public TimeSpan ExecutionTime { get; } | ||
| public OnRetryArguments(int attemptNumber, TimeSpan retryDelay, TimeSpan executionTime); | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.