Closed rynowak closed 6 years ago
We're not doing a filter. The plan is to use action result execution extensibility to do this.
Reactivating this to track the work, which wasn't completed 😆
@pranavkm @rynowak What work is still pending here?
100% of it.
Setting up a meeting with @rynowak for Monday to figure out how much work this would be. This should give us an idea on what we want to do with this item for preview1.
This might be a stupid question, but I presume that:
Default flow for exception in controller will also use the new format?
No, it's primarily meant to convert ActionResult with error status codes to errors.
I have the capability to return new format results in exception handler? Yup. The plan would be to have some way to customize what the format looks like. Right now, you could do this for ApiControllers using
ApiBehaviorOptions.InvalidModelStateResponseFactory
. e.g. https://github.com/aspnet/Mvc/blob/dev/test/WebSites/BasicWebSite/Startup.cs#L37-L47
Moving this out to preview2. We need to design this which we did not get around to as part of this release.