-
Notifications
You must be signed in to change notification settings - Fork 751
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
Address remaining trim warnings #4962
Conversation
@@ -142,6 +143,11 @@ public static IStandardHedgingHandlerBuilder AddStandardHedgingHandler(this IHtt | |||
return new StandardHedgingHandlerBuilder(builder.Name, builder.Services, routingBuilder); | |||
} | |||
|
|||
[UnconditionalSuppressMessage("ReflectionAnalysis", "IL2026:RequiresUnreferencedCode", | |||
Justification = "The EmptyResilienceStrategyOptions doesn't have any properties to validate.")] | |||
private static ResiliencePipelineBuilder<HttpResponseMessage> AddStrategy(this ResiliencePipelineBuilder<HttpResponseMessage> builder, Func<StrategyBuilderContext, ResilienceStrategy> factory) => |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@martintmk - do you think Polly could expose this API instead? That way callers wouldn't have to define an empty ResilienceStrategyOptions
class and suppress the warning.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we could. Could you create an issue in Polly repo?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done. App-vNext/Polly#1985
<!-- See https://github.com/dotnet/extensions/issues/4395 --> | ||
<NoWarn>$(NoWarn);TBD</NoWarn> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
Fix #4002
FYI @EricStG
Microsoft Reviewers: Open in CodeFlow