tajo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jihoon...@apache.org
Subject [02/12] tajo git commit: TAJO-1369: Some stack trace information is missed in error/fail logging. (Contributed by navis, Committed by hyunsik)
Date Wed, 11 Mar 2015 01:21:58 GMT
TAJO-1369: Some stack trace information is missed in error/fail logging. (Contributed by navis,
Committed by hyunsik)

Closes #396


Project: http://git-wip-us.apache.org/repos/asf/tajo/repo
Commit: http://git-wip-us.apache.org/repos/asf/tajo/commit/f1aeb734
Tree: http://git-wip-us.apache.org/repos/asf/tajo/tree/f1aeb734
Diff: http://git-wip-us.apache.org/repos/asf/tajo/diff/f1aeb734

Branch: refs/heads/index_support
Commit: f1aeb734a42dfe0ab756069e5380bb253e09b45c
Parents: 6e519bc
Author: Hyunsik Choi <hyunsik@apache.org>
Authored: Fri Mar 6 00:32:23 2015 -0800
Committer: Hyunsik Choi <hyunsik@apache.org>
Committed: Fri Mar 6 00:36:13 2015 -0800

----------------------------------------------------------------------
 CHANGES                                           |  3 +++
 .../tajo/catalog/AbstractCatalogClient.java       |  4 ++--
 .../org/apache/tajo/catalog/CatalogServer.java    |  6 +++---
 .../tajo/catalog/store/AbstractDBStore.java       | 18 +++++++++---------
 .../tajo/engine/codegen/ExecutorPreCompiler.java  |  2 +-
 .../tajo/engine/function/FunctionLoader.java      |  2 +-
 .../tajo/engine/planner/global/GlobalPlanner.java |  2 +-
 .../tajo/master/QueryCoordinatorService.java      |  2 +-
 .../org/apache/tajo/master/QueryInProgress.java   |  2 +-
 .../java/org/apache/tajo/master/QueryManager.java |  2 +-
 .../java/org/apache/tajo/master/TajoMaster.java   |  4 ++--
 .../tajo/master/rm/TajoWorkerResourceManager.java |  4 ++--
 .../org/apache/tajo/querymaster/QueryMaster.java  |  4 ++--
 .../java/org/apache/tajo/querymaster/Task.java    |  2 +-
 .../org/apache/tajo/session/SessionManager.java   |  2 +-
 .../apache/tajo/util/history/HistoryWriter.java   |  2 +-
 .../apache/tajo/webapp/QueryExecutorServlet.java  |  4 ++--
 .../org/apache/tajo/worker/DeletionService.java   |  4 ++--
 .../apache/tajo/worker/ExecutionBlockContext.java |  2 +-
 .../tajo/worker/ExecutionBlockSharedResource.java |  2 +-
 .../main/java/org/apache/tajo/worker/Fetcher.java |  6 +++---
 .../apache/tajo/worker/TajoResourceAllocator.java |  2 +-
 .../main/java/org/apache/tajo/worker/Task.java    |  2 +-
 .../java/org/apache/tajo/worker/TaskRunner.java   |  2 +-
 .../tajo/worker/WorkerHeartbeatService.java       |  2 +-
 .../tajo/worker/rule/WorkerRuleProvider.java      |  2 +-
 .../java/org/apache/tajo/jdbc/JdbcConnection.java |  4 ++--
 .../java/org/apache/tajo/plan/LogicalPlanner.java |  2 +-
 .../tajo/plan/exprrewrite/EvalTreeOptimizer.java  |  2 +-
 .../tajo/pullserver/PullServerAuxService.java     |  4 ++--
 .../apache/tajo/pullserver/PullServerUtil.java    |  2 +-
 .../tajo/pullserver/TajoPullServerService.java    |  4 ++--
 .../java/org/apache/tajo/rpc/NettyServerBase.java |  2 +-
 .../org/apache/tajo/rpc/RpcConnectionPool.java    |  2 +-
 34 files changed, 57 insertions(+), 54 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/CHANGES
----------------------------------------------------------------------
diff --git a/CHANGES b/CHANGES
index 974e4d7..003ae1a 100644
--- a/CHANGES
+++ b/CHANGES
@@ -11,6 +11,9 @@ Release 0.11.0 - unreleased
 
     TAJO-527: Upgrade to Netty 4. (jihun)
 
