File tree 2 files changed +5
-8
lines changed
2 files changed +5
-8
lines changed Original file line number Diff line number Diff line change 11
11
using System . Reflection ;
12
12
using System . Threading ;
13
13
using System . Threading . Tasks ;
14
+ using Microsoft . AspNetCore . Builder ;
14
15
using Microsoft . AspNetCore . Http ;
15
16
using Microsoft . AspNetCore . Http . Metadata ;
16
17
using Microsoft . Extensions . DependencyInjection ;
@@ -319,12 +320,7 @@ public static RequestDelegate BuildRequestDelegate(Delegate action)
319
320
private static void LogRequestBodyIOException ( HttpContext httpContext , IOException exception )
320
321
{
321
322
var loggerFactory = httpContext . RequestServices . GetRequiredService < ILoggerFactory > ( ) ;
322
-
323
- // REVIEW: I'm not sure how we feel about using an internal type as a category name, but this is what was done in other
324
- // internal classes like DfaMather and DefaultLinkGenerator. My main concern is if we want to use the same category for
325
- // other MapAction implementations (e.g. Roslyn source generators)
326
- var logger = loggerFactory . CreateLogger ( typeof ( MapActionExpressionTreeBuilder ) . FullName ! ) ;
327
-
323
+ var logger = loggerFactory . CreateLogger ( typeof ( MapActionEndpointRouteBuilderExtensions ) . FullName ! ) ;
328
324
Log . RequestBodyIOException ( logger , exception ) ;
329
325
}
330
326
Original file line number Diff line number Diff line change 11
11
using System . Text . Json ;
12
12
using System . Threading ;
13
13
using System . Threading . Tasks ;
14
+ using Microsoft . AspNetCore . Builder ;
14
15
using Microsoft . AspNetCore . Http ;
15
16
using Microsoft . AspNetCore . Http . Features ;
16
17
using Microsoft . AspNetCore . Http . Metadata ;
@@ -256,7 +257,7 @@ public async Task RequestDelegateLogsFromBodyIOExceptionsAsDebug()
256
257
{
257
258
var invoked = false ;
258
259
259
- var sink = new TestSink ( context => context . LoggerName == typeof ( MapActionExpressionTreeBuilder ) . FullName ) ;
260
+ var sink = new TestSink ( context => context . LoggerName == typeof ( MapActionEndpointRouteBuilderExtensions ) . FullName ) ;
260
261
var testLoggerFactory = new TestLoggerFactory ( sink , enabled : true ) ;
261
262
262
263
void TestAction ( [ FromBody ] Todo todo )
@@ -320,7 +321,7 @@ public async Task RequestDelegateLogsFromFormIOExceptionsAsDebug()
320
321
{
321
322
var invoked = false ;
322
323
323
- var sink = new TestSink ( context => context . LoggerName == typeof ( MapActionExpressionTreeBuilder ) . FullName ) ;
324
+ var sink = new TestSink ( context => context . LoggerName == typeof ( MapActionEndpointRouteBuilderExtensions ) . FullName ) ;
324
325
var testLoggerFactory = new TestLoggerFactory ( sink , enabled : true ) ;
325
326
326
327
void TestAction ( [ FromForm ] int value )
You can’t perform that action at this time.
0 commit comments