Skip to content

Commit cf31edb

Browse files
bart-vmwareTimHess
andauthored
Apply suggestions from code review
Co-authored-by: Tim Hess <[email protected]>
1 parent a009e6c commit cf31edb

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/Management/src/Endpoint/ConfigureActuatorsMiddlewareStartupFilter.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ public Action<IApplicationBuilder> Configure(Action<IApplicationBuilder> next)
5252
if (beforeMiddlewareCount != afterMiddlewareCount)
5353
{
5454
_logger.LogWarning(
55-
"Your app adds custom middleware to the pipeline, while actuators were registered to auto-perform middleware setup. This combination is usually undesired. " +
56-
"To correct this, either remove your middleware setup code, or register actuators by setting their configureMiddleware parameter to false.");
55+
"Actuators were registered with automatic middleware setup, and at least one additional middleware was registered afterward. This combination is usually undesired. " +
56+
"To remove this warning, either remove the additional middleware registration or set configureMiddleware to false when registering actuators.");
5757
}
5858

5959
app.UseActuatorEndpoints();

src/Management/test/Endpoint.Test/Actuators/All/AllActuatorsTest.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ public async Task Logs_warning_when_custom_middleware_is_registered_without_conf
151151
await host.StartAsync(TestContext.Current.CancellationToken);
152152

153153
capturingLoggerProvider.GetAll().Should().Contain($"WARN {typeof(ConfigureActuatorsMiddlewareStartupFilter)}: " +
154-
"Your app adds custom middleware to the pipeline, while actuators were registered to auto-perform middleware setup. This combination is usually undesired. " +
155-
"To correct this, either remove your middleware setup code, or register actuators by setting their configureMiddleware parameter to false.");
154+
"Actuators were registered with automatic middleware setup, and at least one additional middleware was registered afterward. This combination is usually undesired. " +
155+
"To remove this warning, either remove the additional middleware registration or set configureMiddleware to false when registering actuators.");
156156
}
157157
}

0 commit comments

Comments
 (0)