See gh-36565
pull/36604/head
Johnny Lim 1 year ago committed by Stephane Nicoll
parent 5cc2d3b764
commit 96c9915f12

@ -79,7 +79,7 @@ class CassandraDataAutoConfigurationIntegrationTests {
CqlSession cqlSession(CqlSessionBuilder cqlSessionBuilder) { CqlSession cqlSession(CqlSessionBuilder cqlSessionBuilder) {
try (CqlSession session = cqlSessionBuilder.build()) { try (CqlSession session = cqlSessionBuilder.build()) {
session.execute("CREATE KEYSPACE IF NOT EXISTS boot_test" session.execute("CREATE KEYSPACE IF NOT EXISTS boot_test"
+ " WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };"); + " WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };");
} }
return cqlSessionBuilder.withKeyspace("boot_test").build(); return cqlSessionBuilder.withKeyspace("boot_test").build();
} }

@ -26,7 +26,7 @@ To enable it, add the `io.r2dbc:r2dbc-proxy` dependency to your project.
[[actuator.observability.common-key-values]] [[actuator.observability.common-key-values]]
=== 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. 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] [source,yaml,indent=0,subs="verbatim",configprops,configblocks]
---- ----
@ -50,15 +50,15 @@ If you'd like to prevent some observations from being reported, you can use the
observations: observations:
enable: enable:
denied: denied:
prefix: false prefix: false
another: another:
denied: denied:
prefix: false prefix: false
---- ----
The preceding example will prevent all observations with a name starting with `denied.prefix` or `another.denied.prefix`. 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`. 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. Observations are only reported if all the `ObservationPredicate` beans return `true` for that observation.

@ -91,7 +91,7 @@ class DataCassandraTestIntegrationTests {
CqlSession cqlSession(CqlSessionBuilder cqlSessionBuilder) { CqlSession cqlSession(CqlSessionBuilder cqlSessionBuilder) {
try (CqlSession session = cqlSessionBuilder.build()) { try (CqlSession session = cqlSessionBuilder.build()) {
session.execute("CREATE KEYSPACE IF NOT EXISTS boot_test" session.execute("CREATE KEYSPACE IF NOT EXISTS boot_test"
+ " WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };"); + " WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };");
} }
return cqlSessionBuilder.withKeyspace("boot_test").build(); return cqlSessionBuilder.withKeyspace("boot_test").build();
} }

@ -77,7 +77,7 @@ class DataCassandraTestWithIncludeFilterIntegrationTests {
CqlSession cqlSession(CqlSessionBuilder cqlSessionBuilder) { CqlSession cqlSession(CqlSessionBuilder cqlSessionBuilder) {
try (CqlSession session = cqlSessionBuilder.build()) { try (CqlSession session = cqlSessionBuilder.build()) {
session.execute("CREATE KEYSPACE IF NOT EXISTS boot_test" session.execute("CREATE KEYSPACE IF NOT EXISTS boot_test"
+ " WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };"); + " WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };");
} }
return cqlSessionBuilder.withKeyspace("boot_test").build(); return cqlSessionBuilder.withKeyspace("boot_test").build();
} }

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

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

@ -80,7 +80,7 @@ class SampleCassandraApplicationReactiveSslTests {
CqlSession cqlSession(CqlSessionBuilder cqlSessionBuilder) { CqlSession cqlSession(CqlSessionBuilder cqlSessionBuilder) {
try (CqlSession session = cqlSessionBuilder.build()) { try (CqlSession session = cqlSessionBuilder.build()) {
session.execute("CREATE KEYSPACE IF NOT EXISTS boot_test" session.execute("CREATE KEYSPACE IF NOT EXISTS boot_test"
+ " WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };"); + " WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };");
} }
return cqlSessionBuilder.withKeyspace("boot_test").build(); return cqlSessionBuilder.withKeyspace("boot_test").build();
} }

@ -80,7 +80,7 @@ class SampleCassandraApplicationSslTests {
CqlSession cqlSession(CqlSessionBuilder cqlSessionBuilder) { CqlSession cqlSession(CqlSessionBuilder cqlSessionBuilder) {
try (CqlSession session = cqlSessionBuilder.build()) { try (CqlSession session = cqlSessionBuilder.build()) {
session.execute("CREATE KEYSPACE IF NOT EXISTS boot_test" session.execute("CREATE KEYSPACE IF NOT EXISTS boot_test"
+ " WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };"); + " WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };");
} }
return cqlSessionBuilder.withKeyspace("boot_test").build(); return cqlSessionBuilder.withKeyspace("boot_test").build();
} }

Loading…
Cancel
Save