Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions docs/migration-v8.md
Original file line number Diff line number Diff line change
Expand Up @@ -938,7 +938,7 @@ ResiliencePipeline<int> pipeline = new ResiliencePipelineBuilder<int>()
var context = ResilienceContextPool.Shared.Get();

Outcome<int> pipelineResult =
await pipeline.ExecuteOutcomeAsync<int, string>(
await pipeline.ExecuteOutcomeAsync(
static async (ctx, state) =>
{
try
Expand Down Expand Up @@ -988,7 +988,7 @@ ResiliencePipeline<int> pipelineWithContext = new ResiliencePipelineBuilder<int>
context = ResilienceContextPool.Shared.Get();

pipelineResult =
await pipelineWithContext.ExecuteOutcomeAsync<int, string>(
await pipelineWithContext.ExecuteOutcomeAsync(
static async (ctx, state) =>
{
try
Expand Down Expand Up @@ -1088,7 +1088,7 @@ registry.TryAddBuilder(PipelineKey, (builder, context) => builder.AddTimeout(Tim
registry.TryGetPipeline(PipelineKey, out ResiliencePipeline? pipeline);

// Try get a generic pipeline
registry.TryGetPipeline<string>(PipelineKey, out ResiliencePipeline<string>? genericPipeline);
registry.TryGetPipeline(PipelineKey, out ResiliencePipeline<string>? genericPipeline);

// Get or add pipeline
registry.GetOrAddPipeline(PipelineKey, builder => builder.AddTimeout(TimeSpan.FromSeconds(10)));
Expand Down
2 changes: 1 addition & 1 deletion docs/strategies/circuit-breaker.md
Original file line number Diff line number Diff line change
Expand Up @@ -685,7 +685,7 @@ var circuitBreaker = new ResiliencePipelineBuilder()
.Build();

Outcome<HttpResponseMessage> outcome =
await circuitBreaker.ExecuteOutcomeAsync<HttpResponseMessage, string>(
await circuitBreaker.ExecuteOutcomeAsync(
static async (ctx, state) =>
{
try
Expand Down
4 changes: 2 additions & 2 deletions docs/strategies/fallback.md
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ public static async ValueTask<HttpResponseMessage> Action()
{
var context = ResilienceContextPool.Shared.Get();

var outcome = await WhateverPipeline.ExecuteOutcomeAsync<HttpResponseMessage, string>(
var outcome = await WhateverPipeline.ExecuteOutcomeAsync(
static async (ctx, state) =>
{
try
Expand Down Expand Up @@ -297,7 +297,7 @@ var fallback = new ResiliencePipelineBuilder<HttpResponseMessage>()
.Build();

var context = ResilienceContextPool.Shared.Get();
var outcome = await fallback.ExecuteOutcomeAsync<HttpResponseMessage, string>(
var outcome = await fallback.ExecuteOutcomeAsync(
async (ctx, state) =>
{
var result = await CallPrimary(ctx.CancellationToken);
Expand Down
2 changes: 1 addition & 1 deletion src/LegacySupport/DynamicallyAccessedMembersAttribute.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ namespace System.Diagnostics.CodeAnalysis;

/// <summary>
/// Indicates that certain members on a specified <see cref="Type"/> are accessed dynamically,
/// for example through <see cref="System.Reflection"/>.
/// for example through <see cref="Reflection"/>.
/// </summary>
/// <remarks>
/// This allows tools to understand which members are being accessed during the execution
Expand Down
2 changes: 1 addition & 1 deletion src/LegacySupport/RequiresUnreferencedCodeAttribute.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ namespace System.Diagnostics.CodeAnalysis;

/// <summary>
/// /// Indicates that the specified method requires dynamic access to code that is not referenced
/// statically, for example through <see cref="System.Reflection"/>.
/// statically, for example through <see cref="Reflection"/>.
/// </summary>
/// <remarks>
/// This allows tools to understand which methods are unsafe to call when removing unreferenced
Expand Down
2 changes: 1 addition & 1 deletion src/Polly.Core/ResiliencePipeline.AsyncT.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public partial class ResiliencePipeline
/// <remarks>
/// <para><strong>Important:</strong> This API targets advanced, low-allocation scenarios. The user callback
/// must not throw an exception. Wrap your code and return <see cref="Outcome{TResult}"/>:
/// use <see cref="Outcome.FromResult{TResult}(TResult)"/> on success, or <see cref="Outcome.FromException{TResult}(System.Exception)"/> on failure.
/// use <see cref="Outcome.FromResult{TResult}(TResult)"/> on success, or <see cref="Outcome.FromException{TResult}(Exception)"/> on failure.
/// Do not rely on strategies to catch your exceptions; any such behavior is an implementation detail and is not
/// guaranteed across strategies or future versions.</para>
/// </remarks>
Expand Down
4 changes: 2 additions & 2 deletions src/Polly.Core/ResiliencePipelineBuilderBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ private protected ResiliencePipelineBuilderBase(ResiliencePipelineBuilderBase ot
public string? InstanceName { get; set; }

/// <summary>
/// Gets or sets the <see cref="Polly.ResilienceContextPool"/> associated with the builder.
/// Gets or sets the <see cref="ResilienceContextPool"/> associated with the builder.
/// </summary>
/// <remarks>
/// A custom pool can be used to configure custom behavior for creation.
Expand All @@ -76,7 +76,7 @@ private protected ResiliencePipelineBuilderBase(ResiliencePipelineBuilderBase ot
public TimeProvider? TimeProvider { get; set; }

/// <summary>
/// Gets or sets the <see cref="Polly.Telemetry.TelemetryListener"/> that is used by Polly to report resilience events.
/// Gets or sets the <see cref="Telemetry.TelemetryListener"/> that is used by Polly to report resilience events.
/// </summary>
/// <remarks>
/// This property is used by the telemetry infrastructure and should not be used directly by user code.
Expand Down
2 changes: 1 addition & 1 deletion src/Polly.Core/ResiliencePipelineT.Async.cs
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public ValueTask<TResult> ExecuteAsync<TResult>(
/// <remarks>
/// <para><strong>Important:</strong> This method targets advanced, low-allocation scenarios. The user callback
/// must not throw an exception. Wrap your code and return <see cref="Outcome{TResult}"/>:
/// use <see cref="Outcome.FromResult{TResult}(TResult)"/> on success, or <see cref="Outcome.FromException{TResult}(System.Exception)"/> on failure.
/// use <see cref="Outcome.FromResult{TResult}(TResult)"/> on success, or <see cref="Outcome.FromException{TResult}(Exception)"/> on failure.
/// Do not rely on strategies to catch your exceptions; any such behavior is an implementation detail and
/// is not guaranteed across strategies or future versions.</para>
/// </remarks>
Expand Down
2 changes: 1 addition & 1 deletion src/Polly/AsyncPolicy.NonGenericImplementation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ protected virtual Task ImplementationAsync(
Context context,
CancellationToken cancellationToken,
bool continueOnCapturedContext) =>
ImplementationAsync<EmptyStruct>(async (ctx, token) =>
ImplementationAsync(async (ctx, token) =>
#pragma warning restore CA1068
{
await action(ctx, token).ConfigureAwait(continueOnCapturedContext);
Expand Down
4 changes: 2 additions & 2 deletions src/Polly/Caching/AsyncCachePolicy.cs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ protected override Task<TResult> ImplementationAsync<TResult>(
throw new ArgumentNullException(nameof(action));
}

return AsyncCacheEngine.ImplementationAsync<TResult>(
return AsyncCacheEngine.ImplementationAsync(
_asyncCacheProvider.AsyncFor<TResult>(),
_ttlStrategy.For<TResult>(),
_cacheKeyStrategy,
Expand Down Expand Up @@ -133,7 +133,7 @@ protected override Task<TResult> ImplementationAsync(
throw new ArgumentNullException(nameof(action));
}

return AsyncCacheEngine.ImplementationAsync<TResult>(
return AsyncCacheEngine.ImplementationAsync(
_asyncCacheProvider,
_ttlStrategy,
_cacheKeyStrategy,
Expand Down
2 changes: 1 addition & 1 deletion src/Polly/Caching/CachePolicy.cs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ protected override TResult Implementation<TResult>(Func<Context, CancellationTok
throw new ArgumentNullException(nameof(action));
}

return CacheEngine.Implementation<TResult>(
return CacheEngine.Implementation(
_syncCacheProvider.For<TResult>(),
_ttlStrategy.For<TResult>(),
_cacheKeyStrategy,
Expand Down
Loading
Loading