From 68574ab7e16cd85fbd177c5765fa235b6163c056 Mon Sep 17 00:00:00 2001 From: Jaime Fullaondo Date: Thu, 12 Nov 2020 02:35:15 +0100 Subject: [PATCH] [reporter] statsd: no need to reinit the statsd client every 5m --- .../org/datadog/jmxfetch/reporter/StatsdReporter.java | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/main/java/org/datadog/jmxfetch/reporter/StatsdReporter.java b/src/main/java/org/datadog/jmxfetch/reporter/StatsdReporter.java index 6cdfed65a..7d8fe1041 100644 --- a/src/main/java/org/datadog/jmxfetch/reporter/StatsdReporter.java +++ b/src/main/java/org/datadog/jmxfetch/reporter/StatsdReporter.java @@ -50,10 +50,6 @@ private void init() { protected void sendMetricPoint( String metricType, String metricName, double value, String[] tags) { - if (System.currentTimeMillis() - this.initializationTime > 300 * 1000) { - this.statsDClient.stop(); - init(); - } if (metricType.equals("monotonic_count")) { statsDClient.count(metricName, (long) value, tags); } else if (metricType.equals("histogram")) { @@ -66,10 +62,6 @@ protected void sendMetricPoint( /** Submits service check. */ public void doSendServiceCheck( String serviceCheckName, String status, String message, String[] tags) { - if (System.currentTimeMillis() - this.initializationTime > 300 * 1000) { - this.statsDClient.stop(); - init(); - } ServiceCheck sc = ServiceCheck.builder() .withName(serviceCheckName)