From ff3482714844e5de61a2195f3278c2dc8032069d Mon Sep 17 00:00:00 2001 From: Tom DeVoe Date: Thu, 22 Feb 2018 10:29:41 -0500 Subject: [PATCH] fix #63 - don't try to log connection data on non-2xx requests --- .../java/metrics_influxdb/measurements/HttpInlinerSender.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/metrics_influxdb/measurements/HttpInlinerSender.java b/src/main/java/metrics_influxdb/measurements/HttpInlinerSender.java index 6f2e9e6..3f62212 100644 --- a/src/main/java/metrics_influxdb/measurements/HttpInlinerSender.java +++ b/src/main/java/metrics_influxdb/measurements/HttpInlinerSender.java @@ -78,7 +78,7 @@ protected boolean doSend(Collection measures) { LOGGER.info("{} Measures sent to {}://{}:{} but not saved by infludb, reason:\n{}", measures.size(), writeURL.getProtocol(), writeURL.getHost(), writeURL.getPort(), Miscellaneous.readFrom(con.getInputStream())); break; default: - LOGGER.info("failed to send {} Measures to {}://{}:{}, HTTP CODE received: {}\n", measures.size(), writeURL.getProtocol(), writeURL.getHost(), writeURL.getPort(), responseCode, Miscellaneous.readFrom(con.getInputStream())); + LOGGER.info("failed to send {} Measures to {}://{}:{}, HTTP CODE received: {}\n", measures.size(), writeURL.getProtocol(), writeURL.getHost(), writeURL.getPort(), responseCode); break; }