+    TAJO-1369: Some stack trace information is missed in error/fail logging. 
+    (Contributed by navis, Committed by hyunsik)
+
   BUG FIXES
 
     TAJO-1362: Resolve findbug warnings on Tajo Core Module. (jihun)

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-catalog/tajo-catalog-client/src/main/java/org/apache/tajo/catalog/AbstractCatalogClient.java
----------------------------------------------------------------------
diff --git a/tajo-catalog/tajo-catalog-client/src/main/java/org/apache/tajo/catalog/AbstractCatalogClient.java
b/tajo-catalog/tajo-catalog-client/src/main/java/org/apache/tajo/catalog/AbstractCatalogClient.java
index 718f7d6..d8350a3 100644
--- a/tajo-catalog/tajo-catalog-client/src/main/java/org/apache/tajo/catalog/AbstractCatalogClient.java
+++ b/tajo-catalog/tajo-catalog-client/src/main/java/org/apache/tajo/catalog/AbstractCatalogClient.java
@@ -459,7 +459,7 @@ public abstract class AbstractCatalogClient implements CatalogService
{
             try {
               list.add(new FunctionDesc(response.getFunctionDesc(i)));
             } catch (ClassNotFoundException e) {
-              LOG.error(e);
+              LOG.error(e, e);
               return null;
             }
           }
@@ -753,7 +753,7 @@ public abstract class AbstractCatalogClient implements CatalogService
{
     try {
       return new FunctionDesc(descProto);
     } catch (ClassNotFoundException e) {
-      LOG.error(e);
+      LOG.error(e, e);
       throw new NoSuchFunctionException(signature, paramTypes);
     }
   }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/CatalogServer.java
----------------------------------------------------------------------
diff --git a/tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/CatalogServer.java
b/tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/CatalogServer.java
index 30b1767..c34b4d2 100644
--- a/tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/CatalogServer.java
+++ b/tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/CatalogServer.java
@@ -895,7 +895,7 @@ public class CatalogServer extends AbstractService {
       try {
         return store.existIndexByName(databaseName, indexName) ? ProtoUtil.TRUE : ProtoUtil.FALSE;
       } catch (Exception e) {
-        LOG.error(e);
+        LOG.error(e, e);
         return BoolProto.newBuilder().setValue(false).build();
       } finally {
         rlock.unlock();
@@ -916,7 +916,7 @@ public class CatalogServer extends AbstractService {
         return store.existIndexByColumn(databaseName, tableName, columnName) ?
             ProtoUtil.TRUE : ProtoUtil.FALSE;
       } catch (Exception e) {
-        LOG.error(e);
+        LOG.error(e, e);
         return BoolProto.newBuilder().setValue(false).build();
       } finally {
         rlock.unlock();
@@ -981,7 +981,7 @@ public class CatalogServer extends AbstractService {
         }
         store.dropIndex(databaseName, indexName);
       } catch (Exception e) {
-        LOG.error(e);
+        LOG.error(e, e);
       } finally {
         wlock.unlock();
       }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/AbstractDBStore.java
----------------------------------------------------------------------
diff --git a/tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/AbstractDBStore.java
b/tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/AbstractDBStore.java
index 04694b0..5c78f82 100644
--- a/tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/AbstractDBStore.java
+++ b/tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/AbstractDBStore.java
@@ -154,7 +154,7 @@ public abstract class AbstractDBStore extends CatalogConstants implements
Catalo
           try {
             dropBaseTable();
           } catch (Throwable t) {
-            LOG.error(t);
+            LOG.error(t, t);
           }
           throw ce;
         }
@@ -299,7 +299,7 @@ public abstract class AbstractDBStore extends CatalogConstants implements
Catalo
         try {
           conn.rollback();
         } catch (SQLException e) {
-          LOG.error(e);
+          LOG.error(e, e);
         }
       }
       throw new CatalogException(se);
@@ -363,7 +363,7 @@ public abstract class AbstractDBStore extends CatalogConstants implements
Catalo
         try {
           conn.rollback();
         } catch (SQLException e) {
-          LOG.error(e);
+          LOG.error(e, e);
         }
       }
       throw new CatalogException(String.format("Failed to drop tablespace \"%s\"", tableSpaceName),
se);
@@ -523,7 +523,7 @@ public abstract class AbstractDBStore extends CatalogConstants implements
Catalo
         try {
           conn.rollback();
         } catch (SQLException e) {
-          LOG.error(e);
+          LOG.error(e, e);
         }
       }
       throw new CatalogException(se);
