HDFS-13435. RBF: Improve the error loggings for printing the stack trace.
(cherry picked from commit c4d3636c21acaeb2b7d56d19cd4996aa25151bd1)
This commit is contained in:
parent
f06b55bbf1
commit
24bdad925e
@ -451,7 +451,7 @@ public String getNodeUsage() {
|
||||
dev = (float) Math.sqrt(dev / usages.length);
|
||||
}
|
||||
} catch (IOException e) {
|
||||
LOG.info("Cannot get the live nodes: {}", e.getMessage());
|
||||
LOG.error("Cannot get the live nodes: {}", e.getMessage());
|
||||
}
|
||||
|
||||
final Map<String, Object> innerInfo = new HashMap<>();
|
||||
|
@ -210,8 +210,7 @@ private Map<String, String> getNamenodesSubcluster(
|
||||
}
|
||||
}
|
||||
} catch (IOException ioe) {
|
||||
LOG.error("Cannot get Namenodes from the State Store: {}",
|
||||
ioe.getMessage());
|
||||
LOG.error("Cannot get Namenodes from the State Store", ioe);
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
@ -100,7 +100,7 @@ synchronized void updateStateStore() {
|
||||
LOG.debug("Router heartbeat for router {}", routerId);
|
||||
}
|
||||
} catch (IOException e) {
|
||||
LOG.error("Cannot heartbeat router {}: {}", routerId, e.getMessage());
|
||||
LOG.error("Cannot heartbeat router {}", routerId, e);
|
||||
}
|
||||
} else {
|
||||
LOG.warn("Cannot heartbeat router {}: State Store unavailable", routerId);
|
||||
@ -132,7 +132,7 @@ long getStateStoreVersion(final Class<S> clazz) {
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
LOG.error("Cannot get version for {}: {}", clazz, e.getMessage());
|
||||
LOG.error("Cannot get version for {}", clazz, e);
|
||||
}
|
||||
return version;
|
||||
}
|
||||
|
@ -1067,8 +1067,8 @@ public Object call() throws Exception {
|
||||
results.put(location, clazz.cast(result));
|
||||
} catch (CancellationException ce) {
|
||||
T loc = orderedLocations.get(i);
|
||||
String msg =
|
||||
"Invocation to \"" + loc + "\" for \"" + method + "\" timed out";
|
||||
String msg = "Invocation to \"" + loc + "\" for \""
|
||||
+ method.getMethodName() + "\" timed out";
|
||||
LOG.error(msg);
|
||||
IOException ioe = new SubClusterTimeoutException(msg);
|
||||
exceptions.put(location, ioe);
|
||||
|
@ -2248,7 +2248,7 @@ private boolean isPathAll(final String path) {
|
||||
return entry.isAll();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
LOG.error("Cannot get mount point: {}", e.getMessage());
|
||||
LOG.error("Cannot get mount point", e);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
@ -2269,7 +2269,7 @@ private boolean isPathReadOnly(final String path) {
|
||||
return true;
|
||||
}
|
||||
} catch (IOException e) {
|
||||
LOG.error("Cannot get mount point: {}", e.getMessage());
|
||||
LOG.error("Cannot get mount point", e);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
@ -2298,7 +2298,7 @@ private Map<String, Long> getMountPointDates(String path) {
|
||||
ret.put(child, entry.getDateModified());
|
||||
}
|
||||
} catch (IOException e) {
|
||||
LOG.error("Cannot get mount point: {}", e.getMessage());
|
||||
LOG.error("Cannot get mount point", e);
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
|
@ -183,7 +183,7 @@ protected void serviceInit(Configuration config) throws Exception {
|
||||
} catch (NotCompliantMBeanException e) {
|
||||
throw new RuntimeException("Bad StateStoreMBean setup", e);
|
||||
} catch (MetricsException e) {
|
||||
LOG.info("Failed to register State Store bean {}", e.getMessage());
|
||||
LOG.error("Failed to register State Store bean {}", e.getMessage());
|
||||
}
|
||||
|
||||
super.serviceInit(this.conf);
|
||||
|
@ -361,7 +361,7 @@ public <T extends BaseRecord> boolean putAll(
|
||||
try {
|
||||
writer.close();
|
||||
} catch (IOException e) {
|
||||
LOG.error("Cannot close the writer for {}", recordPathTemp);
|
||||
LOG.error("Cannot close the writer for {}", recordPathTemp, e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user