diff --git a/src/Microsoft.AspNet.Routing/Logging/LoggerExtensions.cs b/src/Microsoft.AspNet.Routing/Logging/LoggerExtensions.cs index b0bea0e851..6b9ccf2155 100644 --- a/src/Microsoft.AspNet.Routing/Logging/LoggerExtensions.cs +++ b/src/Microsoft.AspNet.Routing/Logging/LoggerExtensions.cs @@ -9,7 +9,7 @@ namespace Microsoft.AspNet.Routing.Logging.Internal { public static void WriteValues([NotNull] this ILogger logger, object values) { - logger.Write( + logger.Log( logLevel: LogLevel.Verbose, eventId: 0, state: values, diff --git a/src/Microsoft.AspNet.Routing/RouteCollection.cs b/src/Microsoft.AspNet.Routing/RouteCollection.cs index 2a85f426de..4afb95591c 100644 --- a/src/Microsoft.AspNet.Routing/RouteCollection.cs +++ b/src/Microsoft.AspNet.Routing/RouteCollection.cs @@ -229,7 +229,7 @@ namespace Microsoft.AspNet.Routing if (_logger == null) { var factory = context.RequestServices.GetRequiredService(); - _logger = factory.Create(); + _logger = factory.CreateLogger(); } } diff --git a/src/Microsoft.AspNet.Routing/RouterMiddleware.cs b/src/Microsoft.AspNet.Routing/RouterMiddleware.cs index 46f357cbc6..545dc7491f 100644 --- a/src/Microsoft.AspNet.Routing/RouterMiddleware.cs +++ b/src/Microsoft.AspNet.Routing/RouterMiddleware.cs @@ -29,7 +29,7 @@ namespace Microsoft.AspNet.Builder _services = services; _router = router; - _logger = loggerFactory.Create(); + _logger = loggerFactory.CreateLogger(); } public async Task Invoke(HttpContext httpContext) diff --git a/src/Microsoft.AspNet.Routing/Template/TemplateRoute.cs b/src/Microsoft.AspNet.Routing/Template/TemplateRoute.cs index 6d706061c6..d0269f55f6 100644 --- a/src/Microsoft.AspNet.Routing/Template/TemplateRoute.cs +++ b/src/Microsoft.AspNet.Routing/Template/TemplateRoute.cs @@ -363,8 +363,8 @@ namespace Microsoft.AspNet.Routing.Template if (_logger == null) { var factory = context.RequestServices.GetRequiredService(); - _logger = factory.Create(); - _constraintLogger = factory.Create(typeof(RouteConstraintMatcher).FullName); + _logger = factory.CreateLogger(); + _constraintLogger = factory.CreateLogger(typeof(RouteConstraintMatcher).FullName); } } diff --git a/test/Microsoft.AspNet.Routing.Tests/Logging/NullLogger.cs b/test/Microsoft.AspNet.Routing.Tests/Logging/NullLogger.cs index 3b2d7ad971..59b3867fd3 100644 --- a/test/Microsoft.AspNet.Routing.Tests/Logging/NullLogger.cs +++ b/test/Microsoft.AspNet.Routing.Tests/Logging/NullLogger.cs @@ -15,7 +15,7 @@ namespace Microsoft.AspNet.Routing return NullDisposable.Instance; } - public void Write(LogLevel logLevel, int eventId, object state, Exception exception, Func formatter) + public void Log(LogLevel logLevel, int eventId, object state, Exception exception, Func formatter) { } diff --git a/test/Microsoft.AspNet.Routing.Tests/Logging/NullLoggerFactory.cs b/test/Microsoft.AspNet.Routing.Tests/Logging/NullLoggerFactory.cs index 060482c200..bf65ab225d 100644 --- a/test/Microsoft.AspNet.Routing.Tests/Logging/NullLoggerFactory.cs +++ b/test/Microsoft.AspNet.Routing.Tests/Logging/NullLoggerFactory.cs @@ -11,7 +11,7 @@ namespace Microsoft.AspNet.Routing public static NullLoggerFactory Instance = new NullLoggerFactory(); - public ILogger Create(string name) + public ILogger CreateLogger(string name) { return NullLogger.Instance; }