kkhatua commented on a change in pull request #1644: DRILL-7036: Improve UI for 
alert and error messages
URL: https://github.com/apache/drill/pull/1644#discussion_r258650932
 
 

 ##########
 File path: 
exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/LogsResources.java
 ##########
 @@ -96,8 +96,13 @@ public Viewable getLogs() {
   @Path("/log/{name}/content")
   @Produces(MediaType.TEXT_HTML)
   public Viewable getLog(@PathParam("name") String name) throws IOException {
-    LogContent content = getLogJSON(name);
-    return ViewableWithPermissions.create(authEnabled.get(), 
"/rest/logs/log.ftl", sc, content);
+    try {
+      LogContent content = getLogJSON(name);
+      return ViewableWithPermissions.create(authEnabled.get(), 
"/rest/logs/log.ftl", sc, content);
+    } catch (Exception | Error e) {
 
 Review comment:
   I suspect the `catch` block is meant to handle all unforeseen exceptions and 
errors. I'm simply passing this as is for Freemarker to render.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to