Skip to content

Commit

Permalink
[hotfix][logging] Fix various logging issues
Browse files Browse the repository at this point in the history
  • Loading branch information
ginolzh authored and zentol committed Feb 12, 2019
1 parent fc7ac3d commit 7eb4072
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ public void close() {
server.close();
}
} catch (IOException e) {
LOG.error("Failed to close socket.", e);
LOG.error("Failed to close server.", e);
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ public static <X> X deserializeFunction(RuntimeContext context, byte[] serFun) t
path,
scriptName);
} catch (Exception e) {
LOG.error("Initialization of jython failed.");

try {
LOG.error("Initialization of jython failed.", e);
throw new FlinkRuntimeException("Initialization of jython failed.", e);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ public boolean hasLeadership(@Nonnull UUID leaderSessionId) {
}

void errorOnGrantLeadership(LeaderContender contender, Throwable error) {
LOG.warn("Error notifying leader listener about new leader", error);
LOG.warn("Error granting leadership to contender", error);
contender.handleError(error instanceof Exception ? (Exception) error : new Exception(error));

synchronized (lock) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -758,7 +758,7 @@ public CompletableFuture<Acknowledge> notifyKvStateRegistered(

return CompletableFuture.completedFuture(Acknowledge.get());
} catch (Exception e) {
log.error("Failed to notify KvStateRegistry about registration {}.", registrationName);
log.error("Failed to notify KvStateRegistry about registration {}.", registrationName, e);
return FutureUtils.completedExceptionally(e);
}
} else {
Expand Down Expand Up @@ -787,7 +787,7 @@ public CompletableFuture<Acknowledge> notifyKvStateUnregistered(

return CompletableFuture.completedFuture(Acknowledge.get());
} catch (Exception e) {
log.error("Failed to notify KvStateRegistry about registration {}.", registrationName, e);
log.error("Failed to notify KvStateRegistry about unregistration {}.", registrationName, e);
return FutureUtils.completedExceptionally(e);
}
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ public ColumnFamilyOptions createColumnOptions(ColumnFamilyOptions currentOption
try {
currentOptions.close();
} catch (Exception e) {
LOG.error("Close previous DBOptions's instance failed.", e);
LOG.error("Close previous ColumnOptions's instance failed.", e);
}

return PredefinedOptions.FLASH_SSD_OPTIMIZED.createColumnOptions();
Expand Down

0 comments on commit 7eb4072

Please sign in to comment.