@@ -584,7 +584,7 @@ public abstract class AbstractDBStore extends CatalogConstants implements
Catalo
         try {
           conn.rollback();
         } catch (SQLException e) {
-          LOG.error(e);
+          LOG.error(e, e);
         }
       }
       throw new CatalogException(String.format("Failed to drop database \"%s\"", databaseName),
se);
@@ -878,7 +878,7 @@ public abstract class AbstractDBStore extends CatalogConstants implements
Catalo
         try {
           conn.rollback();
         } catch (SQLException e) {
-          LOG.error(e);
+          LOG.error(e, e);
         }
       }
       throw new CatalogException(se);
@@ -946,7 +946,7 @@ public abstract class AbstractDBStore extends CatalogConstants implements
Catalo
         try {
           conn.rollback();
         } catch (SQLException e) {
-          LOG.error(e);
+          LOG.error(e, e);
         }
       }
       throw new CatalogException(se);
@@ -1292,7 +1292,7 @@ public abstract class AbstractDBStore extends CatalogConstants implements
Catalo
       try {
         conn.rollback();
       } catch (SQLException e) {
-        LOG.error(e);
+        LOG.error(e, e);
       }
     } finally {
       CatalogUtil.closeQuietly(conn);
@@ -1708,7 +1708,7 @@ public abstract class AbstractDBStore extends CatalogConstants implements
Catalo
         try {
           conn.rollback();
         } catch (SQLException e) {
-          LOG.error(e);
+          LOG.error(e, e);
         }
       }
       throw new CatalogException(se);

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/engine/codegen/ExecutorPreCompiler.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/engine/codegen/ExecutorPreCompiler.java
b/tajo-core/src/main/java/org/apache/tajo/engine/codegen/ExecutorPreCompiler.java
index 79513dc..e472ee1 100644
--- a/tajo-core/src/main/java/org/apache/tajo/engine/codegen/ExecutorPreCompiler.java
+++ b/tajo-core/src/main/java/org/apache/tajo/engine/codegen/ExecutorPreCompiler.java
@@ -85,7 +85,7 @@ public class ExecutorPreCompiler extends BasicLogicalPlanVisitor<ExecutorPreComp
         // If any compilation error occurs, it works in a fallback mode. This mode just uses
EvalNode objects
         // instead of a compiled EvalNode.
         context.compiledEval.put(key, eval);
-        LOG.warn(t);
+        LOG.warn(t, t);
       }
     }
   }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/engine/function/FunctionLoader.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/engine/function/FunctionLoader.java b/tajo-core/src/main/java/org/apache/tajo/engine/function/FunctionLoader.java
index 334a92b..3b3e7c7 100644
--- a/tajo-core/src/main/java/org/apache/tajo/engine/function/FunctionLoader.java
+++ b/tajo-core/src/main/java/org/apache/tajo/engine/function/FunctionLoader.java
@@ -177,7 +177,7 @@ public class FunctionLoader {
       try {
         function = (Function)eachClass.newInstance();
       } catch (Exception e) {
-        LOG.warn(eachClass + " cannot instantiate Function class because of " + e.getMessage());
+        LOG.warn(eachClass + " cannot instantiate Function class because of " + e.getMessage(),
e);
         continue;
       }
       String functionName = function.getClass().getAnnotation(Description.class).functionName();

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/engine/planner/global/GlobalPlanner.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/engine/planner/global/GlobalPlanner.java
b/tajo-core/src/main/java/org/apache/tajo/engine/planner/global/GlobalPlanner.java
index f3dcf86..15d8034 100644
--- a/tajo-core/src/main/java/org/apache/tajo/engine/planner/global/GlobalPlanner.java
+++ b/tajo-core/src/main/java/org/apache/tajo/engine/planner/global/GlobalPlanner.java
@@ -660,7 +660,7 @@ public class GlobalPlanner {
         throw new PlanningException("Cannot support a mix of other functions");
       }
     } catch (InternalException e) {
-      LOG.error(e);
+      LOG.error(e, e);
     }
 
     return rewritten;

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/master/QueryCoordinatorService.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/QueryCoordinatorService.java b/tajo-core/src/main/java/org/apache/tajo/master/QueryCoordinatorService.java
index 1cb3842..1b1d49e 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/QueryCoordinatorService.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/QueryCoordinatorService.java
@@ -66,7 +66,7 @@ public class QueryCoordinatorService extends AbstractService {
     try {
       server = new AsyncRpcServer(QueryCoordinatorProtocol.class, masterHandler, initIsa,
workerNum);
     } catch (Exception e) {
-      LOG.error(e);
+      LOG.error(e, e);
     }
     server.start();
     bindAddress = NetUtils.getConnectAddress(server.getListenAddress());

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/master/QueryInProgress.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/QueryInProgress.java b/tajo-core/src/main/java/org/apache/tajo/master/QueryInProgress.java
index 9e50797..bfc7b9f 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/QueryInProgress.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/QueryInProgress.java
@@ -118,7 +118,7 @@ public class QueryInProgress {
     try {
       masterContext.getHistoryWriter().appendAndFlush(queryInfo);
     } catch (Throwable e) {
-      LOG.warn(e);
+      LOG.warn(e, e);
     }
   }
 

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/master/QueryManager.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/QueryManager.java b/tajo-core/src/main/java/org/apache/tajo/master/QueryManager.java
index a502e4b..3c81540 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/QueryManager.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/QueryManager.java
@@ -135,7 +135,7 @@ public class QueryManager extends CompositeService {
       }
       return result;
     } catch (Throwable e) {
-      LOG.error(e);
+      LOG.error(e, e);
       return Lists.newArrayList();
     }
   }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/master/TajoMaster.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/TajoMaster.java b/tajo-core/src/main/java/org/apache/tajo/master/TajoMaster.java
