|
|
@@ -8,24 +8,24 @@ namespace Microsoft.AspNetCore.Routing.Logging
|
|
|
{
|
|
|
internal static class RouteConstraintMatcherExtensions
|
|
|
{
|
|
|
- private static readonly Action<ILogger, object, string, IRouteConstraint, Exception> _routeValueDoesNotMatchConstraint;
|
|
|
+ private static readonly Action<ILogger, object, string, IRouteConstraint, Exception> _constraintNotMatched;
|
|
|
|
|
|
static RouteConstraintMatcherExtensions()
|
|
|
{
|
|
|
- _routeValueDoesNotMatchConstraint = LoggerMessage.Define<object, string, IRouteConstraint>(
|
|
|
+ _constraintNotMatched = LoggerMessage.Define<object, string, IRouteConstraint>(
|
|
|
LogLevel.Debug,
|
|
|
- 1,
|
|
|
+ new EventId(1, "ConstraintNotMatched"),
|
|
|
"Route value '{RouteValue}' with key '{RouteKey}' did not match " +
|
|
|
"the constraint '{RouteConstraint}'");
|
|
|
}
|
|
|
|
|
|
- public static void RouteValueDoesNotMatchConstraint(
|
|
|
+ public static void ConstraintNotMatched(
|
|
|
this ILogger logger,
|
|
|
object routeValue,
|
|
|
string routeKey,
|
|
|
IRouteConstraint routeConstraint)
|
|
|
{
|
|
|
- _routeValueDoesNotMatchConstraint(logger, routeValue, routeKey, routeConstraint, null);
|
|
|
+ _constraintNotMatched(logger, routeValue, routeKey, routeConstraint, null);
|
|
|
}
|
|
|
}
|
|
|
}
|