You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zeppelin.apache.org by GitBox <gi...@apache.org> on 2022/01/27 03:31:14 UTC

[GitHub] [zeppelin] zjffdu commented on a change in pull request #4288: [ZEPPELIN-5632] zeppelin-zengine: Skip load notebook when it is damaged.

zjffdu commented on a change in pull request #4288:
URL: https://github.com/apache/zeppelin/pull/4288#discussion_r793226376



##########
File path: zeppelin-zengine/src/main/java/org/apache/zeppelin/notebook/NoteManager.java
##########
@@ -78,8 +78,8 @@ private void init() throws IOException {
         {
           try {
             addOrUpdateNoteNode(new Note(new NoteInfo(entry.getKey(), entry.getValue())));
-          } catch (IOException e) {
-            LOGGER.warn(e.getMessage());
+          } catch (Throwable e) {
+            LOGGER.warn("addOrUpdateNoteNode Fail: {}", entry.getKey() + " - " + e.getMessage(), e);

Review comment:
       I think it is better to catch the exception and log the warning when invoking NotebookRepos#get

##########
File path: zeppelin-zengine/src/main/java/org/apache/zeppelin/notebook/NoteManager.java
##########
@@ -78,8 +78,8 @@ private void init() throws IOException {
         {
           try {
             addOrUpdateNoteNode(new Note(new NoteInfo(entry.getKey(), entry.getValue())));
-          } catch (IOException e) {
-            LOGGER.warn(e.getMessage());
+          } catch (Throwable e) {
+            LOGGER.warn("addOrUpdateNoteNode Fail: {}", entry.getKey() + " - " + e.getMessage(), e);

Review comment:
       And please rebase your PR first.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@zeppelin.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org