Author: ctubbsii Date: Fri Jan 25 17:05:35 2013 New Revision: 1438593 URL: http://svn.apache.org/viewvc?rev=1438593&view=rev Log: ACCUMULO-692 Updated log message to show the host:port when failing to connect to garbage collector.
Modified: accumulo/trunk/server/src/main/java/org/apache/accumulo/server/monitor/Monitor.java Modified: accumulo/trunk/server/src/main/java/org/apache/accumulo/server/monitor/Monitor.java URL: http://svn.apache.org/viewvc/accumulo/trunk/server/src/main/java/org/apache/accumulo/server/monitor/Monitor.java?rev=1438593&r1=1438592&r2=1438593&view=diff ============================================================================== --- accumulo/trunk/server/src/main/java/org/apache/accumulo/server/monitor/Monitor.java (original) +++ accumulo/trunk/server/src/main/java/org/apache/accumulo/server/monitor/Monitor.java Fri Jan 25 17:05:35 2013 @@ -415,6 +415,7 @@ public class Monitor { private static GCStatus fetchGcStatus() { GCStatus result = null; + InetSocketAddress address = null; try { // Read the gc location from its lock Instance instance = HdfsZooInstance.getInstance(); @@ -429,7 +430,7 @@ public class Monitor { List<String> locks = zk.getChildren(path, null); if (locks != null && locks.size() > 0) { Collections.sort(locks); - InetSocketAddress address = new ServerServices(new String(zk.getData(path + "/" + locks.get(0), null, null))).getAddress(Service.GC_CLIENT); + address = new ServerServices(new String(zk.getData(path + "/" + locks.get(0), null, null))).getAddress(Service.GC_CLIENT); GCMonitorService.Client client = ThriftUtil.getClient(new GCMonitorService.Client.Factory(), address, config.getConfiguration()); try { result = client.getStatus(Tracer.traceInfo(), SecurityConstants.getThriftSystemCredentials()); @@ -441,7 +442,7 @@ public class Monitor { zk.close(); } } catch (Exception ex) { - log.warn("Unable to contact the garbage collector", ex); + log.warn("Unable to contact the garbage collector at " + address, ex); } return result; }