index 6f7c5a9..371dfb4 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/TajoMaster.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/TajoMaster.java
@@ -372,7 +372,7 @@ public class TajoMaster extends CompositeService {
       try {
         haService.delete();
       } catch (Exception e) {
-        LOG.error(e);
+        LOG.error(e, e);
       }
     }
 
@@ -380,7 +380,7 @@ public class TajoMaster extends CompositeService {
       try {
         webServer.stop();
       } catch (Exception e) {
-        LOG.error(e);
+        LOG.error(e, e);
       }
     }
 

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/master/rm/TajoWorkerResourceManager.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/rm/TajoWorkerResourceManager.java
b/tajo-core/src/main/java/org/apache/tajo/master/rm/TajoWorkerResourceManager.java
index e5cf66c..0d830ea 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/rm/TajoWorkerResourceManager.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/rm/TajoWorkerResourceManager.java
@@ -221,7 +221,7 @@ public class TajoWorkerResourceManager extends CompositeService implements
Worke
     try {
       response = callFuture.get(3, TimeUnit.SECONDS);
     } catch (Throwable t) {
-      LOG.error(t);
+      LOG.error(t, t);
       return null;
     }
 
@@ -345,7 +345,7 @@ public class TajoWorkerResourceManager extends CompositeService implements
Worke
         } catch(InterruptedException ie) {
           LOG.error(ie);
         } catch (Throwable t) {
-          LOG.error(t);
+          LOG.error(t, t);
         }
       }
     }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/querymaster/QueryMaster.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/querymaster/QueryMaster.java b/tajo-core/src/main/java/org/apache/tajo/querymaster/QueryMaster.java
index bfaaca8..bf23133 100644
--- a/tajo-core/src/main/java/org/apache/tajo/querymaster/QueryMaster.java
+++ b/tajo-core/src/main/java/org/apache/tajo/querymaster/QueryMaster.java
@@ -220,7 +220,7 @@ public class QueryMaster extends CompositeService implements EventHandler
{
 
         tajoWorkerProtocolService.cleanup(null, queryId.getProto(), NullCallback.get());
       } catch (Exception e) {
-        LOG.error(e.getMessage());
+        LOG.error(e.getMessage(), e);
       } finally {
         connPool.releaseConnection(rpc);
       }
@@ -375,7 +375,7 @@ public class QueryMaster extends CompositeService implements EventHandler
{
             query.context.getQueryMasterContext().getWorkerContext().
                 getTaskHistoryWriter().appendAndFlush(queryHisory);
           } catch (Throwable e) {
-            LOG.warn(e);
+            LOG.warn(e, e);
           }
         }
       }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/querymaster/Task.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/querymaster/Task.java b/tajo-core/src/main/java/org/apache/tajo/querymaster/Task.java
