WebApi
WebApi copied to clipboard
[feature/netcore] ODataOutputFormatter throws service not found exception.
Requests for non-OData routes causes 500 w/ InvalidOperationException exception.
Assemblies affected
NetCore 7.0 from MYGet
Reproduce steps
Create an ODataRoute and a non-ODataRoute, request a response form the non-ODataRoute.
Expected result
Route works as expected.
Actual result
`An unhandled exception occurred while processing the request. InvalidOperationException: No service for type 'Microsoft.AspNet.OData.Formatter.Serialization.ODataSerializerProvider' has been registered. Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType)