flink-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From se...@apache.org
Subject [12/12] flink git commit: [FLINK-5307] [metrics] Log reporter configuration
Date Wed, 14 Dec 2016 12:10:19 GMT
[FLINK-5307] [metrics] Log reporter configuration

This closes #2979


Project: http://git-wip-us.apache.org/repos/asf/flink/repo
Commit: http://git-wip-us.apache.org/repos/asf/flink/commit/22a82041
Tree: http://git-wip-us.apache.org/repos/asf/flink/tree/22a82041
Diff: http://git-wip-us.apache.org/repos/asf/flink/diff/22a82041

Branch: refs/heads/master
Commit: 22a8204138fdb73115d9501b34a8867a2c4608c6
Parents: a4ff480
Author: zentol <chesnay@apache.org>
Authored: Fri Dec 9 13:25:11 2016 +0100
Committer: Stephan Ewen <sewen@apache.org>
Committed: Wed Dec 14 12:43:33 2016 +0100

----------------------------------------------------------------------
 .../java/org/apache/flink/metrics/ganglia/GangliaReporter.java    | 2 ++
 .../java/org/apache/flink/metrics/graphite/GraphiteReporter.java  | 1 +
 .../src/main/java/org/apache/flink/metrics/jmx/JMXReporter.java   | 1 +
 .../main/java/org/apache/flink/metrics/statsd/StatsDReporter.java | 3 +--
 .../java/org/apache/flink/runtime/metrics/MetricRegistry.java     | 1 +
 5 files changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flink/blob/22a82041/flink-metrics/flink-metrics-ganglia/src/main/java/org/apache/flink/metrics/ganglia/GangliaReporter.java