index 92f4b20..1da623e 100644
--- a/tajo-core/src/main/java/org/apache/tajo/querymaster/Task.java
+++ b/tajo-core/src/main/java/org/apache/tajo/querymaster/Task.java
@@ -272,7 +272,7 @@ public class Task implements EventHandler<TaskEvent> {
         Fragment fragment = FragmentConvertor.convert(systemConf, eachFragment);
         fragmentList.add(fragment.toString());
       } catch (Exception e) {
-        LOG.error(e.getMessage());
+        LOG.error(e.getMessage(), e);
         fragmentList.add("ERROR: " + eachFragment.getStoreType() + "," + eachFragment.getId()
+ ": " + e.getMessage());
       }
     }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/session/SessionManager.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/session/SessionManager.java b/tajo-core/src/main/java/org/apache/tajo/session/SessionManager.java
index 571144b..5d66b2b 100644
--- a/tajo-core/src/main/java/org/apache/tajo/session/SessionManager.java
+++ b/tajo-core/src/main/java/org/apache/tajo/session/SessionManager.java
@@ -131,7 +131,7 @@ public class SessionManager extends CompositeService implements EventHandler<Ses
       assertSessionExistence(event.getSessionId());
       touch(event.getSessionId());
     } catch (InvalidSessionException e) {
-      LOG.error(e);
+      LOG.error(e, e);
     }
 
     if (event.getType() == SessionEventType.EXPIRE) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/util/history/HistoryWriter.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/util/history/HistoryWriter.java b/tajo-core/src/main/java/org/apache/tajo/util/history/HistoryWriter.java
index b06c7e8..f0c6c11 100644
--- a/tajo-core/src/main/java/org/apache/tajo/util/history/HistoryWriter.java
+++ b/tajo-core/src/main/java/org/apache/tajo/util/history/HistoryWriter.java
@@ -436,7 +436,7 @@ public class HistoryWriter extends AbstractService {
           try {
             holder.flush();
           } catch (IOException e) {
-            LOG.warn(e);
+            LOG.warn(e, e);
           }
         }
       }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/webapp/QueryExecutorServlet.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/webapp/QueryExecutorServlet.java b/tajo-core/src/main/java/org/apache/tajo/webapp/QueryExecutorServlet.java
index e9b6230..da7981c 100644
--- a/tajo-core/src/main/java/org/apache/tajo/webapp/QueryExecutorServlet.java
+++ b/tajo-core/src/main/java/org/apache/tajo/webapp/QueryExecutorServlet.java
@@ -95,7 +95,7 @@ public class QueryExecutorServlet extends HttpServlet {
 
       new QueryRunnerCleaner().start();
     } catch (IOException e) {
-      LOG.error(e.getMessage());
+      LOG.error(e.getMessage(), e);
     }
   }
 
@@ -469,7 +469,7 @@ public class QueryExecutorServlet extends HttpServlet {
               try {
                 tajoClient.closeQuery(queryId);
               } catch (Exception e) {
-                LOG.warn(e);
+                LOG.warn(e, e);
               }
             }
           }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/worker/DeletionService.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/worker/DeletionService.java b/tajo-core/src/main/java/org/apache/tajo/worker/DeletionService.java
index 42ea71f..b09d8d5 100644
--- a/tajo-core/src/main/java/org/apache/tajo/worker/DeletionService.java
+++ b/tajo-core/src/main/java/org/apache/tajo/worker/DeletionService.java
@@ -97,7 +97,7 @@ public class DeletionService {
         try {
           lfs.delete(subDir, true);
         } catch (IOException e) {
-          LOG.warn("Failed to delete " + subDir);
+          LOG.warn("Failed to delete " + subDir, e);
         }
         return;
       }
@@ -107,7 +107,7 @@ public class DeletionService {
         try {
           lfs.delete(del, true);
         } catch (IOException e) {
-          LOG.warn("Failed to delete " + subDir);
+          LOG.warn("Failed to delete " + subDir, e);
         }
       }
     }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/worker/ExecutionBlockContext.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/worker/ExecutionBlockContext.java b/tajo-core/src/main/java/org/apache/tajo/worker/ExecutionBlockContext.java
index 813c502..a645689 100644
--- a/tajo-core/src/main/java/org/apache/tajo/worker/ExecutionBlockContext.java
+++ b/tajo-core/src/main/java/org/apache/tajo/worker/ExecutionBlockContext.java
@@ -178,7 +178,7 @@ public class ExecutionBlockContext {
         try{
           task.abort();
         } catch (Throwable e){
-          LOG.error(e);
+          LOG.error(e, e);
         }
       }
     }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/worker/ExecutionBlockSharedResource.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/worker/ExecutionBlockSharedResource.java
