Class ManagementServerProperties
- java.lang.Object
- org.springframework.boot.actuate.autoconfigure.ManagementServerProperties
- All Implemented Interfaces:
org.springframework.boot.autoconfigure.security.SecurityPrerequisite
@ConfigurationProperties(prefix="management", ignoreUnknownFields=true) public class ManagementServerProperties extends Object implements org.springframework.boot.autoconfigure.security.SecurityPrerequisite
Properties for the management server (e.g. port and path settings).- See Also:
ServerProperties
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ManagementServerProperties.Security
Security configuration.static class
ManagementServerProperties.SessionCreationPolicy
Field Summary
Fields Modifier and Type Field Description static int
ACCESS_OVERRIDE_ORDER
Order before the basic authentication access control provided automatically for the management endpoints.static int
BASIC_AUTH_ORDER
Order applied to the WebSecurityConfigurerAdapter that is used to configure basic authentication for management endpoints.
Constructor Summary
Constructors Constructor Description ManagementServerProperties()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
getAddApplicationContextHeader()
InetAddress
getAddress()
String
getContextPath()
Return the context path with no trailing slash (i.e.Integer
getPort()
Returns the management port ornull
if theserver port
should be used.ManagementServerProperties.Security
getSecurity()
org.springframework.boot.context.embedded.Ssl
getSsl()
void
setAddApplicationContextHeader(boolean addApplicationContextHeader)
void
setAddress(InetAddress address)
void
setContextPath(String contextPath)
void
setPort(Integer port)
Sets the port of the management server, usenull
if theserver port
should be used.void
setSsl(org.springframework.boot.context.embedded.Ssl ssl)
Field Detail
BASIC_AUTH_ORDER
public static final int BASIC_AUTH_ORDER
Order applied to the WebSecurityConfigurerAdapter that is used to configure basic authentication for management endpoints. If you want to add your own authentication for all or some of those endpoints the best thing to do is to add your own WebSecurityConfigurerAdapter with lower order, for instance by usingACCESS_OVERRIDE_ORDER
.- See Also:
- Constant Field Values
ACCESS_OVERRIDE_ORDER
public static final int ACCESS_OVERRIDE_ORDER
Order before the basic authentication access control provided automatically for the management endpoints. This is a useful place to put user-defined access rules if you want to override the default access rules for the management endpoints. If you want to keep the default rules for management endpoints but want to override the security for the rest of the application, useSecurityProperties.ACCESS_OVERRIDE_ORDER
instead.- See Also:
- Constant Field Values
Constructor Detail
ManagementServerProperties
public ManagementServerProperties()
Method Detail
getPort
public Integer getPort()
Returns the management port ornull
if theserver port
should be used.- Returns:
- the port
- See Also:
setPort(Integer)
setPort
public void setPort(Integer port)
Sets the port of the management server, usenull
if theserver port
should be used. To disable use 0.- Parameters:
port
- the port
getSsl
public org.springframework.boot.context.embedded.Ssl getSsl()
setSsl
public void setSsl(org.springframework.boot.context.embedded.Ssl ssl)
getAddress
public InetAddress getAddress()
setAddress
public void setAddress(InetAddress address)
getContextPath
public String getContextPath()
Return the context path with no trailing slash (i.e. the '/' root context is represented as the empty string).- Returns:
- the context path (no trailing slash)
setContextPath
public void setContextPath(String contextPath)
getSecurity
public ManagementServerProperties.Security getSecurity()
getAddApplicationContextHeader
public boolean getAddApplicationContextHeader()
setAddApplicationContextHeader
public void setAddApplicationContextHeader(boolean addApplicationContextHeader)