Browse Source

[Bug] [Task] SQL task no exception stack trace in task log (#10656)

3.0.0/version-upgrade
zhuxt2015 2 years ago committed by caishunfeng
parent
commit
cb14726bdd
  1. 1
      dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java
  2. 2
      dolphinscheduler-task-plugin/dolphinscheduler-task-sql/src/main/java/org/apache/dolphinscheduler/plugin/task/sql/SqlTask.java

1
dolphinscheduler-task-plugin/dolphinscheduler-task-datax/src/main/java/org/apache/dolphinscheduler/plugin/task/datax/DataxTask.java

@ -167,6 +167,7 @@ public class DataxTask extends AbstractTaskExecutor {
setAppIds(commandExecuteResult.getAppIds()); setAppIds(commandExecuteResult.getAppIds());
setProcessId(commandExecuteResult.getProcessId()); setProcessId(commandExecuteResult.getProcessId());
} catch (Exception e) { } catch (Exception e) {
logger.error("datax task error", e);
setExitStatusCode(EXIT_CODE_FAILURE); setExitStatusCode(EXIT_CODE_FAILURE);
throw e; throw e;
} }

2
dolphinscheduler-task-plugin/dolphinscheduler-task-sql/src/main/java/org/apache/dolphinscheduler/plugin/task/sql/SqlTask.java

@ -161,7 +161,7 @@ public class SqlTask extends AbstractTaskExecutor {
} catch (Exception e) { } catch (Exception e) {
setExitStatusCode(TaskConstants.EXIT_CODE_FAILURE); setExitStatusCode(TaskConstants.EXIT_CODE_FAILURE);
logger.error("sql task error: {}", e.toString()); logger.error("sql task error", e);
throw e; throw e;
} }
} }

Loading…
Cancel
Save