b/tajo-core/src/main/java/org/apache/tajo/worker/ExecutionBlockSharedResource.java
index 67114a3..b193b24 100644
--- a/tajo-core/src/main/java/org/apache/tajo/worker/ExecutionBlockSharedResource.java
+++ b/tajo-core/src/main/java/org/apache/tajo/worker/ExecutionBlockSharedResource.java
@@ -99,7 +99,7 @@ public class ExecutionBlockSharedResource {
           LOG.warn(eval.toString() + " does not exists. Immediately compile it: " + eval);
           return compileEval(schema, eval);
         } catch (Throwable t) {
-          LOG.warn(t);
+          LOG.warn(t, t);
           return eval;
         }
       }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/worker/Fetcher.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/worker/Fetcher.java b/tajo-core/src/main/java/org/apache/tajo/worker/Fetcher.java
index fc57a96..31599a3 100644
--- a/tajo-core/src/main/java/org/apache/tajo/worker/Fetcher.java
+++ b/tajo-core/src/main/java/org/apache/tajo/worker/Fetcher.java
@@ -243,7 +243,7 @@ public class Fetcher {
             return;
           }
         } catch (Exception e) {
-          LOG.error(e.getMessage());
+          LOG.error(e.getMessage(), e);
         } finally {
           ReferenceCountUtil.release(msg);
         }
@@ -272,7 +272,7 @@ public class Fetcher {
             }
           }
         } catch (Exception e) {
-          LOG.error(e.getMessage());
+          LOG.error(e.getMessage(), e);
         } finally {
           ReferenceCountUtil.release(msg);
         }
@@ -283,7 +283,7 @@ public class Fetcher {
     public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause)
         throws Exception {
       if (cause instanceof ReadTimeoutException) {
-        LOG.warn(cause);
+        LOG.warn(cause, cause);
       } else {
         LOG.error("Fetch failed :", cause);
       }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/worker/TajoResourceAllocator.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/worker/TajoResourceAllocator.java b/tajo-core/src/main/java/org/apache/tajo/worker/TajoResourceAllocator.java
index 827c860..47a9fda 100644
--- a/tajo-core/src/main/java/org/apache/tajo/worker/TajoResourceAllocator.java
+++ b/tajo-core/src/main/java/org/apache/tajo/worker/TajoResourceAllocator.java
@@ -133,7 +133,7 @@ public class TajoResourceAllocator extends AbstractResourceAllocator {
       try {
         eachProxy.stopContainer();
       } catch (Throwable e) {
-        LOG.warn(e.getMessage());
+        LOG.warn(e.getMessage(), e);
       }
     }
 

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/worker/Task.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/worker/Task.java b/tajo-core/src/main/java/org/apache/tajo/worker/Task.java
index ef94337..524b09b 100644
--- a/tajo-core/src/main/java/org/apache/tajo/worker/Task.java
+++ b/tajo-core/src/main/java/org/apache/tajo/worker/Task.java
@@ -417,7 +417,7 @@ public class Task {
           executor.close();
           reloadInputStats();
         } catch (IOException e) {
-          LOG.error(e);
+          LOG.error(e, e);
         }
         this.executor = null;
       }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/worker/TaskRunner.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/worker/TaskRunner.java b/tajo-core/src/main/java/org/apache/tajo/worker/TaskRunner.java
