Fix usage of management.server.add-application-context-header
Closes gh-12190
This commit is contained in:
parent
976a23d977
commit
e1fd9df7b9
|
@ -56,8 +56,7 @@ public class ManagementServerProperties implements SecurityPrerequisite {
|
|||
private Ssl ssl;
|
||||
|
||||
/**
|
||||
* Add the "X-Application-Context" HTTP header in each response. Requires a custom
|
||||
* management.server.port.
|
||||
* Add the "X-Application-Context" HTTP header in each response.
|
||||
*/
|
||||
private boolean addApplicationContextHeader = false;
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2012-2017 the original author or authors.
|
||||
* Copyright 2012-2018 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -55,7 +55,7 @@ public class ServletManagementContextAutoConfiguration {
|
|||
// Put Servlets and Filters in their own nested class so they don't force early
|
||||
// instantiation of ManagementServerProperties.
|
||||
@Configuration
|
||||
@ConditionalOnProperty(prefix = "management", name = "add-application-context-header", havingValue = "true")
|
||||
@ConditionalOnProperty(prefix = "management.server", name = "add-application-context-header", havingValue = "true")
|
||||
protected static class ApplicationContextFilterConfiguration {
|
||||
|
||||
@Bean
|
||||
|
|
|
@ -1123,7 +1123,7 @@ content into your application. Rather, pick only the properties that you need.
|
|||
# ----------------------------------------
|
||||
|
||||
# MANAGEMENT HTTP SERVER ({sc-spring-boot-actuator-autoconfigure}/web/server/ManagementServerProperties.{sc-ext}[ManagementServerProperties])
|
||||
management.server.add-application-context-header=false # Add the "X-Application-Context" HTTP header in each response. Requires a custom management.server.port.
|
||||
management.server.add-application-context-header=false # Add the "X-Application-Context" HTTP header in each response.
|
||||
management.server.address= # Network address to which the management endpoints should bind. Requires a custom management.server.port.
|
||||
management.server.port= # Management endpoint HTTP port (uses the same port as the application by default). Configure a different port to use management-specific SSL.
|
||||
management.server.servlet.context-path= # Management endpoint context-path (for instance, `/management`). Requires a custom management.server.port.
|
||||
|
|
Loading…
Reference in New Issue