Browse Source

Polish

See gh-36565
pull/36604/head
Johnny Lim 2 years ago committed by Stephane Nicoll
parent
commit
96c9915f12
  1. 4
      spring-boot-project/spring-boot-docs/src/docs/asciidoc/actuator/observability.adoc
  2. 1
      spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/mock/mockito/MockitoPostProcessor.java
  3. 1
      spring-boot-project/spring-boot/src/main/java/org/springframework/boot/web/embedded/tomcat/TomcatWebServer.java

4
spring-boot-project/spring-boot-docs/src/docs/asciidoc/actuator/observability.adoc

@ -26,7 +26,7 @@ To enable it, add the `io.r2dbc:r2dbc-proxy` dependency to your project. @@ -26,7 +26,7 @@ To enable it, add the `io.r2dbc:r2dbc-proxy` dependency to your project.
[[actuator.observability.common-key-values]]
=== Common Key-Values
Common key-values are generally used for dimensional drill-down on the operating environment, such as host, instance, region, stack, and others.
Commons key-values are applied to all observations as low cardinality key-values and can be configured, as the following example shows:
Common key-values are applied to all observations as low cardinality key-values and can be configured, as the following example shows:
[source,yaml,indent=0,subs="verbatim",configprops,configblocks]
----
@ -58,7 +58,7 @@ If you'd like to prevent some observations from being reported, you can use the @@ -58,7 +58,7 @@ If you'd like to prevent some observations from being reported, you can use the
The preceding example will prevent all observations with a name starting with `denied.prefix` or `another.denied.prefix`.
TIP: If you want to prevent Spring Security from reporting observations, set the property configprop:management.observations.enable.spring.security[] to `false`.
TIP: If you want to prevent Spring Security from reporting observations, set the property `management.observations.enable.spring.security` to `false`.
If you need greater control over the prevention of observations, you can register beans of type `ObservationPredicate`.
Observations are only reported if all the `ObservationPredicate` beans return `true` for that observation.

1
spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/mock/mockito/MockitoPostProcessor.java

@ -263,7 +263,6 @@ public class MockitoPostProcessor implements InstantiationAwareBeanPostProcessor @@ -263,7 +263,6 @@ public class MockitoPostProcessor implements InstantiationAwareBeanPostProcessor
}
beans.removeIf(this::isScopedTarget);
return beans;
}
private boolean isScopedTarget(String beanName) {

1
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/web/embedded/tomcat/TomcatWebServer.java

@ -344,6 +344,7 @@ public class TomcatWebServer implements WebServer { @@ -344,6 +344,7 @@ public class TomcatWebServer implements WebServer {
}
}
@Override
public void destroy() throws WebServerException {
try {
stopTomcat();

Loading…
Cancel
Save