From cbd9681e3e3d51f7811c603495634d5583fb5c48 Mon Sep 17 00:00:00 2001 From: Jon Chambers Date: Tue, 1 Jun 2021 12:10:44 -0400 Subject: [PATCH] Configure histograms and exclude high-cardinality metrics. --- .../textsecuregcm/WhisperServerService.java | 24 +++++++++++++++---- .../metrics/MetricsRequestEventListener.java | 20 ++++++++-------- 2 files changed, 30 insertions(+), 14 deletions(-) diff --git a/service/src/main/java/org/whispersystems/textsecuregcm/WhisperServerService.java b/service/src/main/java/org/whispersystems/textsecuregcm/WhisperServerService.java index 4d47e029f..98b051d98 100644 --- a/service/src/main/java/org/whispersystems/textsecuregcm/WhisperServerService.java +++ b/service/src/main/java/org/whispersystems/textsecuregcm/WhisperServerService.java @@ -39,6 +39,8 @@ import io.dropwizard.setup.Bootstrap; import io.dropwizard.setup.Environment; import io.lettuce.core.resource.ClientResources; import io.micrometer.core.instrument.Clock; +import io.micrometer.core.instrument.Meter; +import io.micrometer.core.instrument.Meter.Id; import io.micrometer.core.instrument.Metrics; import io.micrometer.core.instrument.config.MeterFilter; import io.micrometer.core.instrument.distribution.DistributionStatisticConfig; @@ -122,6 +124,7 @@ import org.whispersystems.textsecuregcm.metrics.FreeMemoryGauge; import org.whispersystems.textsecuregcm.metrics.GarbageCollectionGauges; import org.whispersystems.textsecuregcm.metrics.MaxFileDescriptorGauge; import org.whispersystems.textsecuregcm.metrics.MetricsApplicationEventListener; +import org.whispersystems.textsecuregcm.metrics.MetricsRequestEventListener; import org.whispersystems.textsecuregcm.metrics.NetworkReceivedGauge; import org.whispersystems.textsecuregcm.metrics.NetworkSentGauge; import org.whispersystems.textsecuregcm.metrics.NstatCounters; @@ -244,8 +247,13 @@ public class WhisperServerService extends Application ACCEPTABLE_DESKTOP_OS_STRINGS = Set.of("linux", "macos", "windows");