Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,13 @@ public ContainerCommandResponseProto sendCommand(
// Re-interrupt the thread while catching InterruptedException
Thread.currentThread().interrupt();
} catch (ExecutionException e) {
LOG.error("Failed to execute command {}", processForDebug(request), e);
String message = "Failed to execute command {}.";
if (LOG.isDebugEnabled()) {
LOG.debug(message, processForDebug(request), e);
} else {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: You need to give space before "Exception Class".

LOG.error(message + " Exception Class: {}, Exception Message: {}",
request.getCmdType(), e.getClass().getName(), e.getMessage());
}
}
return responseProtoHashMap;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,15 @@ public synchronized int read(ByteBuffer buf) throws IOException {
throw e;
}
if (e instanceof BadDataLocationException) {
LOG.warn("Failing over to reconstruction read due to an error in " +
"ECBlockReader", e);
String message = "Failing over to reconstruction read due" +
" to an error in ECBlockReader.";
if (LOG.isDebugEnabled()) {
LOG.debug(message, e);
} else {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Give space after {}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, I see, please ignore this one. comma is out side of string. Thanks

LOG.warn("{} Exception Class: {} , Exception Message: {}",
message, e.getClass().getName(), e.getMessage());
}

failoverToReconstructionRead(
((BadDataLocationException) e).getFailedLocation(), lastPosition);
buf.reset();
Expand Down