-
Notifications
You must be signed in to change notification settings - Fork 10.3k
Make IResults types public #40704
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
Make IResults types public #40704
Conversation
public async Task ExecuteAsync(HttpContext httpContext) | ||
{ | ||
var logger = httpContext.RequestServices.GetRequiredService<ILogger<ChallengeResult>>(); | ||
var logger = httpContext.RequestServices.GetRequiredService<ILogger<ChallengeHttpResult>>(); |
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.
Do we care about changing log categories? I could see that being considered a breaking change. I don't see a huge benefit of changing it other than slightly cleaner code. @BrennanConroy @davidfowl
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 don't think this is super important for preview3, but I'd like to clarify our stance on changing log categories in general.
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.
Changing categories is considered a breaking change, example
aspnetcore/src/SignalR/common/Http.Connections/src/Internal/Transports/WebSocketsServerTransport.cs
Lines 41 to 42 in 49270ee
// We create the logger with a string to preserve the logging namespace after the server side transport renames. | |
_logger = loggerFactory.CreateLogger("Microsoft.AspNetCore.Http.Connections.Internal.Transports.WebSocketsTransport"); |
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.
So, i think we should not change the categories. I have pushed a commit following @BrennanConroy example.
@halter73 / @BrennanConroy can you do a quick review? 00877b5
/// <summary> | ||
/// Gets the Content-Type header for the response. | ||
/// </summary> | ||
public string ContentType { get; internal set; } |
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.
nbd, but why internal set;
instead of internal init;
or just get;
?
Co-authored-by: Brennan <[email protected]>
src/Http/Http.Results/src/UnprocessableEntityObjectHttpResult.cs
Outdated
Show resolved
Hide resolved
src/Http/Http.Results/src/UnprocessableEntityObjectHttpResult.cs
Outdated
Show resolved
Hide resolved
…m/brunolins16/aspnetcore into brunolins16/iresult-apisuggestion
What version is this going to be released in? 8? |
Hi @terryaney. It looks like you just commented on a closed PR. The team will most probably miss it. If you'd like to bring something important up to their attention, consider filing a new issue and add enough details to build context. |
Fix #40656