Change default value for replaceIds (#28)

This commit is contained in:
Stephan Schnabel 2023-04-24 14:55:22 +02:00 committed by GitHub
parent 5fbeb49a61
commit a392076722
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 21 additions and 22 deletions

View file

@ -35,12 +35,12 @@ import io.micrometer.core.instrument.Counter;
import io.micrometer.core.instrument.MeterRegistry;
/**
* Test for {@link MicrometerEventListener} with Mockito.
* Test for {@link MetricsEventListener} with Mockito.
*
* @author Stephan Schnabel
*/
@ExtendWith(MockitoExtension.class)
public class MicrometerEventListenerTest {
public class MetricsEventListenerTest {
@Mock
KeycloakSession session;
@ -378,8 +378,8 @@ public class MicrometerEventListenerTest {
}
}
private MicrometerEventListener listener(boolean replace) {
return new MicrometerEventListener(registry, session, replace);
private MetricsEventListener listener(boolean replaceIds) {
return new MetricsEventListener(registry, replaceIds, session);
}
private void assertCounter(String metric, Map<String, String> tags) {

View file

@ -60,7 +60,6 @@ public class KeycloakExtension implements BeforeAllCallback, ParameterResolver {
.withEnv("KC_LOG_CONSOLE_COLOR", "true")
.withEnv("KC_HEALTH_ENABLED", "true")
.withEnv("KC_METRICS_ENABLED", "true")
.withEnv("KC_METRICS_EVENT_REPLACE_IDS", "true")
.withCopyFileToContainer(MountableFile.forHostPath(jar), "/opt/keycloak/providers/metrics.jar")
.withLogConsumer(out -> System.out.print(out.getUtf8String()))
.withExposedPorts(8080)