Skip to content

Commit

Permalink
Merge pull request #9862 from indexity-io/3.1/exception-details-in-logs
Browse files Browse the repository at this point in the history
Add exception details to some logging that lost stack traces.
  • Loading branch information
tglman authored Aug 24, 2022
2 parents e9c5c89 + 945f06b commit b0dad2b
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -473,6 +473,7 @@ public <T> T baseNetworkOperation(
.debug(
this,
"Redirecting the request from server '%s' to the server '%s' because %s",
e,
e.getFromServer(),
e.toString(),
e.getMessage());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -168,8 +168,7 @@ private void updateViews(ODatabaseDocumentInternal db) {
// When the run is finished schedule the next run.
schedule();
} catch (Exception e) {
OLogManager.instance().warn(this, "Failed to update views");
e.printStackTrace();
OLogManager.instance().warn(this, "Failed to update views", e);
}
}

Expand Down Expand Up @@ -424,7 +423,8 @@ private List<OIndex> createNewIndexesForView(
}
return result;
} catch (Exception e) {
e.printStackTrace();
OLogManager.instance()
.warn(this, "Failed to create new indexes for view %s", e, view.getName());
return null;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ public static boolean sendResponseBack(
sender,
OUT,
"Error on sending response '%s' back (reqId=%s err=%s)",
e,
response,
iRequestId,
e.toString());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1663,6 +1663,7 @@ protected void installNewDatabasesFromCluster() {
null,
DIRECTION.IN,
"Error on installing database '%s' on local node (error=%s)",
e,
databaseName,
e.toString());
}
Expand Down

0 comments on commit b0dad2b

Please sign in to comment.