|
|
@ -37,8 +37,7 @@ import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter
|
|
|
|
* @since 1.3.0
|
|
|
|
* @since 1.3.0
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
@ConfigurationProperties("endpoints.actuator")
|
|
|
|
@ConfigurationProperties("endpoints.actuator")
|
|
|
|
public class HalJsonMvcEndpoint extends WebMvcConfigurerAdapter
|
|
|
|
public class HalJsonMvcEndpoint extends WebMvcConfigurerAdapter implements MvcEndpoint {
|
|
|
|
implements MvcEndpoint {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Endpoint URL path.
|
|
|
|
* Endpoint URL path.
|
|
|
@ -48,14 +47,14 @@ public class HalJsonMvcEndpoint extends WebMvcConfigurerAdapter
|
|
|
|
private String path;
|
|
|
|
private String path;
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Enable security on the endpoint.
|
|
|
|
* Enable the endpoint.
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
private boolean sensitive = false;
|
|
|
|
private boolean enabled = true;
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Enable the endpoint.
|
|
|
|
* Mark if the endpoint exposes sensitive information.
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
private boolean enabled = true;
|
|
|
|
private boolean sensitive = false;
|
|
|
|
|
|
|
|
|
|
|
|
private final ManagementServletContext managementServletContext;
|
|
|
|
private final ManagementServletContext managementServletContext;
|
|
|
|
|
|
|
|
|
|
|
@ -86,6 +85,14 @@ public class HalJsonMvcEndpoint extends WebMvcConfigurerAdapter
|
|
|
|
return this.path;
|
|
|
|
return this.path;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isEnabled() {
|
|
|
|
|
|
|
|
return this.enabled;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setEnabled(boolean enabled) {
|
|
|
|
|
|
|
|
this.enabled = enabled;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
@Override
|
|
|
|
public boolean isSensitive() {
|
|
|
|
public boolean isSensitive() {
|
|
|
|
return this.sensitive;
|
|
|
|
return this.sensitive;
|
|
|
@ -95,14 +102,6 @@ public class HalJsonMvcEndpoint extends WebMvcConfigurerAdapter
|
|
|
|
this.sensitive = sensitive;
|
|
|
|
this.sensitive = sensitive;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public boolean isEnabled() {
|
|
|
|
|
|
|
|
return this.enabled;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setEnabled(boolean enabled) {
|
|
|
|
|
|
|
|
this.enabled = enabled;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
@Override
|
|
|
|
public Class<? extends Endpoint<?>> getEndpointType() {
|
|
|
|
public Class<? extends Endpoint<?>> getEndpointType() {
|
|
|
|
return null;
|
|
|
|
return null;
|
|
|
|