----------------------------------------------------------------------
diff --git a/flink-metrics/flink-metrics-ganglia/src/main/java/org/apache/flink/metrics/ganglia/GangliaReporter.java
b/flink-metrics/flink-metrics-ganglia/src/main/java/org/apache/flink/metrics/ganglia/GangliaReporter.java
index 15176a3..de9da74 100644
--- a/flink-metrics/flink-metrics-ganglia/src/main/java/org/apache/flink/metrics/ganglia/GangliaReporter.java
+++ b/flink-metrics/flink-metrics-ganglia/src/main/java/org/apache/flink/metrics/ganglia/GangliaReporter.java
@@ -71,6 +71,8 @@ public class GangliaReporter extends ScheduledDropwizardReporter {
 			builder.withDMax(dMax);
 			builder.withTMax(tMax);
 
+			log.info("Configured GangliaReporter with {host:{}, port:{}, dmax:{}, tmax:{}, ttl:{},
addressingMode:{}}",
+				host, port, dMax, tMax, ttl, addressingMode);			
 			return builder.build(gMetric);
 		} catch (IOException e) {
 			throw new RuntimeException("Error while instantiating GangliaReporter.", e);

http://git-wip-us.apache.org/repos/asf/flink/blob/22a82041/flink-metrics/flink-metrics-graphite/src/main/java/org/apache/flink/metrics/graphite/GraphiteReporter.java
----------------------------------------------------------------------
diff --git a/flink-metrics/flink-metrics-graphite/src/main/java/org/apache/flink/metrics/graphite/GraphiteReporter.java
b/flink-metrics/flink-metrics-graphite/src/main/java/org/apache/flink/metrics/graphite/GraphiteReporter.java
index 038bc3f..47a9d87 100644
--- a/flink-metrics/flink-metrics-graphite/src/main/java/org/apache/flink/metrics/graphite/GraphiteReporter.java
+++ b/flink-metrics/flink-metrics-graphite/src/main/java/org/apache/flink/metrics/graphite/GraphiteReporter.java
@@ -75,6 +75,7 @@ public class GraphiteReporter extends ScheduledDropwizardReporter {
 			prot = Protocol.TCP;
 		}
 
+		log.info("Configured GraphiteReporter with {host:{}, port:{}, protocol:{}}", host, port,
prot);
 		switch(prot) {
 			case UDP:
 				return builder.build(new GraphiteUDP(host, port));				

http://git-wip-us.apache.org/repos/asf/flink/blob/22a82041/flink-metrics/flink-metrics-jmx/src/main/java/org/apache/flink/metrics/jmx/JMXReporter.java
----------------------------------------------------------------------
diff --git a/flink-metrics/flink-metrics-jmx/src/main/java/org/apache/flink/metrics/jmx/JMXReporter.java
b/flink-metrics/flink-metrics-jmx/src/main/java/org/apache/flink/metrics/jmx/JMXReporter.java
index 7186d30..f0c0fcb 100644
--- a/flink-metrics/flink-metrics-jmx/src/main/java/org/apache/flink/metrics/jmx/JMXReporter.java
+++ b/flink-metrics/flink-metrics-jmx/src/main/java/org/apache/flink/metrics/jmx/JMXReporter.java
@@ -127,6 +127,7 @@ public class JMXReporter implements MetricReporter {
 				throw new RuntimeException("Could not start JMX server on any configured port. Ports:
" + portsConfig);
 			}
 		}
+		LOG.info("Configured JMXReporter with {port:{}}", portsConfig);
 	}
 
 	@Override

http://git-wip-us.apache.org/repos/asf/flink/blob/22a82041/flink-metrics/flink-metrics-statsd/src/main/java/org/apache/flink/metrics/statsd/StatsDReporter.java
----------------------------------------------------------------------
diff --git a/flink-metrics/flink-metrics-statsd/src/main/java/org/apache/flink/metrics/statsd/StatsDReporter.java
b/flink-metrics/flink-metrics-statsd/src/main/java/org/apache/flink/metrics/statsd/StatsDReporter.java
index 977d1b4..42fe6a5 100644
--- a/flink-metrics/flink-metrics-statsd/src/main/java/org/apache/flink/metrics/statsd/StatsDReporter.java
+++ b/flink-metrics/flink-metrics-statsd/src/main/java/org/apache/flink/metrics/statsd/StatsDReporter.java
@@ -72,8 +72,6 @@ public class StatsDReporter extends AbstractReporter implements Scheduled
{
 
 		this.address = new InetSocketAddress(host, port);
 
-		LOG.info("Starting StatsDReporter to send metric reports to " + address);
-
 //		String conversionRate = config.getString(ARG_CONVERSION_RATE, "SECONDS");
 //		String conversionDuration = config.getString(ARG_CONVERSION_DURATION, "MILLISECONDS");
 //		this.rateFactor = TimeUnit.valueOf(conversionRate).toSeconds(1);
@@ -84,6 +82,7 @@ public class StatsDReporter extends AbstractReporter implements Scheduled
{
 		} catch (SocketException e) {
 			throw new RuntimeException("Could not create datagram socket. ", e);
 		}
+		log.info("Configured StatsDReporter with {host:{}, port:{}}", host, port);
 	}
 
 	@Override

http://git-wip-us.apache.org/repos/asf/flink/blob/22a82041/flink-runtime/src/main/java/org/apache/flink/runtime/metrics/MetricRegistry.java
----------------------------------------------------------------------
diff --git a/flink-runtime/src/main/java/org/apache/flink/runtime/metrics/MetricRegistry.java
b/flink-runtime/src/main/java/org/apache/flink/runtime/metrics/MetricRegistry.java
index f4510db..d3b21fc 100644
--- a/flink-runtime/src/main/java/org/apache/flink/runtime/metrics/MetricRegistry.java
+++ b/flink-runtime/src/main/java/org/apache/flink/runtime/metrics/MetricRegistry.java
@@ -116,6 +116,7 @@ public class MetricRegistry {
 
 					MetricConfig metricConfig = new MetricConfig();
 					reporterConfig.addAllToProperties(metricConfig);
+					LOG.info("Configuring {} with {}.", reporterClass.getSimpleName(), metricConfig);
 					reporterInstance.open(metricConfig);
 
 					if (reporterInstance instanceof Scheduled) {


Mime
View raw message