index 2cdebc8..79725f6 100644
--- a/tajo-core/src/main/java/org/apache/tajo/worker/TaskRunner.java
+++ b/tajo-core/src/main/java/org/apache/tajo/worker/TaskRunner.java
@@ -126,7 +126,7 @@ public class TaskRunner extends AbstractService {
       LOG.info("TaskRunner basedir is created (" + baseDirPath +")");
     } catch (Throwable t) {
       t.printStackTrace();
-      LOG.error(t);
+      LOG.error(t, t);
     }
     super.init(conf);
     this.history.setState(getServiceState());

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/worker/WorkerHeartbeatService.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/worker/WorkerHeartbeatService.java b/tajo-core/src/main/java/org/apache/tajo/worker/WorkerHeartbeatService.java
index 462f95d..5493b37 100644
--- a/tajo-core/src/main/java/org/apache/tajo/worker/WorkerHeartbeatService.java
+++ b/tajo-core/src/main/java/org/apache/tajo/worker/WorkerHeartbeatService.java
@@ -204,7 +204,7 @@ public class WorkerHeartbeatService extends AbstractService {
         } catch (InterruptedException e) {
           break;
         } catch (TimeoutException te) {
-          LOG.warn("Heartbeat response is being delayed.");
+          LOG.warn("Heartbeat response is being delayed.", te);
         } catch (Exception e) {
           LOG.error(e.getMessage(), e);
         } finally {

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-core/src/main/java/org/apache/tajo/worker/rule/WorkerRuleProvider.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/worker/rule/WorkerRuleProvider.java b/tajo-core/src/main/java/org/apache/tajo/worker/rule/WorkerRuleProvider.java
index 4094efd..81c2522 100644
--- a/tajo-core/src/main/java/org/apache/tajo/worker/rule/WorkerRuleProvider.java
+++ b/tajo-core/src/main/java/org/apache/tajo/worker/rule/WorkerRuleProvider.java
@@ -43,7 +43,7 @@ public class WorkerRuleProvider implements SelfDiagnosisRuleProvider {
       try {
         ruleList.add(ruleClazz.newInstance());
       } catch (Exception e) {
-        LOG.warn("Cannot instantiate " + ruleClazz.getName() + " class.");
+        LOG.warn("Cannot instantiate " + ruleClazz.getName() + " class.", e);
         continue;
       }
     }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-jdbc/src/main/java/org/apache/tajo/jdbc/JdbcConnection.java
----------------------------------------------------------------------
diff --git a/tajo-jdbc/src/main/java/org/apache/tajo/jdbc/JdbcConnection.java b/tajo-jdbc/src/main/java/org/apache/tajo/jdbc/JdbcConnection.java
index 0919eee..2879540 100644
--- a/tajo-jdbc/src/main/java/org/apache/tajo/jdbc/JdbcConnection.java
+++ b/tajo-jdbc/src/main/java/org/apache/tajo/jdbc/JdbcConnection.java
@@ -276,10 +276,10 @@ public class JdbcConnection implements Connection {
         return false;
       }
     } catch (ServiceException e) {
-      LOG.error("TajoMaster is not available.");
+      LOG.error("TajoMaster is not available.", e);
       return false;
     } catch (IOException e) {
-      LOG.error("JDBC connection is not valid.");
+      LOG.error("JDBC connection is not valid.", e);
       return false;
     }
   }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-plan/src/main/java/org/apache/tajo/plan/LogicalPlanner.java
----------------------------------------------------------------------
diff --git a/tajo-plan/src/main/java/org/apache/tajo/plan/LogicalPlanner.java b/tajo-plan/src/main/java/org/apache/tajo/plan/LogicalPlanner.java
index babcb1e..14fea08 100644
--- a/tajo-plan/src/main/java/org/apache/tajo/plan/LogicalPlanner.java
+++ b/tajo-plan/src/main/java/org/apache/tajo/plan/LogicalPlanner.java
@@ -1328,7 +1328,7 @@ public class LogicalPlanner extends BaseAlgebraVisitor<LogicalPlanner.PlanContex
           }
         }
       } catch (Throwable t) {
-        LOG.warn(t);
+        LOG.warn(t, t);
       }
     }
   }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-plan/src/main/java/org/apache/tajo/plan/exprrewrite/EvalTreeOptimizer.java
----------------------------------------------------------------------
diff --git a/tajo-plan/src/main/java/org/apache/tajo/plan/exprrewrite/EvalTreeOptimizer.java
b/tajo-plan/src/main/java/org/apache/tajo/plan/exprrewrite/EvalTreeOptimizer.java
index 3bea6a4..a8a3ff3 100644
--- a/tajo-plan/src/main/java/org/apache/tajo/plan/exprrewrite/EvalTreeOptimizer.java
+++ b/tajo-plan/src/main/java/org/apache/tajo/plan/exprrewrite/EvalTreeOptimizer.java
@@ -50,7 +50,7 @@ public class EvalTreeOptimizer {
       try {
         rule = (EvalTreeOptimizationRule)eachRule.newInstance();
       } catch (Exception e) {
-        LOG.warn(eachRule + " cannot instantiate EvalTreeOptimizerRule class because of "
+ e.getMessage());
+        LOG.warn(eachRule + " cannot instantiate EvalTreeOptimizerRule class because of "
+ e.getMessage(), e);
         continue;
       }
       rules.add(rule);

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/PullServerAuxService.java
----------------------------------------------------------------------
diff --git a/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/PullServerAuxService.java
b/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/PullServerAuxService.java
index ce4018b..fba0593 100644
--- a/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/PullServerAuxService.java
+++ b/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/PullServerAuxService.java
@@ -214,7 +214,7 @@ public class PullServerAuxService extends AuxiliaryService {
       localFS = new LocalFileSystem();
       super.init(new Configuration(conf));
     } catch (Throwable t) {
-      LOG.error(t);
+      LOG.error(t, t);
     }
   }
 
@@ -269,7 +269,7 @@ public class PullServerAuxService extends AuxiliaryService {
 
       localFS.close();
     } catch (Throwable t) {
-      LOG.error(t);
+      LOG.error(t, t);
     } finally {
       super.stop();
     }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/PullServerUtil.java
----------------------------------------------------------------------
diff --git a/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/PullServerUtil.java
b/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/PullServerUtil.java
index 564950f..c90f1aa 100644
--- a/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/PullServerUtil.java
+++ b/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/PullServerUtil.java
@@ -79,7 +79,7 @@ public class PullServerUtil {
       posixFadviseIfPossible = MethodUtils.getAccessibleMethod(posixClass, "posixFadviseIfPossible",
parameters);
     } catch (Throwable e) {
       loaded = false;
-      LOG.warn("Failed to access posixFadviseIfPossible :" + e.getMessage());
+      LOG.warn("Failed to access posixFadviseIfPossible :" + e.getMessage(), e);
     }
 
     if (posixFadviseIfPossible == null) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/TajoPullServerService.java
----------------------------------------------------------------------
diff --git a/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/TajoPullServerService.java
b/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/TajoPullServerService.java
index f0dcd26..0744b9f 100644
--- a/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/TajoPullServerService.java
+++ b/tajo-pullserver/src/main/java/org/apache/tajo/pullserver/TajoPullServerService.java
@@ -223,7 +223,7 @@ public class TajoPullServerService extends AbstractService {
       super.init(conf);
       LOG.info("Tajo PullServer initialized: readaheadLength=" + readaheadLength);
     } catch (Throwable t) {
-      LOG.error(t);
+      LOG.error(t, t);
     }
   }
 
@@ -335,7 +335,7 @@ public class TajoPullServerService extends AbstractService {
 
       localFS.close();
     } catch (Throwable t) {
-      LOG.error(t);
+      LOG.error(t, t);
     } finally {
       super.stop();
     }

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-rpc/src/main/java/org/apache/tajo/rpc/NettyServerBase.java
----------------------------------------------------------------------
diff --git a/tajo-rpc/src/main/java/org/apache/tajo/rpc/NettyServerBase.java b/tajo-rpc/src/main/java/org/apache/tajo/rpc/NettyServerBase.java
index 1b45ac9..024108b 100644
--- a/tajo-rpc/src/main/java/org/apache/tajo/rpc/NettyServerBase.java
+++ b/tajo-rpc/src/main/java/org/apache/tajo/rpc/NettyServerBase.java
@@ -96,7 +96,7 @@ public class NettyServerBase {
         int port = getUnusedPort();
         serverAddr = new InetSocketAddress(initIsa.getHostName(), port);
       } catch (IOException e) {
-        LOG.error(e);
+        LOG.error(e, e);
       }
     } else {
       serverAddr = initIsa;

http://git-wip-us.apache.org/repos/asf/tajo/blob/f1aeb734/tajo-rpc/src/main/java/org/apache/tajo/rpc/RpcConnectionPool.java
----------------------------------------------------------------------
diff --git a/tajo-rpc/src/main/java/org/apache/tajo/rpc/RpcConnectionPool.java b/tajo-rpc/src/main/java/org/apache/tajo/rpc/RpcConnectionPool.java
index 4ad9771..43feeb1 100644
--- a/tajo-rpc/src/main/java/org/apache/tajo/rpc/RpcConnectionPool.java
+++ b/tajo-rpc/src/main/java/org/apache/tajo/rpc/RpcConnectionPool.java
@@ -151,7 +151,7 @@ public class RpcConnectionPool {
     try {
       accepted.close();
     } catch (Throwable t) {
-      LOG.error(t);
+      LOG.error(t, t);
     }
   }
 


Mime
View raw message